@djb25/digit-ui-module-wt 1.0.76 → 1.0.77
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +243 -197
- package/dist/index.js.map +1 -1
- package/dist/index.modern.js +364 -318
- package/dist/index.modern.js.map +1 -1
- package/package.json +1 -1
package/dist/index.modern.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { TickMark, ArrowDown, ViewsIcon, TextInput, MobileNumber, CardLabelError, Dropdown, DatePicker, SubmitBar, Card, Table, Loader, Modal, Toast, AppContainer, ModuleHeader, ArrowLeft, PrivateRoute, CitizenHomeCard, CHBIcon, PropertyHouse, HomeIcon, KeyNote, CardHeader, FormStep, CardLabel, RadioButtons, UploadFile, TextArea, CheckBox, CardSubHeader, StatusTable, Row, GenericFileIcon, LinkButton, EditIcon, Banner, EmployeeModuleCard, CloseSvg, Label, LinkLabel, ActionBar, DetailsCard, SearchAction, FilterAction, PopUp, ShippingTruck, CustomNameDropdown, MultiSelectDropdown, CollapsibleCardPage as CollapsibleCardPage$1, LabelFieldPair, AddIcon, ToggleSwitch, Menu, CheckSvg, LayoutWrapper, Header, TelePhone, DisplayPhotos, CardSectionHeader, CheckPoint, ConnectingCheckPoints, MultiLink, RemoveableTag, FormComposer, PDFSvg, MultiUploadWrapper, Close as Close$g, BreakLine, InfoBannerIcon, ButtonSelector, LocationIcon, PTIcon, ApplicantDetails, AddressDetails } from '@djb25/digit-ui-react-components';
|
|
2
|
-
import React, { useRef, useEffect, useState, useCallback, useMemo, Fragment, useReducer } from 'react';
|
|
1
|
+
import { TickMark, ArrowDown, ViewsIcon, TextInput, MobileNumber, CardLabelError, Dropdown, DatePicker, SubmitBar, Card, Table, Loader, Modal, Toast, AppContainer, ModuleHeader, ArrowLeft, PrivateRoute, CitizenHomeCard, CHBIcon, PropertyHouse, HomeIcon, KeyNote, CardHeader, FormStep, CardLabel, RadioButtons, UploadFile, TextArea, CheckBox, CardSubHeader, StatusTable, Row, GenericFileIcon, LinkButton, EditIcon, CardText, Banner, EmployeeModuleCard, CloseSvg, Label, LinkLabel, ActionBar, DetailsCard, SearchAction, FilterAction, PopUp, ShippingTruck, CustomNameDropdown, MultiSelectDropdown, CollapsibleCardPage as CollapsibleCardPage$1, LabelFieldPair, AddIcon, ToggleSwitch, Menu, CheckSvg, LayoutWrapper, Header, TelePhone, DisplayPhotos, CardSectionHeader, CheckPoint, ConnectingCheckPoints, MultiLink, RemoveableTag, FormComposer, PDFSvg, MultiUploadWrapper, Close as Close$g, BreakLine, InfoBannerIcon, ButtonSelector, LocationIcon, PTIcon, ApplicantDetails, AddressDetails } from '@djb25/digit-ui-react-components';
|
|
2
|
+
import React, { useRef, useEffect as useEffect$1, useState, useCallback, useMemo, Fragment, useReducer } from 'react';
|
|
3
3
|
import { useTranslation } from 'react-i18next';
|
|
4
4
|
import { useLocation, useRouteMatch, useHistory, Switch, Route, Redirect, Link, useParams } from 'react-router-dom';
|
|
5
5
|
import { useQueryClient } from 'react-query';
|
|
@@ -380,7 +380,7 @@ const WTCreate = () => {
|
|
|
380
380
|
const formStepRoutes = ["applicant-details", "address-details", "request-details", "toiletRequest-details", "treePruningRequest-details"];
|
|
381
381
|
const isFormStep = formStepRoutes.some(route => pathname.includes(route));
|
|
382
382
|
const sectionRefs = useRef({});
|
|
383
|
-
useEffect(() => {
|
|
383
|
+
useEffect$1(() => {
|
|
384
384
|
if (isFormStep) {
|
|
385
385
|
const currentRoute = pathname.split("/").pop();
|
|
386
386
|
if (sectionRefs.current[currentRoute]) {
|
|
@@ -1591,7 +1591,7 @@ const SearchApp = _ref => {
|
|
|
1591
1591
|
setPayload(payload);
|
|
1592
1592
|
}
|
|
1593
1593
|
}
|
|
1594
|
-
useEffect(() => {
|
|
1594
|
+
useEffect$1(() => {
|
|
1595
1595
|
if (showToast) {
|
|
1596
1596
|
const timer = setTimeout(() => {
|
|
1597
1597
|
setShowToast(null);
|
|
@@ -1962,7 +1962,7 @@ const ExistingBookingDetails = _ref => {
|
|
|
1962
1962
|
setExistingDataSet(newSessionData);
|
|
1963
1963
|
setIsDataSet(true);
|
|
1964
1964
|
};
|
|
1965
|
-
useEffect(() => {
|
|
1965
|
+
useEffect$1(() => {
|
|
1966
1966
|
const submitCallback = () => {
|
|
1967
1967
|
if (isDataSet) {
|
|
1968
1968
|
onSubmit();
|
|
@@ -1979,7 +1979,7 @@ const ExistingBookingDetails = _ref => {
|
|
|
1979
1979
|
offset: paginationOffset,
|
|
1980
1980
|
tenantId
|
|
1981
1981
|
};
|
|
1982
|
-
useEffect(() => {
|
|
1982
|
+
useEffect$1(() => {
|
|
1983
1983
|
setFilters(initialFilters);
|
|
1984
1984
|
}, [offset]);
|
|
1985
1985
|
const _Digit$Hooks$wt$useTa = Digit.Hooks.wt.useTankerSearchAPI({
|
|
@@ -2083,7 +2083,7 @@ const BookingPopup = _ref => {
|
|
|
2083
2083
|
setIsDataSet(false);
|
|
2084
2084
|
}
|
|
2085
2085
|
}, [isDataSet, onSubmit]);
|
|
2086
|
-
useEffect(() => {
|
|
2086
|
+
useEffect$1(() => {
|
|
2087
2087
|
handleSubmit();
|
|
2088
2088
|
}, [handleSubmit]);
|
|
2089
2089
|
return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Modal, {
|
|
@@ -2337,7 +2337,7 @@ const RequestDetails = _ref => {
|
|
|
2337
2337
|
setUploadedFile(null);
|
|
2338
2338
|
setFile(e.target.files[0]);
|
|
2339
2339
|
}
|
|
2340
|
-
useEffect(() => {
|
|
2340
|
+
useEffect$1(() => {
|
|
2341
2341
|
(function () {
|
|
2342
2342
|
try {
|
|
2343
2343
|
setError(null);
|
|
@@ -2387,7 +2387,7 @@ const RequestDetails = _ref => {
|
|
|
2387
2387
|
});
|
|
2388
2388
|
onSelect(config.key, request, false);
|
|
2389
2389
|
};
|
|
2390
|
-
useEffect(() => {
|
|
2390
|
+
useEffect$1(() => {
|
|
2391
2391
|
if (!tankerType && tankerTypeDetails !== null && tankerTypeDetails !== void 0 && tankerTypeDetails.length) {
|
|
2392
2392
|
settankerType(tankerTypeDetails[0]);
|
|
2393
2393
|
}
|
|
@@ -2864,6 +2864,7 @@ const BannerPicker = props => {
|
|
|
2864
2864
|
});
|
|
2865
2865
|
};
|
|
2866
2866
|
const WTAcknowledgement = _ref => {
|
|
2867
|
+
var _mutation$data2, _mutation$data3, _mutation$data4, _mutation$data4$data, _mutation$data4$data$, _mutation$data4$data$2, _mutation$error, _mutation$error$respo, _mutation$error$respo2, _mutation$error$respo3, _mutation$error$respo4;
|
|
2867
2868
|
let data = _ref.data,
|
|
2868
2869
|
onSuccess = _ref.onSuccess;
|
|
2869
2870
|
const _useTranslation2 = useTranslation(),
|
|
@@ -2875,14 +2876,20 @@ const WTAcknowledgement = _ref => {
|
|
|
2875
2876
|
storeData = _Digit$Hooks$useStore.data;
|
|
2876
2877
|
const _ref2 = storeData || {},
|
|
2877
2878
|
tenants = _ref2.tenants;
|
|
2878
|
-
useEffect(() => {
|
|
2879
|
+
useEffect$1(() => {
|
|
2879
2880
|
try {
|
|
2880
2881
|
data.tenantId = tenantId;
|
|
2881
2882
|
let formdata = waterTankerPayload(data);
|
|
2882
2883
|
mutation.mutate(formdata, {
|
|
2883
|
-
onSuccess
|
|
2884
|
+
onSuccess: res => {
|
|
2885
|
+
if (!(res !== null && res !== void 0 && res.error)) {
|
|
2886
|
+
onSuccess();
|
|
2887
|
+
}
|
|
2888
|
+
}
|
|
2884
2889
|
});
|
|
2885
|
-
} catch (err) {
|
|
2890
|
+
} catch (err) {
|
|
2891
|
+
console.error("WT payload construction error:", err);
|
|
2892
|
+
}
|
|
2886
2893
|
}, []);
|
|
2887
2894
|
Digit.Hooks.useCustomBackNavigation({
|
|
2888
2895
|
redirectPath: "${APPLICATION_PATH}/citizen"
|
|
@@ -2900,21 +2907,29 @@ const WTAcknowledgement = _ref => {
|
|
|
2900
2907
|
return Promise.reject(e);
|
|
2901
2908
|
}
|
|
2902
2909
|
};
|
|
2910
|
+
const isMutationSuccess = mutation.isSuccess && !((_mutation$data2 = mutation.data) !== null && _mutation$data2 !== void 0 && _mutation$data2.error);
|
|
2911
|
+
const isMutationError = mutation.isError || mutation.isSuccess && ((_mutation$data3 = mutation.data) === null || _mutation$data3 === void 0 ? void 0 : _mutation$data3.error);
|
|
2903
2912
|
return mutation.isLoading || mutation.isIdle ? /*#__PURE__*/React.createElement(Loader, null) : /*#__PURE__*/React.createElement(Card, {
|
|
2904
2913
|
className: "vehicle-details-card"
|
|
2905
2914
|
}, /*#__PURE__*/React.createElement(BannerPicker, {
|
|
2906
2915
|
t: t,
|
|
2907
2916
|
data: mutation.data,
|
|
2908
|
-
isSuccess:
|
|
2917
|
+
isSuccess: isMutationSuccess,
|
|
2909
2918
|
isLoading: mutation.isIdle || mutation.isLoading
|
|
2910
|
-
}),
|
|
2919
|
+
}), isMutationError && /*#__PURE__*/React.createElement(CardText, {
|
|
2920
|
+
style: {
|
|
2921
|
+
color: "#d4351c",
|
|
2922
|
+
textAlign: "center",
|
|
2923
|
+
marginTop: "8px"
|
|
2924
|
+
}
|
|
2925
|
+
}, ((_mutation$data4 = mutation.data) === null || _mutation$data4 === void 0 ? void 0 : (_mutation$data4$data = _mutation$data4.data) === null || _mutation$data4$data === void 0 ? void 0 : (_mutation$data4$data$ = _mutation$data4$data.Errors) === null || _mutation$data4$data$ === void 0 ? void 0 : (_mutation$data4$data$2 = _mutation$data4$data$[0]) === null || _mutation$data4$data$2 === void 0 ? void 0 : _mutation$data4$data$2.message) || ((_mutation$error = mutation.error) === null || _mutation$error === void 0 ? void 0 : (_mutation$error$respo = _mutation$error.response) === null || _mutation$error$respo === void 0 ? void 0 : (_mutation$error$respo2 = _mutation$error$respo.data) === null || _mutation$error$respo2 === void 0 ? void 0 : (_mutation$error$respo3 = _mutation$error$respo2.Errors) === null || _mutation$error$respo3 === void 0 ? void 0 : (_mutation$error$respo4 = _mutation$error$respo3[0]) === null || _mutation$error$respo4 === void 0 ? void 0 : _mutation$error$respo4.message) || t("WT_SUBMISSION_FAILED_MESSAGE")), /*#__PURE__*/React.createElement(StatusTable, null, isMutationSuccess && /*#__PURE__*/React.createElement(Row, {
|
|
2911
2926
|
rowContainerStyle: rowContainerStyle,
|
|
2912
2927
|
last: true,
|
|
2913
2928
|
textStyle: {
|
|
2914
2929
|
whiteSpace: "pre",
|
|
2915
2930
|
width: "60%"
|
|
2916
2931
|
}
|
|
2917
|
-
})),
|
|
2932
|
+
})), isMutationSuccess && /*#__PURE__*/React.createElement(SubmitBar, {
|
|
2918
2933
|
label: t("WT_DOWNLOAD_ACKNOWLEDGEMENT"),
|
|
2919
2934
|
onSubmit: handleDownloadPdf
|
|
2920
2935
|
}), (user === null || user === void 0 ? void 0 : user.type) === "CITIZEN" ? /*#__PURE__*/React.createElement(Link, {
|
|
@@ -3982,7 +3997,7 @@ const ApplicationCard = _ref => {
|
|
|
3982
3997
|
onFilterChange(params);
|
|
3983
3998
|
setPopup(false);
|
|
3984
3999
|
};
|
|
3985
|
-
useEffect(() => {
|
|
4000
|
+
useEffect$1(() => {
|
|
3986
4001
|
if (type) setPopup(true);
|
|
3987
4002
|
}, [type]);
|
|
3988
4003
|
const handlePopupClose = () => {
|
|
@@ -4071,7 +4086,7 @@ const ApplicationLinks = _ref => {
|
|
|
4071
4086
|
const hasAccess = accessTo => {
|
|
4072
4087
|
return roles.filter(role => accessTo.includes(role.code)).length;
|
|
4073
4088
|
};
|
|
4074
|
-
useEffect(() => {
|
|
4089
|
+
useEffect$1(() => {
|
|
4075
4090
|
let linksToShow = [];
|
|
4076
4091
|
allLinks.forEach(link => {
|
|
4077
4092
|
if (link.accessTo) {
|
|
@@ -4261,11 +4276,11 @@ const Inbox = _ref => {
|
|
|
4261
4276
|
data = _ref2.data,
|
|
4262
4277
|
searchFields = _ref2.searchFields,
|
|
4263
4278
|
rest = _objectWithoutPropertiesLoose(_ref2, _excluded$3);
|
|
4264
|
-
useEffect(() => {
|
|
4279
|
+
useEffect$1(() => {
|
|
4265
4280
|
if (rest !== null && rest !== void 0 && rest.revalidate) rest === null || rest === void 0 ? void 0 : rest.revalidate();
|
|
4266
4281
|
if (rest !== null && rest !== void 0 && rest.refetch) rest === null || rest === void 0 ? void 0 : rest.refetch();
|
|
4267
4282
|
}, []);
|
|
4268
|
-
useEffect(() => {
|
|
4283
|
+
useEffect$1(() => {
|
|
4269
4284
|
setPageOffset(0);
|
|
4270
4285
|
}, [searchParams]);
|
|
4271
4286
|
const fetchNextPage = () => {
|
|
@@ -4515,7 +4530,7 @@ const AddTripModal = _ref => {
|
|
|
4515
4530
|
const _useState2 = useState(""),
|
|
4516
4531
|
debouncedSearchQuery = _useState2[0],
|
|
4517
4532
|
setDebouncedSearchQuery = _useState2[1];
|
|
4518
|
-
useEffect(() => {
|
|
4533
|
+
useEffect$1(() => {
|
|
4519
4534
|
const handler = setTimeout(() => {
|
|
4520
4535
|
setDebouncedSearchQuery(searchQuery);
|
|
4521
4536
|
}, 500);
|
|
@@ -5013,7 +5028,7 @@ const FixedPointScheduleManagement = _ref => {
|
|
|
5013
5028
|
isLoading = _Digit$Hooks$wt$useFi.isLoading,
|
|
5014
5029
|
scheduleData = _Digit$Hooks$wt$useFi.data,
|
|
5015
5030
|
refetch = _Digit$Hooks$wt$useFi.refetch;
|
|
5016
|
-
useEffect(() => {
|
|
5031
|
+
useEffect$1(() => {
|
|
5017
5032
|
refetch && refetch();
|
|
5018
5033
|
}, []);
|
|
5019
5034
|
const _Digit$Hooks$wt$useFi2 = Digit.Hooks.wt.useFixedPointSearchAPI({
|
|
@@ -5759,7 +5774,7 @@ const Address = _ref => {
|
|
|
5759
5774
|
const _useState = useState(fallback),
|
|
5760
5775
|
address = _useState[0],
|
|
5761
5776
|
setAddress = _useState[1];
|
|
5762
|
-
useEffect(() => {
|
|
5777
|
+
useEffect$1(() => {
|
|
5763
5778
|
const resolve = function () {
|
|
5764
5779
|
try {
|
|
5765
5780
|
const _temp = function () {
|
|
@@ -5786,7 +5801,7 @@ const MapController = _ref2 => {
|
|
|
5786
5801
|
mapZoom = _ref2.mapZoom,
|
|
5787
5802
|
mapCenter = _ref2.mapCenter;
|
|
5788
5803
|
const map = useMap();
|
|
5789
|
-
useEffect(() => {
|
|
5804
|
+
useEffect$1(() => {
|
|
5790
5805
|
if (selectedDriver !== null && selectedDriver !== void 0 && selectedDriver.lat && selectedDriver !== null && selectedDriver !== void 0 && selectedDriver.lng) {
|
|
5791
5806
|
map.setView([selectedDriver.lat, selectedDriver.lng], mapZoom || 15, {
|
|
5792
5807
|
animate: true,
|
|
@@ -5794,7 +5809,7 @@ const MapController = _ref2 => {
|
|
|
5794
5809
|
});
|
|
5795
5810
|
}
|
|
5796
5811
|
}, [selectedDriver, map]);
|
|
5797
|
-
useEffect(() => {
|
|
5812
|
+
useEffect$1(() => {
|
|
5798
5813
|
if (Array.isArray(mapCenter) && mapCenter.length === 2) {
|
|
5799
5814
|
map.setView(mapCenter, mapZoom || 15, {
|
|
5800
5815
|
animate: true,
|
|
@@ -5802,7 +5817,7 @@ const MapController = _ref2 => {
|
|
|
5802
5817
|
});
|
|
5803
5818
|
}
|
|
5804
5819
|
}, [mapCenter, map]);
|
|
5805
|
-
useEffect(() => {
|
|
5820
|
+
useEffect$1(() => {
|
|
5806
5821
|
if (mapZoom) {
|
|
5807
5822
|
map.setZoom(mapZoom);
|
|
5808
5823
|
}
|
|
@@ -5821,7 +5836,7 @@ const useRoute = (start, end) => {
|
|
|
5821
5836
|
const _useState4 = useState(null),
|
|
5822
5837
|
error = _useState4[0],
|
|
5823
5838
|
setError = _useState4[1];
|
|
5824
|
-
useEffect(() => {
|
|
5839
|
+
useEffect$1(() => {
|
|
5825
5840
|
if (!start || !end) return;
|
|
5826
5841
|
const fetchRoute = function () {
|
|
5827
5842
|
try {
|
|
@@ -6059,7 +6074,7 @@ const DriverCard = _ref5 => {
|
|
|
6059
6074
|
lat: null,
|
|
6060
6075
|
lng: null
|
|
6061
6076
|
});
|
|
6062
|
-
useEffect(() => {
|
|
6077
|
+
useEffect$1(() => {
|
|
6063
6078
|
const resolveCurrent = function () {
|
|
6064
6079
|
try {
|
|
6065
6080
|
const _temp3 = function () {
|
|
@@ -6086,7 +6101,7 @@ const DriverCard = _ref5 => {
|
|
|
6086
6101
|
};
|
|
6087
6102
|
resolveCurrent();
|
|
6088
6103
|
}, [driver.lat, driver.lng]);
|
|
6089
|
-
useEffect(() => {
|
|
6104
|
+
useEffect$1(() => {
|
|
6090
6105
|
const resolveDest = function () {
|
|
6091
6106
|
try {
|
|
6092
6107
|
const _temp5 = function () {
|
|
@@ -6300,7 +6315,7 @@ function LiveTrackingSystem() {
|
|
|
6300
6315
|
const filteredVendorOptions = useMemo(() => {
|
|
6301
6316
|
return vendorOptions || [];
|
|
6302
6317
|
}, [vendorOptions]);
|
|
6303
|
-
useEffect(() => {
|
|
6318
|
+
useEffect$1(() => {
|
|
6304
6319
|
if (vendorOptions !== null && vendorOptions !== void 0 && vendorOptions.length && Object.keys(drivers).length) {
|
|
6305
6320
|
var _vendorOptions$, _vendorOptions$2, _vendorOptions$2$driv;
|
|
6306
6321
|
console.log("=== VENDOR DEBUG ===");
|
|
@@ -6320,7 +6335,7 @@ function LiveTrackingSystem() {
|
|
|
6320
6335
|
setSelectedFillingPoint(value);
|
|
6321
6336
|
setSelectedVendor(null);
|
|
6322
6337
|
};
|
|
6323
|
-
useEffect(() => {
|
|
6338
|
+
useEffect$1(() => {
|
|
6324
6339
|
const handleResize = () => {
|
|
6325
6340
|
setIsMobile(window.innerWidth <= 768);
|
|
6326
6341
|
if (window.innerWidth <= 768) {
|
|
@@ -6340,7 +6355,7 @@ function LiveTrackingSystem() {
|
|
|
6340
6355
|
autoConnect: false
|
|
6341
6356
|
});
|
|
6342
6357
|
}, []);
|
|
6343
|
-
useEffect(() => {
|
|
6358
|
+
useEffect$1(() => {
|
|
6344
6359
|
socket.connect();
|
|
6345
6360
|
socket.on("connect", () => {
|
|
6346
6361
|
console.log("Admin connected:", socket.id);
|
|
@@ -6389,7 +6404,7 @@ function LiveTrackingSystem() {
|
|
|
6389
6404
|
socket.disconnect();
|
|
6390
6405
|
};
|
|
6391
6406
|
}, [socket]);
|
|
6392
|
-
useEffect(() => {
|
|
6407
|
+
useEffect$1(() => {
|
|
6393
6408
|
if (selectedDriver !== null && selectedDriver !== void 0 && selectedDriver.lat && selectedDriver !== null && selectedDriver !== void 0 && selectedDriver.lng) {
|
|
6394
6409
|
setMapCenter([selectedDriver.lat, selectedDriver.lng]);
|
|
6395
6410
|
setMapZoom(15);
|
|
@@ -7241,7 +7256,7 @@ const AddFixFillAddress = _ref => {
|
|
|
7241
7256
|
}, [usedAddressTypes]);
|
|
7242
7257
|
const _Digit$Hooks$useCommo = Digit.Hooks.useCommonMDMS(tenantId, "egov-location", ["TenantBoundary"]),
|
|
7243
7258
|
egovLocationData = _Digit$Hooks$useCommo.data;
|
|
7244
|
-
useEffect(() => {
|
|
7259
|
+
useEffect$1(() => {
|
|
7245
7260
|
if (!city && allCities && allCities.length > 0) {
|
|
7246
7261
|
const defaultCity = allCities.find(c => c.code === tenantId) || allCities[0];
|
|
7247
7262
|
setCity(defaultCity);
|
|
@@ -7337,7 +7352,7 @@ const AddFixFillAddress = _ref => {
|
|
|
7337
7352
|
return pins.some(p => p.toString() === pincode);
|
|
7338
7353
|
});
|
|
7339
7354
|
}, [structuredLocality, pincode, fetchedPincodes]);
|
|
7340
|
-
useEffect(() => {
|
|
7355
|
+
useEffect$1(() => {
|
|
7341
7356
|
var _formData$address13;
|
|
7342
7357
|
const currentId = (formData === null || formData === void 0 ? void 0 : formData.id) || (formData === null || formData === void 0 ? void 0 : formData.bookingId) || (formData === null || formData === void 0 ? void 0 : (_formData$address13 = formData.address) === null || _formData$address13 === void 0 ? void 0 : _formData$address13.id);
|
|
7343
7358
|
if (currentId && lastBookingId.current !== currentId) {
|
|
@@ -7375,14 +7390,14 @@ const AddFixFillAddress = _ref => {
|
|
|
7375
7390
|
}
|
|
7376
7391
|
}
|
|
7377
7392
|
}, [formData === null || formData === void 0 ? void 0 : formData.address, city, allCities, structuredLocality]);
|
|
7378
|
-
useEffect(() => {
|
|
7393
|
+
useEffect$1(() => {
|
|
7379
7394
|
if (!navigator.geolocation) return;
|
|
7380
7395
|
navigator.geolocation.getCurrentPosition(pos => {
|
|
7381
7396
|
setLatitude(pos.coords.latitude);
|
|
7382
7397
|
setLongitude(pos.coords.longitude);
|
|
7383
7398
|
}, () => {});
|
|
7384
7399
|
}, []);
|
|
7385
|
-
useEffect(() => {
|
|
7400
|
+
useEffect$1(() => {
|
|
7386
7401
|
if (selectedAddress && Object.keys(selectedAddress).length) {
|
|
7387
7402
|
setPincode(selectedAddress.pinCode);
|
|
7388
7403
|
setCity(allCities === null || allCities === void 0 ? void 0 : allCities.find(c => c.name === selectedAddress.city));
|
|
@@ -7433,14 +7448,14 @@ const AddFixFillAddress = _ref => {
|
|
|
7433
7448
|
return Promise.reject(e);
|
|
7434
7449
|
}
|
|
7435
7450
|
};
|
|
7436
|
-
useEffect(() => {
|
|
7451
|
+
useEffect$1(() => {
|
|
7437
7452
|
if (!addressLine1 || addressLine1.trim().length < 5) return;
|
|
7438
7453
|
const timer = setTimeout(() => {
|
|
7439
7454
|
getLatLng();
|
|
7440
7455
|
}, 1000);
|
|
7441
7456
|
return () => clearTimeout(timer);
|
|
7442
7457
|
}, [addressLine1]);
|
|
7443
|
-
useEffect(() => {
|
|
7458
|
+
useEffect$1(() => {
|
|
7444
7459
|
if (!onSelect || !isInitialized.current) return;
|
|
7445
7460
|
const currentAddress = {
|
|
7446
7461
|
pincode: pincode || "",
|
|
@@ -7634,7 +7649,7 @@ const AddFillingPointAddress = () => {
|
|
|
7634
7649
|
[key]: _extends({}, prev[key] || {}, data)
|
|
7635
7650
|
}));
|
|
7636
7651
|
};
|
|
7637
|
-
useEffect(() => {
|
|
7652
|
+
useEffect$1(() => {
|
|
7638
7653
|
if (editId && editData !== null && editData !== void 0 && editData.fillingPoints) {
|
|
7639
7654
|
const data = editData.fillingPoints.find(item => item.id === editId);
|
|
7640
7655
|
if (data) {
|
|
@@ -7779,7 +7794,7 @@ const AddFixPointAddress = () => {
|
|
|
7779
7794
|
const _useState3 = useState(false),
|
|
7780
7795
|
isDataFetched = _useState3[0],
|
|
7781
7796
|
setIsDataFetched = _useState3[1];
|
|
7782
|
-
useEffect(() => {
|
|
7797
|
+
useEffect$1(() => {
|
|
7783
7798
|
if (editId && editData !== null && editData !== void 0 && editData.waterTankerBookingDetail && !isDataFetched) {
|
|
7784
7799
|
const data = editData.waterTankerBookingDetail.find(item => {
|
|
7785
7800
|
var _item$applicantDetail;
|
|
@@ -8173,7 +8188,7 @@ const ChangeView = _ref => {
|
|
|
8173
8188
|
center = _ref.center,
|
|
8174
8189
|
zoom = _ref.zoom;
|
|
8175
8190
|
const map = useMap();
|
|
8176
|
-
useEffect(() => {
|
|
8191
|
+
useEffect$1(() => {
|
|
8177
8192
|
if (center) {
|
|
8178
8193
|
map.setView(center, zoom || 15, {
|
|
8179
8194
|
animate: true
|
|
@@ -8245,7 +8260,7 @@ const PointAddressMap = _ref2 => {
|
|
|
8245
8260
|
return ((_fx$address = fx.address) === null || _fx$address === void 0 ? void 0 : _fx$address.latitude) && ((_fx$address2 = fx.address) === null || _fx$address2 === void 0 ? void 0 : _fx$address2.longitude);
|
|
8246
8261
|
});
|
|
8247
8262
|
}, [relatedFixedPoints]);
|
|
8248
|
-
useEffect(() => {
|
|
8263
|
+
useEffect$1(() => {
|
|
8249
8264
|
if (hoveredFixedPointId) {
|
|
8250
8265
|
const marker = markerRefs.current[hoveredFixedPointId];
|
|
8251
8266
|
if (marker) marker.openPopup();
|
|
@@ -9685,7 +9700,7 @@ const VendorMultiSelectDropdown = _ref => {
|
|
|
9685
9700
|
return state;
|
|
9686
9701
|
}
|
|
9687
9702
|
}
|
|
9688
|
-
useEffect(() => {
|
|
9703
|
+
useEffect$1(() => {
|
|
9689
9704
|
dispatch({
|
|
9690
9705
|
type: "REPLACE_COMPLETE_STATE",
|
|
9691
9706
|
payload: fnToSelectOptionThroughProvidedSelection(selected)
|
|
@@ -9936,7 +9951,7 @@ const VendorAssign = _ref => {
|
|
|
9936
9951
|
createWorkOrder = _Digit$Hooks$wt$useVe.mutate;
|
|
9937
9952
|
const _Digit$Hooks$wt$useVe2 = Digit.Hooks.wt.useVendorFillingMap(tenantId),
|
|
9938
9953
|
mapFixedFilling = _Digit$Hooks$wt$useVe2.mutate;
|
|
9939
|
-
useEffect(() => {
|
|
9954
|
+
useEffect$1(() => {
|
|
9940
9955
|
(function () {
|
|
9941
9956
|
try {
|
|
9942
9957
|
setError(null);
|
|
@@ -10816,7 +10831,7 @@ const WTMyApplications = () => {
|
|
|
10816
10831
|
tenantId,
|
|
10817
10832
|
MobileNumber: user === null || user === void 0 ? void 0 : user.mobileNumber
|
|
10818
10833
|
};
|
|
10819
|
-
useEffect(() => {
|
|
10834
|
+
useEffect$1(() => {
|
|
10820
10835
|
setFilters(initialFilters);
|
|
10821
10836
|
}, [filter]);
|
|
10822
10837
|
const _Digit$Hooks$wt$useTa = Digit.Hooks.wt.useTankerSearchAPI({
|
|
@@ -18115,7 +18130,7 @@ const Filter = _ref => {
|
|
|
18115
18130
|
})),
|
|
18116
18131
|
_searchParams = _useState[0],
|
|
18117
18132
|
setSearchParams = _useState[1];
|
|
18118
|
-
useEffect(() => {
|
|
18133
|
+
useEffect$1(() => {
|
|
18119
18134
|
setSearchParams(_extends({}, searchParams, {
|
|
18120
18135
|
services: (searchParams === null || searchParams === void 0 ? void 0 : searchParams.services) || []
|
|
18121
18136
|
}));
|
|
@@ -18404,6 +18419,9 @@ const WTEditApplicationModal = _ref => {
|
|
|
18404
18419
|
}),
|
|
18405
18420
|
formData = _useState[0],
|
|
18406
18421
|
setFormData = _useState[1];
|
|
18422
|
+
const _useState2 = useState(null),
|
|
18423
|
+
showToast = _useState2[0],
|
|
18424
|
+
setShowToast = _useState2[1];
|
|
18407
18425
|
const _Digit$Hooks$fsm$useV = Digit.Hooks.fsm.useVendorSearch({
|
|
18408
18426
|
tenantId,
|
|
18409
18427
|
filters: _extends({}, getFirstAvailable(formData === null || formData === void 0 ? void 0 : (_formData$dispatchDet = formData.dispatchDetails) === null || _formData$dispatchDet === void 0 ? void 0 : (_formData$dispatchDet2 = _formData$dispatchDet.fillingPoint) === null || _formData$dispatchDet2 === void 0 ? void 0 : _formData$dispatchDet2.id, formData === null || formData === void 0 ? void 0 : (_formData$dispatchDet3 = formData.dispatchDetails) === null || _formData$dispatchDet3 === void 0 ? void 0 : (_formData$dispatchDet4 = _formData$dispatchDet3.fillingPoint) === null || _formData$dispatchDet4 === void 0 ? void 0 : _formData$dispatchDet4.fillingPointId, formData === null || formData === void 0 ? void 0 : (_formData$dispatchDet5 = formData.dispatchDetails) === null || _formData$dispatchDet5 === void 0 ? void 0 : (_formData$dispatchDet6 = _formData$dispatchDet5.fillingPoint) === null || _formData$dispatchDet6 === void 0 ? void 0 : _formData$dispatchDet6.bookingId) ? {
|
|
@@ -18469,7 +18487,7 @@ const WTEditApplicationModal = _ref => {
|
|
|
18469
18487
|
}),
|
|
18470
18488
|
fillingPointsData = _Digit$Hooks$wt$useFi2.data;
|
|
18471
18489
|
const mutation = Digit.Hooks.wt.useUpdateEmergencyBooking(tenantId);
|
|
18472
|
-
useEffect(() => {
|
|
18490
|
+
useEffect$1(() => {
|
|
18473
18491
|
if (applicationData) {
|
|
18474
18492
|
var _fixedPointsData$wate, _fixedPointsData$wate2, _fillingPointsData$fi, _selectedVendor$vehic, _selectedVendor$drive, _applicationData$appl5, _applicationData$appl6, _applicationData$appl7, _applicationData$appl8, _fixedPointObj$applic, _fixedPointObj$applic2, _applicationData$appl9, _applicationData$appl0, _applicationData$addr, _applicationData$addr2, _applicationData$addr3, _applicationData$addr4, _applicationData$addr5, _applicationData$addr6, _applicationData$addr7, _applicationData$addr8, _applicationData$addr9, _applicationData$addr0, _applicationData$addr1, _applicationData$addr10, _applicationData$addr11, _applicationData$addr12;
|
|
18475
18493
|
const tankerTypeObj = (TankerType === null || TankerType === void 0 ? void 0 : TankerType.find(tt => matchesAny(tt.code, [applicationData.tankerType]))) || {
|
|
@@ -18693,12 +18711,18 @@ const WTEditApplicationModal = _ref => {
|
|
|
18693
18711
|
window.location.reload();
|
|
18694
18712
|
},
|
|
18695
18713
|
onError: error => {
|
|
18714
|
+
var _error$response, _error$response$data, _error$response$data$, _error$response$data$2;
|
|
18696
18715
|
console.error("Update Error:", error);
|
|
18716
|
+
setShowToast({
|
|
18717
|
+
isError: true,
|
|
18718
|
+
label: (error === null || error === void 0 ? void 0 : (_error$response = error.response) === null || _error$response === void 0 ? void 0 : (_error$response$data = _error$response.data) === null || _error$response$data === void 0 ? void 0 : (_error$response$data$ = _error$response$data.Errors) === null || _error$response$data$ === void 0 ? void 0 : (_error$response$data$2 = _error$response$data$[0]) === null || _error$response$data$2 === void 0 ? void 0 : _error$response$data$2.message) || t("WT_APPLICATION_UPDATE_FAILED")
|
|
18719
|
+
});
|
|
18720
|
+
setTimeout(() => setShowToast(null), 5000);
|
|
18697
18721
|
}
|
|
18698
18722
|
});
|
|
18699
18723
|
};
|
|
18700
18724
|
if (mutation.isLoading) return /*#__PURE__*/React.createElement(Loader, null);
|
|
18701
|
-
return /*#__PURE__*/React.createElement(Modal, {
|
|
18725
|
+
return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Modal, {
|
|
18702
18726
|
headerBarMain: /*#__PURE__*/React.createElement("h1", {
|
|
18703
18727
|
className: "heading-m"
|
|
18704
18728
|
}, t("WT_EDIT_APPLICATION_DETAILS")),
|
|
@@ -19105,7 +19129,11 @@ const WTEditApplicationModal = _ref => {
|
|
|
19105
19129
|
})),
|
|
19106
19130
|
optionKey: "name",
|
|
19107
19131
|
t: t
|
|
19108
|
-
}))))))
|
|
19132
|
+
})))))), showToast && /*#__PURE__*/React.createElement(Toast, {
|
|
19133
|
+
error: showToast.isError,
|
|
19134
|
+
label: showToast.label,
|
|
19135
|
+
onClose: () => setShowToast(null)
|
|
19136
|
+
}));
|
|
19109
19137
|
};
|
|
19110
19138
|
|
|
19111
19139
|
const TripImages = _ref => {
|
|
@@ -19123,7 +19151,7 @@ const TripImages = _ref => {
|
|
|
19123
19151
|
endImageUrl = _useState3[0],
|
|
19124
19152
|
setEndImageUrl = _useState3[1];
|
|
19125
19153
|
const tenantId = Digit.ULBService.getCurrentTenantId();
|
|
19126
|
-
useEffect(() => {
|
|
19154
|
+
useEffect$1(() => {
|
|
19127
19155
|
const fetchImages = function () {
|
|
19128
19156
|
try {
|
|
19129
19157
|
const _temp4 = _catch(function () {
|
|
@@ -20021,13 +20049,13 @@ const ActionModal = _ref => {
|
|
|
20021
20049
|
selectedFinancialYear = _useState9[0],
|
|
20022
20050
|
setSelectedFinancialYear = _useState9[1];
|
|
20023
20051
|
const _useState0 = useState(false);
|
|
20024
|
-
useEffect(() => {
|
|
20052
|
+
useEffect$1(() => {
|
|
20025
20053
|
if (financialYearsData && financialYearsData["egf-master"]) {
|
|
20026
20054
|
var _financialYearsData$e;
|
|
20027
20055
|
setFinancialYears((_financialYearsData$e = financialYearsData["egf-master"]) === null || _financialYearsData$e === void 0 ? void 0 : _financialYearsData$e["FinancialYear"]);
|
|
20028
20056
|
}
|
|
20029
20057
|
}, [financialYearsData]);
|
|
20030
|
-
useEffect(() => {
|
|
20058
|
+
useEffect$1(() => {
|
|
20031
20059
|
var _approverData$Employe;
|
|
20032
20060
|
setApprovers(approverData === null || approverData === void 0 ? void 0 : (_approverData$Employe = approverData.Employees) === null || _approverData$Employe === void 0 ? void 0 : _approverData$Employe.map(employee => {
|
|
20033
20061
|
var _employee$user;
|
|
@@ -20040,7 +20068,7 @@ const ActionModal = _ref => {
|
|
|
20040
20068
|
function selectFile(e) {
|
|
20041
20069
|
setFile(e.target.files[0]);
|
|
20042
20070
|
}
|
|
20043
|
-
useEffect(() => {
|
|
20071
|
+
useEffect$1(() => {
|
|
20044
20072
|
(function () {
|
|
20045
20073
|
try {
|
|
20046
20074
|
setError(null);
|
|
@@ -20122,7 +20150,7 @@ const ActionModal = _ref => {
|
|
|
20122
20150
|
});
|
|
20123
20151
|
}
|
|
20124
20152
|
}
|
|
20125
|
-
useEffect(() => {
|
|
20153
|
+
useEffect$1(() => {
|
|
20126
20154
|
if (action) {
|
|
20127
20155
|
if (action !== null && action !== void 0 && action.showFinancialYearsModal) {
|
|
20128
20156
|
setConfig(configPTAssessProperty({
|
|
@@ -20248,13 +20276,13 @@ const ActionModal$1 = _ref => {
|
|
|
20248
20276
|
setFinancialYears = _useState8[1];
|
|
20249
20277
|
const _useState9 = useState(null),
|
|
20250
20278
|
selectedFinancialYear = _useState9[0];
|
|
20251
|
-
useEffect(() => {
|
|
20279
|
+
useEffect$1(() => {
|
|
20252
20280
|
if (financialYearsData && financialYearsData["egf-master"]) {
|
|
20253
20281
|
var _financialYearsData$e;
|
|
20254
20282
|
setFinancialYears((_financialYearsData$e = financialYearsData["egf-master"]) === null || _financialYearsData$e === void 0 ? void 0 : _financialYearsData$e["FinancialYear"]);
|
|
20255
20283
|
}
|
|
20256
20284
|
}, [financialYearsData]);
|
|
20257
|
-
useEffect(() => {
|
|
20285
|
+
useEffect$1(() => {
|
|
20258
20286
|
var _approverData$Employe;
|
|
20259
20287
|
setApprovers(approverData === null || approverData === void 0 ? void 0 : (_approverData$Employe = approverData.Employees) === null || _approverData$Employe === void 0 ? void 0 : _approverData$Employe.map(employee => {
|
|
20260
20288
|
var _employee$user;
|
|
@@ -20267,7 +20295,7 @@ const ActionModal$1 = _ref => {
|
|
|
20267
20295
|
function selectFile(e) {
|
|
20268
20296
|
setFile(e.target.files[0]);
|
|
20269
20297
|
}
|
|
20270
|
-
useEffect(() => {
|
|
20298
|
+
useEffect$1(() => {
|
|
20271
20299
|
(function () {
|
|
20272
20300
|
try {
|
|
20273
20301
|
setError(null);
|
|
@@ -20317,7 +20345,7 @@ const ActionModal$1 = _ref => {
|
|
|
20317
20345
|
Licenses: [applicationData]
|
|
20318
20346
|
});
|
|
20319
20347
|
}
|
|
20320
|
-
useEffect(() => {
|
|
20348
|
+
useEffect$1(() => {
|
|
20321
20349
|
if (action) {
|
|
20322
20350
|
setConfig(configTLApproverApplication({
|
|
20323
20351
|
t,
|
|
@@ -20419,7 +20447,7 @@ const ActionModal$2 = _ref => {
|
|
|
20419
20447
|
error = _useState7[0],
|
|
20420
20448
|
setError = _useState7[1];
|
|
20421
20449
|
const mobileView = Digit.Utils.browser.isMobile() ? true : false;
|
|
20422
|
-
useEffect(() => {
|
|
20450
|
+
useEffect$1(() => {
|
|
20423
20451
|
var _approverData$Employe;
|
|
20424
20452
|
setApprovers(approverData === null || approverData === void 0 ? void 0 : (_approverData$Employe = approverData.Employees) === null || _approverData$Employe === void 0 ? void 0 : _approverData$Employe.map(employee => {
|
|
20425
20453
|
var _employee$user;
|
|
@@ -20432,7 +20460,7 @@ const ActionModal$2 = _ref => {
|
|
|
20432
20460
|
function selectFile(e) {
|
|
20433
20461
|
setFile(e.target.files[0]);
|
|
20434
20462
|
}
|
|
20435
|
-
useEffect(() => {
|
|
20463
|
+
useEffect$1(() => {
|
|
20436
20464
|
(function () {
|
|
20437
20465
|
try {
|
|
20438
20466
|
setError(null);
|
|
@@ -20493,7 +20521,7 @@ const ActionModal$2 = _ref => {
|
|
|
20493
20521
|
bpa: false
|
|
20494
20522
|
});
|
|
20495
20523
|
}
|
|
20496
|
-
useEffect(() => {
|
|
20524
|
+
useEffect$1(() => {
|
|
20497
20525
|
if (action) {
|
|
20498
20526
|
setConfig(configBPAREGApproverApplication({
|
|
20499
20527
|
t,
|
|
@@ -20702,7 +20730,7 @@ const ActionModal$3 = _ref => {
|
|
|
20702
20730
|
const _useState8 = useState(null),
|
|
20703
20731
|
selectedFinancialYear = _useState8[0];
|
|
20704
20732
|
const mobileView = Digit.Utils.browser.isMobile() ? true : false;
|
|
20705
|
-
useEffect(() => {
|
|
20733
|
+
useEffect$1(() => {
|
|
20706
20734
|
var _approverData$Employe;
|
|
20707
20735
|
setApprovers(approverData === null || approverData === void 0 ? void 0 : (_approverData$Employe = approverData.Employees) === null || _approverData$Employe === void 0 ? void 0 : _approverData$Employe.map(employee => {
|
|
20708
20736
|
var _employee$user;
|
|
@@ -20715,7 +20743,7 @@ const ActionModal$3 = _ref => {
|
|
|
20715
20743
|
function selectFile(e) {
|
|
20716
20744
|
setFile(e.target.files[0]);
|
|
20717
20745
|
}
|
|
20718
|
-
useEffect(() => {
|
|
20746
|
+
useEffect$1(() => {
|
|
20719
20747
|
(function () {
|
|
20720
20748
|
try {
|
|
20721
20749
|
setError(null);
|
|
@@ -20830,7 +20858,7 @@ const ActionModal$3 = _ref => {
|
|
|
20830
20858
|
result = (_result = result) === null || _result === void 0 ? void 0 : _result.concat(newApprovals !== null ? newApprovals.filter(ob => ob.label !== "").map(approval => approval === null || approval === void 0 ? void 0 : approval.label) : []);
|
|
20831
20859
|
return result;
|
|
20832
20860
|
};
|
|
20833
|
-
useEffect(() => {
|
|
20861
|
+
useEffect$1(() => {
|
|
20834
20862
|
if (action) {
|
|
20835
20863
|
setConfig(configBPAApproverApplication({
|
|
20836
20864
|
t,
|
|
@@ -20960,7 +20988,7 @@ const ActionModal$4 = _ref => {
|
|
|
20960
20988
|
setError = _useState7[1];
|
|
20961
20989
|
const mobileView = Digit.Utils.browser.isMobile() ? true : false;
|
|
20962
20990
|
const history = useHistory();
|
|
20963
|
-
useEffect(() => {
|
|
20991
|
+
useEffect$1(() => {
|
|
20964
20992
|
var _approverData$Employe;
|
|
20965
20993
|
setApprovers(approverData === null || approverData === void 0 ? void 0 : (_approverData$Employe = approverData.Employees) === null || _approverData$Employe === void 0 ? void 0 : _approverData$Employe.map(employee => {
|
|
20966
20994
|
var _employee$user;
|
|
@@ -20973,7 +21001,7 @@ const ActionModal$4 = _ref => {
|
|
|
20973
21001
|
function selectFile(e) {
|
|
20974
21002
|
setFile(e.target.files[0]);
|
|
20975
21003
|
}
|
|
20976
|
-
useEffect(() => {
|
|
21004
|
+
useEffect$1(() => {
|
|
20977
21005
|
(function () {
|
|
20978
21006
|
try {
|
|
20979
21007
|
setError(null);
|
|
@@ -21042,7 +21070,7 @@ const ActionModal$4 = _ref => {
|
|
|
21042
21070
|
isNoc: true
|
|
21043
21071
|
});
|
|
21044
21072
|
}
|
|
21045
|
-
useEffect(() => {
|
|
21073
|
+
useEffect$1(() => {
|
|
21046
21074
|
if (action) {
|
|
21047
21075
|
setConfig(configNOCApproverApplication({
|
|
21048
21076
|
t,
|
|
@@ -21942,7 +21970,7 @@ const ActionModal$5 = _ref => {
|
|
|
21942
21970
|
setError = _useState7[1];
|
|
21943
21971
|
const isMobile = window.Digit.Utils.browser.isMobile();
|
|
21944
21972
|
const isEmployee = window.location.href.includes("/employee");
|
|
21945
|
-
useEffect(() => {
|
|
21973
|
+
useEffect$1(() => {
|
|
21946
21974
|
var _approverData$Employe;
|
|
21947
21975
|
setApprovers(approverData === null || approverData === void 0 ? void 0 : (_approverData$Employe = approverData.Employees) === null || _approverData$Employe === void 0 ? void 0 : _approverData$Employe.map(employee => {
|
|
21948
21976
|
var _employee$user;
|
|
@@ -21955,7 +21983,7 @@ const ActionModal$5 = _ref => {
|
|
|
21955
21983
|
function selectFile(e) {
|
|
21956
21984
|
setFile(e.target.files[0]);
|
|
21957
21985
|
}
|
|
21958
|
-
useEffect(() => {
|
|
21986
|
+
useEffect$1(() => {
|
|
21959
21987
|
(function () {
|
|
21960
21988
|
try {
|
|
21961
21989
|
setError(null);
|
|
@@ -22115,7 +22143,12 @@ const ActionModal$5 = _ref => {
|
|
|
22115
22143
|
const inspectionInformationData = sessionStorage.getItem("Digit.INSPECTION_INFORMATION_DATA");
|
|
22116
22144
|
if (inspectionInformationData) {
|
|
22117
22145
|
try {
|
|
22118
|
-
|
|
22146
|
+
const parsedInspectionData = JSON.parse(inspectionInformationData);
|
|
22147
|
+
if (parsedInspectionData !== null && parsedInspectionData !== void 0 && parsedInspectionData.inspectionDate) {
|
|
22148
|
+
const dateVal = parsedInspectionData.inspectionDate;
|
|
22149
|
+
parsedInspectionData.inspectionDate = typeof dateVal === 'string' ? new Date(dateVal).getTime() : dateVal;
|
|
22150
|
+
}
|
|
22151
|
+
applicationData.inspectionInformation = parsedInspectionData;
|
|
22119
22152
|
} catch (e) {
|
|
22120
22153
|
console.error("Error parsing inspection information data", e);
|
|
22121
22154
|
}
|
|
@@ -22131,7 +22164,7 @@ const ActionModal$5 = _ref => {
|
|
|
22131
22164
|
});
|
|
22132
22165
|
}
|
|
22133
22166
|
}
|
|
22134
|
-
useEffect(() => {
|
|
22167
|
+
useEffect$1(() => {
|
|
22135
22168
|
var _applicationData13, _applicationData13$pr, _applicationData14, _applicationData14$pr;
|
|
22136
22169
|
if (((_applicationData13 = applicationData) === null || _applicationData13 === void 0 ? void 0 : (_applicationData13$pr = _applicationData13.processInstance) === null || _applicationData13$pr === void 0 ? void 0 : _applicationData13$pr.businessService) == "DisconnectWSConnection" || ((_applicationData14 = applicationData) === null || _applicationData14 === void 0 ? void 0 : (_applicationData14$pr = _applicationData14.processInstance) === null || _applicationData14$pr === void 0 ? void 0 : _applicationData14$pr.businessService) == "DisconnectSWConnection") {
|
|
22137
22170
|
if (action) {
|
|
@@ -22257,7 +22290,7 @@ const ActionModal$6 = _ref => {
|
|
|
22257
22290
|
const _useState7 = useState(null),
|
|
22258
22291
|
setError = _useState7[1];
|
|
22259
22292
|
const _useState8 = useState(false);
|
|
22260
|
-
useEffect(() => {
|
|
22293
|
+
useEffect$1(() => {
|
|
22261
22294
|
var _approverData$Employe;
|
|
22262
22295
|
setApprovers(approverData === null || approverData === void 0 ? void 0 : (_approverData$Employe = approverData.Employees) === null || _approverData$Employe === void 0 ? void 0 : _approverData$Employe.map(employee => {
|
|
22263
22296
|
var _employee$user;
|
|
@@ -22270,7 +22303,7 @@ const ActionModal$6 = _ref => {
|
|
|
22270
22303
|
function selectFile(e) {
|
|
22271
22304
|
setFile(e.target.files[0]);
|
|
22272
22305
|
}
|
|
22273
|
-
useEffect(() => {
|
|
22306
|
+
useEffect$1(() => {
|
|
22274
22307
|
(function () {
|
|
22275
22308
|
try {
|
|
22276
22309
|
setError(null);
|
|
@@ -22323,7 +22356,7 @@ const ActionModal$6 = _ref => {
|
|
|
22323
22356
|
})]
|
|
22324
22357
|
});
|
|
22325
22358
|
}
|
|
22326
|
-
useEffect(() => {
|
|
22359
|
+
useEffect$1(() => {
|
|
22327
22360
|
if (action) {
|
|
22328
22361
|
setConfig(configPTRApproverApplication({
|
|
22329
22362
|
t,
|
|
@@ -22420,7 +22453,7 @@ const ActionModal$7 = _ref => {
|
|
|
22420
22453
|
const _useState5 = useState(null),
|
|
22421
22454
|
uploadedFile = _useState5[0],
|
|
22422
22455
|
setUploadedFile = _useState5[1];
|
|
22423
|
-
useEffect(() => {
|
|
22456
|
+
useEffect$1(() => {
|
|
22424
22457
|
var _approverData$Employe;
|
|
22425
22458
|
setApprovers(approverData === null || approverData === void 0 ? void 0 : (_approverData$Employe = approverData.Employees) === null || _approverData$Employe === void 0 ? void 0 : _approverData$Employe.map(employee => {
|
|
22426
22459
|
var _employee$user;
|
|
@@ -22444,7 +22477,7 @@ const ActionModal$7 = _ref => {
|
|
|
22444
22477
|
})
|
|
22445
22478
|
});
|
|
22446
22479
|
}
|
|
22447
|
-
useEffect(() => {
|
|
22480
|
+
useEffect$1(() => {
|
|
22448
22481
|
if ((action === null || action === void 0 ? void 0 : action.state) === "INITIATED") {
|
|
22449
22482
|
history.push("/digit-ui/employee/asset/assetservice/edit/" + ("" + (applicationData === null || applicationData === void 0 ? void 0 : applicationData.applicationNo)));
|
|
22450
22483
|
} else {
|
|
@@ -22547,7 +22580,7 @@ const ActionModal$8 = _ref => {
|
|
|
22547
22580
|
const _useState7 = useState(null),
|
|
22548
22581
|
setError = _useState7[1];
|
|
22549
22582
|
const _useState8 = useState(false);
|
|
22550
|
-
useEffect(() => {
|
|
22583
|
+
useEffect$1(() => {
|
|
22551
22584
|
var _approverData$Employe;
|
|
22552
22585
|
setApprovers(approverData === null || approverData === void 0 ? void 0 : (_approverData$Employe = approverData.Employees) === null || _approverData$Employe === void 0 ? void 0 : _approverData$Employe.map(employee => {
|
|
22553
22586
|
var _employee$user;
|
|
@@ -22560,7 +22593,7 @@ const ActionModal$8 = _ref => {
|
|
|
22560
22593
|
function selectFile(e) {
|
|
22561
22594
|
setFile(e.target.files[0]);
|
|
22562
22595
|
}
|
|
22563
|
-
useEffect(() => {
|
|
22596
|
+
useEffect$1(() => {
|
|
22564
22597
|
(function () {
|
|
22565
22598
|
try {
|
|
22566
22599
|
setError(null);
|
|
@@ -22613,7 +22646,7 @@ const ActionModal$8 = _ref => {
|
|
|
22613
22646
|
})
|
|
22614
22647
|
});
|
|
22615
22648
|
}
|
|
22616
|
-
useEffect(() => {
|
|
22649
|
+
useEffect$1(() => {
|
|
22617
22650
|
if (action) {
|
|
22618
22651
|
setConfig(configCHBApproverApplication({
|
|
22619
22652
|
t,
|
|
@@ -22713,7 +22746,7 @@ const ActionModal$9 = _ref => {
|
|
|
22713
22746
|
const _useState8 = useState(null),
|
|
22714
22747
|
setError = _useState8[1];
|
|
22715
22748
|
const _useState9 = useState(false);
|
|
22716
|
-
useEffect(() => {
|
|
22749
|
+
useEffect$1(() => {
|
|
22717
22750
|
var _approverData$Employe;
|
|
22718
22751
|
setApprovers(approverData === null || approverData === void 0 ? void 0 : (_approverData$Employe = approverData.Employees) === null || _approverData$Employe === void 0 ? void 0 : _approverData$Employe.map(employee => {
|
|
22719
22752
|
var _employee$user;
|
|
@@ -22726,7 +22759,7 @@ const ActionModal$9 = _ref => {
|
|
|
22726
22759
|
function selectFile(e) {
|
|
22727
22760
|
setFile(e.target.files[0]);
|
|
22728
22761
|
}
|
|
22729
|
-
useEffect(() => {
|
|
22762
|
+
useEffect$1(() => {
|
|
22730
22763
|
(function () {
|
|
22731
22764
|
try {
|
|
22732
22765
|
setError(null);
|
|
@@ -22783,7 +22816,7 @@ const ActionModal$9 = _ref => {
|
|
|
22783
22816
|
})]
|
|
22784
22817
|
});
|
|
22785
22818
|
}
|
|
22786
|
-
useEffect(() => {
|
|
22819
|
+
useEffect$1(() => {
|
|
22787
22820
|
if (action) {
|
|
22788
22821
|
setConfig(configEWApproverApplication({
|
|
22789
22822
|
t,
|
|
@@ -22884,7 +22917,7 @@ const ActionModal$a = _ref => {
|
|
|
22884
22917
|
const _useState8 = useState(false),
|
|
22885
22918
|
isUploading = _useState8[0],
|
|
22886
22919
|
setIsUploading = _useState8[1];
|
|
22887
|
-
useEffect(() => {
|
|
22920
|
+
useEffect$1(() => {
|
|
22888
22921
|
var _approverData$Employe;
|
|
22889
22922
|
setApprovers(approverData === null || approverData === void 0 ? void 0 : (_approverData$Employe = approverData.Employees) === null || _approverData$Employe === void 0 ? void 0 : _approverData$Employe.map(employee => {
|
|
22890
22923
|
var _employee$user;
|
|
@@ -22898,7 +22931,7 @@ const ActionModal$a = _ref => {
|
|
|
22898
22931
|
setIsUploading(true);
|
|
22899
22932
|
setFile(e.target.files[0]);
|
|
22900
22933
|
}
|
|
22901
|
-
useEffect(() => {
|
|
22934
|
+
useEffect$1(() => {
|
|
22902
22935
|
(function () {
|
|
22903
22936
|
try {
|
|
22904
22937
|
setError(null);
|
|
@@ -22960,7 +22993,7 @@ const ActionModal$a = _ref => {
|
|
|
22960
22993
|
})
|
|
22961
22994
|
});
|
|
22962
22995
|
}
|
|
22963
|
-
useEffect(() => {
|
|
22996
|
+
useEffect$1(() => {
|
|
22964
22997
|
setConfig(configSVApproverApplication({
|
|
22965
22998
|
t,
|
|
22966
22999
|
action,
|
|
@@ -23172,7 +23205,7 @@ const ActionModal$b = _ref => {
|
|
|
23172
23205
|
const _useState8 = useState(null),
|
|
23173
23206
|
selectVehicle = _useState8[0],
|
|
23174
23207
|
setSelectVehicle = _useState8[1];
|
|
23175
|
-
useEffect(() => {
|
|
23208
|
+
useEffect$1(() => {
|
|
23176
23209
|
var _approverData$Employe;
|
|
23177
23210
|
setApprovers(approverData === null || approverData === void 0 ? void 0 : (_approverData$Employe = approverData.Employees) === null || _approverData$Employe === void 0 ? void 0 : _approverData$Employe.map(employee => {
|
|
23178
23211
|
var _employee$user;
|
|
@@ -23185,7 +23218,7 @@ const ActionModal$b = _ref => {
|
|
|
23185
23218
|
function selectFile(e) {
|
|
23186
23219
|
setFile(e.target.files[0]);
|
|
23187
23220
|
}
|
|
23188
|
-
useEffect(() => {
|
|
23221
|
+
useEffect$1(() => {
|
|
23189
23222
|
(function () {
|
|
23190
23223
|
try {
|
|
23191
23224
|
setError(null);
|
|
@@ -23257,7 +23290,7 @@ const ActionModal$b = _ref => {
|
|
|
23257
23290
|
};
|
|
23258
23291
|
submitAction(requestPayload);
|
|
23259
23292
|
}
|
|
23260
|
-
useEffect(() => {
|
|
23293
|
+
useEffect$1(() => {
|
|
23261
23294
|
if (action) {
|
|
23262
23295
|
setConfig(configWTApproverApplication({
|
|
23263
23296
|
t,
|
|
@@ -23507,7 +23540,7 @@ const BPADocuments = _ref => {
|
|
|
23507
23540
|
const _Digit$Hooks$obps$use2 = Digit.Hooks.obps.useMDMS(stateId, "common-masters", ["DocumentType"]),
|
|
23508
23541
|
commonDocsLoading = _Digit$Hooks$obps$use2.isLoading,
|
|
23509
23542
|
commonDocs = _Digit$Hooks$obps$use2.data;
|
|
23510
|
-
useEffect(() => {
|
|
23543
|
+
useEffect$1(() => {
|
|
23511
23544
|
var _bpaDocs$BPA, _filtredBpaDocs, _filtredBpaDocs$, _filtredBpaDocs$$docT;
|
|
23512
23545
|
let filtredBpaDocs = [];
|
|
23513
23546
|
if (bpaDocs !== null && bpaDocs !== void 0 && (_bpaDocs$BPA = bpaDocs.BPA) !== null && _bpaDocs$BPA !== void 0 && _bpaDocs$BPA.DocTypeMapping) {
|
|
@@ -23544,7 +23577,7 @@ const BPADocuments = _ref => {
|
|
|
23544
23577
|
sessionStorage.setItem("BPA_DOCUMENTS", JSON.stringify(documentsList));
|
|
23545
23578
|
setBpaTaxDocuments(documentsList);
|
|
23546
23579
|
}, [!bpaDocsLoading, !commonDocsLoading]);
|
|
23547
|
-
useEffect(() => {
|
|
23580
|
+
useEffect$1(() => {
|
|
23548
23581
|
let count = 0;
|
|
23549
23582
|
bpaTaxDocuments.map(doc => {
|
|
23550
23583
|
let isRequired = false;
|
|
@@ -23559,7 +23592,7 @@ const BPADocuments = _ref => {
|
|
|
23559
23592
|
});
|
|
23560
23593
|
if ((count == "0" || count == 0) && documents.length > 0) setEnableSubmit(false);else setEnableSubmit(true);
|
|
23561
23594
|
}, [documents, checkRequiredFields]);
|
|
23562
|
-
useEffect(() => {
|
|
23595
|
+
useEffect$1(() => {
|
|
23563
23596
|
if (applicationStatus === "DOC_VERIFICATION_INPROGRESS" && (actions === null || actions === void 0 ? void 0 : actions.length) > 0) setCheckEnablingDocs(true);else setCheckEnablingDocs(false);
|
|
23564
23597
|
}, [applicationData, bpaActionsDetails]);
|
|
23565
23598
|
return /*#__PURE__*/React.createElement("div", null, bpaTaxDocuments === null || bpaTaxDocuments === void 0 ? void 0 : bpaTaxDocuments.map((document, index) => {
|
|
@@ -23614,7 +23647,7 @@ function SelectDocument(_ref2) {
|
|
|
23614
23647
|
function selectfiles(e) {
|
|
23615
23648
|
e && setFile(e.file);
|
|
23616
23649
|
}
|
|
23617
|
-
useEffect(() => {
|
|
23650
|
+
useEffect$1(() => {
|
|
23618
23651
|
if (selectedDocument !== null && selectedDocument !== void 0 && selectedDocument.code) {
|
|
23619
23652
|
setDocuments(prev => {
|
|
23620
23653
|
var _documents$find;
|
|
@@ -23631,7 +23664,7 @@ function SelectDocument(_ref2) {
|
|
|
23631
23664
|
});
|
|
23632
23665
|
}
|
|
23633
23666
|
}, [uploadedFile, selectedDocument]);
|
|
23634
|
-
useEffect(() => {
|
|
23667
|
+
useEffect$1(() => {
|
|
23635
23668
|
try {
|
|
23636
23669
|
if (selectArrayFiles.length > 0) {
|
|
23637
23670
|
sessionStorage.removeItem("BPA_DOCUMENTS");
|
|
@@ -23654,7 +23687,7 @@ function SelectDocument(_ref2) {
|
|
|
23654
23687
|
Promise.reject(e);
|
|
23655
23688
|
}
|
|
23656
23689
|
}, [selectArrayFiles, selectedDocument]);
|
|
23657
|
-
useEffect(() => {
|
|
23690
|
+
useEffect$1(() => {
|
|
23658
23691
|
}, [file]);
|
|
23659
23692
|
const getData = (index, state) => {
|
|
23660
23693
|
let data = Object.fromEntries(state);
|
|
@@ -23846,7 +23879,7 @@ function SelectDocument$1(_ref) {
|
|
|
23846
23879
|
function selectfile(e) {
|
|
23847
23880
|
e && setFile(e.file);
|
|
23848
23881
|
}
|
|
23849
|
-
useEffect(() => {
|
|
23882
|
+
useEffect$1(() => {
|
|
23850
23883
|
var _doc$dropdownData, _doc$dropdownData$;
|
|
23851
23884
|
if (doc !== null && doc !== void 0 && (_doc$dropdownData = doc.dropdownData) !== null && _doc$dropdownData !== void 0 && (_doc$dropdownData$ = _doc$dropdownData[0]) !== null && _doc$dropdownData$ !== void 0 && _doc$dropdownData$.code) {
|
|
23852
23885
|
setNocDocuments(prev => {
|
|
@@ -23868,7 +23901,7 @@ function SelectDocument$1(_ref) {
|
|
|
23868
23901
|
});
|
|
23869
23902
|
}
|
|
23870
23903
|
}, [uploadedFile]);
|
|
23871
|
-
useEffect(() => {
|
|
23904
|
+
useEffect$1(() => {
|
|
23872
23905
|
(function () {
|
|
23873
23906
|
try {
|
|
23874
23907
|
setError(null);
|
|
@@ -23982,11 +24015,11 @@ const NOCDocuments = _ref2 => {
|
|
|
23982
24015
|
error = _useState7[0],
|
|
23983
24016
|
setError = _useState7[1];
|
|
23984
24017
|
const isEmployee = window.location.href.includes("/employee/");
|
|
23985
|
-
useEffect(() => {
|
|
24018
|
+
useEffect$1(() => {
|
|
23986
24019
|
var _commonDocs$commonMa;
|
|
23987
24020
|
setCommonDocMaping(commonDocs === null || commonDocs === void 0 ? void 0 : (_commonDocs$commonMa = commonDocs["common-masters"]) === null || _commonDocs$commonMa === void 0 ? void 0 : _commonDocs$commonMa.DocumentType);
|
|
23988
24021
|
}, [commonDocs]);
|
|
23989
|
-
useEffect(() => {
|
|
24022
|
+
useEffect$1(() => {
|
|
23990
24023
|
var _filteredData, _filteredData$, _filteredData$$docTyp;
|
|
23991
24024
|
let documents = [];
|
|
23992
24025
|
let filteredData;
|
|
@@ -24029,7 +24062,7 @@ const NOCDocuments = _ref2 => {
|
|
|
24029
24062
|
setNocTaxDocuments(documentsList);
|
|
24030
24063
|
}
|
|
24031
24064
|
}, [nocDocs, commonDocMaping]);
|
|
24032
|
-
useEffect(() => {
|
|
24065
|
+
useEffect$1(() => {
|
|
24033
24066
|
if (bpaApplicationStatus === "NOC_VERIFICATION_INPROGRESS" && (actions === null || actions === void 0 ? void 0 : actions.length) > 0) setCheckEnablingDocs(true);else setCheckEnablingDocs(false);
|
|
24034
24067
|
}, [applicationData, bpaActionsDetails]);
|
|
24035
24068
|
return /*#__PURE__*/React.createElement("div", {
|
|
@@ -24102,7 +24135,7 @@ const PermissionCheck = _ref => {
|
|
|
24102
24135
|
const _Digit$Hooks$useSessi2 = Digit.Hooks.useSessionStorage('OBPS_NEW_APPROVALS', []),
|
|
24103
24136
|
newApprovals = _Digit$Hooks$useSessi2[0],
|
|
24104
24137
|
setNewApprovals = _Digit$Hooks$useSessi2[1];
|
|
24105
|
-
useEffect(() => {
|
|
24138
|
+
useEffect$1(() => {
|
|
24106
24139
|
return () => {
|
|
24107
24140
|
Digit.SessionStorage.del("OBPS_NEW_APPROVALS");
|
|
24108
24141
|
Digit.SessionStorage.del("OBPS_APPROVAL_CHECKS");
|
|
@@ -24218,7 +24251,7 @@ function PropertyDocuments(_ref) {
|
|
|
24218
24251
|
const _useState4 = useState({}),
|
|
24219
24252
|
checkedMap = _useState4[0],
|
|
24220
24253
|
setCheckedMap = _useState4[1];
|
|
24221
|
-
useEffect(() => {
|
|
24254
|
+
useEffect$1(() => {
|
|
24222
24255
|
let requiredDocsCount = 0;
|
|
24223
24256
|
let checkedCount = 0;
|
|
24224
24257
|
documents === null || documents === void 0 ? void 0 : documents.forEach(document => {
|
|
@@ -24242,7 +24275,7 @@ function PropertyDocuments(_ref) {
|
|
|
24242
24275
|
detail: finalVerified
|
|
24243
24276
|
}));
|
|
24244
24277
|
}, [checkedMap, documents, applicationStatus]);
|
|
24245
|
-
useEffect(() => {
|
|
24278
|
+
useEffect$1(() => {
|
|
24246
24279
|
var _acc;
|
|
24247
24280
|
let acc = [];
|
|
24248
24281
|
documents === null || documents === void 0 ? void 0 : documents.forEach(element => {
|
|
@@ -24250,7 +24283,7 @@ function PropertyDocuments(_ref) {
|
|
|
24250
24283
|
});
|
|
24251
24284
|
setFilesArray((_acc = acc) === null || _acc === void 0 ? void 0 : _acc.map(value => value === null || value === void 0 ? void 0 : value.fileStoreId));
|
|
24252
24285
|
}, [documents]);
|
|
24253
|
-
useEffect(() => {
|
|
24286
|
+
useEffect$1(() => {
|
|
24254
24287
|
var _documents$;
|
|
24255
24288
|
if (filesArray !== null && filesArray !== void 0 && filesArray.length && (documents === null || documents === void 0 ? void 0 : (_documents$ = documents[0]) === null || _documents$ === void 0 ? void 0 : _documents$.BS) === "BillAmend") {
|
|
24256
24289
|
Digit.UploadServices.Filefetch(filesArray, Digit.ULBService.getCurrentTenantId()).then(res => {
|
|
@@ -25342,7 +25375,7 @@ const WSFeeEstimation = _ref => {
|
|
|
25342
25375
|
setValues = _useState5[1];
|
|
25343
25376
|
const stateCode = Digit.ULBService.getStateId();
|
|
25344
25377
|
const _Digit$Hooks$ws$useMD = Digit.Hooks.ws.useMDMS(stateCode, "BillingService", ["TaxHeadMaster"]);
|
|
25345
|
-
useEffect(() => {
|
|
25378
|
+
useEffect$1(() => {
|
|
25346
25379
|
var _wsAdditionalDetails$2, _wsAdditionalDetails$3, _sessionFormData$bill;
|
|
25347
25380
|
const data = _extends({}, wsAdditionalDetails === null || wsAdditionalDetails === void 0 ? void 0 : (_wsAdditionalDetails$2 = wsAdditionalDetails.additionalDetails) === null || _wsAdditionalDetails$2 === void 0 ? void 0 : (_wsAdditionalDetails$3 = _wsAdditionalDetails$2.appDetails) === null || _wsAdditionalDetails$3 === void 0 ? void 0 : _wsAdditionalDetails$3.additionalDetails);
|
|
25348
25381
|
if ((sessionFormData === null || sessionFormData === void 0 ? void 0 : (_sessionFormData$bill = sessionFormData.billDetails) === null || _sessionFormData$bill === void 0 ? void 0 : _sessionFormData$bill.length) > 0) {
|
|
@@ -25831,29 +25864,7 @@ const ViewBreakup = _ref => {
|
|
|
25831
25864
|
textStyle: {
|
|
25832
25865
|
textAlign: "right"
|
|
25833
25866
|
}
|
|
25834
|
-
})), /*#__PURE__*/React.createElement(
|
|
25835
|
-
style: {
|
|
25836
|
-
color: "#cccccc",
|
|
25837
|
-
backgroundColor: "#cccccc",
|
|
25838
|
-
marginBottom: "10px"
|
|
25839
|
-
}
|
|
25840
|
-
}), /*#__PURE__*/React.createElement(Row, {
|
|
25841
|
-
className: "border-none",
|
|
25842
|
-
rowContainerStyle: {
|
|
25843
|
-
margin: "0px"
|
|
25844
|
-
},
|
|
25845
|
-
labelStyle: {
|
|
25846
|
-
width: "50%"
|
|
25847
|
-
},
|
|
25848
|
-
key: "PDF_STATIC_LABEL_CONSOLIDATED_TLAPP_TOTAL_AMOUNT1",
|
|
25849
|
-
label: "" + t("PDF_STATIC_LABEL_CONSOLIDATED_TLAPP_TOTAL_AMOUNT"),
|
|
25850
|
-
text: /*#__PURE__*/React.createElement("span", null, "\u20B9", Number(breakUpData === null || breakUpData === void 0 ? void 0 : breakUpData.fee) || 0),
|
|
25851
|
-
textStyle: {
|
|
25852
|
-
textAlign: "right",
|
|
25853
|
-
fontWeight: "700",
|
|
25854
|
-
fontSize: "24px"
|
|
25855
|
-
}
|
|
25856
|
-
}), /*#__PURE__*/React.createElement(CardSectionHeader, {
|
|
25867
|
+
})), /*#__PURE__*/React.createElement(CardSectionHeader, {
|
|
25857
25868
|
style: {
|
|
25858
25869
|
margin: "10px 0px"
|
|
25859
25870
|
}
|
|
@@ -25871,29 +25882,7 @@ const ViewBreakup = _ref => {
|
|
|
25871
25882
|
textStyle: {
|
|
25872
25883
|
textAlign: "right"
|
|
25873
25884
|
}
|
|
25874
|
-
})), /*#__PURE__*/React.createElement(
|
|
25875
|
-
style: {
|
|
25876
|
-
color: "#cccccc",
|
|
25877
|
-
backgroundColor: "#cccccc",
|
|
25878
|
-
marginBottom: "10px"
|
|
25879
|
-
}
|
|
25880
|
-
}), /*#__PURE__*/React.createElement(Row, {
|
|
25881
|
-
className: "border-none",
|
|
25882
|
-
rowContainerStyle: {
|
|
25883
|
-
margin: "0px"
|
|
25884
|
-
},
|
|
25885
|
-
labelStyle: {
|
|
25886
|
-
width: "50%"
|
|
25887
|
-
},
|
|
25888
|
-
key: "PDF_STATIC_LABEL_CONSOLIDATED_TLAPP_TOTAL_AMOUNT2",
|
|
25889
|
-
label: "" + t("PDF_STATIC_LABEL_CONSOLIDATED_TLAPP_TOTAL_AMOUNT"),
|
|
25890
|
-
text: /*#__PURE__*/React.createElement("span", null, "\u20B9", Number(breakUpData === null || breakUpData === void 0 ? void 0 : breakUpData.charge) || 0),
|
|
25891
|
-
textStyle: {
|
|
25892
|
-
textAlign: "right",
|
|
25893
|
-
fontWeight: "700",
|
|
25894
|
-
fontSize: "24px"
|
|
25895
|
-
}
|
|
25896
|
-
}), breakUpData === null || breakUpData === void 0 ? void 0 : (_breakUpData$billSlab5 = breakUpData.billSlabData) === null || _breakUpData$billSlab5 === void 0 ? void 0 : (_breakUpData$billSlab6 = _breakUpData$billSlab5.TAX) === null || _breakUpData$billSlab6 === void 0 ? void 0 : _breakUpData$billSlab6.map(data => /*#__PURE__*/React.createElement(Row, {
|
|
25885
|
+
})), breakUpData === null || breakUpData === void 0 ? void 0 : (_breakUpData$billSlab5 = breakUpData.billSlabData) === null || _breakUpData$billSlab5 === void 0 ? void 0 : (_breakUpData$billSlab6 = _breakUpData$billSlab5.TAX) === null || _breakUpData$billSlab6 === void 0 ? void 0 : _breakUpData$billSlab6.map(data => /*#__PURE__*/React.createElement(Row, {
|
|
25897
25886
|
className: "border-none",
|
|
25898
25887
|
rowContainerStyle: {
|
|
25899
25888
|
margin: "0px"
|
|
@@ -26225,7 +26214,8 @@ const DueVerification = _ref => {
|
|
|
26225
26214
|
return newData;
|
|
26226
26215
|
});
|
|
26227
26216
|
}, [applicationData]);
|
|
26228
|
-
const isPendingApproval = (applicationData === null || applicationData === void 0 ? void 0 : applicationData.applicationStatus) === "PENDING_APPROVAL_FOR_CONNECTION";
|
|
26217
|
+
const isPendingApproval = (applicationData === null || applicationData === void 0 ? void 0 : applicationData.applicationStatus) === "PENDING_APPROVAL_FOR_CONNECTION" || (applicationData === null || applicationData === void 0 ? void 0 : applicationData.applicationStatus) === "PENDING_FOR_CONNECTION_ACTIVATION";
|
|
26218
|
+
const isActivation = (applicationData === null || applicationData === void 0 ? void 0 : applicationData.applicationStatus) === "PENDING_FOR_CONNECTION_ACTIVATION";
|
|
26229
26219
|
const columns = useMemo(() => {
|
|
26230
26220
|
const baseColumns = [{
|
|
26231
26221
|
Header: t("K No."),
|
|
@@ -26250,7 +26240,7 @@ const DueVerification = _ref => {
|
|
|
26250
26240
|
Cell: _ref2 => {
|
|
26251
26241
|
let row = _ref2.row,
|
|
26252
26242
|
value = _ref2.value;
|
|
26253
|
-
return /*#__PURE__*/React.createElement(TextInput, {
|
|
26243
|
+
return isActivation ? value || "-" : /*#__PURE__*/React.createElement(TextInput, {
|
|
26254
26244
|
style: {
|
|
26255
26245
|
marginBottom: "0px",
|
|
26256
26246
|
minWidth: "150px"
|
|
@@ -26263,7 +26253,7 @@ const DueVerification = _ref => {
|
|
|
26263
26253
|
}
|
|
26264
26254
|
return baseColumns;
|
|
26265
26255
|
}, [t, handleRemarkChange, isPendingApproval]);
|
|
26266
|
-
useEffect(() => {
|
|
26256
|
+
useEffect$1(() => {
|
|
26267
26257
|
if (applicationData !== null && applicationData !== void 0 && applicationData.dueVerification && Array.isArray(applicationData.dueVerification)) {
|
|
26268
26258
|
setTableData(applicationData.dueVerification);
|
|
26269
26259
|
}
|
|
@@ -26332,7 +26322,7 @@ const DueVerification = _ref => {
|
|
|
26332
26322
|
flex: 1,
|
|
26333
26323
|
paddingBottom: "2px"
|
|
26334
26324
|
}
|
|
26335
|
-
}, /*#__PURE__*/React.createElement("button", {
|
|
26325
|
+
}, !isActivation && /*#__PURE__*/React.createElement("button", {
|
|
26336
26326
|
type: "button",
|
|
26337
26327
|
onClick: handleAdd,
|
|
26338
26328
|
style: {
|
|
@@ -26379,31 +26369,13 @@ const InspectionInformation = _ref => {
|
|
|
26379
26369
|
const _useState3 = useState(""),
|
|
26380
26370
|
inspectorName = _useState3[0],
|
|
26381
26371
|
setInspectorName = _useState3[1];
|
|
26382
|
-
useEffect(() => {
|
|
26383
|
-
|
|
26384
|
-
|
|
26385
|
-
|
|
26386
|
-
|
|
26387
|
-
setInspectionType(parsed.inspectionType || null);
|
|
26388
|
-
setInspectionDate(parsed.inspectionDate || "");
|
|
26389
|
-
setInspectorName(parsed.inspectorName || "");
|
|
26390
|
-
} catch (e) {
|
|
26391
|
-
console.error("Error parsing inspection information data", e);
|
|
26392
|
-
}
|
|
26393
|
-
} else if (applicationData !== null && applicationData !== void 0 && applicationData.inspectionInformation) {
|
|
26394
|
-
setInspectionType(applicationData.inspectionInformation.inspectionType || null);
|
|
26395
|
-
setInspectionDate(applicationData.inspectionInformation.inspectionDate || "");
|
|
26396
|
-
setInspectorName(applicationData.inspectionInformation.inspectorName || "");
|
|
26397
|
-
sessionStorage.setItem("Digit.INSPECTION_INFORMATION_DATA", JSON.stringify(applicationData.inspectionInformation));
|
|
26372
|
+
useEffect$1(() => {
|
|
26373
|
+
if (applicationData !== null && applicationData !== void 0 && applicationData.inspectionInformation) {
|
|
26374
|
+
setInspectionType(applicationData.inspectionInformation.inspectionType);
|
|
26375
|
+
setInspectionDate(applicationData.inspectionInformation.inspectionDate);
|
|
26376
|
+
setInspectorName(applicationData.inspectionInformation.inspectorName);
|
|
26398
26377
|
}
|
|
26399
26378
|
}, [applicationData]);
|
|
26400
|
-
useEffect(() => {
|
|
26401
|
-
sessionStorage.setItem("Digit.INSPECTION_INFORMATION_DATA", JSON.stringify({
|
|
26402
|
-
inspectionType,
|
|
26403
|
-
inspectionDate,
|
|
26404
|
-
inspectorName
|
|
26405
|
-
}));
|
|
26406
|
-
}, [inspectionType, inspectionDate, inspectorName]);
|
|
26407
26379
|
const inspectionTypeOptions = [{
|
|
26408
26380
|
i18nKey: "ES_COMMON_SELECT",
|
|
26409
26381
|
code: ""
|
|
@@ -26411,6 +26383,7 @@ const InspectionInformation = _ref => {
|
|
|
26411
26383
|
i18nKey: "New Connection Visit",
|
|
26412
26384
|
code: "new_connection_visit"
|
|
26413
26385
|
}];
|
|
26386
|
+
const readOnly = (applicationData === null || applicationData === void 0 ? void 0 : applicationData.applicationStatus) === "PENDING_FOR_CONNECTION_ACTIVATION";
|
|
26414
26387
|
return /*#__PURE__*/React.createElement("div", {
|
|
26415
26388
|
style: {
|
|
26416
26389
|
marginBottom: "20px"
|
|
@@ -26430,84 +26403,58 @@ const InspectionInformation = _ref => {
|
|
|
26430
26403
|
}
|
|
26431
26404
|
}, /*#__PURE__*/React.createElement("div", {
|
|
26432
26405
|
style: {
|
|
26433
|
-
flex:
|
|
26406
|
+
flex: 1
|
|
26434
26407
|
}
|
|
26435
26408
|
}, /*#__PURE__*/React.createElement("span", {
|
|
26436
26409
|
style: {
|
|
26437
26410
|
fontSize: "16px",
|
|
26438
|
-
color: "#0B0C0C",
|
|
26439
26411
|
marginBottom: "8px",
|
|
26440
26412
|
display: "inline-block"
|
|
26441
26413
|
}
|
|
26442
|
-
}, t("Inspection Type"),
|
|
26443
|
-
style: {
|
|
26444
|
-
color: "red"
|
|
26445
|
-
}
|
|
26446
|
-
}, "*")), /*#__PURE__*/React.createElement(Dropdown, {
|
|
26414
|
+
}, t("Inspection Type")), /*#__PURE__*/React.createElement(Dropdown, {
|
|
26447
26415
|
option: inspectionTypeOptions,
|
|
26448
26416
|
optionKey: "i18nKey",
|
|
26449
|
-
id: "inspectionType",
|
|
26450
26417
|
selected: inspectionType,
|
|
26451
26418
|
select: setInspectionType,
|
|
26452
26419
|
t: t,
|
|
26453
|
-
|
|
26454
|
-
width: "100%"
|
|
26455
|
-
}
|
|
26420
|
+
disabled: readOnly
|
|
26456
26421
|
})), /*#__PURE__*/React.createElement("div", {
|
|
26457
26422
|
style: {
|
|
26458
|
-
flex:
|
|
26423
|
+
flex: 1
|
|
26459
26424
|
}
|
|
26460
26425
|
}, /*#__PURE__*/React.createElement("span", {
|
|
26461
26426
|
style: {
|
|
26462
26427
|
fontSize: "16px",
|
|
26463
|
-
color: "#0B0C0C",
|
|
26464
26428
|
marginBottom: "8px",
|
|
26465
26429
|
display: "inline-block"
|
|
26466
26430
|
}
|
|
26467
|
-
}, t("Inspection Date"),
|
|
26468
|
-
style: {
|
|
26469
|
-
color: "red"
|
|
26470
|
-
}
|
|
26471
|
-
}, "*")), /*#__PURE__*/React.createElement(DatePicker, {
|
|
26431
|
+
}, t("Inspection Date")), /*#__PURE__*/React.createElement(DatePicker, {
|
|
26472
26432
|
date: inspectionDate,
|
|
26473
26433
|
onChange: setInspectionDate,
|
|
26474
|
-
|
|
26475
|
-
width: "100%"
|
|
26476
|
-
}
|
|
26434
|
+
disabled: readOnly
|
|
26477
26435
|
}))), /*#__PURE__*/React.createElement("div", {
|
|
26478
26436
|
style: {
|
|
26479
|
-
display: "flex"
|
|
26480
|
-
gap: "20px",
|
|
26481
|
-
marginBottom: "20px",
|
|
26482
|
-
flexWrap: "wrap"
|
|
26437
|
+
display: "flex"
|
|
26483
26438
|
}
|
|
26484
26439
|
}, /*#__PURE__*/React.createElement("div", {
|
|
26485
26440
|
style: {
|
|
26486
|
-
flex:
|
|
26441
|
+
flex: 1
|
|
26487
26442
|
}
|
|
26488
26443
|
}, /*#__PURE__*/React.createElement("span", {
|
|
26489
26444
|
style: {
|
|
26490
26445
|
fontSize: "16px",
|
|
26491
|
-
color: "#0B0C0C",
|
|
26492
26446
|
marginBottom: "8px",
|
|
26493
26447
|
display: "inline-block"
|
|
26494
26448
|
}
|
|
26495
|
-
}, t("Inspector Name"),
|
|
26496
|
-
style: {
|
|
26497
|
-
color: "red"
|
|
26498
|
-
}
|
|
26499
|
-
}, "*")), /*#__PURE__*/React.createElement(TextInput, {
|
|
26449
|
+
}, t("Inspector Name")), /*#__PURE__*/React.createElement(TextInput, {
|
|
26500
26450
|
value: inspectorName,
|
|
26501
26451
|
onChange: e => setInspectorName(e.target.value),
|
|
26502
|
-
|
|
26503
|
-
width: "50%",
|
|
26504
|
-
marginBottom: "0"
|
|
26505
|
-
}
|
|
26452
|
+
disabled: readOnly
|
|
26506
26453
|
}))));
|
|
26507
26454
|
};
|
|
26508
26455
|
|
|
26509
26456
|
function ApplicationDetailsContent(_ref) {
|
|
26510
|
-
var _applicationDetails$a, _workflowDetails$data3, _workflowDetails$data4, _workflowDetails$data5, _workflowDetails$data6, _workflowDetails$data7, _workflowDetails$data8, _workflowDetails$data9, _workflowDetails$data0, _workflowDetails$data1, _workflowDetails$data10, _workflowDetails$data11, _workflowDetails$data19, _workflowDetails$data20;
|
|
26457
|
+
var _detail, _detail$additionalDet, _applicationDetails$a, _workflowDetails$data3, _workflowDetails$data4, _workflowDetails$data5, _workflowDetails$data6, _workflowDetails$data7, _workflowDetails$data8, _workflowDetails$data9, _workflowDetails$data0, _workflowDetails$data1, _workflowDetails$data10, _workflowDetails$data11, _workflowDetails$data19, _workflowDetails$data20;
|
|
26511
26458
|
let applicationDetails = _ref.applicationDetails,
|
|
26512
26459
|
workflowDetails = _ref.workflowDetails,
|
|
26513
26460
|
isDataLoading = _ref.isDataLoading,
|
|
@@ -26521,6 +26468,7 @@ function ApplicationDetailsContent(_ref) {
|
|
|
26521
26468
|
oldValue = _ref.oldValue,
|
|
26522
26469
|
_ref$isInfoLabel = _ref.isInfoLabel,
|
|
26523
26470
|
isInfoLabel = _ref$isInfoLabel === void 0 ? false : _ref$isInfoLabel;
|
|
26471
|
+
alert("ApplicationDetailsContent Loaded");
|
|
26524
26472
|
const _useTranslation = useTranslation(),
|
|
26525
26473
|
t = _useTranslation.t;
|
|
26526
26474
|
const _useState = useState(false),
|
|
@@ -26535,6 +26483,19 @@ function ApplicationDetailsContent(_ref) {
|
|
|
26535
26483
|
const _useState2 = useState({}),
|
|
26536
26484
|
fetchBillData = _useState2[0],
|
|
26537
26485
|
updatefetchBillData = _useState2[1];
|
|
26486
|
+
const isMounted = React.useRef(true);
|
|
26487
|
+
useEffect(() => {
|
|
26488
|
+
return () => {
|
|
26489
|
+
isMounted.current = false;
|
|
26490
|
+
};
|
|
26491
|
+
}, []);
|
|
26492
|
+
const _useState3 = useState({
|
|
26493
|
+
loading: false,
|
|
26494
|
+
loaded: false,
|
|
26495
|
+
canLoad: false
|
|
26496
|
+
}),
|
|
26497
|
+
billData = _useState3[0],
|
|
26498
|
+
updateCanFetchBillData = _useState3[1];
|
|
26538
26499
|
const setBillData = function (tenantId, propertyIds, updatefetchBillData, updateCanFetchBillData) {
|
|
26539
26500
|
try {
|
|
26540
26501
|
return Promise.resolve(Digit.PTService.assessmentSearch({
|
|
@@ -26544,12 +26505,14 @@ function ApplicationDetailsContent(_ref) {
|
|
|
26544
26505
|
}
|
|
26545
26506
|
})).then(function (assessmentData) {
|
|
26546
26507
|
function _temp2() {
|
|
26547
|
-
|
|
26548
|
-
|
|
26549
|
-
|
|
26550
|
-
|
|
26551
|
-
|
|
26552
|
-
|
|
26508
|
+
if (isMounted.current) {
|
|
26509
|
+
updatefetchBillData(billData);
|
|
26510
|
+
updateCanFetchBillData({
|
|
26511
|
+
loading: false,
|
|
26512
|
+
loaded: true,
|
|
26513
|
+
canLoad: true
|
|
26514
|
+
});
|
|
26515
|
+
}
|
|
26553
26516
|
}
|
|
26554
26517
|
let billData = {};
|
|
26555
26518
|
const _temp = function (_assessmentData$Asses) {
|
|
@@ -26568,28 +26531,23 @@ function ApplicationDetailsContent(_ref) {
|
|
|
26568
26531
|
return Promise.reject(e);
|
|
26569
26532
|
}
|
|
26570
26533
|
};
|
|
26571
|
-
|
|
26572
|
-
|
|
26573
|
-
|
|
26574
|
-
|
|
26575
|
-
|
|
26576
|
-
|
|
26577
|
-
|
|
26578
|
-
|
|
26579
|
-
|
|
26580
|
-
|
|
26581
|
-
|
|
26582
|
-
|
|
26583
|
-
|
|
26584
|
-
|
|
26585
|
-
|
|
26586
|
-
|
|
26587
|
-
|
|
26588
|
-
loaded: false,
|
|
26589
|
-
canLoad: true
|
|
26590
|
-
});
|
|
26591
|
-
setBillData((applicationData === null || applicationData === void 0 ? void 0 : applicationData.tenantId) || tenantId, applicationData === null || applicationData === void 0 ? void 0 : applicationData.propertyId, updatefetchBillData, updateCanFetchBillData);
|
|
26592
|
-
}
|
|
26534
|
+
useEffect(() => {
|
|
26535
|
+
if ((applicationData === null || applicationData === void 0 ? void 0 : applicationData.status) === "ACTIVE" && !billData.loading && !billData.loaded && !billData.canLoad) {
|
|
26536
|
+
updateCanFetchBillData({
|
|
26537
|
+
loading: false,
|
|
26538
|
+
loaded: false,
|
|
26539
|
+
canLoad: true
|
|
26540
|
+
});
|
|
26541
|
+
}
|
|
26542
|
+
if (billData !== null && billData !== void 0 && billData.canLoad && !billData.loading && !billData.loaded) {
|
|
26543
|
+
updateCanFetchBillData({
|
|
26544
|
+
loading: true,
|
|
26545
|
+
loaded: false,
|
|
26546
|
+
canLoad: true
|
|
26547
|
+
});
|
|
26548
|
+
setBillData((applicationData === null || applicationData === void 0 ? void 0 : applicationData.tenantId) || tenantId, applicationData === null || applicationData === void 0 ? void 0 : applicationData.propertyId, updatefetchBillData, updateCanFetchBillData);
|
|
26549
|
+
}
|
|
26550
|
+
}, [applicationData, billData, tenantId]);
|
|
26593
26551
|
const convertEpochToDateDMY = dateEpoch => {
|
|
26594
26552
|
if (dateEpoch == null || dateEpoch === undefined || dateEpoch === "") {
|
|
26595
26553
|
return "NA";
|
|
@@ -26774,6 +26732,11 @@ function ApplicationDetailsContent(_ref) {
|
|
|
26774
26732
|
const handleViewClick = data => {
|
|
26775
26733
|
setShowPopup(true);
|
|
26776
26734
|
};
|
|
26735
|
+
console.log("applicationStatus", applicationData === null || applicationData === void 0 ? void 0 : applicationData.applicationStatus);
|
|
26736
|
+
console.log("documents", (_detail = detail) === null || _detail === void 0 ? void 0 : (_detail$additionalDet = _detail.additionalDetails) === null || _detail$additionalDet === void 0 ? void 0 : _detail$additionalDet.documents);
|
|
26737
|
+
console.log("dueVerification", applicationData === null || applicationData === void 0 ? void 0 : applicationData.dueVerification);
|
|
26738
|
+
console.log("inspectionInformation", applicationData === null || applicationData === void 0 ? void 0 : applicationData.inspectionInformation);
|
|
26739
|
+
console.log(detail);
|
|
26777
26740
|
return /*#__PURE__*/React.createElement(Card, {
|
|
26778
26741
|
style: {
|
|
26779
26742
|
position: "relative"
|
|
@@ -26787,7 +26750,7 @@ function ApplicationDetailsContent(_ref) {
|
|
|
26787
26750
|
infoClickInfoLabel: getClickInfoDetails(),
|
|
26788
26751
|
infoClickInfoLabel1: getClickInfoDetails1()
|
|
26789
26752
|
}) : null, applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$a = applicationDetails.applicationDetails) === null || _applicationDetails$a === void 0 ? void 0 : _applicationDetails$a.map((detail, index) => {
|
|
26790
|
-
var _detail$title, _detail$values, _detail$
|
|
26753
|
+
var _detail$title, _detail$values, _detail$additionalDet2, _applicationDetails$a2, _applicationDetails$a3, _applicationDetails$a4, _detail$additionalDet3, _applicationDetails$a5, _applicationDetails$a6, _detail$additionalDet4, _detail$additionalDet5, _detail$additionalDet6, _detail$additionalDet7, _detail$additionalDet8, _detail$additionalDet9, _detail$additionalDet0, _workflowDetails$data, _workflowDetails$data2, _detail$additionalDet1, _detail$additionalDet10, _detail$additionalDet11, _detail$additionalDet12, _detail$additionalDet13, _detail$additionalDet14, _detail$additionalDet15, _detail$additionalDet16, _detail$additionalDet17, _detail$additionalDet18, _detail$additionalDet19, _detail$additionalDet20, _detail$additionalDet21, _detail$additionalDet22, _detail$additionalDet23, _detail$additionalDet24, _detail$additionalDet25, _detail$additionalDet26, _detail$additionalDet27, _detail$additionalDet28, _detail$additionalDet29, _detail$additionalDet30;
|
|
26791
26754
|
return /*#__PURE__*/React.createElement(React.Fragment, {
|
|
26792
26755
|
key: index
|
|
26793
26756
|
}, /*#__PURE__*/React.createElement("div", {
|
|
@@ -26978,61 +26941,69 @@ function ApplicationDetailsContent(_ref) {
|
|
|
26978
26941
|
}), value.title === "PT_TOTAL_DUES" ? /*#__PURE__*/React.createElement(ArrearSummary, {
|
|
26979
26942
|
bill: (_fetchBillData$Bill = fetchBillData.Bill) === null || _fetchBillData$Bill === void 0 ? void 0 : _fetchBillData$Bill[0]
|
|
26980
26943
|
}) : "");
|
|
26981
|
-
})))), (detail === null || detail === void 0 ? void 0 : detail.belowComponent) && /*#__PURE__*/React.createElement(detail.belowComponent, null), (detail === null || detail === void 0 ? void 0 : (_detail$
|
|
26944
|
+
})))), (detail === null || detail === void 0 ? void 0 : detail.belowComponent) && /*#__PURE__*/React.createElement(detail.belowComponent, null), (detail === null || detail === void 0 ? void 0 : (_detail$additionalDet2 = detail.additionalDetails) === null || _detail$additionalDet2 === void 0 ? void 0 : _detail$additionalDet2.inspectionReport) && /*#__PURE__*/React.createElement(ScruntinyDetails, {
|
|
26982
26945
|
scrutinyDetails: detail === null || detail === void 0 ? void 0 : detail.additionalDetails,
|
|
26983
26946
|
paymentsList: paymentsList
|
|
26984
|
-
}), (applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$a2 = applicationDetails.applicationData) === null || _applicationDetails$a2 === void 0 ? void 0 : (_applicationDetails$a3 = _applicationDetails$a2.additionalDetails) === null || _applicationDetails$a3 === void 0 ? void 0 : (_applicationDetails$a4 = _applicationDetails$a3.fieldinspection_pending) === null || _applicationDetails$a4 === void 0 ? void 0 : _applicationDetails$a4.length) > 0 && (detail === null || detail === void 0 ? void 0 : (_detail$
|
|
26947
|
+
}), (applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$a2 = applicationDetails.applicationData) === null || _applicationDetails$a2 === void 0 ? void 0 : (_applicationDetails$a3 = _applicationDetails$a2.additionalDetails) === null || _applicationDetails$a3 === void 0 ? void 0 : (_applicationDetails$a4 = _applicationDetails$a3.fieldinspection_pending) === null || _applicationDetails$a4 === void 0 ? void 0 : _applicationDetails$a4.length) > 0 && (detail === null || detail === void 0 ? void 0 : (_detail$additionalDet3 = detail.additionalDetails) === null || _detail$additionalDet3 === void 0 ? void 0 : _detail$additionalDet3.fiReport) && /*#__PURE__*/React.createElement(InspectionReport, {
|
|
26985
26948
|
fiReport: applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$a5 = applicationDetails.applicationData) === null || _applicationDetails$a5 === void 0 ? void 0 : (_applicationDetails$a6 = _applicationDetails$a5.additionalDetails) === null || _applicationDetails$a6 === void 0 ? void 0 : _applicationDetails$a6.fieldinspection_pending
|
|
26986
|
-
}), (detail === null || detail === void 0 ? void 0 : (_detail$
|
|
26987
|
-
floors: detail === null || detail === void 0 ? void 0 : (_detail$
|
|
26988
|
-
}), (detail === null || detail === void 0 ? void 0 : (_detail$
|
|
26989
|
-
units: detail === null || detail === void 0 ? void 0 : (_detail$
|
|
26990
|
-
}), (detail === null || detail === void 0 ? void 0 : (_detail$
|
|
26991
|
-
units: detail === null || detail === void 0 ? void 0 : (_detail$
|
|
26992
|
-
}), (detail === null || detail === void 0 ? void 0 : (_detail$
|
|
26949
|
+
}), (detail === null || detail === void 0 ? void 0 : (_detail$additionalDet4 = detail.additionalDetails) === null || _detail$additionalDet4 === void 0 ? void 0 : _detail$additionalDet4.floors) && /*#__PURE__*/React.createElement(PropertyFloors, {
|
|
26950
|
+
floors: detail === null || detail === void 0 ? void 0 : (_detail$additionalDet5 = detail.additionalDetails) === null || _detail$additionalDet5 === void 0 ? void 0 : _detail$additionalDet5.floors
|
|
26951
|
+
}), (detail === null || detail === void 0 ? void 0 : (_detail$additionalDet6 = detail.additionalDetails) === null || _detail$additionalDet6 === void 0 ? void 0 : _detail$additionalDet6.units) && /*#__PURE__*/React.createElement(TLTradeUnits, {
|
|
26952
|
+
units: detail === null || detail === void 0 ? void 0 : (_detail$additionalDet7 = detail.additionalDetails) === null || _detail$additionalDet7 === void 0 ? void 0 : _detail$additionalDet7.units
|
|
26953
|
+
}), (detail === null || detail === void 0 ? void 0 : (_detail$additionalDet8 = detail.additionalDetails) === null || _detail$additionalDet8 === void 0 ? void 0 : _detail$additionalDet8.accessories) && /*#__PURE__*/React.createElement(TLTradeAccessories, {
|
|
26954
|
+
units: detail === null || detail === void 0 ? void 0 : (_detail$additionalDet9 = detail.additionalDetails) === null || _detail$additionalDet9 === void 0 ? void 0 : _detail$additionalDet9.accessories
|
|
26955
|
+
}), (detail === null || detail === void 0 ? void 0 : (_detail$additionalDet0 = detail.additionalDetails) === null || _detail$additionalDet0 === void 0 ? void 0 : _detail$additionalDet0.permissions) && (workflowDetails === null || workflowDetails === void 0 ? void 0 : (_workflowDetails$data = workflowDetails.data) === null || _workflowDetails$data === void 0 ? void 0 : (_workflowDetails$data2 = _workflowDetails$data.nextActions) === null || _workflowDetails$data2 === void 0 ? void 0 : _workflowDetails$data2.length) > 0 && /*#__PURE__*/React.createElement(PermissionCheck, {
|
|
26993
26956
|
applicationData: applicationDetails === null || applicationDetails === void 0 ? void 0 : applicationDetails.applicationData,
|
|
26994
26957
|
t: t,
|
|
26995
|
-
permissions: detail === null || detail === void 0 ? void 0 : (_detail$
|
|
26996
|
-
}), (detail === null || detail === void 0 ? void 0 : (_detail$
|
|
26958
|
+
permissions: detail === null || detail === void 0 ? void 0 : (_detail$additionalDet1 = detail.additionalDetails) === null || _detail$additionalDet1 === void 0 ? void 0 : _detail$additionalDet1.permissions
|
|
26959
|
+
}), (detail === null || detail === void 0 ? void 0 : (_detail$additionalDet10 = detail.additionalDetails) === null || _detail$additionalDet10 === void 0 ? void 0 : _detail$additionalDet10.obpsDocuments) && /*#__PURE__*/React.createElement(BPADocuments, {
|
|
26997
26960
|
t: t,
|
|
26998
26961
|
applicationData: applicationDetails === null || applicationDetails === void 0 ? void 0 : applicationDetails.applicationData,
|
|
26999
26962
|
docs: detail.additionalDetails.obpsDocuments,
|
|
27000
26963
|
bpaActionsDetails: workflowDetails
|
|
27001
|
-
}), (detail === null || detail === void 0 ? void 0 : (_detail$
|
|
26964
|
+
}), (detail === null || detail === void 0 ? void 0 : (_detail$additionalDet11 = detail.additionalDetails) === null || _detail$additionalDet11 === void 0 ? void 0 : _detail$additionalDet11.noc) && /*#__PURE__*/React.createElement(NOCDocuments, {
|
|
27002
26965
|
t: t,
|
|
27003
26966
|
isNoc: true,
|
|
27004
26967
|
NOCdata: detail.values,
|
|
27005
26968
|
applicationData: applicationDetails === null || applicationDetails === void 0 ? void 0 : applicationDetails.applicationData,
|
|
27006
26969
|
docs: detail.additionalDetails.noc,
|
|
27007
|
-
noc: (_detail$
|
|
26970
|
+
noc: (_detail$additionalDet12 = detail.additionalDetails) === null || _detail$additionalDet12 === void 0 ? void 0 : _detail$additionalDet12.data,
|
|
27008
26971
|
bpaActionsDetails: workflowDetails
|
|
27009
|
-
}), (detail === null || detail === void 0 ? void 0 : (_detail$
|
|
26972
|
+
}), (detail === null || detail === void 0 ? void 0 : (_detail$additionalDet13 = detail.additionalDetails) === null || _detail$additionalDet13 === void 0 ? void 0 : _detail$additionalDet13.scruntinyDetails) && /*#__PURE__*/React.createElement(ScruntinyDetails, {
|
|
27010
26973
|
scrutinyDetails: detail === null || detail === void 0 ? void 0 : detail.additionalDetails
|
|
27011
|
-
}), (detail === null || detail === void 0 ? void 0 : (_detail$
|
|
26974
|
+
}), (detail === null || detail === void 0 ? void 0 : (_detail$additionalDet14 = detail.additionalDetails) === null || _detail$additionalDet14 === void 0 ? void 0 : _detail$additionalDet14.buildingExtractionDetails) && /*#__PURE__*/React.createElement(ScruntinyDetails, {
|
|
27012
26975
|
scrutinyDetails: detail === null || detail === void 0 ? void 0 : detail.additionalDetails
|
|
27013
|
-
}), (detail === null || detail === void 0 ? void 0 : (_detail$
|
|
26976
|
+
}), (detail === null || detail === void 0 ? void 0 : (_detail$additionalDet15 = detail.additionalDetails) === null || _detail$additionalDet15 === void 0 ? void 0 : _detail$additionalDet15.subOccupancyTableDetails) && /*#__PURE__*/React.createElement(SubOccupancyTable, {
|
|
27014
26977
|
edcrDetails: detail === null || detail === void 0 ? void 0 : detail.additionalDetails,
|
|
27015
26978
|
applicationData: applicationDetails === null || applicationDetails === void 0 ? void 0 : applicationDetails.applicationData
|
|
27016
|
-
}), (detail === null || detail === void 0 ? void 0 : (_detail$
|
|
27017
|
-
documents: detail === null || detail === void 0 ? void 0 : (_detail$
|
|
27018
|
-
}), (detail === null || detail === void 0 ? void 0 : (_detail$
|
|
27019
|
-
documents: detail === null || detail === void 0 ? void 0 : (_detail$
|
|
26979
|
+
}), (detail === null || detail === void 0 ? void 0 : (_detail$additionalDet16 = detail.additionalDetails) === null || _detail$additionalDet16 === void 0 ? void 0 : _detail$additionalDet16.documentsWithUrl) && /*#__PURE__*/React.createElement(DocumentsPreview, {
|
|
26980
|
+
documents: detail === null || detail === void 0 ? void 0 : (_detail$additionalDet17 = detail.additionalDetails) === null || _detail$additionalDet17 === void 0 ? void 0 : _detail$additionalDet17.documentsWithUrl
|
|
26981
|
+
}), (detail === null || detail === void 0 ? void 0 : (_detail$additionalDet18 = detail.additionalDetails) === null || _detail$additionalDet18 === void 0 ? void 0 : _detail$additionalDet18.documents) && /*#__PURE__*/React.createElement(PropertyDocuments, {
|
|
26982
|
+
documents: detail === null || detail === void 0 ? void 0 : (_detail$additionalDet19 = detail.additionalDetails) === null || _detail$additionalDet19 === void 0 ? void 0 : _detail$additionalDet19.documents,
|
|
27020
26983
|
applicationStatus: applicationData === null || applicationData === void 0 ? void 0 : applicationData.applicationStatus
|
|
27021
|
-
}),
|
|
26984
|
+
}), /*#__PURE__*/React.createElement("h1", {
|
|
26985
|
+
style: {
|
|
26986
|
+
background: "red",
|
|
26987
|
+
color: "#fff",
|
|
26988
|
+
padding: 20
|
|
26989
|
+
}
|
|
26990
|
+
}, "HELLO"), (detail === null || detail === void 0 ? void 0 : (_detail$additionalDet20 = detail.additionalDetails) === null || _detail$additionalDet20 === void 0 ? void 0 : _detail$additionalDet20.documents) && ((applicationData === null || applicationData === void 0 ? void 0 : applicationData.applicationStatus) === "PENDING_FOR_FIELD_INSPECTION" || (applicationData === null || applicationData === void 0 ? void 0 : applicationData.applicationStatus) === "PENDING_APPROVAL_FOR_CONNECTION" || (applicationData === null || applicationData === void 0 ? void 0 : applicationData.applicationStatus) === "PENDING_FOR_CONNECTION_ACTIVATION" || (applicationData === null || applicationData === void 0 ? void 0 : applicationData.applicationStatus) === "PENDING_FOR_RECONNECTION") && /*#__PURE__*/React.createElement(DueVerification, {
|
|
27022
26991
|
applicationData: applicationData
|
|
27023
|
-
}), (detail === null || detail === void 0 ? void 0 : (_detail$
|
|
27024
|
-
|
|
26992
|
+
}), " ", (detail === null || detail === void 0 ? void 0 : (_detail$additionalDet21 = detail.additionalDetails) === null || _detail$additionalDet21 === void 0 ? void 0 : _detail$additionalDet21.documents) && ((applicationData === null || applicationData === void 0 ? void 0 : applicationData.applicationStatus) === "PENDING_APPROVAL_FOR_CONNECTION" || (applicationData === null || applicationData === void 0 ? void 0 : applicationData.applicationStatus) === "PENDING_FOR_CONNECTION_ACTIVATION") && /*#__PURE__*/React.createElement(InspectionInformation, {
|
|
26993
|
+
applicationData: applicationData
|
|
26994
|
+
}), (detail === null || detail === void 0 ? void 0 : (_detail$additionalDet22 = detail.additionalDetails) === null || _detail$additionalDet22 === void 0 ? void 0 : _detail$additionalDet22.taxHeadEstimatesCalculation) && /*#__PURE__*/React.createElement(PropertyEstimates, {
|
|
26995
|
+
taxHeadEstimatesCalculation: detail === null || detail === void 0 ? void 0 : (_detail$additionalDet23 = detail.additionalDetails) === null || _detail$additionalDet23 === void 0 ? void 0 : _detail$additionalDet23.taxHeadEstimatesCalculation
|
|
27025
26996
|
}), (detail === null || detail === void 0 ? void 0 : detail.isWaterConnectionDetails) && /*#__PURE__*/React.createElement(WSAdditonalDetails, {
|
|
27026
26997
|
wsAdditionalDetails: detail,
|
|
27027
26998
|
oldValue: oldValue
|
|
27028
|
-
}), (detail === null || detail === void 0 ? void 0 : (_detail$
|
|
27029
|
-
to: detail === null || detail === void 0 ? void 0 : (_detail$
|
|
26999
|
+
}), (detail === null || detail === void 0 ? void 0 : (_detail$additionalDet24 = detail.additionalDetails) === null || _detail$additionalDet24 === void 0 ? void 0 : _detail$additionalDet24.redirectUrl) && /*#__PURE__*/React.createElement(Link, {
|
|
27000
|
+
to: detail === null || detail === void 0 ? void 0 : (_detail$additionalDet25 = detail.additionalDetails) === null || _detail$additionalDet25 === void 0 ? void 0 : (_detail$additionalDet26 = _detail$additionalDet25.redirectUrl) === null || _detail$additionalDet26 === void 0 ? void 0 : _detail$additionalDet26.url
|
|
27030
27001
|
}, /*#__PURE__*/React.createElement("span", {
|
|
27031
27002
|
className: "add-details-link hover-button"
|
|
27032
|
-
}, detail === null || detail === void 0 ? void 0 : (_detail$
|
|
27003
|
+
}, detail === null || detail === void 0 ? void 0 : (_detail$additionalDet27 = detail.additionalDetails) === null || _detail$additionalDet27 === void 0 ? void 0 : (_detail$additionalDet28 = _detail$additionalDet27.redirectUrl) === null || _detail$additionalDet28 === void 0 ? void 0 : _detail$additionalDet28.title)), (detail === null || detail === void 0 ? void 0 : (_detail$additionalDet29 = detail.additionalDetails) === null || _detail$additionalDet29 === void 0 ? void 0 : _detail$additionalDet29.estimationDetails) && /*#__PURE__*/React.createElement(WSFeeEstimation, {
|
|
27033
27004
|
wsAdditionalDetails: detail,
|
|
27034
27005
|
workflowDetails: workflowDetails
|
|
27035
|
-
}), (detail === null || detail === void 0 ? void 0 : (_detail$
|
|
27006
|
+
}), (detail === null || detail === void 0 ? void 0 : (_detail$additionalDet30 = detail.additionalDetails) === null || _detail$additionalDet30 === void 0 ? void 0 : _detail$additionalDet30.estimationDetails) && /*#__PURE__*/React.createElement(ViewBreakup, {
|
|
27036
27007
|
wsAdditionalDetails: detail,
|
|
27037
27008
|
workflowDetails: workflowDetails
|
|
27038
27009
|
}));
|
|
@@ -27412,7 +27383,7 @@ const ApplicationDetails = props => {
|
|
|
27412
27383
|
clearDataDetails = props.clearDataDetails,
|
|
27413
27384
|
_props$isAction = props.isAction,
|
|
27414
27385
|
isAction = _props$isAction === void 0 ? false : _props$isAction;
|
|
27415
|
-
useEffect(() => {
|
|
27386
|
+
useEffect$1(() => {
|
|
27416
27387
|
if (showToast) {
|
|
27417
27388
|
workflowDetails.revalidate();
|
|
27418
27389
|
}
|
|
@@ -27808,7 +27779,7 @@ const ApplicationDetails$1 = () => {
|
|
|
27808
27779
|
const closeToast = () => {
|
|
27809
27780
|
setShowToast(null);
|
|
27810
27781
|
};
|
|
27811
|
-
useEffect(() => {
|
|
27782
|
+
useEffect$1(() => {
|
|
27812
27783
|
if (applicationDetails) {
|
|
27813
27784
|
var _details$applicationD, _details$applicationD2, _details$applicationD3, _details$applicationD6, _details$applicationD9, _details$applicationD0, _details$applicationD1;
|
|
27814
27785
|
let details = lodash.cloneDeep(applicationDetails);
|
|
@@ -27897,7 +27868,7 @@ const ApplicationDetails$1 = () => {
|
|
|
27897
27868
|
setAppDetailsToShow(details);
|
|
27898
27869
|
}
|
|
27899
27870
|
}, [applicationDetails, isFixedPoint]);
|
|
27900
|
-
useEffect(() => {
|
|
27871
|
+
useEffect$1(() => {
|
|
27901
27872
|
var _workflowDetails$data, _workflowDetails$data2, _workflowDetails$data3, _workflowDetails$data4;
|
|
27902
27873
|
if (workflowDetails !== null && workflowDetails !== void 0 && (_workflowDetails$data = workflowDetails.data) !== null && _workflowDetails$data !== void 0 && _workflowDetails$data.applicationBusinessService && !((workflowDetails === null || workflowDetails === void 0 ? void 0 : (_workflowDetails$data2 = workflowDetails.data) === null || _workflowDetails$data2 === void 0 ? void 0 : _workflowDetails$data2.applicationBusinessService) === "watertanker" && businessService === "watertanker" || (workflowDetails === null || workflowDetails === void 0 ? void 0 : (_workflowDetails$data3 = workflowDetails.data) === null || _workflowDetails$data3 === void 0 ? void 0 : _workflowDetails$data3.applicationBusinessService) === "mobileToilet" && businessService === "mobileToilet" || (workflowDetails === null || workflowDetails === void 0 ? void 0 : (_workflowDetails$data4 = workflowDetails.data) === null || _workflowDetails$data4 === void 0 ? void 0 : _workflowDetails$data4.applicationBusinessService) === "treePruning" && businessService === "treePruning")) {
|
|
27903
27874
|
var _workflowDetails$data5;
|
|
@@ -27976,7 +27947,7 @@ const WTCitizenCard = () => {
|
|
|
27976
27947
|
data = _Digit$Hooks$useNewIn.data,
|
|
27977
27948
|
isFetching = _Digit$Hooks$useNewIn.isFetching,
|
|
27978
27949
|
isSuccess = _Digit$Hooks$useNewIn.isSuccess;
|
|
27979
|
-
useEffect(() => {
|
|
27950
|
+
useEffect$1(() => {
|
|
27980
27951
|
if (!isFetching && isSuccess) setTotal(data);
|
|
27981
27952
|
}, [isFetching]);
|
|
27982
27953
|
const handleDetailsClick = () => {
|
|
@@ -28033,7 +28004,7 @@ const MTCard = () => {
|
|
|
28033
28004
|
isLoading = _Digit$Hooks$useNewIn.isLoading,
|
|
28034
28005
|
isFetching = _Digit$Hooks$useNewIn.isFetching,
|
|
28035
28006
|
isSuccess = _Digit$Hooks$useNewIn.isSuccess;
|
|
28036
|
-
useEffect(() => {
|
|
28007
|
+
useEffect$1(() => {
|
|
28037
28008
|
if (!isFetching && isSuccess) setTotal(data);
|
|
28038
28009
|
}, [isFetching]);
|
|
28039
28010
|
if (!Digit.Utils.mtAccess()) {
|
|
@@ -28092,7 +28063,7 @@ const TPCard = () => {
|
|
|
28092
28063
|
isLoading = _Digit$Hooks$useNewIn.isLoading,
|
|
28093
28064
|
isFetching = _Digit$Hooks$useNewIn.isFetching,
|
|
28094
28065
|
isSuccess = _Digit$Hooks$useNewIn.isSuccess;
|
|
28095
|
-
useEffect(() => {
|
|
28066
|
+
useEffect$1(() => {
|
|
28096
28067
|
if (!isFetching && isSuccess) setTotal(data);
|
|
28097
28068
|
}, [isFetching]);
|
|
28098
28069
|
const links = [{
|
|
@@ -28153,7 +28124,7 @@ const ServiceTypes = _ref => {
|
|
|
28153
28124
|
});
|
|
28154
28125
|
onSelect(config.key, ServiceType, false);
|
|
28155
28126
|
}, [formData.serviceType, serviceType, onSelect, config.key]);
|
|
28156
|
-
useEffect(() => {
|
|
28127
|
+
useEffect$1(() => {
|
|
28157
28128
|
if (userType === "citizen") {
|
|
28158
28129
|
goNext();
|
|
28159
28130
|
}
|
|
@@ -28281,7 +28252,7 @@ const ToiletRequestDetails = _ref => {
|
|
|
28281
28252
|
});
|
|
28282
28253
|
onSelect(config.key, Service, false);
|
|
28283
28254
|
};
|
|
28284
|
-
useEffect(() => {
|
|
28255
|
+
useEffect$1(() => {
|
|
28285
28256
|
if (userType === "citizen") {
|
|
28286
28257
|
goNext();
|
|
28287
28258
|
}
|
|
@@ -28409,7 +28380,7 @@ const TreePruningRequestDetails = _ref => {
|
|
|
28409
28380
|
});
|
|
28410
28381
|
onSelect(config.key, Service, false);
|
|
28411
28382
|
};
|
|
28412
|
-
useEffect(() => {
|
|
28383
|
+
useEffect$1(() => {
|
|
28413
28384
|
if (userType === "citizen") {
|
|
28414
28385
|
goNext();
|
|
28415
28386
|
}
|
|
@@ -28668,6 +28639,7 @@ const BannerPicker$1 = props => {
|
|
|
28668
28639
|
});
|
|
28669
28640
|
};
|
|
28670
28641
|
const MTAcknowledgement = _ref => {
|
|
28642
|
+
var _mutation$data2, _mutation$data3, _mutation$data4, _mutation$data4$data, _mutation$data4$data$, _mutation$data4$data$2, _mutation$error, _mutation$error$respo, _mutation$error$respo2, _mutation$error$respo3, _mutation$error$respo4;
|
|
28671
28643
|
let data = _ref.data,
|
|
28672
28644
|
onSuccess = _ref.onSuccess;
|
|
28673
28645
|
const _useTranslation2 = useTranslation(),
|
|
@@ -28679,14 +28651,20 @@ const MTAcknowledgement = _ref => {
|
|
|
28679
28651
|
storeData = _Digit$Hooks$useStore.data;
|
|
28680
28652
|
const _ref2 = storeData || {},
|
|
28681
28653
|
tenants = _ref2.tenants;
|
|
28682
|
-
useEffect(() => {
|
|
28654
|
+
useEffect$1(() => {
|
|
28683
28655
|
try {
|
|
28684
28656
|
data.tenantId = tenantId;
|
|
28685
28657
|
let formdata = mobileToiletPayload(data);
|
|
28686
28658
|
mutation.mutate(formdata, {
|
|
28687
|
-
onSuccess
|
|
28659
|
+
onSuccess: res => {
|
|
28660
|
+
if (!(res !== null && res !== void 0 && res.error)) {
|
|
28661
|
+
onSuccess();
|
|
28662
|
+
}
|
|
28663
|
+
}
|
|
28688
28664
|
});
|
|
28689
|
-
} catch (err) {
|
|
28665
|
+
} catch (err) {
|
|
28666
|
+
console.error("MT payload construction error:", err);
|
|
28667
|
+
}
|
|
28690
28668
|
}, []);
|
|
28691
28669
|
Digit.Hooks.useCustomBackNavigation({
|
|
28692
28670
|
redirectPath: '${APPLICATION_PATH}/citizen'
|
|
@@ -28704,19 +28682,27 @@ const MTAcknowledgement = _ref => {
|
|
|
28704
28682
|
return Promise.reject(e);
|
|
28705
28683
|
}
|
|
28706
28684
|
};
|
|
28685
|
+
const isMutationSuccess = mutation.isSuccess && !((_mutation$data2 = mutation.data) !== null && _mutation$data2 !== void 0 && _mutation$data2.error);
|
|
28686
|
+
const isMutationError = mutation.isError || mutation.isSuccess && ((_mutation$data3 = mutation.data) === null || _mutation$data3 === void 0 ? void 0 : _mutation$data3.error);
|
|
28707
28687
|
return mutation.isLoading || mutation.isIdle ? /*#__PURE__*/React.createElement(Loader, null) : /*#__PURE__*/React.createElement(Card, null, /*#__PURE__*/React.createElement(BannerPicker$1, {
|
|
28708
28688
|
t: t,
|
|
28709
28689
|
data: mutation.data,
|
|
28710
|
-
isSuccess:
|
|
28690
|
+
isSuccess: isMutationSuccess,
|
|
28711
28691
|
isLoading: mutation.isIdle || mutation.isLoading
|
|
28712
|
-
}),
|
|
28692
|
+
}), isMutationError && /*#__PURE__*/React.createElement(CardText, {
|
|
28693
|
+
style: {
|
|
28694
|
+
color: "#d4351c",
|
|
28695
|
+
textAlign: "center",
|
|
28696
|
+
marginTop: "8px"
|
|
28697
|
+
}
|
|
28698
|
+
}, ((_mutation$data4 = mutation.data) === null || _mutation$data4 === void 0 ? void 0 : (_mutation$data4$data = _mutation$data4.data) === null || _mutation$data4$data === void 0 ? void 0 : (_mutation$data4$data$ = _mutation$data4$data.Errors) === null || _mutation$data4$data$ === void 0 ? void 0 : (_mutation$data4$data$2 = _mutation$data4$data$[0]) === null || _mutation$data4$data$2 === void 0 ? void 0 : _mutation$data4$data$2.message) || ((_mutation$error = mutation.error) === null || _mutation$error === void 0 ? void 0 : (_mutation$error$respo = _mutation$error.response) === null || _mutation$error$respo === void 0 ? void 0 : (_mutation$error$respo2 = _mutation$error$respo.data) === null || _mutation$error$respo2 === void 0 ? void 0 : (_mutation$error$respo3 = _mutation$error$respo2.Errors) === null || _mutation$error$respo3 === void 0 ? void 0 : (_mutation$error$respo4 = _mutation$error$respo3[0]) === null || _mutation$error$respo4 === void 0 ? void 0 : _mutation$error$respo4.message) || t("MT_SUBMISSION_FAILED_MESSAGE")), /*#__PURE__*/React.createElement(StatusTable, null, isMutationSuccess && /*#__PURE__*/React.createElement(Row, {
|
|
28713
28699
|
rowContainerStyle: rowContainerStyle$1,
|
|
28714
28700
|
last: true,
|
|
28715
28701
|
textStyle: {
|
|
28716
28702
|
whiteSpace: "pre",
|
|
28717
28703
|
width: "60%"
|
|
28718
28704
|
}
|
|
28719
|
-
})),
|
|
28705
|
+
})), isMutationSuccess && /*#__PURE__*/React.createElement(SubmitBar, {
|
|
28720
28706
|
label: t("MT_DOWNLOAD_ACKNOWLEDGEMENT"),
|
|
28721
28707
|
onSubmit: handleDownloadPdf
|
|
28722
28708
|
}), (user === null || user === void 0 ? void 0 : user.type) === "CITIZEN" ? /*#__PURE__*/React.createElement(Link, {
|
|
@@ -28838,6 +28824,7 @@ const BannerPicker$2 = props => {
|
|
|
28838
28824
|
});
|
|
28839
28825
|
};
|
|
28840
28826
|
const TPAcknowledgement = _ref => {
|
|
28827
|
+
var _mutation$data2, _mutation$data3, _mutation$data4, _mutation$data4$data, _mutation$data4$data$, _mutation$data4$data$2, _mutation$error, _mutation$error$respo, _mutation$error$respo2, _mutation$error$respo3, _mutation$error$respo4;
|
|
28841
28828
|
let data = _ref.data,
|
|
28842
28829
|
onSuccess = _ref.onSuccess;
|
|
28843
28830
|
const _useTranslation2 = useTranslation(),
|
|
@@ -28849,14 +28836,20 @@ const TPAcknowledgement = _ref => {
|
|
|
28849
28836
|
storeData = _Digit$Hooks$useStore.data;
|
|
28850
28837
|
const _ref2 = storeData || {},
|
|
28851
28838
|
tenants = _ref2.tenants;
|
|
28852
|
-
useEffect(() => {
|
|
28839
|
+
useEffect$1(() => {
|
|
28853
28840
|
try {
|
|
28854
28841
|
data.tenantId = tenantId;
|
|
28855
28842
|
let formdata = treePruningPayload(data);
|
|
28856
28843
|
mutation.mutate(formdata, {
|
|
28857
|
-
onSuccess
|
|
28844
|
+
onSuccess: res => {
|
|
28845
|
+
if (!(res !== null && res !== void 0 && res.error)) {
|
|
28846
|
+
onSuccess();
|
|
28847
|
+
}
|
|
28848
|
+
}
|
|
28858
28849
|
});
|
|
28859
|
-
} catch (err) {
|
|
28850
|
+
} catch (err) {
|
|
28851
|
+
console.error("TP payload construction error:", err);
|
|
28852
|
+
}
|
|
28860
28853
|
}, []);
|
|
28861
28854
|
Digit.Hooks.useCustomBackNavigation({
|
|
28862
28855
|
redirectPath: '${APPLICATION_PATH}/citizen'
|
|
@@ -28874,19 +28867,27 @@ const TPAcknowledgement = _ref => {
|
|
|
28874
28867
|
return Promise.reject(e);
|
|
28875
28868
|
}
|
|
28876
28869
|
};
|
|
28870
|
+
const isMutationSuccess = mutation.isSuccess && !((_mutation$data2 = mutation.data) !== null && _mutation$data2 !== void 0 && _mutation$data2.error);
|
|
28871
|
+
const isMutationError = mutation.isError || mutation.isSuccess && ((_mutation$data3 = mutation.data) === null || _mutation$data3 === void 0 ? void 0 : _mutation$data3.error);
|
|
28877
28872
|
return mutation.isLoading || mutation.isIdle ? /*#__PURE__*/React.createElement(Loader, null) : /*#__PURE__*/React.createElement(Card, null, /*#__PURE__*/React.createElement(BannerPicker$2, {
|
|
28878
28873
|
t: t,
|
|
28879
28874
|
data: mutation.data,
|
|
28880
|
-
isSuccess:
|
|
28875
|
+
isSuccess: isMutationSuccess,
|
|
28881
28876
|
isLoading: mutation.isIdle || mutation.isLoading
|
|
28882
|
-
}),
|
|
28877
|
+
}), isMutationError && /*#__PURE__*/React.createElement(CardText, {
|
|
28878
|
+
style: {
|
|
28879
|
+
color: "#d4351c",
|
|
28880
|
+
textAlign: "center",
|
|
28881
|
+
marginTop: "8px"
|
|
28882
|
+
}
|
|
28883
|
+
}, ((_mutation$data4 = mutation.data) === null || _mutation$data4 === void 0 ? void 0 : (_mutation$data4$data = _mutation$data4.data) === null || _mutation$data4$data === void 0 ? void 0 : (_mutation$data4$data$ = _mutation$data4$data.Errors) === null || _mutation$data4$data$ === void 0 ? void 0 : (_mutation$data4$data$2 = _mutation$data4$data$[0]) === null || _mutation$data4$data$2 === void 0 ? void 0 : _mutation$data4$data$2.message) || ((_mutation$error = mutation.error) === null || _mutation$error === void 0 ? void 0 : (_mutation$error$respo = _mutation$error.response) === null || _mutation$error$respo === void 0 ? void 0 : (_mutation$error$respo2 = _mutation$error$respo.data) === null || _mutation$error$respo2 === void 0 ? void 0 : (_mutation$error$respo3 = _mutation$error$respo2.Errors) === null || _mutation$error$respo3 === void 0 ? void 0 : (_mutation$error$respo4 = _mutation$error$respo3[0]) === null || _mutation$error$respo4 === void 0 ? void 0 : _mutation$error$respo4.message) || t("TP_SUBMISSION_FAILED_MESSAGE")), /*#__PURE__*/React.createElement(StatusTable, null, isMutationSuccess && /*#__PURE__*/React.createElement(Row, {
|
|
28883
28884
|
rowContainerStyle: rowContainerStyle$2,
|
|
28884
28885
|
last: true,
|
|
28885
28886
|
textStyle: {
|
|
28886
28887
|
whiteSpace: "pre",
|
|
28887
28888
|
width: "60%"
|
|
28888
28889
|
}
|
|
28889
|
-
})),
|
|
28890
|
+
})), isMutationSuccess && /*#__PURE__*/React.createElement(SubmitBar, {
|
|
28890
28891
|
label: t("TP_DOWNLOAD_ACKNOWLEDGEMENT"),
|
|
28891
28892
|
onSubmit: handleDownloadPdf
|
|
28892
28893
|
}), (user === null || user === void 0 ? void 0 : user.type) === "CITIZEN" ? /*#__PURE__*/React.createElement(Link, {
|
|
@@ -29383,7 +29384,7 @@ const MTCitizenCard = () => {
|
|
|
29383
29384
|
data = _Digit$Hooks$useNewIn.data,
|
|
29384
29385
|
isFetching = _Digit$Hooks$useNewIn.isFetching,
|
|
29385
29386
|
isSuccess = _Digit$Hooks$useNewIn.isSuccess;
|
|
29386
|
-
useEffect(() => {
|
|
29387
|
+
useEffect$1(() => {
|
|
29387
29388
|
if (!isFetching && isSuccess) setTotal(data);
|
|
29388
29389
|
}, [isFetching]);
|
|
29389
29390
|
const links = [{
|
|
@@ -29624,7 +29625,7 @@ const EmergencyFixedPointRequestDetails = _ref => {
|
|
|
29624
29625
|
setUploadedFile(null);
|
|
29625
29626
|
setFile(e.target.files[0]);
|
|
29626
29627
|
}
|
|
29627
|
-
useEffect(() => {
|
|
29628
|
+
useEffect$1(() => {
|
|
29628
29629
|
(function () {
|
|
29629
29630
|
try {
|
|
29630
29631
|
setError(null);
|
|
@@ -29659,7 +29660,7 @@ const EmergencyFixedPointRequestDetails = _ref => {
|
|
|
29659
29660
|
}
|
|
29660
29661
|
})();
|
|
29661
29662
|
}, [file]);
|
|
29662
|
-
useEffect(() => {
|
|
29663
|
+
useEffect$1(() => {
|
|
29663
29664
|
if (!waterType && WaterTypeData !== null && WaterTypeData !== void 0 && WaterTypeData.length) {
|
|
29664
29665
|
const drinkableOption = WaterTypeData.find(data => {
|
|
29665
29666
|
var _data$code, _data$code2;
|
|
@@ -30088,6 +30089,7 @@ const BannerPicker$3 = props => {
|
|
|
30088
30089
|
});
|
|
30089
30090
|
};
|
|
30090
30091
|
const WTEmergencyFixedPointAcknowledgement = _ref => {
|
|
30092
|
+
var _mutation$data2, _mutation$data3, _mutation$data4, _mutation$data4$data, _mutation$data4$data$, _mutation$data4$data$2, _mutation$error, _mutation$error$respo, _mutation$error$respo2, _mutation$error$respo3, _mutation$error$respo4;
|
|
30091
30093
|
let data = _ref.data,
|
|
30092
30094
|
onSuccess = _ref.onSuccess;
|
|
30093
30095
|
const _useTranslation2 = useTranslation(),
|
|
@@ -30099,14 +30101,20 @@ const WTEmergencyFixedPointAcknowledgement = _ref => {
|
|
|
30099
30101
|
storeData = _Digit$Hooks$useStore.data;
|
|
30100
30102
|
const _ref2 = storeData || {},
|
|
30101
30103
|
tenants = _ref2.tenants;
|
|
30102
|
-
useEffect(() => {
|
|
30104
|
+
useEffect$1(() => {
|
|
30103
30105
|
try {
|
|
30104
30106
|
data.tenantId = tenantId;
|
|
30105
30107
|
let formdata = emergencyWaterTankerPayload(data);
|
|
30106
30108
|
mutation.mutate(formdata, {
|
|
30107
|
-
onSuccess
|
|
30109
|
+
onSuccess: res => {
|
|
30110
|
+
if (!(res !== null && res !== void 0 && res.error)) {
|
|
30111
|
+
onSuccess();
|
|
30112
|
+
}
|
|
30113
|
+
}
|
|
30108
30114
|
});
|
|
30109
|
-
} catch (err) {
|
|
30115
|
+
} catch (err) {
|
|
30116
|
+
console.error("Emergency WT payload construction error:", err);
|
|
30117
|
+
}
|
|
30110
30118
|
}, []);
|
|
30111
30119
|
Digit.Hooks.useCustomBackNavigation({
|
|
30112
30120
|
redirectPath: "${APPLICATION_PATH}/citizen"
|
|
@@ -30124,21 +30132,29 @@ const WTEmergencyFixedPointAcknowledgement = _ref => {
|
|
|
30124
30132
|
return Promise.reject(e);
|
|
30125
30133
|
}
|
|
30126
30134
|
};
|
|
30135
|
+
const isMutationSuccess = mutation.isSuccess && !((_mutation$data2 = mutation.data) !== null && _mutation$data2 !== void 0 && _mutation$data2.error);
|
|
30136
|
+
const isMutationError = mutation.isError || mutation.isSuccess && ((_mutation$data3 = mutation.data) === null || _mutation$data3 === void 0 ? void 0 : _mutation$data3.error);
|
|
30127
30137
|
return mutation.isLoading || mutation.isIdle ? /*#__PURE__*/React.createElement(Loader, null) : /*#__PURE__*/React.createElement(Card, {
|
|
30128
30138
|
className: "vehicle-details-card"
|
|
30129
30139
|
}, /*#__PURE__*/React.createElement(BannerPicker$3, {
|
|
30130
30140
|
t: t,
|
|
30131
30141
|
data: mutation.data,
|
|
30132
|
-
isSuccess:
|
|
30142
|
+
isSuccess: isMutationSuccess,
|
|
30133
30143
|
isLoading: mutation.isIdle || mutation.isLoading
|
|
30134
|
-
}),
|
|
30144
|
+
}), isMutationError && /*#__PURE__*/React.createElement(CardText, {
|
|
30145
|
+
style: {
|
|
30146
|
+
color: "#d4351c",
|
|
30147
|
+
textAlign: "center",
|
|
30148
|
+
marginTop: "8px"
|
|
30149
|
+
}
|
|
30150
|
+
}, ((_mutation$data4 = mutation.data) === null || _mutation$data4 === void 0 ? void 0 : (_mutation$data4$data = _mutation$data4.data) === null || _mutation$data4$data === void 0 ? void 0 : (_mutation$data4$data$ = _mutation$data4$data.Errors) === null || _mutation$data4$data$ === void 0 ? void 0 : (_mutation$data4$data$2 = _mutation$data4$data$[0]) === null || _mutation$data4$data$2 === void 0 ? void 0 : _mutation$data4$data$2.message) || ((_mutation$error = mutation.error) === null || _mutation$error === void 0 ? void 0 : (_mutation$error$respo = _mutation$error.response) === null || _mutation$error$respo === void 0 ? void 0 : (_mutation$error$respo2 = _mutation$error$respo.data) === null || _mutation$error$respo2 === void 0 ? void 0 : (_mutation$error$respo3 = _mutation$error$respo2.Errors) === null || _mutation$error$respo3 === void 0 ? void 0 : (_mutation$error$respo4 = _mutation$error$respo3[0]) === null || _mutation$error$respo4 === void 0 ? void 0 : _mutation$error$respo4.message) || t("WT_SUBMISSION_FAILED_MESSAGE")), /*#__PURE__*/React.createElement(StatusTable, null, isMutationSuccess && /*#__PURE__*/React.createElement(Row, {
|
|
30135
30151
|
rowContainerStyle: rowContainerStyle$3,
|
|
30136
30152
|
last: true,
|
|
30137
30153
|
textStyle: {
|
|
30138
30154
|
whiteSpace: "pre",
|
|
30139
30155
|
width: "60%"
|
|
30140
30156
|
}
|
|
30141
|
-
})),
|
|
30157
|
+
})), isMutationSuccess && /*#__PURE__*/React.createElement(SubmitBar, {
|
|
30142
30158
|
label: t("WT_DOWNLOAD_ACKNOWLEDGEMENT"),
|
|
30143
30159
|
onSubmit: handleDownloadPdf
|
|
30144
30160
|
}), (user === null || user === void 0 ? void 0 : user.type) === "CITIZEN" ? /*#__PURE__*/React.createElement(Link, {
|
|
@@ -30180,6 +30196,7 @@ const BannerPicker$4 = props => {
|
|
|
30180
30196
|
});
|
|
30181
30197
|
};
|
|
30182
30198
|
const MTEmergencyFixedPointAcknowledgement = _ref => {
|
|
30199
|
+
var _mutation$data2, _mutation$data3, _mutation$data4, _mutation$data4$data, _mutation$data4$data$, _mutation$data4$data$2, _mutation$error, _mutation$error$respo, _mutation$error$respo2, _mutation$error$respo3, _mutation$error$respo4;
|
|
30183
30200
|
let data = _ref.data,
|
|
30184
30201
|
onSuccess = _ref.onSuccess;
|
|
30185
30202
|
const _useTranslation2 = useTranslation(),
|
|
@@ -30191,14 +30208,20 @@ const MTEmergencyFixedPointAcknowledgement = _ref => {
|
|
|
30191
30208
|
storeData = _Digit$Hooks$useStore.data;
|
|
30192
30209
|
const _ref2 = storeData || {},
|
|
30193
30210
|
tenants = _ref2.tenants;
|
|
30194
|
-
useEffect(() => {
|
|
30211
|
+
useEffect$1(() => {
|
|
30195
30212
|
try {
|
|
30196
30213
|
data.tenantId = tenantId;
|
|
30197
30214
|
let formdata = mobileToiletPayload(data);
|
|
30198
30215
|
mutation.mutate(formdata, {
|
|
30199
|
-
onSuccess
|
|
30216
|
+
onSuccess: res => {
|
|
30217
|
+
if (!(res !== null && res !== void 0 && res.error)) {
|
|
30218
|
+
onSuccess();
|
|
30219
|
+
}
|
|
30220
|
+
}
|
|
30200
30221
|
});
|
|
30201
|
-
} catch (err) {
|
|
30222
|
+
} catch (err) {
|
|
30223
|
+
console.error("Emergency MT payload construction error:", err);
|
|
30224
|
+
}
|
|
30202
30225
|
}, []);
|
|
30203
30226
|
Digit.Hooks.useCustomBackNavigation({
|
|
30204
30227
|
redirectPath: '${APPLICATION_PATH}/citizen'
|
|
@@ -30216,19 +30239,27 @@ const MTEmergencyFixedPointAcknowledgement = _ref => {
|
|
|
30216
30239
|
return Promise.reject(e);
|
|
30217
30240
|
}
|
|
30218
30241
|
};
|
|
30242
|
+
const isMutationSuccess = mutation.isSuccess && !((_mutation$data2 = mutation.data) !== null && _mutation$data2 !== void 0 && _mutation$data2.error);
|
|
30243
|
+
const isMutationError = mutation.isError || mutation.isSuccess && ((_mutation$data3 = mutation.data) === null || _mutation$data3 === void 0 ? void 0 : _mutation$data3.error);
|
|
30219
30244
|
return mutation.isLoading || mutation.isIdle ? /*#__PURE__*/React.createElement(Loader, null) : /*#__PURE__*/React.createElement(Card, null, /*#__PURE__*/React.createElement(BannerPicker$4, {
|
|
30220
30245
|
t: t,
|
|
30221
30246
|
data: mutation.data,
|
|
30222
|
-
isSuccess:
|
|
30247
|
+
isSuccess: isMutationSuccess,
|
|
30223
30248
|
isLoading: mutation.isIdle || mutation.isLoading
|
|
30224
|
-
}),
|
|
30249
|
+
}), isMutationError && /*#__PURE__*/React.createElement(CardText, {
|
|
30250
|
+
style: {
|
|
30251
|
+
color: "#d4351c",
|
|
30252
|
+
textAlign: "center",
|
|
30253
|
+
marginTop: "8px"
|
|
30254
|
+
}
|
|
30255
|
+
}, ((_mutation$data4 = mutation.data) === null || _mutation$data4 === void 0 ? void 0 : (_mutation$data4$data = _mutation$data4.data) === null || _mutation$data4$data === void 0 ? void 0 : (_mutation$data4$data$ = _mutation$data4$data.Errors) === null || _mutation$data4$data$ === void 0 ? void 0 : (_mutation$data4$data$2 = _mutation$data4$data$[0]) === null || _mutation$data4$data$2 === void 0 ? void 0 : _mutation$data4$data$2.message) || ((_mutation$error = mutation.error) === null || _mutation$error === void 0 ? void 0 : (_mutation$error$respo = _mutation$error.response) === null || _mutation$error$respo === void 0 ? void 0 : (_mutation$error$respo2 = _mutation$error$respo.data) === null || _mutation$error$respo2 === void 0 ? void 0 : (_mutation$error$respo3 = _mutation$error$respo2.Errors) === null || _mutation$error$respo3 === void 0 ? void 0 : (_mutation$error$respo4 = _mutation$error$respo3[0]) === null || _mutation$error$respo4 === void 0 ? void 0 : _mutation$error$respo4.message) || t("MT_SUBMISSION_FAILED_MESSAGE")), /*#__PURE__*/React.createElement(StatusTable, null, isMutationSuccess && /*#__PURE__*/React.createElement(Row, {
|
|
30225
30256
|
rowContainerStyle: rowContainerStyle$4,
|
|
30226
30257
|
last: true,
|
|
30227
30258
|
textStyle: {
|
|
30228
30259
|
whiteSpace: "pre",
|
|
30229
30260
|
width: "60%"
|
|
30230
30261
|
}
|
|
30231
|
-
})),
|
|
30262
|
+
})), isMutationSuccess && /*#__PURE__*/React.createElement(SubmitBar, {
|
|
30232
30263
|
label: t("MT_DOWNLOAD_ACKNOWLEDGEMENT"),
|
|
30233
30264
|
onSubmit: handleDownloadPdf
|
|
30234
30265
|
}), (user === null || user === void 0 ? void 0 : user.type) === "CITIZEN" ? /*#__PURE__*/React.createElement(Link, {
|
|
@@ -30269,6 +30300,7 @@ const BannerPicker$5 = props => {
|
|
|
30269
30300
|
});
|
|
30270
30301
|
};
|
|
30271
30302
|
const EmergencyFixedPointTPAcknowledgement = _ref => {
|
|
30303
|
+
var _mutation$data2, _mutation$data3, _mutation$data4, _mutation$data4$data, _mutation$data4$data$, _mutation$data4$data$2, _mutation$error, _mutation$error$respo, _mutation$error$respo2, _mutation$error$respo3, _mutation$error$respo4;
|
|
30272
30304
|
let data = _ref.data,
|
|
30273
30305
|
onSuccess = _ref.onSuccess;
|
|
30274
30306
|
const _useTranslation2 = useTranslation(),
|
|
@@ -30280,14 +30312,20 @@ const EmergencyFixedPointTPAcknowledgement = _ref => {
|
|
|
30280
30312
|
storeData = _Digit$Hooks$useStore.data;
|
|
30281
30313
|
const _ref2 = storeData || {},
|
|
30282
30314
|
tenants = _ref2.tenants;
|
|
30283
|
-
useEffect(() => {
|
|
30315
|
+
useEffect$1(() => {
|
|
30284
30316
|
try {
|
|
30285
30317
|
data.tenantId = tenantId;
|
|
30286
30318
|
let formdata = treePruningPayload(data);
|
|
30287
30319
|
mutation.mutate(formdata, {
|
|
30288
|
-
onSuccess
|
|
30320
|
+
onSuccess: res => {
|
|
30321
|
+
if (!(res !== null && res !== void 0 && res.error)) {
|
|
30322
|
+
onSuccess();
|
|
30323
|
+
}
|
|
30324
|
+
}
|
|
30289
30325
|
});
|
|
30290
|
-
} catch (err) {
|
|
30326
|
+
} catch (err) {
|
|
30327
|
+
console.error("Emergency TP payload construction error:", err);
|
|
30328
|
+
}
|
|
30291
30329
|
}, []);
|
|
30292
30330
|
Digit.Hooks.useCustomBackNavigation({
|
|
30293
30331
|
redirectPath: '${APPLICATION_PATH}/citizen'
|
|
@@ -30305,19 +30343,27 @@ const EmergencyFixedPointTPAcknowledgement = _ref => {
|
|
|
30305
30343
|
return Promise.reject(e);
|
|
30306
30344
|
}
|
|
30307
30345
|
};
|
|
30346
|
+
const isMutationSuccess = mutation.isSuccess && !((_mutation$data2 = mutation.data) !== null && _mutation$data2 !== void 0 && _mutation$data2.error);
|
|
30347
|
+
const isMutationError = mutation.isError || mutation.isSuccess && ((_mutation$data3 = mutation.data) === null || _mutation$data3 === void 0 ? void 0 : _mutation$data3.error);
|
|
30308
30348
|
return mutation.isLoading || mutation.isIdle ? /*#__PURE__*/React.createElement(Loader, null) : /*#__PURE__*/React.createElement(Card, null, /*#__PURE__*/React.createElement(BannerPicker$5, {
|
|
30309
30349
|
t: t,
|
|
30310
30350
|
data: mutation.data,
|
|
30311
|
-
isSuccess:
|
|
30351
|
+
isSuccess: isMutationSuccess,
|
|
30312
30352
|
isLoading: mutation.isIdle || mutation.isLoading
|
|
30313
|
-
}),
|
|
30353
|
+
}), isMutationError && /*#__PURE__*/React.createElement(CardText, {
|
|
30354
|
+
style: {
|
|
30355
|
+
color: "#d4351c",
|
|
30356
|
+
textAlign: "center",
|
|
30357
|
+
marginTop: "8px"
|
|
30358
|
+
}
|
|
30359
|
+
}, ((_mutation$data4 = mutation.data) === null || _mutation$data4 === void 0 ? void 0 : (_mutation$data4$data = _mutation$data4.data) === null || _mutation$data4$data === void 0 ? void 0 : (_mutation$data4$data$ = _mutation$data4$data.Errors) === null || _mutation$data4$data$ === void 0 ? void 0 : (_mutation$data4$data$2 = _mutation$data4$data$[0]) === null || _mutation$data4$data$2 === void 0 ? void 0 : _mutation$data4$data$2.message) || ((_mutation$error = mutation.error) === null || _mutation$error === void 0 ? void 0 : (_mutation$error$respo = _mutation$error.response) === null || _mutation$error$respo === void 0 ? void 0 : (_mutation$error$respo2 = _mutation$error$respo.data) === null || _mutation$error$respo2 === void 0 ? void 0 : (_mutation$error$respo3 = _mutation$error$respo2.Errors) === null || _mutation$error$respo3 === void 0 ? void 0 : (_mutation$error$respo4 = _mutation$error$respo3[0]) === null || _mutation$error$respo4 === void 0 ? void 0 : _mutation$error$respo4.message) || t("TP_SUBMISSION_FAILED_MESSAGE")), /*#__PURE__*/React.createElement(StatusTable, null, isMutationSuccess && /*#__PURE__*/React.createElement(Row, {
|
|
30314
30360
|
rowContainerStyle: rowContainerStyle$5,
|
|
30315
30361
|
last: true,
|
|
30316
30362
|
textStyle: {
|
|
30317
30363
|
whiteSpace: "pre",
|
|
30318
30364
|
width: "60%"
|
|
30319
30365
|
}
|
|
30320
|
-
})),
|
|
30366
|
+
})), isMutationSuccess && /*#__PURE__*/React.createElement(SubmitBar, {
|
|
30321
30367
|
label: t("TP_DOWNLOAD_ACKNOWLEDGEMENT"),
|
|
30322
30368
|
onSubmit: handleDownloadPdf
|
|
30323
30369
|
}), (user === null || user === void 0 ? void 0 : user.type) === "CITIZEN" ? /*#__PURE__*/React.createElement(Link, {
|
|
@@ -30445,7 +30491,7 @@ const WTEmergencyFixedPointCreate = () => {
|
|
|
30445
30491
|
conf.indexRoute = "fp-info";
|
|
30446
30492
|
return conf;
|
|
30447
30493
|
}, []);
|
|
30448
|
-
useEffect(() => {
|
|
30494
|
+
useEffect$1(() => {
|
|
30449
30495
|
if (params && Object.keys(params).length > 0 && window.location.href.includes("/fp-info") && sessionStorage.getItem("docReqScreenByBack") !== "true") {
|
|
30450
30496
|
clearParams();
|
|
30451
30497
|
queryClient.invalidateQueries("FP_Create");
|
|
@@ -30494,7 +30540,7 @@ const WTEmergencyFixedPointCreate = () => {
|
|
|
30494
30540
|
}
|
|
30495
30541
|
};
|
|
30496
30542
|
const paramsRef = useRef(params);
|
|
30497
|
-
useEffect(() => {
|
|
30543
|
+
useEffect$1(() => {
|
|
30498
30544
|
paramsRef.current = params;
|
|
30499
30545
|
}, [params]);
|
|
30500
30546
|
const handleSelect = useCallback(function (key, data, skipStep, index, isAddMultiple) {
|
|
@@ -30606,7 +30652,7 @@ const WTEmergencyFixedPointCreate = () => {
|
|
|
30606
30652
|
};
|
|
30607
30653
|
const isFormStep = formStepRoutes.some(route => pathname.includes(route));
|
|
30608
30654
|
const sectionRefs = useRef({});
|
|
30609
|
-
useEffect(() => {
|
|
30655
|
+
useEffect$1(() => {
|
|
30610
30656
|
if (isFormStep) {
|
|
30611
30657
|
const currentRoute = pathname.split("/").pop();
|
|
30612
30658
|
if (sectionRefs.current[currentRoute]) {
|
|
@@ -31186,7 +31232,7 @@ const EmergencyFixedPointDispatchDetails = _ref => {
|
|
|
31186
31232
|
}
|
|
31187
31233
|
}),
|
|
31188
31234
|
vehicleSearchData = _Digit$Hooks$fsm$useV2.data;
|
|
31189
|
-
useEffect(() => {
|
|
31235
|
+
useEffect$1(() => {
|
|
31190
31236
|
var _vehicleSearchData$ve, _vehicleSearchData$ve2;
|
|
31191
31237
|
const drv = vehicleSearchData === null || vehicleSearchData === void 0 ? void 0 : (_vehicleSearchData$ve = vehicleSearchData.vehicle) === null || _vehicleSearchData$ve === void 0 ? void 0 : (_vehicleSearchData$ve2 = _vehicleSearchData$ve[0]) === null || _vehicleSearchData$ve2 === void 0 ? void 0 : _vehicleSearchData$ve2.driverData;
|
|
31192
31238
|
if (drv) {
|
|
@@ -31315,7 +31361,7 @@ const WTModule = _ref => {
|
|
|
31315
31361
|
language
|
|
31316
31362
|
});
|
|
31317
31363
|
Digit.SessionStorage.set("WT_TENANTS", tenants);
|
|
31318
|
-
useEffect(() => userType === "employee" && Digit.LocalizationService.getLocale({
|
|
31364
|
+
useEffect$1(() => userType === "employee" && Digit.LocalizationService.getLocale({
|
|
31319
31365
|
modules: ["rainmaker-" + Digit.ULBService.getCurrentTenantId()],
|
|
31320
31366
|
locale: Digit.StoreData.getCurrentLanguage(),
|
|
31321
31367
|
tenantId: Digit.ULBService.getCurrentTenantId()
|
|
@@ -31334,7 +31380,7 @@ const WTLinks = _ref2 => {
|
|
|
31334
31380
|
t = _useTranslation.t;
|
|
31335
31381
|
const _Digit$Hooks$useSessi = Digit.Hooks.useSessionStorage("WT", {}),
|
|
31336
31382
|
clearParams = _Digit$Hooks$useSessi[2];
|
|
31337
|
-
useEffect(() => {
|
|
31383
|
+
useEffect$1(() => {
|
|
31338
31384
|
clearParams();
|
|
31339
31385
|
}, []);
|
|
31340
31386
|
const links = [{
|