@djb25/digit-ui-module-ws 1.0.19 → 1.0.21
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.css +332 -0
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/index.modern.js +676 -352
- package/dist/index.modern.js.map +1 -1
- package/package.json +1 -1
package/dist/index.modern.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React, { useState, useEffect, useRef, useMemo, Fragment as Fragment$1, useReducer, useCallback } from 'react';
|
|
2
2
|
import { useTranslation } from 'react-i18next';
|
|
3
3
|
import { Link, useLocation, Switch, Route, useHistory, useRouteMatch, Redirect, useParams } from 'react-router-dom';
|
|
4
|
-
import { Loader, Card, KeyNote, SubmitBar, InfoBannerIcon, Header, BackButton, PrivateRoute, Banner, CardText, ActionBar, HomeIcon, PrintBtnCommon, MultiLink, LinkButton, Toast,
|
|
4
|
+
import { Loader, Card, KeyNote, SubmitBar, InfoBannerIcon, Header, BackButton, PrivateRoute, Banner, CardText, ActionBar, HomeIcon, PrintBtnCommon, MultiLink, LinkButton, Toast, ModuleHeader, ArrowLeft, TickMark, FormStep, CardLabel, RadioOrSelect, TextInput, CardHeader, CitizenInfoLabel, CardSubHeader, Dropdown, UploadFile, CheckBox, RadioButtons, MobileNumber, LabelFieldPair, DatePicker, CardLabelError, DeleteIcon, WrapUnMaskComponent, StatusTable, Row, CardSectionHeader, InfoIcon, TextArea, SearchField, FilterFormField, RemoveableTag, MultiSelectDropdown, InboxComposer, DropIcon, WSICon, EmployeeModuleCard, SearchAction, PopUp, DetailsCard, SearchForm, CloseSvg, CollapsibleCardPage, Table, Localities, Modal, DownloadBtnCommon, CollectionIcon, ResponseComposer, TelePhone, DisplayPhotos, CheckPoint, ConnectingCheckPoints, ActionLinks, PDFSvg, EditIcon, CardSectionSubText, DownloadIcon, CardLabelDesc, VerticalTimeline, FormComposer, MultiUploadWrapper, Close as Close$e, BreakLine, ViewsIcon, Menu, ButtonSelector, CitizenHomeCard } from '@djb25/digit-ui-react-components';
|
|
5
5
|
import { useForm, Controller, useWatch, useFormContext } from 'react-hook-form';
|
|
6
6
|
import { read, utils as utils$1 } from 'xlsx';
|
|
7
7
|
import { useQueryClient } from 'react-query';
|
|
@@ -441,21 +441,36 @@ const getFiles = async (filesArray, tenant) => {
|
|
|
441
441
|
response !== null && response !== void 0 && (_response$data = response.data) !== null && _response$data !== void 0 && (_response$data$fileSt = _response$data.fileStoreIds) !== null && _response$data$fileSt !== void 0 && (_response$data$fileSt2 = _response$data$fileSt[0]) !== null && _response$data$fileSt2 !== void 0 && _response$data$fileSt2.url ? window.open(response === null || response === void 0 ? void 0 : (_response$data2 = response.data) === null || _response$data2 === void 0 ? void 0 : (_response$data2$fileS = _response$data2.fileStoreIds) === null || _response$data2$fileS === void 0 ? void 0 : (_response$data2$fileS2 = _response$data2$fileS[0]) === null || _response$data2$fileS2 === void 0 ? void 0 : _response$data2$fileS2.url) : null;
|
|
442
442
|
};
|
|
443
443
|
const createPayloadOfWS = async data => {
|
|
444
|
-
var _data$cpt, _data$cpt$details, _data$cpt$details$own, _data$applicationSele, _data$applicationSele2, _data$useDetails, _data$useDetails2, _data$useDetails3, _data$useDetails3$pro, _data$useDetails4, _data$useDetails4$pro, _data$useDetails5, _data$useDetails6, _data$useDetails7, _data$useDetails8, _data$propertyAddress, _data$applicant, _data$useDetails9, _data$useDetails9$gen, _data$contact, _data$applicant2, _data$applicant3, _data$applicant4, _data$applicationSele3, _data$applicationSele4, _data$contact2, _data$cpt2, _data$cpt3, _data$cpt3$details, _data$zro, _data$propertyAddress2, _data$propertyAddress3, _data$applicationSele5, _data$applicationSele6, _data$applicationSele7, _data$applicationSele8, _data$applicationSele9, _data$applicationSele0, _data$applicationSele1, _data$applicationSele10, _data$applicationSele11, _data$applicationSele12, _data$applicationSele13, _data$applicationSele14, _data$applicationSele15, _data$applicationSele16, _data$applicationSele17, _data$applicationSele18, _data$applicationSele19, _data$applicationSele20, _data$applicationSele21, _data$applicationSele22, _data$applicationSele23, _data$contact3, _data$documents, _data$documents2, _data$documents3, _data$
|
|
444
|
+
var _data$cpt, _data$cpt$details, _data$cpt$details$own, _data$applicationSele, _data$applicationSele2, _data$ConnectionHolde, _data$useDetails, _data$useDetails2, _data$useDetails3, _data$useDetails3$pro, _connectionDetailsObj, _connectionDetailsObj2, _data$useDetails4, _data$useDetails4$pro, _connectionDetailsObj3, _connectionDetailsObj4, _data$useDetails5, _data$useDetails6, _data$useDetails7, _data$useDetails8, _connectionHolder$gen, _connectionHolder$own, _connectionHolder$rel, _data$propertyAddress, _data$applicant, _data$useDetails9, _data$useDetails9$gen, _data$contact, _data$applicant2, _data$applicant3, _data$applicant4, _data$applicationSele3, _data$applicationSele4, _data$contact2, _data$cpt2, _data$cpt3, _data$cpt3$details, _data$zro, _data$propertyAddress2, _data$propertyAddress3, _data$cpt4, _data$cpt4$details, _data$cpt4$details$ad, _data$cpt4$details$ad2, _data$applicationSele5, _data$applicationSele6, _data$applicationSele7, _data$applicationSele8, _connectionDetailsObj5, _data$applicationSele9, _data$applicationSele0, _connectionHolder$own2, _data$applicationSele1, _data$applicationSele10, _data$applicationSele11, _data$applicationSele12, _data$applicationSele13, _data$applicationSele14, _data$applicationSele15, _data$applicationSele16, _data$applicationSele17, _data$applicationSele18, _data$applicationSele19, _data$applicationSele20, _data$applicationSele21, _data$applicationSele22, _data$applicationSele23, _data$contact3, _data$documents, _data$documents2, _data$documents3, _data$cpt5, _data$cpt5$details, _data$cpt5$details$te, _data$propertyAddress4, _data$propertyAddress5, _data$propertyAddress6, _data$cpt6, _Digit, _Digit$Customizations, _Digit$Customizations2, _Digit2, _Digit2$Customization, _Digit2$Customization2;
|
|
445
445
|
data === null || data === void 0 ? void 0 : (_data$cpt = data.cpt) === null || _data$cpt === void 0 ? void 0 : (_data$cpt$details = _data$cpt.details) === null || _data$cpt$details === void 0 ? void 0 : (_data$cpt$details$own = _data$cpt$details.owners) === null || _data$cpt$details$own === void 0 ? void 0 : _data$cpt$details$own.forEach(owner => {
|
|
446
446
|
if (owner !== null && owner !== void 0 && owner.permanentAddress) owner.correspondenceAddress = owner === null || owner === void 0 ? void 0 : owner.permanentAddress;
|
|
447
447
|
});
|
|
448
448
|
const serviceType = data === null || data === void 0 ? void 0 : (_data$applicationSele = data.applicationSelection) === null || _data$applicationSele === void 0 ? void 0 : (_data$applicationSele2 = _data$applicationSele.serviceType) === null || _data$applicationSele2 === void 0 ? void 0 : _data$applicationSele2.code;
|
|
449
|
-
const
|
|
450
|
-
const
|
|
449
|
+
const connectionDetailsArray = Array.isArray(data === null || data === void 0 ? void 0 : data.ConnectionDetails) ? data.ConnectionDetails : data !== null && data !== void 0 && data.ConnectionDetails ? Object.values(data.ConnectionDetails).filter(i => typeof i === 'object') : [];
|
|
450
|
+
const connectionDetail = (connectionDetailsArray === null || connectionDetailsArray === void 0 ? void 0 : connectionDetailsArray[0]) || (data === null || data === void 0 ? void 0 : data.ConnectionDetails) || {};
|
|
451
|
+
const isWater = serviceType === "WATER" || serviceType === "BOTH" || (connectionDetail === null || connectionDetail === void 0 ? void 0 : connectionDetail.water);
|
|
452
|
+
const isSewerage = serviceType === "SEWERAGE" || serviceType === "BOTH" || (connectionDetail === null || connectionDetail === void 0 ? void 0 : connectionDetail.sewerage);
|
|
453
|
+
const connectionDetailsObject = connectionDetail;
|
|
454
|
+
const useDetailsObject = (data === null || data === void 0 ? void 0 : data.useDetails) || connectionDetailsObject || {};
|
|
455
|
+
const connectionHolder = (data === null || data === void 0 ? void 0 : (_data$ConnectionHolde = data.ConnectionHolderDetails) === null || _data$ConnectionHolde === void 0 ? void 0 : _data$ConnectionHolde[0]) || (data === null || data === void 0 ? void 0 : data.ConnectionHolderDetails);
|
|
451
456
|
let payload = {
|
|
452
|
-
water: isWater,
|
|
453
|
-
sewerage: isSewerage,
|
|
454
|
-
proposedTaps: (data === null || data === void 0 ? void 0 : (_data$useDetails = data.useDetails) === null || _data$useDetails === void 0 ? void 0 : _data$useDetails.noOfTaps) && Number(data === null || data === void 0 ? void 0 : (_data$useDetails2 = data.useDetails) === null || _data$useDetails2 === void 0 ? void 0 : _data$useDetails2.noOfTaps),
|
|
455
|
-
proposedPipeSize: (data === null || data === void 0 ? void 0 : (_data$useDetails3 = data.useDetails) === null || _data$useDetails3 === void 0 ? void 0 : (_data$useDetails3$pro = _data$useDetails3.proposedPipeSize) === null || _data$useDetails3$pro === void 0 ? void 0 : _data$useDetails3$pro.size) && Number(data === null || data === void 0 ? void 0 : (_data$useDetails4 = data.useDetails) === null || _data$useDetails4 === void 0 ? void 0 : (_data$useDetails4$pro = _data$useDetails4.proposedPipeSize) === null || _data$useDetails4$pro === void 0 ? void 0 : _data$useDetails4$pro.size),
|
|
456
|
-
proposedWaterClosets: (data === null || data === void 0 ? void 0 : (_data$useDetails5 = data.useDetails) === null || _data$useDetails5 === void 0 ? void 0 : _data$useDetails5.proposedWaterClosets) && Number(data === null || data === void 0 ? void 0 : (_data$useDetails6 = data.useDetails) === null || _data$useDetails6 === void 0 ? void 0 : _data$useDetails6.proposedWaterClosets),
|
|
457
|
-
proposedToilets: (data === null || data === void 0 ? void 0 : (_data$useDetails7 = data.useDetails) === null || _data$useDetails7 === void 0 ? void 0 : _data$useDetails7.proposedToilets) && Number(data === null || data === void 0 ? void 0 : (_data$useDetails8 = data.useDetails) === null || _data$useDetails8 === void 0 ? void 0 : _data$useDetails8.proposedToilets),
|
|
458
|
-
connectionHolders: [{
|
|
457
|
+
water: !!isWater,
|
|
458
|
+
sewerage: !!isSewerage,
|
|
459
|
+
proposedTaps: ((data === null || data === void 0 ? void 0 : (_data$useDetails = data.useDetails) === null || _data$useDetails === void 0 ? void 0 : _data$useDetails.noOfTaps) || (connectionDetailsObject === null || connectionDetailsObject === void 0 ? void 0 : connectionDetailsObject.proposedTaps)) && Number((data === null || data === void 0 ? void 0 : (_data$useDetails2 = data.useDetails) === null || _data$useDetails2 === void 0 ? void 0 : _data$useDetails2.noOfTaps) || (connectionDetailsObject === null || connectionDetailsObject === void 0 ? void 0 : connectionDetailsObject.proposedTaps)),
|
|
460
|
+
proposedPipeSize: ((data === null || data === void 0 ? void 0 : (_data$useDetails3 = data.useDetails) === null || _data$useDetails3 === void 0 ? void 0 : (_data$useDetails3$pro = _data$useDetails3.proposedPipeSize) === null || _data$useDetails3$pro === void 0 ? void 0 : _data$useDetails3$pro.size) || (connectionDetailsObject === null || connectionDetailsObject === void 0 ? void 0 : (_connectionDetailsObj = connectionDetailsObject.proposedPipeSize) === null || _connectionDetailsObj === void 0 ? void 0 : _connectionDetailsObj.size) || (connectionDetailsObject === null || connectionDetailsObject === void 0 ? void 0 : (_connectionDetailsObj2 = connectionDetailsObject.proposedPipeSize) === null || _connectionDetailsObj2 === void 0 ? void 0 : _connectionDetailsObj2.code)) && Number((data === null || data === void 0 ? void 0 : (_data$useDetails4 = data.useDetails) === null || _data$useDetails4 === void 0 ? void 0 : (_data$useDetails4$pro = _data$useDetails4.proposedPipeSize) === null || _data$useDetails4$pro === void 0 ? void 0 : _data$useDetails4$pro.size) || (connectionDetailsObject === null || connectionDetailsObject === void 0 ? void 0 : (_connectionDetailsObj3 = connectionDetailsObject.proposedPipeSize) === null || _connectionDetailsObj3 === void 0 ? void 0 : _connectionDetailsObj3.size) || (connectionDetailsObject === null || connectionDetailsObject === void 0 ? void 0 : (_connectionDetailsObj4 = connectionDetailsObject.proposedPipeSize) === null || _connectionDetailsObj4 === void 0 ? void 0 : _connectionDetailsObj4.code)),
|
|
461
|
+
proposedWaterClosets: ((data === null || data === void 0 ? void 0 : (_data$useDetails5 = data.useDetails) === null || _data$useDetails5 === void 0 ? void 0 : _data$useDetails5.proposedWaterClosets) || (connectionDetailsObject === null || connectionDetailsObject === void 0 ? void 0 : connectionDetailsObject.proposedWaterClosets)) && Number((data === null || data === void 0 ? void 0 : (_data$useDetails6 = data.useDetails) === null || _data$useDetails6 === void 0 ? void 0 : _data$useDetails6.proposedWaterClosets) || (connectionDetailsObject === null || connectionDetailsObject === void 0 ? void 0 : connectionDetailsObject.proposedWaterClosets)),
|
|
462
|
+
proposedToilets: ((data === null || data === void 0 ? void 0 : (_data$useDetails7 = data.useDetails) === null || _data$useDetails7 === void 0 ? void 0 : _data$useDetails7.proposedToilets) || (connectionDetailsObject === null || connectionDetailsObject === void 0 ? void 0 : connectionDetailsObject.proposedToilets)) && Number((data === null || data === void 0 ? void 0 : (_data$useDetails8 = data.useDetails) === null || _data$useDetails8 === void 0 ? void 0 : _data$useDetails8.proposedToilets) || (connectionDetailsObject === null || connectionDetailsObject === void 0 ? void 0 : connectionDetailsObject.proposedToilets)),
|
|
463
|
+
connectionHolders: connectionHolder ? [{
|
|
464
|
+
correspondenceAddress: (connectionHolder === null || connectionHolder === void 0 ? void 0 : connectionHolder.address) || (connectionHolder === null || connectionHolder === void 0 ? void 0 : connectionHolder.correspondenceAddress) || "",
|
|
465
|
+
fatherOrHusbandName: (connectionHolder === null || connectionHolder === void 0 ? void 0 : connectionHolder.guardian) || (connectionHolder === null || connectionHolder === void 0 ? void 0 : connectionHolder.fatherOrHusbandName) || "",
|
|
466
|
+
gender: (connectionHolder === null || connectionHolder === void 0 ? void 0 : (_connectionHolder$gen = connectionHolder.gender) === null || _connectionHolder$gen === void 0 ? void 0 : _connectionHolder$gen.code) || (connectionHolder === null || connectionHolder === void 0 ? void 0 : connectionHolder.gender) || "",
|
|
467
|
+
mobileNumber: (connectionHolder === null || connectionHolder === void 0 ? void 0 : connectionHolder.mobileNumber) || "",
|
|
468
|
+
name: (connectionHolder === null || connectionHolder === void 0 ? void 0 : connectionHolder.name) || "",
|
|
469
|
+
ownerType: (connectionHolder === null || connectionHolder === void 0 ? void 0 : (_connectionHolder$own = connectionHolder.ownerType) === null || _connectionHolder$own === void 0 ? void 0 : _connectionHolder$own.code) || (connectionHolder === null || connectionHolder === void 0 ? void 0 : connectionHolder.ownerType) || "",
|
|
470
|
+
relationship: (connectionHolder === null || connectionHolder === void 0 ? void 0 : (_connectionHolder$rel = connectionHolder.relationship) === null || _connectionHolder$rel === void 0 ? void 0 : _connectionHolder$rel.code) || (connectionHolder === null || connectionHolder === void 0 ? void 0 : connectionHolder.relationship) || "OTHERS",
|
|
471
|
+
sameAsPropertyAddress: (connectionHolder === null || connectionHolder === void 0 ? void 0 : connectionHolder.sameAsOwnerDetails) || (connectionHolder === null || connectionHolder === void 0 ? void 0 : connectionHolder.sameAsPropertyAddress) || false,
|
|
472
|
+
emailId: (connectionHolder === null || connectionHolder === void 0 ? void 0 : connectionHolder.emailId) || ""
|
|
473
|
+
}] : [{
|
|
459
474
|
correspondenceAddress: (data === null || data === void 0 ? void 0 : (_data$propertyAddress = data.propertyAddress) === null || _data$propertyAddress === void 0 ? void 0 : _data$propertyAddress.address) || "",
|
|
460
475
|
fatherOrHusbandName: (data === null || data === void 0 ? void 0 : (_data$applicant = data.applicant) === null || _data$applicant === void 0 ? void 0 : _data$applicant.ParentorSpouse) || "",
|
|
461
476
|
gender: (data === null || data === void 0 ? void 0 : (_data$useDetails9 = data.useDetails) === null || _data$useDetails9 === void 0 ? void 0 : (_data$useDetails9$gen = _data$useDetails9.gender) === null || _data$useDetails9$gen === void 0 ? void 0 : _data$useDetails9$gen.code) || "",
|
|
@@ -474,14 +489,14 @@ const createPayloadOfWS = async data => {
|
|
|
474
489
|
noOfWaterClosets: null,
|
|
475
490
|
noOfToilets: null,
|
|
476
491
|
additionalDetails: {
|
|
477
|
-
...
|
|
492
|
+
...useDetailsObject,
|
|
478
493
|
...(data === null || data === void 0 ? void 0 : data.djbEmployee),
|
|
479
494
|
...(data === null || data === void 0 ? void 0 : data.bankDetails),
|
|
480
|
-
zro: data === null || data === void 0 ? void 0 : (_data$zro = data.zro) === null || _data$zro === void 0 ? void 0 : _data$zro.code,
|
|
481
|
-
locality: data === null || data === void 0 ? void 0 : (_data$propertyAddress2 = data.propertyAddress) === null || _data$propertyAddress2 === void 0 ? void 0 : (_data$propertyAddress3 = _data$propertyAddress2.locality) === null || _data$propertyAddress3 === void 0 ? void 0 : _data$propertyAddress3.code,
|
|
495
|
+
zro: (data === null || data === void 0 ? void 0 : (_data$zro = data.zro) === null || _data$zro === void 0 ? void 0 : _data$zro.code) || (data === null || data === void 0 ? void 0 : data.zro),
|
|
496
|
+
locality: (data === null || data === void 0 ? void 0 : (_data$propertyAddress2 = data.propertyAddress) === null || _data$propertyAddress2 === void 0 ? void 0 : (_data$propertyAddress3 = _data$propertyAddress2.locality) === null || _data$propertyAddress3 === void 0 ? void 0 : _data$propertyAddress3.code) || (data === null || data === void 0 ? void 0 : (_data$cpt4 = data.cpt) === null || _data$cpt4 === void 0 ? void 0 : (_data$cpt4$details = _data$cpt4.details) === null || _data$cpt4$details === void 0 ? void 0 : (_data$cpt4$details$ad = _data$cpt4$details.address) === null || _data$cpt4$details$ad === void 0 ? void 0 : (_data$cpt4$details$ad2 = _data$cpt4$details$ad.locality) === null || _data$cpt4$details$ad2 === void 0 ? void 0 : _data$cpt4$details$ad2.code),
|
|
482
497
|
applicantType: data === null || data === void 0 ? void 0 : (_data$applicationSele5 = data.applicationSelection) === null || _data$applicationSele5 === void 0 ? void 0 : (_data$applicationSele6 = _data$applicationSele5.applicantType) === null || _data$applicationSele6 === void 0 ? void 0 : _data$applicationSele6.code,
|
|
483
|
-
connectionType: data === null || data === void 0 ? void 0 : (_data$applicationSele7 = data.applicationSelection) === null || _data$applicationSele7 === void 0 ? void 0 : (_data$applicationSele8 = _data$applicationSele7.connectionType) === null || _data$applicationSele8 === void 0 ? void 0 : _data$applicationSele8.code,
|
|
484
|
-
categoryType: data === null || data === void 0 ? void 0 : (_data$applicationSele9 = data.applicationSelection) === null || _data$applicationSele9 === void 0 ? void 0 : (_data$applicationSele0 = _data$applicationSele9.categoryType) === null || _data$applicationSele0 === void 0 ? void 0 : _data$applicationSele0.code,
|
|
498
|
+
connectionType: (data === null || data === void 0 ? void 0 : (_data$applicationSele7 = data.applicationSelection) === null || _data$applicationSele7 === void 0 ? void 0 : (_data$applicationSele8 = _data$applicationSele7.connectionType) === null || _data$applicationSele8 === void 0 ? void 0 : _data$applicationSele8.code) || (connectionDetailsObject === null || connectionDetailsObject === void 0 ? void 0 : (_connectionDetailsObj5 = connectionDetailsObject.connectionType) === null || _connectionDetailsObj5 === void 0 ? void 0 : _connectionDetailsObj5.code) || (connectionDetailsObject === null || connectionDetailsObject === void 0 ? void 0 : connectionDetailsObject.connectionType) || "Metered",
|
|
499
|
+
categoryType: (data === null || data === void 0 ? void 0 : (_data$applicationSele9 = data.applicationSelection) === null || _data$applicationSele9 === void 0 ? void 0 : (_data$applicationSele0 = _data$applicationSele9.categoryType) === null || _data$applicationSele0 === void 0 ? void 0 : _data$applicationSele0.code) || (connectionHolder === null || connectionHolder === void 0 ? void 0 : (_connectionHolder$own2 = connectionHolder.ownerType) === null || _connectionHolder$own2 === void 0 ? void 0 : _connectionHolder$own2.code) || (connectionHolder === null || connectionHolder === void 0 ? void 0 : connectionHolder.ownerType),
|
|
485
500
|
subCategory: data === null || data === void 0 ? void 0 : (_data$applicationSele1 = data.applicationSelection) === null || _data$applicationSele1 === void 0 ? void 0 : (_data$applicationSele10 = _data$applicationSele1.subCategory) === null || _data$applicationSele10 === void 0 ? void 0 : _data$applicationSele10.code,
|
|
486
501
|
domesticType: data === null || data === void 0 ? void 0 : (_data$applicationSele11 = data.applicationSelection) === null || _data$applicationSele11 === void 0 ? void 0 : (_data$applicationSele12 = _data$applicationSele11.domesticType) === null || _data$applicationSele12 === void 0 ? void 0 : _data$applicationSele12.code,
|
|
487
502
|
temporaryConnection: data === null || data === void 0 ? void 0 : (_data$applicationSele13 = data.applicationSelection) === null || _data$applicationSele13 === void 0 ? void 0 : (_data$applicationSele14 = _data$applicationSele13.temporaryConnection) === null || _data$applicationSele14 === void 0 ? void 0 : _data$applicationSele14.code,
|
|
@@ -497,14 +512,14 @@ const createPayloadOfWS = async data => {
|
|
|
497
512
|
otherDocumentNumber: data === null || data === void 0 ? void 0 : (_data$documents3 = data.documents) === null || _data$documents3 === void 0 ? void 0 : _data$documents3.otherDocumentNumber,
|
|
498
513
|
detailsProvidedBy: ""
|
|
499
514
|
},
|
|
500
|
-
tenantId: (data === null || data === void 0 ? void 0 : (_data$
|
|
515
|
+
tenantId: (data === null || data === void 0 ? void 0 : (_data$cpt5 = data.cpt) === null || _data$cpt5 === void 0 ? void 0 : (_data$cpt5$details = _data$cpt5.details) === null || _data$cpt5$details === void 0 ? void 0 : (_data$cpt5$details$te = _data$cpt5$details.tenantId) === null || _data$cpt5$details$te === void 0 ? void 0 : _data$cpt5$details$te.split(".")[0]) || (data === null || data === void 0 ? void 0 : (_data$propertyAddress4 = data.propertyAddress) === null || _data$propertyAddress4 === void 0 ? void 0 : (_data$propertyAddress5 = _data$propertyAddress4.city) === null || _data$propertyAddress5 === void 0 ? void 0 : (_data$propertyAddress6 = _data$propertyAddress5.code) === null || _data$propertyAddress6 === void 0 ? void 0 : _data$propertyAddress6.split(".")[0]) || Digit.ULBService.getStateId(),
|
|
501
516
|
processInstance: {
|
|
502
517
|
action: "INITIATE"
|
|
503
518
|
},
|
|
504
|
-
channel: "CFC_COUNTER"
|
|
519
|
+
channel: (data === null || data === void 0 ? void 0 : data.channel) || "CFC_COUNTER"
|
|
505
520
|
};
|
|
506
|
-
sessionStorage.setItem("WS_DOCUMENTS_INOF", JSON.stringify(data === null || data === void 0 ? void 0 : data.documents));
|
|
507
|
-
sessionStorage.setItem("WS_PROPERTY_INOF", JSON.stringify(data === null || data === void 0 ? void 0 : (_data$
|
|
521
|
+
sessionStorage.setItem("WS_DOCUMENTS_INOF", JSON.stringify((data === null || data === void 0 ? void 0 : data.documents) || []));
|
|
522
|
+
sessionStorage.setItem("WS_PROPERTY_INOF", JSON.stringify((data === null || data === void 0 ? void 0 : (_data$cpt6 = data.cpt) === null || _data$cpt6 === void 0 ? void 0 : _data$cpt6.details) || {}));
|
|
508
523
|
payload = (_Digit = Digit) !== null && _Digit !== void 0 && (_Digit$Customizations = _Digit.Customizations) !== null && _Digit$Customizations !== void 0 && (_Digit$Customizations2 = _Digit$Customizations.WS) !== null && _Digit$Customizations2 !== void 0 && _Digit$Customizations2.customiseCreatePayloadOfWS ? (_Digit2 = Digit) === null || _Digit2 === void 0 ? void 0 : (_Digit2$Customization = _Digit2.Customizations) === null || _Digit2$Customization === void 0 ? void 0 : (_Digit2$Customization2 = _Digit2$Customization.WS) === null || _Digit2$Customization2 === void 0 ? void 0 : _Digit2$Customization2.customiseCreatePayloadOfWS(data, payload) : payload;
|
|
509
524
|
return payload;
|
|
510
525
|
};
|
|
@@ -516,8 +531,8 @@ const updatePayloadOfWS = async (data, type) => {
|
|
|
516
531
|
...(data === null || data === void 0 ? void 0 : data.processInstance),
|
|
517
532
|
action: "SUBMIT_APPLICATION"
|
|
518
533
|
},
|
|
519
|
-
documents: JSON.parse(sessionStorage.getItem("WS_DOCUMENTS_INOF")),
|
|
520
|
-
property: JSON.parse(sessionStorage.getItem("WS_PROPERTY_INOF")),
|
|
534
|
+
documents: JSON.parse(sessionStorage.getItem("WS_DOCUMENTS_INOF") && sessionStorage.getItem("WS_DOCUMENTS_INOF") !== "undefined" ? sessionStorage.getItem("WS_DOCUMENTS_INOF") : "null"),
|
|
535
|
+
property: JSON.parse(sessionStorage.getItem("WS_PROPERTY_INOF") && sessionStorage.getItem("WS_PROPERTY_INOF") !== "undefined" ? sessionStorage.getItem("WS_PROPERTY_INOF") : "null"),
|
|
521
536
|
connectionType: type === "WATER" ? data === null || data === void 0 ? void 0 : data.connectionType : "Non Metered"
|
|
522
537
|
};
|
|
523
538
|
payload = (_Digit3 = Digit) !== null && _Digit3 !== void 0 && (_Digit3$Customization = _Digit3.Customizations) !== null && _Digit3$Customization !== void 0 && (_Digit3$Customization2 = _Digit3$Customization.WS) !== null && _Digit3$Customization2 !== void 0 && _Digit3$Customization2.customiseUpdatePayloadOfWS ? (_Digit4 = Digit) === null || _Digit4 === void 0 ? void 0 : (_Digit4$Customization = _Digit4.Customizations) === null || _Digit4$Customization === void 0 ? void 0 : (_Digit4$Customization2 = _Digit4$Customization.WS) === null || _Digit4$Customization2 === void 0 ? void 0 : _Digit4$Customization2.customiseUpdatePayloadOfWS(data, payload, type) : payload;
|
|
@@ -538,7 +553,7 @@ const convertToWSUpdate = data => {
|
|
|
538
553
|
return formdata;
|
|
539
554
|
};
|
|
540
555
|
const convertToEditWSUpdate = data => {
|
|
541
|
-
var _data$WaterConnection3, _data$WaterConnection4, _data$documents5, _data$
|
|
556
|
+
var _data$WaterConnection3, _data$WaterConnection4, _data$documents5, _data$ConnectionHolde2, _data$ConnectionHolde3, _data$ConnectionHolde4, _data$ConnectionHolde5, _data$ConnectionHolde6, _data$ConnectionHolde7, _data$ConnectionHolde8, _data$ConnectionHolde9, _data$ConnectionHolde0, _data$ConnectionHolde1, _data$ConnectionHolde10, _data$ConnectionHolde11, _data$ConnectionHolde12, _data$waterConectionD, _data$waterConectionD2, _data$waterConectionD3, _data$applicationType, _data$applicationType2, _data$serviceName, _waterResult$serviceN, _data$documents6, _data$sewerageConnect, _data$sewerageConnect2, _Digit7, _Digit7$Customization, _Digit7$Customization2, _Digit8, _Digit8$Customization, _Digit8$Customization2;
|
|
542
557
|
let waterResult = data === null || data === void 0 ? void 0 : (_data$WaterConnection3 = data.WaterConnectionResult) === null || _data$WaterConnection3 === void 0 ? void 0 : (_data$WaterConnection4 = _data$WaterConnection3.WaterConnection) === null || _data$WaterConnection4 === void 0 ? void 0 : _data$WaterConnection4[0];
|
|
543
558
|
let formdata = {
|
|
544
559
|
WaterConnection: {
|
|
@@ -573,16 +588,16 @@ const convertToEditWSUpdate = data => {
|
|
|
573
588
|
},
|
|
574
589
|
applicationType: data !== null && data !== void 0 && data.isEditApplication ? data === null || data === void 0 ? void 0 : data.applicationType : "MODIFY_WATER_CONNECTION",
|
|
575
590
|
dateEffectiveFrom: convertDateToEpoch(Date.now() + 86400000),
|
|
576
|
-
connectionHolders: data !== null && data !== void 0 && data.isEditApplication ? !(data !== null && data !== void 0 && (_data$
|
|
577
|
-
correspondenceAddress: (data === null || data === void 0 ? void 0 : (_data$
|
|
578
|
-
fatherOrHusbandName: (data === null || data === void 0 ? void 0 : (_data$
|
|
579
|
-
gender: (data === null || data === void 0 ? void 0 : (_data$
|
|
580
|
-
mobileNumber: (data === null || data === void 0 ? void 0 : (_data$
|
|
581
|
-
name: (data === null || data === void 0 ? void 0 : (_data$
|
|
582
|
-
emailId: (data === null || data === void 0 ? void 0 : (_data$
|
|
583
|
-
ownerType: (data === null || data === void 0 ? void 0 : (_data$
|
|
584
|
-
relationship: (data === null || data === void 0 ? void 0 : (_data$
|
|
585
|
-
sameAsPropertyAddress: data === null || data === void 0 ? void 0 : (_data$
|
|
591
|
+
connectionHolders: data !== null && data !== void 0 && data.isEditApplication ? !(data !== null && data !== void 0 && (_data$ConnectionHolde2 = data.ConnectionHolderDetails) !== null && _data$ConnectionHolde2 !== void 0 && _data$ConnectionHolde2.isOwnerSame) ? [{
|
|
592
|
+
correspondenceAddress: (data === null || data === void 0 ? void 0 : (_data$ConnectionHolde3 = data.ConnectionHolderDetails) === null || _data$ConnectionHolde3 === void 0 ? void 0 : _data$ConnectionHolde3.address) || "",
|
|
593
|
+
fatherOrHusbandName: (data === null || data === void 0 ? void 0 : (_data$ConnectionHolde4 = data.ConnectionHolderDetails) === null || _data$ConnectionHolde4 === void 0 ? void 0 : _data$ConnectionHolde4.guardian) || "",
|
|
594
|
+
gender: (data === null || data === void 0 ? void 0 : (_data$ConnectionHolde5 = data.ConnectionHolderDetails) === null || _data$ConnectionHolde5 === void 0 ? void 0 : (_data$ConnectionHolde6 = _data$ConnectionHolde5.gender) === null || _data$ConnectionHolde6 === void 0 ? void 0 : _data$ConnectionHolde6.code) || "",
|
|
595
|
+
mobileNumber: (data === null || data === void 0 ? void 0 : (_data$ConnectionHolde7 = data.ConnectionHolderDetails) === null || _data$ConnectionHolde7 === void 0 ? void 0 : _data$ConnectionHolde7.mobileNumber) || "",
|
|
596
|
+
name: (data === null || data === void 0 ? void 0 : (_data$ConnectionHolde8 = data.ConnectionHolderDetails) === null || _data$ConnectionHolde8 === void 0 ? void 0 : _data$ConnectionHolde8.name) || "",
|
|
597
|
+
emailId: (data === null || data === void 0 ? void 0 : (_data$ConnectionHolde9 = data.ConnectionHolderDetails) === null || _data$ConnectionHolde9 === void 0 ? void 0 : _data$ConnectionHolde9.emailId) || "",
|
|
598
|
+
ownerType: (data === null || data === void 0 ? void 0 : (_data$ConnectionHolde0 = data.ConnectionHolderDetails) === null || _data$ConnectionHolde0 === void 0 ? void 0 : (_data$ConnectionHolde1 = _data$ConnectionHolde0.specialCategoryType) === null || _data$ConnectionHolde1 === void 0 ? void 0 : _data$ConnectionHolde1.code) || "",
|
|
599
|
+
relationship: (data === null || data === void 0 ? void 0 : (_data$ConnectionHolde10 = data.ConnectionHolderDetails) === null || _data$ConnectionHolde10 === void 0 ? void 0 : (_data$ConnectionHolde11 = _data$ConnectionHolde10.relationship) === null || _data$ConnectionHolde11 === void 0 ? void 0 : _data$ConnectionHolde11.code) || "",
|
|
600
|
+
sameAsPropertyAddress: data === null || data === void 0 ? void 0 : (_data$ConnectionHolde12 = data.ConnectionHolderDetails) === null || _data$ConnectionHolde12 === void 0 ? void 0 : _data$ConnectionHolde12.sameAsOwnerDetails
|
|
586
601
|
}] : null : waterResult === null || waterResult === void 0 ? void 0 : waterResult.connectionHolders,
|
|
587
602
|
oldApplication: false,
|
|
588
603
|
channel: "CITIZEN",
|
|
@@ -617,7 +632,7 @@ const convertToEditWSUpdate = data => {
|
|
|
617
632
|
return formdata;
|
|
618
633
|
};
|
|
619
634
|
const convertToEditSWUpdate = data => {
|
|
620
|
-
var _data$SewerageConnect, _data$SewerageConnect2, _data$documents7, _data$
|
|
635
|
+
var _data$SewerageConnect, _data$SewerageConnect2, _data$documents7, _data$ConnectionHolde13, _data$ConnectionHolde14, _data$ConnectionHolde15, _data$ConnectionHolde16, _data$ConnectionHolde17, _data$ConnectionHolde18, _data$ConnectionHolde19, _data$ConnectionHolde20, _data$ConnectionHolde21, _data$ConnectionHolde22, _data$ConnectionHolde23, _data$ConnectionHolde24, _data$ConnectionHolde25, _data$waterConectionD4, _data$waterConectionD5, _data$waterConectionD6, _data$applicationType3, _data$applicationType4, _data$serviceName2, _SewerageResult$servi, _data$documents8, _data$sewerageConnect3, _data$sewerageConnect4, _Digit9, _Digit9$Customization, _Digit9$Customization2, _Digit0, _Digit0$Customization, _Digit0$Customization2;
|
|
621
636
|
let SewerageResult = data === null || data === void 0 ? void 0 : (_data$SewerageConnect = data.SewerageConnectionResult) === null || _data$SewerageConnect === void 0 ? void 0 : (_data$SewerageConnect2 = _data$SewerageConnect.SewerageConnections) === null || _data$SewerageConnect2 === void 0 ? void 0 : _data$SewerageConnect2[0];
|
|
622
637
|
let formdata = {
|
|
623
638
|
SewerageConnection: {
|
|
@@ -652,16 +667,16 @@ const convertToEditSWUpdate = data => {
|
|
|
652
667
|
},
|
|
653
668
|
applicationType: data !== null && data !== void 0 && data.isEditApplication ? data === null || data === void 0 ? void 0 : data.applicationType : "MODIFY_WATER_CONNECTION",
|
|
654
669
|
dateEffectiveFrom: convertDateToEpoch(Date.now() + 86400000),
|
|
655
|
-
connectionHolders: data !== null && data !== void 0 && data.isEditApplication ? !(data !== null && data !== void 0 && (_data$
|
|
656
|
-
correspondenceAddress: (data === null || data === void 0 ? void 0 : (_data$
|
|
657
|
-
fatherOrHusbandName: (data === null || data === void 0 ? void 0 : (_data$
|
|
658
|
-
gender: (data === null || data === void 0 ? void 0 : (_data$
|
|
659
|
-
mobileNumber: (data === null || data === void 0 ? void 0 : (_data$
|
|
660
|
-
name: (data === null || data === void 0 ? void 0 : (_data$
|
|
661
|
-
emailId: (data === null || data === void 0 ? void 0 : (_data$
|
|
662
|
-
ownerType: (data === null || data === void 0 ? void 0 : (_data$
|
|
663
|
-
relationship: (data === null || data === void 0 ? void 0 : (_data$
|
|
664
|
-
sameAsPropertyAddress: data === null || data === void 0 ? void 0 : (_data$
|
|
670
|
+
connectionHolders: data !== null && data !== void 0 && data.isEditApplication ? !(data !== null && data !== void 0 && (_data$ConnectionHolde13 = data.ConnectionHolderDetails) !== null && _data$ConnectionHolde13 !== void 0 && _data$ConnectionHolde13.isOwnerSame) ? [{
|
|
671
|
+
correspondenceAddress: (data === null || data === void 0 ? void 0 : (_data$ConnectionHolde14 = data.ConnectionHolderDetails) === null || _data$ConnectionHolde14 === void 0 ? void 0 : _data$ConnectionHolde14.address) || "",
|
|
672
|
+
fatherOrHusbandName: (data === null || data === void 0 ? void 0 : (_data$ConnectionHolde15 = data.ConnectionHolderDetails) === null || _data$ConnectionHolde15 === void 0 ? void 0 : _data$ConnectionHolde15.guardian) || "",
|
|
673
|
+
gender: (data === null || data === void 0 ? void 0 : (_data$ConnectionHolde16 = data.ConnectionHolderDetails) === null || _data$ConnectionHolde16 === void 0 ? void 0 : (_data$ConnectionHolde17 = _data$ConnectionHolde16.gender) === null || _data$ConnectionHolde17 === void 0 ? void 0 : _data$ConnectionHolde17.code) || "",
|
|
674
|
+
mobileNumber: (data === null || data === void 0 ? void 0 : (_data$ConnectionHolde18 = data.ConnectionHolderDetails) === null || _data$ConnectionHolde18 === void 0 ? void 0 : _data$ConnectionHolde18.mobileNumber) || "",
|
|
675
|
+
name: (data === null || data === void 0 ? void 0 : (_data$ConnectionHolde19 = data.ConnectionHolderDetails) === null || _data$ConnectionHolde19 === void 0 ? void 0 : _data$ConnectionHolde19.name) || "",
|
|
676
|
+
emailId: (data === null || data === void 0 ? void 0 : (_data$ConnectionHolde20 = data.ConnectionHolderDetails) === null || _data$ConnectionHolde20 === void 0 ? void 0 : _data$ConnectionHolde20.emailId) || "",
|
|
677
|
+
ownerType: (data === null || data === void 0 ? void 0 : (_data$ConnectionHolde21 = data.ConnectionHolderDetails) === null || _data$ConnectionHolde21 === void 0 ? void 0 : (_data$ConnectionHolde22 = _data$ConnectionHolde21.specialCategoryType) === null || _data$ConnectionHolde22 === void 0 ? void 0 : _data$ConnectionHolde22.code) || "",
|
|
678
|
+
relationship: (data === null || data === void 0 ? void 0 : (_data$ConnectionHolde23 = data.ConnectionHolderDetails) === null || _data$ConnectionHolde23 === void 0 ? void 0 : (_data$ConnectionHolde24 = _data$ConnectionHolde23.relationship) === null || _data$ConnectionHolde24 === void 0 ? void 0 : _data$ConnectionHolde24.code) || "",
|
|
679
|
+
sameAsPropertyAddress: data === null || data === void 0 ? void 0 : (_data$ConnectionHolde25 = data.ConnectionHolderDetails) === null || _data$ConnectionHolde25 === void 0 ? void 0 : _data$ConnectionHolde25.sameAsOwnerDetails
|
|
665
680
|
}] : null : SewerageResult === null || SewerageResult === void 0 ? void 0 : SewerageResult.connectionHolders,
|
|
666
681
|
oldApplication: false,
|
|
667
682
|
channel: "CITIZEN",
|
|
@@ -1049,7 +1064,7 @@ const getDocumentsForPDF = (app, t) => {
|
|
|
1049
1064
|
});
|
|
1050
1065
|
};
|
|
1051
1066
|
const getPDFData = (application, data, tenantInfo, t) => {
|
|
1052
|
-
var _tenantInfo$city, _data$
|
|
1067
|
+
var _tenantInfo$city, _data$cpt7, _data$cpt7$details, _data$cpt8, _data$cpt8$details, _data$cpt9, _data$cpt9$details, _data$cpt0, _data$cpt0$details, _data$cpt1, _data$cpt1$details, _data$cpt1$details$ad, _data$cpt10, _data$cpt10$details, _data$cpt10$details$a, _data$cpt11, _data$cpt11$details, _data$cpt11$details$a, _data$cpt12, _data$cpt12$details, _data$cpt12$details$a, _data$cpt13, _data$cpt13$details, _data$cpt13$details$a, _data$cpt14, _data$cpt14$details, _data$cpt14$details$a, _data$cpt14$details$a2, _data$cpt15, _application$plumberI, _application$plumberI2, _application$plumberI3, _application$plumberI4;
|
|
1053
1068
|
return {
|
|
1054
1069
|
t: t,
|
|
1055
1070
|
tenantId: tenantInfo === null || tenantInfo === void 0 ? void 0 : tenantInfo.code,
|
|
@@ -1071,44 +1086,44 @@ const getPDFData = (application, data, tenantInfo, t) => {
|
|
|
1071
1086
|
value: (application === null || application === void 0 ? void 0 : application.propertyId) || "N/A"
|
|
1072
1087
|
}, {
|
|
1073
1088
|
title: t("WS_PROPERTY_TYPE_LABEL"),
|
|
1074
|
-
value: (data === null || data === void 0 ? void 0 : (_data$
|
|
1089
|
+
value: (data === null || data === void 0 ? void 0 : (_data$cpt7 = data.cpt) === null || _data$cpt7 === void 0 ? void 0 : (_data$cpt7$details = _data$cpt7.details) === null || _data$cpt7$details === void 0 ? void 0 : _data$cpt7$details.propertyType) || "N/A"
|
|
1075
1090
|
}, {
|
|
1076
1091
|
title: t("WS_PROPERTY_USAGE_TYPE_LABEL"),
|
|
1077
|
-
value: (data === null || data === void 0 ? void 0 : (_data$
|
|
1092
|
+
value: (data === null || data === void 0 ? void 0 : (_data$cpt8 = data.cpt) === null || _data$cpt8 === void 0 ? void 0 : (_data$cpt8$details = _data$cpt8.details) === null || _data$cpt8$details === void 0 ? void 0 : _data$cpt8$details.usageCategory) || "N/A"
|
|
1078
1093
|
}, {
|
|
1079
1094
|
title: t("WS_PROPERTY_SUB_USAGE_TYPE_LABEL"),
|
|
1080
1095
|
value: "N/A"
|
|
1081
1096
|
}, {
|
|
1082
1097
|
title: t("WS_PROP_DETAIL_PLOT_SIZE_LABEL"),
|
|
1083
|
-
value: (data === null || data === void 0 ? void 0 : (_data$
|
|
1098
|
+
value: (data === null || data === void 0 ? void 0 : (_data$cpt9 = data.cpt) === null || _data$cpt9 === void 0 ? void 0 : (_data$cpt9$details = _data$cpt9.details) === null || _data$cpt9$details === void 0 ? void 0 : _data$cpt9$details.superBuiltUpArea) || "N/A"
|
|
1084
1099
|
}, {
|
|
1085
1100
|
title: t("WS_PROPERTY_NO_OF_FLOOR_LABEL"),
|
|
1086
|
-
value: (data === null || data === void 0 ? void 0 : (_data$
|
|
1101
|
+
value: (data === null || data === void 0 ? void 0 : (_data$cpt0 = data.cpt) === null || _data$cpt0 === void 0 ? void 0 : (_data$cpt0$details = _data$cpt0.details) === null || _data$cpt0$details === void 0 ? void 0 : _data$cpt0$details.noOfFloors) || "N/A"
|
|
1087
1102
|
}, {
|
|
1088
1103
|
title: t("WS_SERV_DETAIL_CONN_RAIN_WATER_HARVESTING_FAC"),
|
|
1089
|
-
value: data === null || data === void 0 ? void 0 : (_data$
|
|
1104
|
+
value: data === null || data === void 0 ? void 0 : (_data$cpt1 = data.cpt) === null || _data$cpt1 === void 0 ? void 0 : (_data$cpt1$details = _data$cpt1.details) === null || _data$cpt1$details === void 0 ? void 0 : (_data$cpt1$details$ad = _data$cpt1$details.additionalDetails) === null || _data$cpt1$details$ad === void 0 ? void 0 : _data$cpt1$details$ad.isRainwaterHarvesting
|
|
1090
1105
|
}]
|
|
1091
1106
|
}, {
|
|
1092
1107
|
title: t("WS_COMMON_PROP_LOC_DETAIL_HEADER"),
|
|
1093
1108
|
values: [{
|
|
1094
1109
|
title: t("WS_PROP_DETAIL_CITY"),
|
|
1095
|
-
value: data === null || data === void 0 ? void 0 : (_data$
|
|
1110
|
+
value: data === null || data === void 0 ? void 0 : (_data$cpt10 = data.cpt) === null || _data$cpt10 === void 0 ? void 0 : (_data$cpt10$details = _data$cpt10.details) === null || _data$cpt10$details === void 0 ? void 0 : (_data$cpt10$details$a = _data$cpt10$details.address) === null || _data$cpt10$details$a === void 0 ? void 0 : _data$cpt10$details$a.city
|
|
1096
1111
|
}, {
|
|
1097
1112
|
title: t("WS_PROP_DETAIL_DHNO"),
|
|
1098
|
-
value: data === null || data === void 0 ? void 0 : (_data$
|
|
1113
|
+
value: data === null || data === void 0 ? void 0 : (_data$cpt11 = data.cpt) === null || _data$cpt11 === void 0 ? void 0 : (_data$cpt11$details = _data$cpt11.details) === null || _data$cpt11$details === void 0 ? void 0 : (_data$cpt11$details$a = _data$cpt11$details.address) === null || _data$cpt11$details$a === void 0 ? void 0 : _data$cpt11$details$a.doorNo
|
|
1099
1114
|
}, {
|
|
1100
1115
|
title: t("WS_PROP_DETAIL_BUILD_NAME_LABEL"),
|
|
1101
|
-
value: data === null || data === void 0 ? void 0 : (_data$
|
|
1116
|
+
value: data === null || data === void 0 ? void 0 : (_data$cpt12 = data.cpt) === null || _data$cpt12 === void 0 ? void 0 : (_data$cpt12$details = _data$cpt12.details) === null || _data$cpt12$details === void 0 ? void 0 : (_data$cpt12$details$a = _data$cpt12$details.address) === null || _data$cpt12$details$a === void 0 ? void 0 : _data$cpt12$details$a.buildingName
|
|
1102
1117
|
}, {
|
|
1103
1118
|
title: t("WS_PROP_DETAIL_STREET_NAME"),
|
|
1104
|
-
value: data === null || data === void 0 ? void 0 : (_data$
|
|
1119
|
+
value: data === null || data === void 0 ? void 0 : (_data$cpt13 = data.cpt) === null || _data$cpt13 === void 0 ? void 0 : (_data$cpt13$details = _data$cpt13.details) === null || _data$cpt13$details === void 0 ? void 0 : (_data$cpt13$details$a = _data$cpt13$details.address) === null || _data$cpt13$details$a === void 0 ? void 0 : _data$cpt13$details$a.street
|
|
1105
1120
|
}, {
|
|
1106
1121
|
title: t("WS_PROP_DETAIL_LOCALITY_MOHALLA_LABEL"),
|
|
1107
|
-
value: data === null || data === void 0 ? void 0 : (_data$
|
|
1122
|
+
value: data === null || data === void 0 ? void 0 : (_data$cpt14 = data.cpt) === null || _data$cpt14 === void 0 ? void 0 : (_data$cpt14$details = _data$cpt14.details) === null || _data$cpt14$details === void 0 ? void 0 : (_data$cpt14$details$a = _data$cpt14$details.address) === null || _data$cpt14$details$a === void 0 ? void 0 : (_data$cpt14$details$a2 = _data$cpt14$details$a.locality) === null || _data$cpt14$details$a2 === void 0 ? void 0 : _data$cpt14$details$a2.name
|
|
1108
1123
|
}]
|
|
1109
1124
|
}, {
|
|
1110
1125
|
title: t("WS_TASK_PROP_OWN_HEADER"),
|
|
1111
|
-
values: getOwnersforPDF(data === null || data === void 0 ? void 0 : (_data$
|
|
1126
|
+
values: getOwnersforPDF(data === null || data === void 0 ? void 0 : (_data$cpt15 = data.cpt) === null || _data$cpt15 === void 0 ? void 0 : _data$cpt15.details, t)
|
|
1112
1127
|
}, {
|
|
1113
1128
|
...(application !== null && application !== void 0 && application.applicationType.includes("WATER") ? {
|
|
1114
1129
|
title: t("WS_COMMON_CONNECTION_DETAILS"),
|
|
@@ -1427,30 +1442,30 @@ const convertApplicationData = (data, serviceType, modify = false, editByConfig
|
|
|
1427
1442
|
return payload;
|
|
1428
1443
|
};
|
|
1429
1444
|
const convertEditApplicationDetails = async (data, appData, actionData) => {
|
|
1430
|
-
var _data$
|
|
1431
|
-
data === null || data === void 0 ? void 0 : (_data$
|
|
1445
|
+
var _data$cpt16, _data$cpt16$details, _data$cpt16$details$o, _data$cpt17, _data$cpt17$details, _data$ConnectionDetai, _data$ConnectionDetai2, _data$ConnectionDetai3, _data$ConnectionDetai4, _data$ConnectionDetai5, _data$ConnectionDetai6, _data$ConnectionDetai7, _data$ConnectionDetai8, _data$ConnectionDetai9, _data$ConnectionDetai0, _data$ConnectionDetai1, _data$ConnectionDetai10, _data$ConnectionDetai11, _data$ConnectionDetai12, _data$ConnectionDetai13, _data$ConnectionDetai14, _data$ConnectionDetai15, _data$ConnectionDetai16, _data$ConnectionHolde26, _data$ConnectionHolde27, _appData$applicationD, _appData$applicationD2, _data$ConnectionHolde28, _data$ConnectionHolde29, _data$ConnectionHolde30, _data$ConnectionHolde31, _data$ConnectionHolde32, _data$ConnectionHolde33, _data$ConnectionHolde34, _data$ConnectionHolde35, _data$ConnectionHolde36, _data$ConnectionHolde37, _data$ConnectionHolde38, _data$ConnectionHolde39, _data$ConnectionHolde40, _data$ConnectionHolde41, _data$ConnectionHolde42, _data$ConnectionHolde43, _data$ConnectionHolde44, _data$ConnectionHolde45, _data$ConnectionHolde46, _data$ConnectionHolde47, _data$ConnectionHolde48, _data$cpt18, _data$DocumentsRequir;
|
|
1446
|
+
data === null || data === void 0 ? void 0 : (_data$cpt16 = data.cpt) === null || _data$cpt16 === void 0 ? void 0 : (_data$cpt16$details = _data$cpt16.details) === null || _data$cpt16$details === void 0 ? void 0 : (_data$cpt16$details$o = _data$cpt16$details.owners) === null || _data$cpt16$details$o === void 0 ? void 0 : _data$cpt16$details$o.forEach(owner => {
|
|
1432
1447
|
if (owner !== null && owner !== void 0 && owner.permanentAddress) owner.correspondenceAddress = owner === null || owner === void 0 ? void 0 : owner.permanentAddress;
|
|
1433
1448
|
});
|
|
1434
1449
|
let payload = {
|
|
1435
1450
|
...appData.applicationData,
|
|
1436
|
-
propertyId: data === null || data === void 0 ? void 0 : (_data$
|
|
1451
|
+
propertyId: data === null || data === void 0 ? void 0 : (_data$cpt17 = data.cpt) === null || _data$cpt17 === void 0 ? void 0 : (_data$cpt17$details = _data$cpt17.details) === null || _data$cpt17$details === void 0 ? void 0 : _data$cpt17$details.propertyId,
|
|
1437
1452
|
proposedTaps: (data === null || data === void 0 ? void 0 : (_data$ConnectionDetai = data.ConnectionDetails) === null || _data$ConnectionDetai === void 0 ? void 0 : (_data$ConnectionDetai2 = _data$ConnectionDetai[0]) === null || _data$ConnectionDetai2 === void 0 ? void 0 : _data$ConnectionDetai2.proposedTaps) && Number(data === null || data === void 0 ? void 0 : (_data$ConnectionDetai3 = data.ConnectionDetails) === null || _data$ConnectionDetai3 === void 0 ? void 0 : (_data$ConnectionDetai4 = _data$ConnectionDetai3[0]) === null || _data$ConnectionDetai4 === void 0 ? void 0 : _data$ConnectionDetai4.proposedTaps),
|
|
1438
1453
|
proposedPipeSize: (data === null || data === void 0 ? void 0 : (_data$ConnectionDetai5 = data.ConnectionDetails) === null || _data$ConnectionDetai5 === void 0 ? void 0 : (_data$ConnectionDetai6 = _data$ConnectionDetai5[0]) === null || _data$ConnectionDetai6 === void 0 ? void 0 : (_data$ConnectionDetai7 = _data$ConnectionDetai6.proposedPipeSize) === null || _data$ConnectionDetai7 === void 0 ? void 0 : _data$ConnectionDetai7.size) && Number(data === null || data === void 0 ? void 0 : (_data$ConnectionDetai8 = data.ConnectionDetails) === null || _data$ConnectionDetai8 === void 0 ? void 0 : (_data$ConnectionDetai9 = _data$ConnectionDetai8[0]) === null || _data$ConnectionDetai9 === void 0 ? void 0 : (_data$ConnectionDetai0 = _data$ConnectionDetai9.proposedPipeSize) === null || _data$ConnectionDetai0 === void 0 ? void 0 : _data$ConnectionDetai0.size),
|
|
1439
1454
|
proposedWaterClosets: (data === null || data === void 0 ? void 0 : (_data$ConnectionDetai1 = data.ConnectionDetails) === null || _data$ConnectionDetai1 === void 0 ? void 0 : (_data$ConnectionDetai10 = _data$ConnectionDetai1[0]) === null || _data$ConnectionDetai10 === void 0 ? void 0 : _data$ConnectionDetai10.proposedWaterClosets) && Number(data === null || data === void 0 ? void 0 : (_data$ConnectionDetai11 = data.ConnectionDetails) === null || _data$ConnectionDetai11 === void 0 ? void 0 : (_data$ConnectionDetai12 = _data$ConnectionDetai11[0]) === null || _data$ConnectionDetai12 === void 0 ? void 0 : _data$ConnectionDetai12.proposedWaterClosets),
|
|
1440
1455
|
proposedToilets: (data === null || data === void 0 ? void 0 : (_data$ConnectionDetai13 = data.ConnectionDetails) === null || _data$ConnectionDetai13 === void 0 ? void 0 : (_data$ConnectionDetai14 = _data$ConnectionDetai13[0]) === null || _data$ConnectionDetai14 === void 0 ? void 0 : _data$ConnectionDetai14.proposedToilets) && Number(data === null || data === void 0 ? void 0 : (_data$ConnectionDetai15 = data.ConnectionDetails) === null || _data$ConnectionDetai15 === void 0 ? void 0 : (_data$ConnectionDetai16 = _data$ConnectionDetai15[0]) === null || _data$ConnectionDetai16 === void 0 ? void 0 : _data$ConnectionDetai16.proposedToilets),
|
|
1441
|
-
connectionHolders: !(data !== null && data !== void 0 && (_data$
|
|
1456
|
+
connectionHolders: !(data !== null && data !== void 0 && (_data$ConnectionHolde26 = data.ConnectionHolderDetails) !== null && _data$ConnectionHolde26 !== void 0 && (_data$ConnectionHolde27 = _data$ConnectionHolde26[0]) !== null && _data$ConnectionHolde27 !== void 0 && _data$ConnectionHolde27.sameAsOwnerDetails) ? [{
|
|
1442
1457
|
...(appData === null || appData === void 0 ? void 0 : (_appData$applicationD = appData.applicationData) === null || _appData$applicationD === void 0 ? void 0 : (_appData$applicationD2 = _appData$applicationD.connectionHolders) === null || _appData$applicationD2 === void 0 ? void 0 : _appData$applicationD2[0]),
|
|
1443
|
-
correspondenceAddress: (data === null || data === void 0 ? void 0 : (_data$
|
|
1444
|
-
fatherOrHusbandName: (data === null || data === void 0 ? void 0 : (_data$
|
|
1445
|
-
gender: (data === null || data === void 0 ? void 0 : (_data$
|
|
1446
|
-
mobileNumber: (data === null || data === void 0 ? void 0 : (_data$
|
|
1447
|
-
name: (data === null || data === void 0 ? void 0 : (_data$
|
|
1448
|
-
emailId: (data === null || data === void 0 ? void 0 : (_data$
|
|
1449
|
-
ownerType: (data === null || data === void 0 ? void 0 : (_data$
|
|
1450
|
-
relationship: (data === null || data === void 0 ? void 0 : (_data$
|
|
1451
|
-
sameAsPropertyAddress: data === null || data === void 0 ? void 0 : (_data$
|
|
1458
|
+
correspondenceAddress: (data === null || data === void 0 ? void 0 : (_data$ConnectionHolde28 = data.ConnectionHolderDetails) === null || _data$ConnectionHolde28 === void 0 ? void 0 : (_data$ConnectionHolde29 = _data$ConnectionHolde28[0]) === null || _data$ConnectionHolde29 === void 0 ? void 0 : _data$ConnectionHolde29.address) || "",
|
|
1459
|
+
fatherOrHusbandName: (data === null || data === void 0 ? void 0 : (_data$ConnectionHolde30 = data.ConnectionHolderDetails) === null || _data$ConnectionHolde30 === void 0 ? void 0 : (_data$ConnectionHolde31 = _data$ConnectionHolde30[0]) === null || _data$ConnectionHolde31 === void 0 ? void 0 : _data$ConnectionHolde31.guardian) || "",
|
|
1460
|
+
gender: (data === null || data === void 0 ? void 0 : (_data$ConnectionHolde32 = data.ConnectionHolderDetails) === null || _data$ConnectionHolde32 === void 0 ? void 0 : (_data$ConnectionHolde33 = _data$ConnectionHolde32[0]) === null || _data$ConnectionHolde33 === void 0 ? void 0 : (_data$ConnectionHolde34 = _data$ConnectionHolde33.gender) === null || _data$ConnectionHolde34 === void 0 ? void 0 : _data$ConnectionHolde34.code) || "",
|
|
1461
|
+
mobileNumber: (data === null || data === void 0 ? void 0 : (_data$ConnectionHolde35 = data.ConnectionHolderDetails) === null || _data$ConnectionHolde35 === void 0 ? void 0 : (_data$ConnectionHolde36 = _data$ConnectionHolde35[0]) === null || _data$ConnectionHolde36 === void 0 ? void 0 : _data$ConnectionHolde36.mobileNumber) || "",
|
|
1462
|
+
name: (data === null || data === void 0 ? void 0 : (_data$ConnectionHolde37 = data.ConnectionHolderDetails) === null || _data$ConnectionHolde37 === void 0 ? void 0 : (_data$ConnectionHolde38 = _data$ConnectionHolde37[0]) === null || _data$ConnectionHolde38 === void 0 ? void 0 : _data$ConnectionHolde38.name) || "",
|
|
1463
|
+
emailId: (data === null || data === void 0 ? void 0 : (_data$ConnectionHolde39 = data.ConnectionHolderDetails) === null || _data$ConnectionHolde39 === void 0 ? void 0 : (_data$ConnectionHolde40 = _data$ConnectionHolde39[0]) === null || _data$ConnectionHolde40 === void 0 ? void 0 : _data$ConnectionHolde40.emailId) || "",
|
|
1464
|
+
ownerType: (data === null || data === void 0 ? void 0 : (_data$ConnectionHolde41 = data.ConnectionHolderDetails) === null || _data$ConnectionHolde41 === void 0 ? void 0 : (_data$ConnectionHolde42 = _data$ConnectionHolde41[0]) === null || _data$ConnectionHolde42 === void 0 ? void 0 : (_data$ConnectionHolde43 = _data$ConnectionHolde42.ownerType) === null || _data$ConnectionHolde43 === void 0 ? void 0 : _data$ConnectionHolde43.code) || "",
|
|
1465
|
+
relationship: (data === null || data === void 0 ? void 0 : (_data$ConnectionHolde44 = data.ConnectionHolderDetails) === null || _data$ConnectionHolde44 === void 0 ? void 0 : (_data$ConnectionHolde45 = _data$ConnectionHolde44[0]) === null || _data$ConnectionHolde45 === void 0 ? void 0 : (_data$ConnectionHolde46 = _data$ConnectionHolde45.relationship) === null || _data$ConnectionHolde46 === void 0 ? void 0 : _data$ConnectionHolde46.code) || "",
|
|
1466
|
+
sameAsPropertyAddress: data === null || data === void 0 ? void 0 : (_data$ConnectionHolde47 = data.ConnectionHolderDetails) === null || _data$ConnectionHolde47 === void 0 ? void 0 : (_data$ConnectionHolde48 = _data$ConnectionHolde47[0]) === null || _data$ConnectionHolde48 === void 0 ? void 0 : _data$ConnectionHolde48.sameAsOwnerDetails
|
|
1452
1467
|
}] : null,
|
|
1453
|
-
property: data === null || data === void 0 ? void 0 : (_data$
|
|
1468
|
+
property: data === null || data === void 0 ? void 0 : (_data$cpt18 = data.cpt) === null || _data$cpt18 === void 0 ? void 0 : _data$cpt18.details,
|
|
1454
1469
|
processInstance: {
|
|
1455
1470
|
action: actionData ? actionData : "RESUBMIT_APPLICATION"
|
|
1456
1471
|
},
|
|
@@ -1571,14 +1586,14 @@ const getConvertedDate = async dateOfTime => {
|
|
|
1571
1586
|
return convertedDate;
|
|
1572
1587
|
};
|
|
1573
1588
|
const convertModifyApplicationDetails = async (data, appData, actionData = "INITIATE") => {
|
|
1574
|
-
var _data$
|
|
1575
|
-
data === null || data === void 0 ? void 0 : (_data$
|
|
1589
|
+
var _data$cpt19, _data$cpt19$details, _data$cpt19$details$o, _data$cpt20, _data$cpt20$details, _data$cpt21, _data$cpt21$details, _data$connectionDetai, _data$connectionDetai2, _data$connectionDetai3, _data$connectionDetai4, _data$connectionDetai5, _data$connectionDetai6, _data$connectionDetai7, _data$connectionDetai8, _data$connectionDetai9, _data$connectionDetai0, _data$connectionDetai1, _data$connectionDetai10, _data$connectionDetai11, _data$connectionDetai12, _data$connectionDetai13, _data$connectionDetai14, _data$connectionDetai15, _data$connectionDetai16, _data$connectionDetai17, _data$connectionDetai18, _data$connectionDetai19, _data$connectionDetai20, _data$connectionDetai21, _data$connectionDetai22, _data$connectionDetai23, _data$connectionDetai24, _data$connectionDetai25, _data$connectionDetai26, _data$connectionDetai27, _data$connectionDetai28, _data$activationDetai, _data$activationDetai2, _data$activationDetai3, _data$activationDetai4, _data$activationDetai5, _data$activationDetai6, _data$activationDetai7, _data$activationDetai8, _data$activationDetai9, _data$activationDetai0, _data$activationDetai1, _data$activationDetai10, _data$activationDetai11, _data$activationDetai12, _data$activationDetai13, _data$activationDetai14, _data$activationDetai15, _data$activationDetai16, _data$activationDetai17, _data$activationDetai18, _data$DocumentsRequir3, _data$DocumentsRequir4, _data$DocumentsRequir5, _data$ConnectionHolde49, _data$ConnectionHolde50, _data$DocumentsRequir6, _data$cpt22;
|
|
1590
|
+
data === null || data === void 0 ? void 0 : (_data$cpt19 = data.cpt) === null || _data$cpt19 === void 0 ? void 0 : (_data$cpt19$details = _data$cpt19.details) === null || _data$cpt19$details === void 0 ? void 0 : (_data$cpt19$details$o = _data$cpt19$details.owners) === null || _data$cpt19$details$o === void 0 ? void 0 : _data$cpt19$details$o.forEach(owner => {
|
|
1576
1591
|
if (owner !== null && owner !== void 0 && owner.permanentAddress) owner.correspondenceAddress = owner === null || owner === void 0 ? void 0 : owner.permanentAddress;
|
|
1577
1592
|
});
|
|
1578
1593
|
let formData = {
|
|
1579
1594
|
...appData.applicationData
|
|
1580
1595
|
};
|
|
1581
|
-
if (data !== null && data !== void 0 && (_data$
|
|
1596
|
+
if (data !== null && data !== void 0 && (_data$cpt20 = data.cpt) !== null && _data$cpt20 !== void 0 && (_data$cpt20$details = _data$cpt20.details) !== null && _data$cpt20$details !== void 0 && _data$cpt20$details.propertyId) formData.propertyId = data === null || data === void 0 ? void 0 : (_data$cpt21 = data.cpt) === null || _data$cpt21 === void 0 ? void 0 : (_data$cpt21$details = _data$cpt21.details) === null || _data$cpt21$details === void 0 ? void 0 : _data$cpt21$details.propertyId;
|
|
1582
1597
|
if (data !== null && data !== void 0 && (_data$connectionDetai = data.connectionDetails) !== null && _data$connectionDetai !== void 0 && (_data$connectionDetai2 = _data$connectionDetai[0]) !== null && _data$connectionDetai2 !== void 0 && (_data$connectionDetai3 = _data$connectionDetai2.connectionType) !== null && _data$connectionDetai3 !== void 0 && _data$connectionDetai3.code) formData.connectionType = data === null || data === void 0 ? void 0 : (_data$connectionDetai4 = data.connectionDetails) === null || _data$connectionDetai4 === void 0 ? void 0 : (_data$connectionDetai5 = _data$connectionDetai4[0]) === null || _data$connectionDetai5 === void 0 ? void 0 : (_data$connectionDetai6 = _data$connectionDetai5.connectionType) === null || _data$connectionDetai6 === void 0 ? void 0 : _data$connectionDetai6.code;
|
|
1583
1598
|
if (data !== null && data !== void 0 && (_data$connectionDetai7 = data.connectionDetails) !== null && _data$connectionDetai7 !== void 0 && (_data$connectionDetai8 = _data$connectionDetai7[0]) !== null && _data$connectionDetai8 !== void 0 && (_data$connectionDetai9 = _data$connectionDetai8.waterSource) !== null && _data$connectionDetai9 !== void 0 && _data$connectionDetai9.code) formData.waterSource = data === null || data === void 0 ? void 0 : (_data$connectionDetai0 = data.connectionDetails) === null || _data$connectionDetai0 === void 0 ? void 0 : (_data$connectionDetai1 = _data$connectionDetai0[0]) === null || _data$connectionDetai1 === void 0 ? void 0 : (_data$connectionDetai10 = _data$connectionDetai1.waterSource) === null || _data$connectionDetai10 === void 0 ? void 0 : _data$connectionDetai10.code;
|
|
1584
1599
|
if (data !== null && data !== void 0 && (_data$connectionDetai11 = data.connectionDetails) !== null && _data$connectionDetai11 !== void 0 && (_data$connectionDetai12 = _data$connectionDetai11[0]) !== null && _data$connectionDetai12 !== void 0 && (_data$connectionDetai13 = _data$connectionDetai12.pipeSize) !== null && _data$connectionDetai13 !== void 0 && _data$connectionDetai13.size) formData.pipeSize = data === null || data === void 0 ? void 0 : (_data$connectionDetai14 = data.connectionDetails) === null || _data$connectionDetai14 === void 0 ? void 0 : (_data$connectionDetai15 = _data$connectionDetai14[0]) === null || _data$connectionDetai15 === void 0 ? void 0 : (_data$connectionDetai16 = _data$connectionDetai15.pipeSize) === null || _data$connectionDetai16 === void 0 ? void 0 : _data$connectionDetai16.size;
|
|
@@ -1591,19 +1606,19 @@ const convertModifyApplicationDetails = async (data, appData, actionData = "INIT
|
|
|
1591
1606
|
if (data !== null && data !== void 0 && (_data$activationDetai11 = data.activationDetails) !== null && _data$activationDetai11 !== void 0 && (_data$activationDetai12 = _data$activationDetai11[0]) !== null && _data$activationDetai12 !== void 0 && _data$activationDetai12.connectionExecutionDate) formData.connectionExecutionDate = await getConvertedDate(data === null || data === void 0 ? void 0 : (_data$activationDetai13 = data.activationDetails) === null || _data$activationDetai13 === void 0 ? void 0 : (_data$activationDetai14 = _data$activationDetai13[0]) === null || _data$activationDetai14 === void 0 ? void 0 : _data$activationDetai14.connectionExecutionDate);
|
|
1592
1607
|
if (data !== null && data !== void 0 && (_data$activationDetai15 = data.activationDetails) !== null && _data$activationDetai15 !== void 0 && (_data$activationDetai16 = _data$activationDetai15[0]) !== null && _data$activationDetai16 !== void 0 && _data$activationDetai16.dateEffectiveFrom) formData.dateEffectiveFrom = await getConvertedDate(data === null || data === void 0 ? void 0 : (_data$activationDetai17 = data.activationDetails) === null || _data$activationDetai17 === void 0 ? void 0 : (_data$activationDetai18 = _data$activationDetai17[0]) === null || _data$activationDetai18 === void 0 ? void 0 : _data$activationDetai18.dateEffectiveFrom);
|
|
1593
1608
|
if (data !== null && data !== void 0 && (_data$DocumentsRequir3 = data.DocumentsRequired) !== null && _data$DocumentsRequir3 !== void 0 && (_data$DocumentsRequir4 = _data$DocumentsRequir3.documents) !== null && _data$DocumentsRequir4 !== void 0 && _data$DocumentsRequir4.length) formData.documents = data === null || data === void 0 ? void 0 : (_data$DocumentsRequir5 = data.DocumentsRequired) === null || _data$DocumentsRequir5 === void 0 ? void 0 : _data$DocumentsRequir5.documents;else formData.documents = null;
|
|
1594
|
-
if (!(data !== null && data !== void 0 && (_data$
|
|
1595
|
-
var _appData$applicationD8, _appData$applicationD9, _data$
|
|
1609
|
+
if (!(data !== null && data !== void 0 && (_data$ConnectionHolde49 = data.ConnectionHolderDetails) !== null && _data$ConnectionHolde49 !== void 0 && (_data$ConnectionHolde50 = _data$ConnectionHolde49[0]) !== null && _data$ConnectionHolde50 !== void 0 && _data$ConnectionHolde50.sameAsOwnerDetails)) {
|
|
1610
|
+
var _appData$applicationD8, _appData$applicationD9, _data$ConnectionHolde51, _data$ConnectionHolde52, _data$ConnectionHolde53, _data$ConnectionHolde54, _data$ConnectionHolde55, _data$ConnectionHolde56, _data$ConnectionHolde57, _data$ConnectionHolde58, _data$ConnectionHolde59, _data$ConnectionHolde60, _data$ConnectionHolde61, _data$ConnectionHolde62, _data$ConnectionHolde63, _data$ConnectionHolde64, _data$ConnectionHolde65, _data$ConnectionHolde66, _data$ConnectionHolde67, _data$ConnectionHolde68, _data$ConnectionHolde69, _data$ConnectionHolde70, _data$ConnectionHolde71;
|
|
1596
1611
|
formData.connectionHolders = [{
|
|
1597
1612
|
...(appData === null || appData === void 0 ? void 0 : (_appData$applicationD8 = appData.applicationData) === null || _appData$applicationD8 === void 0 ? void 0 : (_appData$applicationD9 = _appData$applicationD8.connectionHolders) === null || _appData$applicationD9 === void 0 ? void 0 : _appData$applicationD9[0]),
|
|
1598
|
-
correspondenceAddress: (data === null || data === void 0 ? void 0 : (_data$
|
|
1599
|
-
fatherOrHusbandName: (data === null || data === void 0 ? void 0 : (_data$
|
|
1600
|
-
gender: (data === null || data === void 0 ? void 0 : (_data$
|
|
1601
|
-
mobileNumber: (data === null || data === void 0 ? void 0 : (_data$
|
|
1602
|
-
name: (data === null || data === void 0 ? void 0 : (_data$
|
|
1603
|
-
emailId: (data === null || data === void 0 ? void 0 : (_data$
|
|
1604
|
-
ownerType: (data === null || data === void 0 ? void 0 : (_data$
|
|
1605
|
-
relationship: (data === null || data === void 0 ? void 0 : (_data$
|
|
1606
|
-
sameAsPropertyAddress: data === null || data === void 0 ? void 0 : (_data$
|
|
1613
|
+
correspondenceAddress: (data === null || data === void 0 ? void 0 : (_data$ConnectionHolde51 = data.ConnectionHolderDetails) === null || _data$ConnectionHolde51 === void 0 ? void 0 : (_data$ConnectionHolde52 = _data$ConnectionHolde51[0]) === null || _data$ConnectionHolde52 === void 0 ? void 0 : _data$ConnectionHolde52.address) || "",
|
|
1614
|
+
fatherOrHusbandName: (data === null || data === void 0 ? void 0 : (_data$ConnectionHolde53 = data.ConnectionHolderDetails) === null || _data$ConnectionHolde53 === void 0 ? void 0 : (_data$ConnectionHolde54 = _data$ConnectionHolde53[0]) === null || _data$ConnectionHolde54 === void 0 ? void 0 : _data$ConnectionHolde54.guardian) || "",
|
|
1615
|
+
gender: (data === null || data === void 0 ? void 0 : (_data$ConnectionHolde55 = data.ConnectionHolderDetails) === null || _data$ConnectionHolde55 === void 0 ? void 0 : (_data$ConnectionHolde56 = _data$ConnectionHolde55[0]) === null || _data$ConnectionHolde56 === void 0 ? void 0 : (_data$ConnectionHolde57 = _data$ConnectionHolde56.gender) === null || _data$ConnectionHolde57 === void 0 ? void 0 : _data$ConnectionHolde57.code) || "",
|
|
1616
|
+
mobileNumber: (data === null || data === void 0 ? void 0 : (_data$ConnectionHolde58 = data.ConnectionHolderDetails) === null || _data$ConnectionHolde58 === void 0 ? void 0 : (_data$ConnectionHolde59 = _data$ConnectionHolde58[0]) === null || _data$ConnectionHolde59 === void 0 ? void 0 : _data$ConnectionHolde59.mobileNumber) || "",
|
|
1617
|
+
name: (data === null || data === void 0 ? void 0 : (_data$ConnectionHolde60 = data.ConnectionHolderDetails) === null || _data$ConnectionHolde60 === void 0 ? void 0 : (_data$ConnectionHolde61 = _data$ConnectionHolde60[0]) === null || _data$ConnectionHolde61 === void 0 ? void 0 : _data$ConnectionHolde61.name) || "",
|
|
1618
|
+
emailId: (data === null || data === void 0 ? void 0 : (_data$ConnectionHolde62 = data.ConnectionHolderDetails) === null || _data$ConnectionHolde62 === void 0 ? void 0 : (_data$ConnectionHolde63 = _data$ConnectionHolde62[0]) === null || _data$ConnectionHolde63 === void 0 ? void 0 : _data$ConnectionHolde63.emailId) || "",
|
|
1619
|
+
ownerType: (data === null || data === void 0 ? void 0 : (_data$ConnectionHolde64 = data.ConnectionHolderDetails) === null || _data$ConnectionHolde64 === void 0 ? void 0 : (_data$ConnectionHolde65 = _data$ConnectionHolde64[0]) === null || _data$ConnectionHolde65 === void 0 ? void 0 : (_data$ConnectionHolde66 = _data$ConnectionHolde65.ownerType) === null || _data$ConnectionHolde66 === void 0 ? void 0 : _data$ConnectionHolde66.code) || "",
|
|
1620
|
+
relationship: (data === null || data === void 0 ? void 0 : (_data$ConnectionHolde67 = data.ConnectionHolderDetails) === null || _data$ConnectionHolde67 === void 0 ? void 0 : (_data$ConnectionHolde68 = _data$ConnectionHolde67[0]) === null || _data$ConnectionHolde68 === void 0 ? void 0 : (_data$ConnectionHolde69 = _data$ConnectionHolde68.relationship) === null || _data$ConnectionHolde69 === void 0 ? void 0 : _data$ConnectionHolde69.code) || "",
|
|
1621
|
+
sameAsPropertyAddress: data === null || data === void 0 ? void 0 : (_data$ConnectionHolde70 = data.ConnectionHolderDetails) === null || _data$ConnectionHolde70 === void 0 ? void 0 : (_data$ConnectionHolde71 = _data$ConnectionHolde70[0]) === null || _data$ConnectionHolde71 === void 0 ? void 0 : _data$ConnectionHolde71.sameAsOwnerDetails
|
|
1607
1622
|
}];
|
|
1608
1623
|
}
|
|
1609
1624
|
formData.processInstance = {
|
|
@@ -1612,7 +1627,7 @@ const convertModifyApplicationDetails = async (data, appData, actionData = "INIT
|
|
|
1612
1627
|
formData.action = actionData;
|
|
1613
1628
|
formData.channel = "CFC_COUNTER";
|
|
1614
1629
|
sessionStorage.setItem("WS_DOCUMENTS_INOF", JSON.stringify((data === null || data === void 0 ? void 0 : (_data$DocumentsRequir6 = data.DocumentsRequired) === null || _data$DocumentsRequir6 === void 0 ? void 0 : _data$DocumentsRequir6.documents) || []));
|
|
1615
|
-
sessionStorage.setItem("WS_PROPERTY_INOF", JSON.stringify(data === null || data === void 0 ? void 0 : (_data$
|
|
1630
|
+
sessionStorage.setItem("WS_PROPERTY_INOF", JSON.stringify(data === null || data === void 0 ? void 0 : (_data$cpt22 = data.cpt) === null || _data$cpt22 === void 0 ? void 0 : _data$cpt22.details));
|
|
1616
1631
|
return formData;
|
|
1617
1632
|
};
|
|
1618
1633
|
const downloadPdf = (blob, fileName) => {
|
|
@@ -8972,9 +8987,10 @@ const WSDisconnectionResponse$1 = props => {
|
|
|
8972
8987
|
};
|
|
8973
8988
|
|
|
8974
8989
|
const BILLSBreadCrumbs = ({
|
|
8975
|
-
location
|
|
8990
|
+
location,
|
|
8991
|
+
showPrint
|
|
8976
8992
|
}) => {
|
|
8977
|
-
var _applicationDetails$a, _applicationDetails$a9, _applicationDetails$a0, _applicationDetails$a1, _applicationDetails$a13, _applicationDetails$a14, _reciept_data$Payment2
|
|
8993
|
+
var _applicationDetails$a, _applicationDetails$a9, _applicationDetails$a0, _applicationDetails$a1, _applicationDetails$a13, _applicationDetails$a14, _reciept_data$Payment2;
|
|
8978
8994
|
const {
|
|
8979
8995
|
t
|
|
8980
8996
|
} = useTranslation();
|
|
@@ -8987,6 +9003,8 @@ const BILLSBreadCrumbs = ({
|
|
|
8987
9003
|
const applicationNumbercheck = new URLSearchParams(search).get("applicationNumber") || null;
|
|
8988
9004
|
let isMobile = window.Digit.Utils.browser.isMobile();
|
|
8989
9005
|
let requestParam = window.location.href.split("?")[1];
|
|
9006
|
+
const receiptKey = "consolidatedreceipt";
|
|
9007
|
+
const oldApplication = {};
|
|
8990
9008
|
function findLastIndex(array, searchKey, searchValue) {
|
|
8991
9009
|
var index = array.slice().reverse().findIndex(x => x[searchKey] === searchValue);
|
|
8992
9010
|
var count = array.length - 1;
|
|
@@ -9181,11 +9199,11 @@ const BILLSBreadCrumbs = ({
|
|
|
9181
9199
|
icon: HomeIcon
|
|
9182
9200
|
}, {
|
|
9183
9201
|
path: "/digit-ui/employee/module/details",
|
|
9184
|
-
|
|
9202
|
+
label: t("ES_TITLE_WATER_AND_SEWERAGE"),
|
|
9185
9203
|
show: location.pathname.includes("/create-application") || location.pathname.includes("/new-application")
|
|
9186
9204
|
}, {
|
|
9187
9205
|
path: "/digit-ui/employee/ws/create-application",
|
|
9188
|
-
|
|
9206
|
+
label: t("ES_COMMON_WS_DOCUMENTS_REQUIRED"),
|
|
9189
9207
|
show: location.pathname.includes("/create-application") || location.pathname.includes("/new-application"),
|
|
9190
9208
|
rightContent: location.pathname.includes("/create-application") && /*#__PURE__*/React.createElement("div", {
|
|
9191
9209
|
className: "flex-center flex-gap-1 .cursorPointer",
|
|
@@ -9199,61 +9217,61 @@ const BILLSBreadCrumbs = ({
|
|
|
9199
9217
|
}, "Print"))
|
|
9200
9218
|
}, {
|
|
9201
9219
|
path: "/digit-ui/employee/water/inbox",
|
|
9202
|
-
|
|
9220
|
+
label: t("ES_COMMON_BILLS_WATER_INBOX_LABEL"),
|
|
9203
9221
|
show: location.pathname.includes("/water/inbox") ? true : false
|
|
9204
9222
|
}, {
|
|
9205
9223
|
path: "/digit-ui/employee/ws/water/bill-amendment/inbox",
|
|
9206
|
-
|
|
9224
|
+
label: t("ES_COMMON_BILL_AMEND_WATER_INBOX_LABEL"),
|
|
9207
9225
|
show: location.pathname.includes("/water/bill-amendment/inbox") ? true : false
|
|
9208
9226
|
}, {
|
|
9209
9227
|
path: "/digit-ui/employee/ws/sewerage/bill-amendment/inbox",
|
|
9210
|
-
|
|
9228
|
+
label: t("ES_COMMON_BILL_AMEND_SEWERAGE_INBOX_LABEL"),
|
|
9211
9229
|
show: location.pathname.includes("/sewerage/bill-amendment/inbox") ? true : false
|
|
9212
9230
|
}, {
|
|
9213
9231
|
path: "/digit-ui/employee/ws/water/search-application",
|
|
9214
|
-
|
|
9232
|
+
label: fromScreen ? `${t(fromScreen)} / ${t("WS_SEARCH_APPLICATIONS")}` : t("WS_SEARCH_APPLICATIONS"),
|
|
9215
9233
|
show: location.pathname.includes("/water/search-application") ? true : false,
|
|
9216
9234
|
isBack: fromScreen && true
|
|
9217
9235
|
}, {
|
|
9218
9236
|
path: "/digit-ui/employee/ws/water/search-connection",
|
|
9219
|
-
|
|
9237
|
+
label: fromScreen ? `${t(fromScreen)} / ${t("WS_SEARCH_CONNECTION")}` : t("WS_SEARCH_CONNECTION"),
|
|
9220
9238
|
show: location.pathname.includes("/water/search-connection") ? true : false,
|
|
9221
9239
|
isBack: fromScreen && true
|
|
9222
9240
|
}, {
|
|
9223
9241
|
path: "/digit-ui/employee/ws/water/wns-search",
|
|
9224
|
-
|
|
9242
|
+
label: fromScreen ? `${t(fromScreen)} / ${t("WS_SEARCH_INTEGRATED_BILL")}` : t("WS_SEARCH_INTEGRATED_BILL"),
|
|
9225
9243
|
show: location.pathname.includes("/water/wns-search") ? true : false,
|
|
9226
9244
|
isBack: fromScreen && true
|
|
9227
9245
|
}, {
|
|
9228
9246
|
path: "/digit-ui/employee/ws/sewerage/search-application",
|
|
9229
|
-
|
|
9247
|
+
label: fromScreen ? `${t(fromScreen)} / ${t("WS_SEARCH_APPLICATIONS")}` : t("WS_SEARCH_APPLICATIONS"),
|
|
9230
9248
|
show: location.pathname.includes("/sewerage/search-application") ? true : false,
|
|
9231
9249
|
isBack: fromScreen && true
|
|
9232
9250
|
}, {
|
|
9233
9251
|
path: "/digit-ui/employee/ws/sewerage/search-connection",
|
|
9234
|
-
|
|
9252
|
+
label: fromScreen ? `${t(fromScreen)} / ${t("WS_SEARCH_CONNECTION")}` : t("WS_SEARCH_CONNECTION"),
|
|
9235
9253
|
show: location.pathname.includes("/sewerage/search-connection") ? true : false,
|
|
9236
9254
|
isBack: fromScreen && true
|
|
9237
9255
|
}, {
|
|
9238
9256
|
path: "/digit-ui/employee/sewerage/inbox",
|
|
9239
|
-
|
|
9257
|
+
label: t("ES_COMMON_BILLS_SEWERAGE_INBOX_LABEL"),
|
|
9240
9258
|
show: location.pathname.includes("/sewerage/inbox") ? true : false
|
|
9241
9259
|
}, {
|
|
9242
9260
|
path: "/digit-ui/employee/ws/new-application",
|
|
9243
|
-
|
|
9261
|
+
label: fromScreen ? `${t(fromScreen)} / ${t("ES_COMMON_WS_NEW_CONNECTION")}` : t("ES_COMMON_WS_NEW_CONNECTION"),
|
|
9244
9262
|
show: location.pathname.includes("/new-application") ? true : false
|
|
9245
9263
|
}, {
|
|
9246
9264
|
path: `${location === null || location === void 0 ? void 0 : location.pathname}${location.search}`,
|
|
9247
|
-
|
|
9265
|
+
label: t("ACTION_TEST_RESPONSE"),
|
|
9248
9266
|
show: location.pathname.includes("/ws-response") ? true : false
|
|
9249
9267
|
}, {
|
|
9250
9268
|
path: "/digit-ui/employee/ws/consumption-details",
|
|
9251
|
-
|
|
9269
|
+
label: fromScreen ? `${t(fromScreen)} / ${t("WS_VIEW_CONSUMPTION_DETAIL")}` : t("WS_VIEW_CONSUMPTION_DETAIL"),
|
|
9252
9270
|
show: location.pathname.includes("/consumption-details") ? true : false,
|
|
9253
9271
|
isBack: fromScreen && true
|
|
9254
9272
|
}, {
|
|
9255
9273
|
path: sessionStorage.getItem("redirectedfromEDIT") === "true" ? applicationNumbercheck !== null && applicationNumbercheck !== void 0 && applicationNumbercheck.includes("SW_AP") ? "/digit-ui/employee/ws/sewerage/search-application" : "/digit-ui/employee/ws/water/search-application" : "/digit-ui/employee/ws/application-details",
|
|
9256
|
-
|
|
9274
|
+
label: fromScreen ? `${t(fromScreen)} / ${t("WS_APPLICATION_DETAILS_HEADER")}` : t("WS_APPLICATION_DETAILS_HEADER"),
|
|
9257
9275
|
show: location.pathname.includes("/application-details") ? true : false,
|
|
9258
9276
|
isBack: sessionStorage.getItem("redirectedfromEDIT") !== "true" && fromScreen && true,
|
|
9259
9277
|
rightContent: /*#__PURE__*/React.createElement("div", {
|
|
@@ -9291,87 +9309,87 @@ const BILLSBreadCrumbs = ({
|
|
|
9291
9309
|
}))
|
|
9292
9310
|
}, {
|
|
9293
9311
|
path: sessionStorage.getItem("redirectedfromEDIT") === "true" ? applicationNumbercheck !== null && applicationNumbercheck !== void 0 && applicationNumbercheck.includes("SW_AP") ? "/digit-ui/employee/ws/sewerage/search-application" : "/digit-ui/employee/ws/water/search-application" : "/digit-ui/employee/ws/modify-details",
|
|
9294
|
-
|
|
9312
|
+
label: fromScreen ? `${t(fromScreen)} / ${t("WS_APPLICATION_DETAILS_HEADER")}` : t("WS_APPLICATION_DETAILS_HEADER"),
|
|
9295
9313
|
show: location.pathname.includes("/modify-details") ? true : false,
|
|
9296
9314
|
isBack: sessionStorage.getItem("redirectedfromEDIT") !== "true" && fromScreen && true
|
|
9297
9315
|
}, {
|
|
9298
9316
|
path: "/digit-ui/employee/ws/disconnection-details",
|
|
9299
|
-
|
|
9317
|
+
label: fromScreen ? `${t(fromScreen)} / ${t("WS_APPLICATION_DETAILS_HEADER")}` : t("WS_APPLICATION_DETAILS_HEADER"),
|
|
9300
9318
|
show: location.pathname.includes("/disconnection-details") ? true : false,
|
|
9301
9319
|
isBack: fromScreen && true
|
|
9302
9320
|
}, {
|
|
9303
9321
|
path: "/digit-ui/employee/ws/connection-details",
|
|
9304
|
-
|
|
9322
|
+
label: fromScreen ? `${t(fromScreen)} / ${t("WS_COMMON_CONNECTION_DETAIL")}` : t("WS_COMMON_CONNECTION_DETAIL"),
|
|
9305
9323
|
show: location.pathname.includes("/connection-details") ? true : false,
|
|
9306
9324
|
isBack: fromScreen && true
|
|
9307
9325
|
}, {
|
|
9308
9326
|
path: "/digit-ui/employee/ws/edit-application",
|
|
9309
|
-
|
|
9327
|
+
label: `${t("WS_APPLICATION_DETAILS_HEADER")} / ${t("WS_APP_FOR_WATER_AND_SEWERAGE_EDIT_LABEL")}`,
|
|
9310
9328
|
show: location.pathname.includes("/edit-application") ? true : false,
|
|
9311
9329
|
isBack: true
|
|
9312
9330
|
}, {
|
|
9313
9331
|
path: `${location === null || location === void 0 ? void 0 : location.pathname}${location.search}`,
|
|
9314
|
-
|
|
9332
|
+
label: `${t("WS_APPLICATION_DETAILS_HEADER")} / ${t("WF_EMPLOYEE_NEWSW1_ACTIVATE_CONNECTION")}`,
|
|
9315
9333
|
show: location.pathname.includes("/activate-connection") ? true : false,
|
|
9316
9334
|
isBack: true
|
|
9317
9335
|
}, {
|
|
9318
9336
|
path: `${location === null || location === void 0 ? void 0 : location.pathname}${location.search}`,
|
|
9319
|
-
|
|
9337
|
+
label: `${t("WS_APPLICATION_DETAILS_HEADER")} / ${t("WS_WATER_SEWERAGE_DISCONNECTION_EDIT_LABEL")}`,
|
|
9320
9338
|
show: location.pathname.includes("edit-disconnection-application") ? true : false,
|
|
9321
9339
|
isBack: true
|
|
9322
9340
|
}, {
|
|
9323
9341
|
path: `${location === null || location === void 0 ? void 0 : location.pathname}${location.search}`,
|
|
9324
|
-
|
|
9342
|
+
label: `${t("WS_APPLICATION_DETAILS_HEADER")} / ${t("WS_WATER_SEWERAGE_DISCONNECTION_EDIT_LABEL")}`,
|
|
9325
9343
|
show: location.pathname.includes("config-by-disconnection-application") ? true : false,
|
|
9326
9344
|
isBack: true
|
|
9327
9345
|
}, {
|
|
9328
9346
|
path: `${location === null || location === void 0 ? void 0 : location.pathname}${location.search}`,
|
|
9329
|
-
|
|
9347
|
+
label: `${t("WS_APPLICATION_DETAILS_HEADER")} / ${t("WS_WATER_SEWERAGE_DISCONNECTION_EDIT_LABEL")}`,
|
|
9330
9348
|
show: location.pathname.includes("resubmit-disconnection-application") ? true : false,
|
|
9331
9349
|
isBack: true
|
|
9332
9350
|
}, {
|
|
9333
9351
|
path: `/digit-ui/employee/ws/new-disconnection/docsrequired`,
|
|
9334
|
-
|
|
9352
|
+
label: t("WS_NEW_DISCONNECTION_DOCS_REQUIRED"),
|
|
9335
9353
|
show: location.pathname.includes("/new-disconnection/docsrequired") ? true : false
|
|
9336
9354
|
}, {
|
|
9337
9355
|
path: `/digit-ui/employee/ws/new-disconnection/application-form`,
|
|
9338
|
-
|
|
9356
|
+
label: isMobile ? `${t("WS_NEW_DISCONNECTION_DOCS_REQUIRED")} / ${t("WS_NEW_DISCONNECTION_APPLICATION")}` : `${t("WS_NEW_DISCONNECTION_DOCS_REQUIRED")} / ${t("WS_NEW_DISCONNECTION_APPLICATION")}`,
|
|
9339
9357
|
show: location.pathname.includes("/new-disconnection/application-form") ? true : false,
|
|
9340
9358
|
isBack: true
|
|
9341
9359
|
}, {
|
|
9342
9360
|
path: `${location === null || location === void 0 ? void 0 : location.pathname}${location.search}`,
|
|
9343
|
-
|
|
9361
|
+
label: `${t("WS_NEW_DISCONNECTION_RESPONSE")}`,
|
|
9344
9362
|
show: location.pathname.includes("/ws-disconnection-response") ? true : false,
|
|
9345
9363
|
isBack: true
|
|
9346
9364
|
}, {
|
|
9347
9365
|
path: `${location === null || location === void 0 ? void 0 : location.pathname}${location.search}`,
|
|
9348
|
-
|
|
9366
|
+
label: fromScreen ? `${t(fromScreen)} / ${t("WS_MODIFY_CONNECTION_BUTTON")}` : t("WS_MODIFY_CONNECTION_BUTTON"),
|
|
9349
9367
|
show: location.pathname.includes("ws/modify-application") ? true : false,
|
|
9350
9368
|
isBack: true
|
|
9351
9369
|
}, {
|
|
9352
9370
|
path: "/digit-ui/employee/ws/required-documents",
|
|
9353
|
-
|
|
9371
|
+
label: t("ES_COMMON_WS_DOCUMENTS_REQUIRED"),
|
|
9354
9372
|
show: location.pathname.includes("/required-documents") ? true : false
|
|
9355
9373
|
}, {
|
|
9356
9374
|
path: requestParam ? `/digit-ui/employee/ws/bill-amendment?${requestParam}` : "/digit-ui/employee/ws/bill-amendment",
|
|
9357
|
-
|
|
9375
|
+
label: t("WS_BILL_AMEND_APP"),
|
|
9358
9376
|
show: location.pathname.includes("ws/bill-amendment") && !IsEdit ? true : false
|
|
9359
9377
|
}, {
|
|
9360
9378
|
path: "/digit-ui/employee/ws/bill-amendment",
|
|
9361
|
-
|
|
9379
|
+
label: t("WS_BILL_AMEND_EDIT_APP"),
|
|
9362
9380
|
show: location.pathname.includes("ws/bill-amendment") && IsEdit ? true : false
|
|
9363
9381
|
}, {
|
|
9364
9382
|
path: "/digit-ui/employee/ws/response",
|
|
9365
|
-
|
|
9383
|
+
label: t("WS_ACK_SCREEN"),
|
|
9366
9384
|
show: location.pathname.includes("/employee/ws/response") ? true : false,
|
|
9367
9385
|
isclickable: false
|
|
9368
9386
|
}, {
|
|
9369
9387
|
path: "/digit-ui/employee/ws/generate-note-bill-amendment",
|
|
9370
|
-
|
|
9388
|
+
label: t("CS_TITLE_GENERATE_NOTE"),
|
|
9371
9389
|
show: location.pathname.includes("/generate-note-bill-amendment") ? true : false
|
|
9372
9390
|
}, {
|
|
9373
9391
|
path: "/digit-ui/employee/ws/water/bulk-bil",
|
|
9374
|
-
|
|
9392
|
+
label: t("CS_TITLE_BULK_BILL"),
|
|
9375
9393
|
show: location.pathname.includes("/ws/water/bulk-bill") ? true : false
|
|
9376
9394
|
}];
|
|
9377
9395
|
let lastCrumbIndex = findLastIndex(crumbs, "show", true);
|
|
@@ -9379,6 +9397,9 @@ const BILLSBreadCrumbs = ({
|
|
|
9379
9397
|
...crumbs[lastCrumbIndex],
|
|
9380
9398
|
isclickable: false
|
|
9381
9399
|
};
|
|
9400
|
+
const getDynamicBreadcrumbs = () => {
|
|
9401
|
+
return crumbs.filter(crumb => crumb.show);
|
|
9402
|
+
};
|
|
9382
9403
|
return /*#__PURE__*/React.createElement(React.Fragment, null, showWaringToast && /*#__PURE__*/React.createElement(Toast, {
|
|
9383
9404
|
style: {
|
|
9384
9405
|
zIndex: "10000"
|
|
@@ -9388,21 +9409,18 @@ const BILLSBreadCrumbs = ({
|
|
|
9388
9409
|
label: t(showWaringToast === null || showWaringToast === void 0 ? void 0 : showWaringToast.message),
|
|
9389
9410
|
onClose: () => setShowWaringToast(null),
|
|
9390
9411
|
isDleteBtn: true
|
|
9391
|
-
}), /*#__PURE__*/React.createElement(
|
|
9392
|
-
style: (_window = window) !== null && _window !== void 0 && _window.location.href.includes("/employee/ws/bill-amendment") || (_window2 = window) !== null && _window2 !== void 0 && _window2.location.href.includes("/employee/ws/response") ? {
|
|
9393
|
-
marginLeft: "20px"
|
|
9394
|
-
} : {},
|
|
9412
|
+
}), /*#__PURE__*/React.createElement(ModuleHeader, {
|
|
9395
9413
|
leftContent: /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(ArrowLeft, {
|
|
9396
9414
|
className: "icon"
|
|
9397
9415
|
}), "Back"),
|
|
9398
9416
|
onLeftClick: () => window.history.back(),
|
|
9399
|
-
breadcrumbs:
|
|
9417
|
+
breadcrumbs: getDynamicBreadcrumbs()
|
|
9400
9418
|
}));
|
|
9401
9419
|
};
|
|
9402
9420
|
const App$1 = ({
|
|
9403
9421
|
path
|
|
9404
9422
|
}) => {
|
|
9405
|
-
var _Digit, _Digit$ComponentRegis, _Digit2, _Digit2$ComponentRegi, _Digit3, _Digit3$ComponentRegi, _Digit4, _Digit4$ComponentRegi, _Digit5, _Digit5$ComponentRegi, _Digit6, _Digit6$ComponentRegi, _Digit7, _Digit7$ComponentRegi, _Digit8, _Digit8$ComponentRegi, _Digit9, _Digit9$ComponentRegi, _Digit0, _Digit0$ComponentRegi, _Digit1, _Digit1$ComponentRegi, _Digit10, _Digit10$ComponentReg, _Digit11, _Digit11$ComponentReg, _Digit12, _Digit12$ComponentReg, _Digit13, _Digit13$ComponentReg, _Digit14, _Digit14$ComponentReg, _Digit15, _Digit15$ComponentReg, _Digit16, _Digit16$ComponentReg, _Digit17, _Digit17$ComponentReg, _Digit18, _Digit18$ComponentReg, _Digit19, _Digit19$ComponentReg, _Digit20, _Digit20$ComponentReg, _Digit21, _Digit21$ComponentReg, _Digit22, _Digit22$ComponentReg, _Digit23, _Digit23$ComponentReg, _Digit24, _Digit24$ComponentReg, _Digit25, _Digit25$ComponentReg;
|
|
9423
|
+
var _Digit, _Digit$ComponentRegis, _Digit2, _Digit2$ComponentRegi, _Digit3, _Digit3$ComponentRegi, _Digit4, _Digit4$ComponentRegi, _Digit5, _Digit5$ComponentRegi, _Digit6, _Digit6$ComponentRegi, _Digit7, _Digit7$ComponentRegi, _Digit8, _Digit8$ComponentRegi, _Digit9, _Digit9$ComponentRegi, _Digit0, _Digit0$ComponentRegi, _Digit1, _Digit1$ComponentRegi, _Digit10, _Digit10$ComponentReg, _Digit11, _Digit11$ComponentReg, _Digit12, _Digit12$ComponentReg, _Digit13, _Digit13$ComponentReg, _Digit14, _Digit14$ComponentReg, _Digit15, _Digit15$ComponentReg, _Digit16, _Digit16$ComponentReg, _Digit17, _Digit17$ComponentReg, _Digit18, _Digit18$ComponentReg, _Digit19, _Digit19$ComponentReg, _Digit20, _Digit20$ComponentReg, _Digit21, _Digit21$ComponentReg, _Digit22, _Digit22$ComponentReg, _Digit23, _Digit23$ComponentReg, _Digit24, _Digit24$ComponentReg, _Digit25, _Digit25$ComponentReg, _Digit26, _Digit26$ComponentReg;
|
|
9406
9424
|
const location = useLocation();
|
|
9407
9425
|
const WSDocsRequired = (_Digit = Digit) === null || _Digit === void 0 ? void 0 : (_Digit$ComponentRegis = _Digit.ComponentRegistryService) === null || _Digit$ComponentRegis === void 0 ? void 0 : _Digit$ComponentRegis.getComponent("WSDocsRequired");
|
|
9408
9426
|
const WSInbox = (_Digit2 = Digit) === null || _Digit2 === void 0 ? void 0 : (_Digit2$ComponentRegi = _Digit2.ComponentRegistryService) === null || _Digit2$ComponentRegi === void 0 ? void 0 : _Digit2$ComponentRegi.getComponent("WSInbox");
|
|
@@ -9410,27 +9428,28 @@ const App$1 = ({
|
|
|
9410
9428
|
const WSApplicationBillAmendment = (_Digit4 = Digit) === null || _Digit4 === void 0 ? void 0 : (_Digit4$ComponentRegi = _Digit4.ComponentRegistryService) === null || _Digit4$ComponentRegi === void 0 ? void 0 : _Digit4$ComponentRegi.getComponent("WSApplicationBillAmendment");
|
|
9411
9429
|
const WSRequiredDocuments = (_Digit5 = Digit) === null || _Digit5 === void 0 ? void 0 : (_Digit5$ComponentRegi = _Digit5.ComponentRegistryService) === null || _Digit5$ComponentRegi === void 0 ? void 0 : _Digit5$ComponentRegi.getComponent("WSRequiredDocuments");
|
|
9412
9430
|
const WSNewApplication = (_Digit6 = Digit) === null || _Digit6 === void 0 ? void 0 : (_Digit6$ComponentRegi = _Digit6.ComponentRegistryService) === null || _Digit6$ComponentRegi === void 0 ? void 0 : _Digit6$ComponentRegi.getComponent("WSNewApplication");
|
|
9413
|
-
const
|
|
9414
|
-
const
|
|
9415
|
-
const
|
|
9416
|
-
const
|
|
9417
|
-
const
|
|
9418
|
-
const
|
|
9419
|
-
const
|
|
9420
|
-
const
|
|
9421
|
-
const
|
|
9422
|
-
const
|
|
9423
|
-
const
|
|
9424
|
-
const
|
|
9425
|
-
const
|
|
9426
|
-
const
|
|
9427
|
-
const
|
|
9428
|
-
const
|
|
9429
|
-
const
|
|
9430
|
-
const
|
|
9431
|
-
const
|
|
9432
|
-
const
|
|
9433
|
-
const
|
|
9431
|
+
const WSOLDApplication = (_Digit7 = Digit) === null || _Digit7 === void 0 ? void 0 : (_Digit7$ComponentRegi = _Digit7.ComponentRegistryService) === null || _Digit7$ComponentRegi === void 0 ? void 0 : _Digit7$ComponentRegi.getComponent("WSOLDApplication");
|
|
9432
|
+
const WSApplicationDetails = (_Digit8 = Digit) === null || _Digit8 === void 0 ? void 0 : (_Digit8$ComponentRegi = _Digit8.ComponentRegistryService) === null || _Digit8$ComponentRegi === void 0 ? void 0 : _Digit8$ComponentRegi.getComponent("WSApplicationDetails");
|
|
9433
|
+
const WSGetConnectionDetails = (_Digit9 = Digit) === null || _Digit9 === void 0 ? void 0 : (_Digit9$ComponentRegi = _Digit9.ComponentRegistryService) === null || _Digit9$ComponentRegi === void 0 ? void 0 : _Digit9$ComponentRegi.getComponent("WSGetConnectionDetails");
|
|
9434
|
+
const WSActivateConnection = (_Digit0 = Digit) === null || _Digit0 === void 0 ? void 0 : (_Digit0$ComponentRegi = _Digit0.ComponentRegistryService) === null || _Digit0$ComponentRegi === void 0 ? void 0 : _Digit0$ComponentRegi.getComponent("WSActivateConnection");
|
|
9435
|
+
const WSApplicationDetailsBillAmendment = (_Digit1 = Digit) === null || _Digit1 === void 0 ? void 0 : (_Digit1$ComponentRegi = _Digit1.ComponentRegistryService) === null || _Digit1$ComponentRegi === void 0 ? void 0 : _Digit1$ComponentRegi.getComponent("WSApplicationDetailsBillAmendment");
|
|
9436
|
+
const WSSearch = (_Digit10 = Digit) === null || _Digit10 === void 0 ? void 0 : (_Digit10$ComponentReg = _Digit10.ComponentRegistryService) === null || _Digit10$ComponentReg === void 0 ? void 0 : _Digit10$ComponentReg.getComponent("WSSearch");
|
|
9437
|
+
const WSSearchWater = (_Digit11 = Digit) === null || _Digit11 === void 0 ? void 0 : (_Digit11$ComponentReg = _Digit11.ComponentRegistryService) === null || _Digit11$ComponentReg === void 0 ? void 0 : _Digit11$ComponentReg.getComponent("WSSearchWater");
|
|
9438
|
+
const WSEditApplication = (_Digit12 = Digit) === null || _Digit12 === void 0 ? void 0 : (_Digit12$ComponentReg = _Digit12.ComponentRegistryService) === null || _Digit12$ComponentReg === void 0 ? void 0 : _Digit12$ComponentReg.getComponent("WSEditApplication");
|
|
9439
|
+
const WSConsumptionDetails = (_Digit13 = Digit) === null || _Digit13 === void 0 ? void 0 : (_Digit13$ComponentReg = _Digit13.ComponentRegistryService) === null || _Digit13$ComponentReg === void 0 ? void 0 : _Digit13$ComponentReg.getComponent("WSConsumptionDetails");
|
|
9440
|
+
const WSModifyApplication = (_Digit14 = Digit) === null || _Digit14 === void 0 ? void 0 : (_Digit14$ComponentReg = _Digit14.ComponentRegistryService) === null || _Digit14$ComponentReg === void 0 ? void 0 : _Digit14$ComponentReg.getComponent("WSModifyApplication");
|
|
9441
|
+
const WSEditModifyApplication = (_Digit15 = Digit) === null || _Digit15 === void 0 ? void 0 : (_Digit15$ComponentReg = _Digit15.ComponentRegistryService) === null || _Digit15$ComponentReg === void 0 ? void 0 : _Digit15$ComponentReg.getComponent("WSEditModifyApplication");
|
|
9442
|
+
const WSDisconnectionApplication = (_Digit16 = Digit) === null || _Digit16 === void 0 ? void 0 : (_Digit16$ComponentReg = _Digit16.ComponentRegistryService) === null || _Digit16$ComponentReg === void 0 ? void 0 : _Digit16$ComponentReg.getComponent("WSDisconnectionApplication");
|
|
9443
|
+
const WSRestorationApplication = (_Digit17 = Digit) === null || _Digit17 === void 0 ? void 0 : (_Digit17$ComponentReg = _Digit17.ComponentRegistryService) === null || _Digit17$ComponentReg === void 0 ? void 0 : _Digit17$ComponentReg.getComponent("WSRestorationApplication");
|
|
9444
|
+
const WSEditApplicationByConfig = (_Digit18 = Digit) === null || _Digit18 === void 0 ? void 0 : (_Digit18$ComponentReg = _Digit18.ComponentRegistryService) === null || _Digit18$ComponentReg === void 0 ? void 0 : _Digit18$ComponentReg.getComponent("WSEditApplicationByConfig");
|
|
9445
|
+
const WSBillIAmendMentInbox = (_Digit19 = Digit) === null || _Digit19 === void 0 ? void 0 : (_Digit19$ComponentReg = _Digit19.ComponentRegistryService) === null || _Digit19$ComponentReg === void 0 ? void 0 : _Digit19$ComponentReg.getComponent("WSBillIAmendMentInbox");
|
|
9446
|
+
const WSGetDisconnectionDetails = (_Digit20 = Digit) === null || _Digit20 === void 0 ? void 0 : (_Digit20$ComponentReg = _Digit20.ComponentRegistryService) === null || _Digit20$ComponentReg === void 0 ? void 0 : _Digit20$ComponentReg.getComponent("WSGetDisconnectionDetails");
|
|
9447
|
+
const WSModifyApplicationDetails = (_Digit21 = Digit) === null || _Digit21 === void 0 ? void 0 : (_Digit21$ComponentReg = _Digit21.ComponentRegistryService) === null || _Digit21$ComponentReg === void 0 ? void 0 : _Digit21$ComponentReg.getComponent("WSModifyApplicationDetails");
|
|
9448
|
+
const WSEditDisconnectionApplication = (_Digit22 = Digit) === null || _Digit22 === void 0 ? void 0 : (_Digit22$ComponentReg = _Digit22.ComponentRegistryService) === null || _Digit22$ComponentReg === void 0 ? void 0 : _Digit22$ComponentReg.getComponent("WSEditDisconnectionApplication");
|
|
9449
|
+
const WSEditDisconnectionByConfig = (_Digit23 = Digit) === null || _Digit23 === void 0 ? void 0 : (_Digit23$ComponentReg = _Digit23.ComponentRegistryService) === null || _Digit23$ComponentReg === void 0 ? void 0 : _Digit23$ComponentReg.getComponent("WSEditDisconnectionByConfig");
|
|
9450
|
+
const WSResubmitDisconnection = (_Digit24 = Digit) === null || _Digit24 === void 0 ? void 0 : (_Digit24$ComponentReg = _Digit24.ComponentRegistryService) === null || _Digit24$ComponentReg === void 0 ? void 0 : _Digit24$ComponentReg.getComponent("WSResubmitDisconnection");
|
|
9451
|
+
const WSSearchIntegrated = (_Digit25 = Digit) === null || _Digit25 === void 0 ? void 0 : (_Digit25$ComponentReg = _Digit25.ComponentRegistryService) === null || _Digit25$ComponentReg === void 0 ? void 0 : _Digit25$ComponentReg.getComponent("WSSearchIntegrated");
|
|
9452
|
+
const WSBulkBillGeneration = (_Digit26 = Digit) === null || _Digit26 === void 0 ? void 0 : (_Digit26$ComponentReg = _Digit26.ComponentRegistryService) === null || _Digit26$ComponentReg === void 0 ? void 0 : _Digit26$ComponentReg.getComponent("WSBulkBillGeneration");
|
|
9434
9453
|
const locationCheck = window.location.href.includes("/employee/ws/new-application") || window.location.href.includes("/employee/ws/modify-application") || window.location.href.includes("/employee/ws/edit-application") || window.location.href.includes("/employee/ws/activate-connection") || window.location.href.includes("/employee/ws/application-details") || window.location.href.includes("/employee/ws/modify-details") || window.location.href.includes("/employee/ws/ws-response") || window.location.href.includes("/employee/ws/new-disconnection/application-form") || window.location.href.includes("/employee/ws/ws-disconnection-response") || window.location.href.includes("/employee/ws/consumption-details") || window.location.href.includes("/employee/ws/edit-disconnection-application") || window.location.href.includes("/employee/ws/config-by-disconnection-application") || window.location.href.includes("/employee/ws/resubmit-disconnection-application") || window.location.href.includes("/employee/ws/water/bulk-bill");
|
|
9435
9454
|
const locationCheckReqDocs = window.location.href.includes("/employee/ws/create-application") || window.location.href.includes("/employee/ws/new-disconnection/docsrequired");
|
|
9436
9455
|
return /*#__PURE__*/React.createElement("div", {
|
|
@@ -9449,6 +9468,9 @@ const App$1 = ({
|
|
|
9449
9468
|
}), /*#__PURE__*/React.createElement(PrivateRoute, {
|
|
9450
9469
|
path: `${path}/new-application`,
|
|
9451
9470
|
component: WSNewApplication
|
|
9471
|
+
}), /*#__PURE__*/React.createElement(PrivateRoute, {
|
|
9472
|
+
path: `${path}/old-application`,
|
|
9473
|
+
component: WSOLDApplication
|
|
9452
9474
|
}), /*#__PURE__*/React.createElement(PrivateRoute, {
|
|
9453
9475
|
path: `${path}/edit-application`,
|
|
9454
9476
|
component: WSEditApplication
|
|
@@ -10932,14 +10954,14 @@ const WSConnectionDetails = ({
|
|
|
10932
10954
|
formState,
|
|
10933
10955
|
clearErrors
|
|
10934
10956
|
}) => {
|
|
10935
|
-
var _formData$ConnectionD;
|
|
10957
|
+
var _formData$ConnectionD, _formData$ConnectionD2;
|
|
10936
10958
|
const {
|
|
10937
10959
|
t
|
|
10938
10960
|
} = useTranslation();
|
|
10939
10961
|
const {
|
|
10940
10962
|
pathname
|
|
10941
10963
|
} = useLocation();
|
|
10942
|
-
const [connectionDetails, setConnectionDetails] = useState(formData
|
|
10964
|
+
const [connectionDetails, setConnectionDetails] = useState((formData === null || formData === void 0 ? void 0 : (_formData$ConnectionD = formData.ConnectionDetails) === null || _formData$ConnectionD === void 0 ? void 0 : _formData$ConnectionD.length) > 0 ? [formData === null || formData === void 0 ? void 0 : (_formData$ConnectionD2 = formData.ConnectionDetails) === null || _formData$ConnectionD2 === void 0 ? void 0 : _formData$ConnectionD2[0]] : [createConnectionDetails()]);
|
|
10943
10965
|
const [focusIndex, setFocusIndex] = useState({
|
|
10944
10966
|
index: -1,
|
|
10945
10967
|
type: ""
|
|
@@ -10970,10 +10992,7 @@ const WSConnectionDetails = ({
|
|
|
10970
10992
|
useEffect(() => {
|
|
10971
10993
|
var _connectionDetails$, _connectionDetails$2;
|
|
10972
10994
|
if (userType === "employee") {
|
|
10973
|
-
onSelect(config.key,
|
|
10974
|
-
...formData[config.key],
|
|
10975
|
-
...connectionDetails
|
|
10976
|
-
});
|
|
10995
|
+
onSelect(config.key, connectionDetails);
|
|
10977
10996
|
}
|
|
10978
10997
|
if (connectionDetails !== null && connectionDetails !== void 0 && (_connectionDetails$ = connectionDetails[0]) !== null && _connectionDetails$ !== void 0 && _connectionDetails$.water) setWaterSewarageSelection({
|
|
10979
10998
|
water: true,
|
|
@@ -11461,11 +11480,12 @@ const WSRoadCuttingDetails = ({
|
|
|
11461
11480
|
pathname
|
|
11462
11481
|
} = useLocation();
|
|
11463
11482
|
const isEditScreen = pathname.includes("/modify-application/");
|
|
11464
|
-
const
|
|
11483
|
+
const tenantId = Digit.ULBService.getCurrentTenantId();
|
|
11465
11484
|
const {
|
|
11466
11485
|
isMdmsLoading,
|
|
11467
11486
|
data: mdmsData
|
|
11468
|
-
} = Digit.Hooks.ws.useMDMS(
|
|
11487
|
+
} = Digit.Hooks.ws.useMDMS(tenantId, window.location.href.includes("sewerage") ? "sw-services-calculation" : "ws-services-calculation", ["RoadType"]);
|
|
11488
|
+
console.log(mdmsData, "yuyu");
|
|
11469
11489
|
const [roadCuttingDetails, setRoadCuttingDetails] = useState((formData === null || formData === void 0 ? void 0 : formData.roadCuttingDetails) || [createRoadCuttingDetails()]);
|
|
11470
11490
|
const [focusIndex, setFocusIndex] = useState({
|
|
11471
11491
|
index: -1,
|
|
@@ -11550,12 +11570,13 @@ const RoadCuttForm = _props => {
|
|
|
11550
11570
|
errors
|
|
11551
11571
|
} = localFormState;
|
|
11552
11572
|
const roadCuttingTypeMenu = useMemo(() => {
|
|
11553
|
-
var _mdmsData$
|
|
11554
|
-
const
|
|
11555
|
-
const
|
|
11573
|
+
var _mdmsData$calculation, _mdmsData$MdmsRes, _mdmsData$MdmsRes$cal;
|
|
11574
|
+
const calculationModule = window.location.href.includes("sewerage") ? "sw-services-calculation" : "ws-services-calculation";
|
|
11575
|
+
const RoadTypes = (mdmsData === null || mdmsData === void 0 ? void 0 : (_mdmsData$calculation = mdmsData[calculationModule]) === null || _mdmsData$calculation === void 0 ? void 0 : _mdmsData$calculation.RoadType) || (mdmsData === null || mdmsData === void 0 ? void 0 : (_mdmsData$MdmsRes = mdmsData.MdmsRes) === null || _mdmsData$MdmsRes === void 0 ? void 0 : (_mdmsData$MdmsRes$cal = _mdmsData$MdmsRes[calculationModule]) === null || _mdmsData$MdmsRes$cal === void 0 ? void 0 : _mdmsData$MdmsRes$cal.RoadType) || [];
|
|
11576
|
+
const filteredRoadTypes = Array.isArray(RoadTypes) ? RoadTypes.filter(data => (data === null || data === void 0 ? void 0 : data.isActive) === true || (data === null || data === void 0 ? void 0 : data.active) === true) : [];
|
|
11556
11577
|
filteredRoadTypes.forEach(data => {
|
|
11557
11578
|
var _data$code;
|
|
11558
|
-
return data.i18nKey = `WS_ROADTYPE_${stringReplaceAll(data === null || data === void 0 ? void 0 : (_data$code = data.code) === null || _data$code === void 0 ? void 0 : _data$code.toUpperCase(), " ", "_")}`;
|
|
11579
|
+
return data.i18nKey = data.i18nKey || `WS_ROADTYPE_${stringReplaceAll(data === null || data === void 0 ? void 0 : (_data$code = data.code) === null || _data$code === void 0 ? void 0 : _data$code.toUpperCase(), " ", "_")}`;
|
|
11559
11580
|
});
|
|
11560
11581
|
return filteredRoadTypes;
|
|
11561
11582
|
}, [mdmsData]);
|
|
@@ -11893,8 +11914,8 @@ const WSConnectionHolderDetails = ({
|
|
|
11893
11914
|
const {
|
|
11894
11915
|
data: Menu,
|
|
11895
11916
|
isLoading: isSpecialcategoryLoading
|
|
11896
|
-
} = Digit.Hooks.
|
|
11897
|
-
Menu ? Menu.sort((a, b) => a.
|
|
11917
|
+
} = Digit.Hooks.ws.useWSConfigMDMS.OwnerType(stateId);
|
|
11918
|
+
Menu ? Menu.sort((a, b) => t(a.i18nKey).localeCompare(t(b.i18nKey))) : "";
|
|
11898
11919
|
useEffect(() => {
|
|
11899
11920
|
const data = connectionHolderDetails.map(e => {
|
|
11900
11921
|
return e;
|
|
@@ -12031,7 +12052,7 @@ const ConnectionDetails$1 = _props => {
|
|
|
12031
12052
|
trigger();
|
|
12032
12053
|
}, []);
|
|
12033
12054
|
useEffect(() => {
|
|
12034
|
-
if (Object.entries(formValue).length > 0
|
|
12055
|
+
if (Object.entries(formValue).length > 0) {
|
|
12035
12056
|
const keys = Object.keys(formValue);
|
|
12036
12057
|
const part = {};
|
|
12037
12058
|
keys.forEach(key => part[key] = connectionHolderDetail[key]);
|
|
@@ -12077,7 +12098,7 @@ const ConnectionDetails$1 = _props => {
|
|
|
12077
12098
|
setError(config.key, {
|
|
12078
12099
|
type: errors
|
|
12079
12100
|
});
|
|
12080
|
-
} else if (!Object.keys(errors).length && formState.errors[config.key]
|
|
12101
|
+
} else if (!Object.keys(errors).length && formState.errors[config.key]) {
|
|
12081
12102
|
clearErrors(config.key);
|
|
12082
12103
|
}
|
|
12083
12104
|
}, [errors]);
|
|
@@ -21829,6 +21850,10 @@ const WSCard = () => {
|
|
|
21829
21850
|
label: t("WS_APPLY_NEW_CONNECTION_HOME_CARD_LABEL"),
|
|
21830
21851
|
link: `/digit-ui/employee/ws/create-application`,
|
|
21831
21852
|
roles: ["WS_CEMP", "SW_CEMP"]
|
|
21853
|
+
}, {
|
|
21854
|
+
label: t("WS_APPLY_OLD_CONNECTION_HOME_CARD_LABEL"),
|
|
21855
|
+
link: `/digit-ui/employee/ws/old-application`,
|
|
21856
|
+
roles: ["WS_CEMP", "SW_CEMP"]
|
|
21832
21857
|
}];
|
|
21833
21858
|
links = links.filter(link => link.roles ? checkForEmployee(link.roles) : true);
|
|
21834
21859
|
const propsForModuleCard = {
|
|
@@ -31094,17 +31119,20 @@ const DEFAULT_FORM_VALUES = {
|
|
|
31094
31119
|
whatsAppNumber: ""
|
|
31095
31120
|
},
|
|
31096
31121
|
applicationSelection: {
|
|
31097
|
-
serviceType:
|
|
31098
|
-
applicantType:
|
|
31099
|
-
connectionType:
|
|
31100
|
-
categoryType:
|
|
31101
|
-
subCategory:
|
|
31122
|
+
serviceType: dropdownData.serviceTypes[0],
|
|
31123
|
+
applicantType: dropdownData.applicantTypes[0],
|
|
31124
|
+
connectionType: dropdownData.connectionTypes[0],
|
|
31125
|
+
categoryType: dropdownData.categoryTypes[1],
|
|
31126
|
+
subCategory: dropdownData.subCategories[0],
|
|
31102
31127
|
temporaryConnection: null,
|
|
31103
31128
|
ownerAuthorizationDoc: null,
|
|
31104
31129
|
ownerContactNumber: "",
|
|
31105
31130
|
ownerOtp: "",
|
|
31106
31131
|
isOwnerVerified: false,
|
|
31107
|
-
domesticType:
|
|
31132
|
+
domesticType: {
|
|
31133
|
+
code: "INDIVIDUAL",
|
|
31134
|
+
name: "Individual"
|
|
31135
|
+
},
|
|
31108
31136
|
commercialType: null
|
|
31109
31137
|
},
|
|
31110
31138
|
djbEmployee: {
|
|
@@ -31167,6 +31195,7 @@ const DEFAULT_FORM_VALUES = {
|
|
|
31167
31195
|
signatureFile: null,
|
|
31168
31196
|
agree: false
|
|
31169
31197
|
},
|
|
31198
|
+
zro: null,
|
|
31170
31199
|
cpt: {
|
|
31171
31200
|
id: "",
|
|
31172
31201
|
details: null
|
|
@@ -31352,10 +31381,7 @@ const linkButtonStyle = {
|
|
|
31352
31381
|
textDecoration: "underline"
|
|
31353
31382
|
};
|
|
31354
31383
|
const buildDefaultValues = () => ({
|
|
31355
|
-
zro:
|
|
31356
|
-
value: "",
|
|
31357
|
-
error: ""
|
|
31358
|
-
},
|
|
31384
|
+
zro: DEFAULT_FORM_VALUES.zro,
|
|
31359
31385
|
typeOfRequest: DEFAULT_FORM_VALUES.typeOfRequest,
|
|
31360
31386
|
connectionType: DEFAULT_FORM_VALUES.connectionType,
|
|
31361
31387
|
applicant: {
|
|
@@ -31397,15 +31423,16 @@ const resolveNestedValue = (value, path) => path.split(".").reduce((accumulator,
|
|
|
31397
31423
|
if (accumulator === null || accumulator === undefined) return undefined;
|
|
31398
31424
|
return accumulator[currentKey];
|
|
31399
31425
|
}, value);
|
|
31400
|
-
const getDisplayValue = value => {
|
|
31401
|
-
if (value === null || value === undefined || value === "") return "
|
|
31402
|
-
if (typeof value === "boolean") return value ? "
|
|
31426
|
+
const getDisplayValue = (value, t) => {
|
|
31427
|
+
if (value === null || value === undefined || value === "") return t("CS_COMMON_NOT_AVAILABLE");
|
|
31428
|
+
if (typeof value === "boolean") return value ? t("CS_COMMON_YES") : t("CS_COMMON_NO");
|
|
31403
31429
|
if (typeof value === "object") {
|
|
31404
31430
|
if (value !== null && value !== void 0 && value.fileName) return value.fileName;
|
|
31405
|
-
if (value !== null && value !== void 0 && value.
|
|
31406
|
-
if (value !== null && value !== void 0 && value.
|
|
31431
|
+
if (value !== null && value !== void 0 && value.i18nKey) return t(value.i18nKey);
|
|
31432
|
+
if (value !== null && value !== void 0 && value.name) return t(value.name);
|
|
31433
|
+
if (value !== null && value !== void 0 && value.code) return t(value.code);
|
|
31407
31434
|
}
|
|
31408
|
-
return String(value);
|
|
31435
|
+
return t(String(value));
|
|
31409
31436
|
};
|
|
31410
31437
|
const FieldBlock = ({
|
|
31411
31438
|
label,
|
|
@@ -31517,6 +31544,9 @@ const PreviewItem = ({
|
|
|
31517
31544
|
value,
|
|
31518
31545
|
isFullWidth
|
|
31519
31546
|
}) => {
|
|
31547
|
+
const {
|
|
31548
|
+
t
|
|
31549
|
+
} = useTranslation();
|
|
31520
31550
|
const stateId = Digit.ULBService.getStateId();
|
|
31521
31551
|
const isFile = value && typeof value === "object" && (value === null || value === void 0 ? void 0 : value.fileStoreId);
|
|
31522
31552
|
return /*#__PURE__*/React.createElement("div", {
|
|
@@ -31531,7 +31561,7 @@ const PreviewItem = ({
|
|
|
31531
31561
|
fontWeight: "600",
|
|
31532
31562
|
marginBottom: "0px"
|
|
31533
31563
|
}
|
|
31534
|
-
}, label), /*#__PURE__*/React.createElement("div", {
|
|
31564
|
+
}, t(label)), /*#__PURE__*/React.createElement("div", {
|
|
31535
31565
|
style: {
|
|
31536
31566
|
display: "flex",
|
|
31537
31567
|
alignItems: "center",
|
|
@@ -31542,7 +31572,7 @@ const PreviewItem = ({
|
|
|
31542
31572
|
marginBottom: "0px",
|
|
31543
31573
|
marginTop: "0px"
|
|
31544
31574
|
}
|
|
31545
|
-
}, getDisplayValue(value)), isFile && /*#__PURE__*/React.createElement("div", {
|
|
31575
|
+
}, getDisplayValue(value, t)), isFile && /*#__PURE__*/React.createElement("div", {
|
|
31546
31576
|
onClick: () => handleView(value.fileStoreId, stateId),
|
|
31547
31577
|
style: {
|
|
31548
31578
|
cursor: "pointer",
|
|
@@ -31550,7 +31580,7 @@ const PreviewItem = ({
|
|
|
31550
31580
|
alignItems: "center",
|
|
31551
31581
|
color: "#0B4B66"
|
|
31552
31582
|
},
|
|
31553
|
-
title: "
|
|
31583
|
+
title: t("CS_COMMON_VIEW_DOCUMENT")
|
|
31554
31584
|
}, /*#__PURE__*/React.createElement("svg", {
|
|
31555
31585
|
width: "20",
|
|
31556
31586
|
height: "20",
|
|
@@ -31600,7 +31630,7 @@ const FileUploadField = ({
|
|
|
31600
31630
|
}, isUploading ? "Uploading file..." : (value === null || value === void 0 ? void 0 : value.fileName) || "No file selected"));
|
|
31601
31631
|
};
|
|
31602
31632
|
const NewApplication = () => {
|
|
31603
|
-
var _Digit$SessionStorage, _getFieldError, _getFieldError2, _getFieldError3, _getFieldError4, _getFieldError5, _getFieldError6, _getFieldError7, _getFieldError8, _getFieldError9, _getFieldError0, _getFieldError1, _formValues$applicati, _formValues$applicati2, _formValues$applicati3, _formValues$applicati4, _formValues$applicati5, _formValues$applicati6, _formValues$applicati7, _formValues$applicati8, _formValues$applicati9, _formValues$applicati0, _formValues$applicati1, _formValues$applicati10, _formValues$applicati11, _formValues$applicati12, _formValues$applicati13, _formValues$applicati14, _formValues$applicati15, _formValues$applicati16, _formValues$applicati17, _formValues$applicati18, _formValues$applicati19, _formValues$applicati20, _formValues$applicant, _formValues$applicant2, _formValues$applicant3, _formValues$applicant4, _formValues$applicant5, _formValues$applicant6, _formValues$applicant7, _formValues$useDetail, _formValues$applicant8, _formValues$contact, _formValues$contact2, _formValues$contact3, _formValues$documents, _formValues$djbEmploy, _formValues$djbEmploy2, _formValues$djbEmploy3, _formValues$djbEmploy4, _formValues$djbEmploy5, _formValues$governmen, _formValues$governmen2, _formValues$governmen3, _formValues$governmen4, _formValues$propertyA, _formValues$propertyA2, _formValues$propertyA3, _formValues$propertyA4, _formValues$propertyA5, _formValues$propertyA6, _formValues$propertyA7, _formValues$propertyA8, _formValues$propertyA9, _formValues$propertyA0, _formValues$propertyA1, _formValues$useDetail2, _formValues$useDetail3, _formValues$useDetail4, _formValues$useDetail5, _formValues$useDetail6, _formValues$useDetail7, _formValues$useDetail8, _formValues$useDetail9, _formValues$useDetail0, _formValues$useDetail1, _formValues$useDetail10, _formValues$useDetail11, _formValues$bankDetai, _formValues$bankDetai2, _formValues$bankDetai3, _formValues$bankDetai4, _formValues$documents2, _formValues$documents3, _formValues$documents4, _formValues$documents5, _formValues$documents6, _formValues$declarati, _formValues$declarati2, _formValues$declarati3;
|
|
31633
|
+
var _Digit$SessionStorage, _getFieldError, _getFieldError2, _getFieldError3, _getFieldError4, _getFieldError5, _getFieldError6, _getFieldError7, _getFieldError8, _getFieldError9, _getFieldError0, _getFieldError1, _getFieldError10, _formValues$applicati, _formValues$applicati2, _formValues$applicati3, _formValues$applicati4, _formValues$applicati5, _formValues$applicati6, _formValues$applicati7, _formValues$applicati8, _formValues$applicati9, _formValues$applicati0, _formValues$applicati1, _formValues$applicati10, _formValues$applicati11, _formValues$applicati12, _formValues$applicati13, _formValues$applicati14, _formValues$applicati15, _formValues$applicati16, _formValues$applicati17, _formValues$applicati18, _formValues$applicati19, _formValues$applicati20, _formValues$applicant, _formValues$applicant2, _formValues$applicant3, _formValues$applicant4, _formValues$applicant5, _formValues$applicant6, _formValues$applicant7, _formValues$useDetail, _formValues$applicant8, _formValues$contact, _formValues$contact2, _formValues$contact3, _formValues$documents, _formValues$djbEmploy, _formValues$djbEmploy2, _formValues$djbEmploy3, _formValues$djbEmploy4, _formValues$djbEmploy5, _formValues$governmen, _formValues$governmen2, _formValues$governmen3, _formValues$governmen4, _formValues$propertyA, _formValues$propertyA2, _formValues$propertyA3, _formValues$propertyA4, _formValues$propertyA5, _formValues$propertyA6, _formValues$propertyA7, _formValues$propertyA8, _formValues$propertyA9, _formValues$propertyA0, _formValues$propertyA1, _formValues$useDetail2, _formValues$useDetail3, _formValues$useDetail4, _formValues$useDetail5, _formValues$useDetail6, _formValues$useDetail7, _formValues$useDetail8, _formValues$useDetail9, _formValues$useDetail0, _formValues$useDetail1, _formValues$useDetail10, _formValues$useDetail11, _formValues$bankDetai, _formValues$bankDetai2, _formValues$bankDetai3, _formValues$bankDetai4, _formValues$documents2, _formValues$documents3, _formValues$documents4, _formValues$documents5, _formValues$documents6, _formValues$declarati, _formValues$declarati2, _formValues$declarati3;
|
|
31604
31634
|
const {
|
|
31605
31635
|
t
|
|
31606
31636
|
} = useTranslation();
|
|
@@ -31624,9 +31654,19 @@ const NewApplication = () => {
|
|
|
31624
31654
|
const [waterAndSewerageBoth, setWaterAndSewerageBoth] = useState(null);
|
|
31625
31655
|
const [propertyId, setPropertyId] = useState(new URLSearchParams(location.search).get("propertyId"));
|
|
31626
31656
|
const initialFormValues = buildDefaultValues();
|
|
31627
|
-
const [zro, setZro] = useState(initialFormValues.zro);
|
|
31628
|
-
const [localFormState, setLocalFormState] = useState(false);
|
|
31629
31657
|
const [city, setCity] = useState("");
|
|
31658
|
+
const {
|
|
31659
|
+
data: ZROLocation
|
|
31660
|
+
} = Digit.Hooks.ws.useWSConfigMDMS.ZROLocation(tenantId);
|
|
31661
|
+
const {
|
|
31662
|
+
data: ConnectionType
|
|
31663
|
+
} = Digit.Hooks.ws.useWSConfigMDMS.ConnectionCategory(tenantId);
|
|
31664
|
+
const mappedZROLocation = useMemo(() => {
|
|
31665
|
+
return ZROLocation === null || ZROLocation === void 0 ? void 0 : ZROLocation.map(item => ({
|
|
31666
|
+
...item,
|
|
31667
|
+
i18nKey: (item === null || item === void 0 ? void 0 : item.i18nKey) || (item === null || item === void 0 ? void 0 : item.name) || (item === null || item === void 0 ? void 0 : item.code)
|
|
31668
|
+
}));
|
|
31669
|
+
}, [ZROLocation]);
|
|
31630
31670
|
useEffect(() => {
|
|
31631
31671
|
if (allCities && tenantId && !city) {
|
|
31632
31672
|
const currentCity = allCities === null || allCities === void 0 ? void 0 : allCities.find(c => c.code === tenantId);
|
|
@@ -31761,7 +31801,7 @@ const NewApplication = () => {
|
|
|
31761
31801
|
const isOwnerVerified = watch("applicationSelection.isOwnerVerified");
|
|
31762
31802
|
const subCategoryIsDomestic = (selectedSubCategory === null || selectedSubCategory === void 0 ? void 0 : selectedSubCategory.code) === "DOMESTIC";
|
|
31763
31803
|
const selectedConnectionType = watch("applicationSelection.connectionType");
|
|
31764
|
-
const connectionTypeIsTemporary = (selectedConnectionType === null || selectedConnectionType === void 0 ? void 0 : selectedConnectionType.code) === "
|
|
31804
|
+
const connectionTypeIsTemporary = (selectedConnectionType === null || selectedConnectionType === void 0 ? void 0 : selectedConnectionType.code) === "Temporary";
|
|
31765
31805
|
const selectedDomesticType = watch("applicationSelection.domesticType");
|
|
31766
31806
|
const activeType = (selectedSubCategory === null || selectedSubCategory === void 0 ? void 0 : selectedSubCategory.code) === "DOMESTIC" ? selectedDomesticType : selectedCommercialType;
|
|
31767
31807
|
const applicantSectionTitle = useMemo(() => {
|
|
@@ -32269,23 +32309,6 @@ const NewApplication = () => {
|
|
|
32269
32309
|
if (isEnableLoader || isPropertyLoading) {
|
|
32270
32310
|
return /*#__PURE__*/React.createElement(Loader, null);
|
|
32271
32311
|
}
|
|
32272
|
-
const menu = [{
|
|
32273
|
-
i18nKey: "ASHOK VIHAR",
|
|
32274
|
-
code: "ASHOK VIHAR",
|
|
32275
|
-
value: "ASHOK VIHAR"
|
|
32276
|
-
}, {
|
|
32277
|
-
i18nKey: "BURARI",
|
|
32278
|
-
code: "BURARI",
|
|
32279
|
-
value: "BURARI"
|
|
32280
|
-
}, {
|
|
32281
|
-
i18nKey: "DWARKA",
|
|
32282
|
-
code: "DWARKA",
|
|
32283
|
-
value: "DWARKA"
|
|
32284
|
-
}, {
|
|
32285
|
-
i18nKey: "OKHLA",
|
|
32286
|
-
code: "OKHLA",
|
|
32287
|
-
value: "OKHLA"
|
|
32288
|
-
}];
|
|
32289
32312
|
return /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("style", null, `
|
|
32290
32313
|
.ws-new-application-collapsible .collapsible-card-tabs {
|
|
32291
32314
|
display: none;
|
|
@@ -32362,12 +32385,7 @@ const NewApplication = () => {
|
|
|
32362
32385
|
background-color: #F9FAFB;
|
|
32363
32386
|
}
|
|
32364
32387
|
`), /*#__PURE__*/React.createElement("div", {
|
|
32365
|
-
|
|
32366
|
-
display: "flex",
|
|
32367
|
-
alignItems: "flex-start",
|
|
32368
|
-
gap: "24px",
|
|
32369
|
-
marginBottom: "80px"
|
|
32370
|
-
}
|
|
32388
|
+
className: "employee-form-section-wrapper"
|
|
32371
32389
|
}, !previewMode && /*#__PURE__*/React.createElement(VerticalTimeline, {
|
|
32372
32390
|
config: timelineConfig,
|
|
32373
32391
|
currentActiveIndex: currentStep - 1,
|
|
@@ -32386,16 +32404,15 @@ const NewApplication = () => {
|
|
|
32386
32404
|
isOpen: collapsedSections.application,
|
|
32387
32405
|
onToggle: toggleSection,
|
|
32388
32406
|
sectionKey: "application",
|
|
32389
|
-
title: "
|
|
32407
|
+
title: t("WS_APPLICATION_SELECTION"),
|
|
32390
32408
|
sectionRef: sectionRefs.application
|
|
32391
32409
|
}, /*#__PURE__*/React.createElement(LabelFieldPair, null, /*#__PURE__*/React.createElement(CardLabel, {
|
|
32392
32410
|
className: "card-label-smaller"
|
|
32393
|
-
}, "
|
|
32411
|
+
}, t("WS_ZRO_LOCATION")), /*#__PURE__*/React.createElement("div", {
|
|
32394
32412
|
className: "field"
|
|
32395
32413
|
}, /*#__PURE__*/React.createElement(Controller, {
|
|
32396
32414
|
control: control,
|
|
32397
32415
|
name: "zro",
|
|
32398
|
-
defaultValue: zro,
|
|
32399
32416
|
rules: {
|
|
32400
32417
|
required: t("REQUIRED_FIELD")
|
|
32401
32418
|
},
|
|
@@ -32404,22 +32421,16 @@ const NewApplication = () => {
|
|
|
32404
32421
|
className: "form-field",
|
|
32405
32422
|
selected: props.value,
|
|
32406
32423
|
disable: false,
|
|
32407
|
-
option:
|
|
32424
|
+
option: mappedZROLocation,
|
|
32408
32425
|
errorStyle: !!getFieldError("zro"),
|
|
32409
|
-
select:
|
|
32410
|
-
props.onChange(e);
|
|
32411
|
-
setZro(prev => ({
|
|
32412
|
-
...prev,
|
|
32413
|
-
value: e
|
|
32414
|
-
}));
|
|
32415
|
-
},
|
|
32426
|
+
select: props.onChange,
|
|
32416
32427
|
optionKey: "i18nKey",
|
|
32417
32428
|
onBlur: props.onBlur,
|
|
32418
32429
|
t: t
|
|
32419
32430
|
}))
|
|
32420
|
-
}))),
|
|
32431
|
+
}))), getFieldError("zro") && /*#__PURE__*/React.createElement(CardLabelError, null, (_getFieldError = getFieldError("zro")) === null || _getFieldError === void 0 ? void 0 : _getFieldError.message), /*#__PURE__*/React.createElement(LabelFieldPair, null, /*#__PURE__*/React.createElement(CardLabel, {
|
|
32421
32432
|
className: "card-label-smaller"
|
|
32422
|
-
}, "
|
|
32433
|
+
}, t("WS_SERVICE_TYPE")), /*#__PURE__*/React.createElement("div", {
|
|
32423
32434
|
className: "field"
|
|
32424
32435
|
}, /*#__PURE__*/React.createElement(Controller, {
|
|
32425
32436
|
control: control,
|
|
@@ -32439,9 +32450,9 @@ const NewApplication = () => {
|
|
|
32439
32450
|
onBlur: props.onBlur,
|
|
32440
32451
|
t: t
|
|
32441
32452
|
})
|
|
32442
|
-
}))), getFieldError("applicationSelection.serviceType") && /*#__PURE__*/React.createElement(CardLabelError, null, (
|
|
32453
|
+
}))), getFieldError("applicationSelection.serviceType") && /*#__PURE__*/React.createElement(CardLabelError, null, (_getFieldError2 = getFieldError("applicationSelection.serviceType")) === null || _getFieldError2 === void 0 ? void 0 : _getFieldError2.message), /*#__PURE__*/React.createElement(LabelFieldPair, null, /*#__PURE__*/React.createElement(CardLabel, {
|
|
32443
32454
|
className: "card-label-smaller"
|
|
32444
|
-
}, "
|
|
32455
|
+
}, t("WS_APPLICANT_TYPE")), /*#__PURE__*/React.createElement("div", {
|
|
32445
32456
|
className: "field"
|
|
32446
32457
|
}, /*#__PURE__*/React.createElement(Controller, {
|
|
32447
32458
|
control: control,
|
|
@@ -32461,9 +32472,9 @@ const NewApplication = () => {
|
|
|
32461
32472
|
onBlur: props.onBlur,
|
|
32462
32473
|
t: t
|
|
32463
32474
|
})
|
|
32464
|
-
}))), getFieldError("applicationSelection.applicantType") && /*#__PURE__*/React.createElement(CardLabelError, null, (
|
|
32475
|
+
}))), getFieldError("applicationSelection.applicantType") && /*#__PURE__*/React.createElement(CardLabelError, null, (_getFieldError3 = getFieldError("applicationSelection.applicantType")) === null || _getFieldError3 === void 0 ? void 0 : _getFieldError3.message), isTenantOrRelative && /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(LabelFieldPair, null, /*#__PURE__*/React.createElement(CardLabel, {
|
|
32465
32476
|
className: "card-label-smaller"
|
|
32466
|
-
}, "
|
|
32477
|
+
}, t("WS_OWNER_AUTHORIZATION")), /*#__PURE__*/React.createElement("div", {
|
|
32467
32478
|
className: "field"
|
|
32468
32479
|
}, /*#__PURE__*/React.createElement(Controller, {
|
|
32469
32480
|
control: control,
|
|
@@ -32481,7 +32492,7 @@ const NewApplication = () => {
|
|
|
32481
32492
|
})
|
|
32482
32493
|
}))), /*#__PURE__*/React.createElement(LabelFieldPair, null, /*#__PURE__*/React.createElement(CardLabel, {
|
|
32483
32494
|
className: "card-label-smaller"
|
|
32484
|
-
}, "
|
|
32495
|
+
}, t("WS_OWNER_CONTACT_NUMBER")), /*#__PURE__*/React.createElement("div", {
|
|
32485
32496
|
className: "field",
|
|
32486
32497
|
style: {
|
|
32487
32498
|
display: "flex",
|
|
@@ -32519,15 +32530,15 @@ const NewApplication = () => {
|
|
|
32519
32530
|
});
|
|
32520
32531
|
}
|
|
32521
32532
|
}
|
|
32522
|
-
}, isOtpSent ? "
|
|
32533
|
+
}, isOtpSent ? t("WS_RESEND_OTP") : t("WS_VERIFY")), isOwnerVerified && /*#__PURE__*/React.createElement("span", {
|
|
32523
32534
|
style: {
|
|
32524
32535
|
color: "green",
|
|
32525
32536
|
fontSize: "14px",
|
|
32526
32537
|
fontWeight: "600"
|
|
32527
32538
|
}
|
|
32528
|
-
}, "
|
|
32539
|
+
}, t("WS_VERIFIED"), " \u2713"))), getFieldError("applicationSelection.ownerContactNumber") && /*#__PURE__*/React.createElement(CardLabelError, null, (_getFieldError4 = getFieldError("applicationSelection.ownerContactNumber")) === null || _getFieldError4 === void 0 ? void 0 : _getFieldError4.message), isOtpSent && !isOwnerVerified && /*#__PURE__*/React.createElement(LabelFieldPair, null, /*#__PURE__*/React.createElement(CardLabel, {
|
|
32529
32540
|
className: "card-label-smaller"
|
|
32530
|
-
}, "
|
|
32541
|
+
}, t("WS_OTP_VERIFICATION")), /*#__PURE__*/React.createElement("div", {
|
|
32531
32542
|
className: "field",
|
|
32532
32543
|
style: {
|
|
32533
32544
|
display: "flex",
|
|
@@ -32559,9 +32570,9 @@ const NewApplication = () => {
|
|
|
32559
32570
|
setOtpError("Enter 6 digit OTP");
|
|
32560
32571
|
}
|
|
32561
32572
|
}
|
|
32562
|
-
}, "
|
|
32573
|
+
}, t("WS_CONFIRM")))), (getFieldError("applicationSelection.ownerOtp") || otpError) && /*#__PURE__*/React.createElement(CardLabelError, null, ((_getFieldError5 = getFieldError("applicationSelection.ownerOtp")) === null || _getFieldError5 === void 0 ? void 0 : _getFieldError5.message) || otpError)), /*#__PURE__*/React.createElement(LabelFieldPair, null, /*#__PURE__*/React.createElement(CardLabel, {
|
|
32563
32574
|
className: "card-label-smaller"
|
|
32564
|
-
}, "
|
|
32575
|
+
}, t("WS_CONNECTION_TYPE")), /*#__PURE__*/React.createElement("div", {
|
|
32565
32576
|
className: "field"
|
|
32566
32577
|
}, /*#__PURE__*/React.createElement(Controller, {
|
|
32567
32578
|
control: control,
|
|
@@ -32574,16 +32585,16 @@ const NewApplication = () => {
|
|
|
32574
32585
|
className: "form-field",
|
|
32575
32586
|
selected: props.value,
|
|
32576
32587
|
disable: false,
|
|
32577
|
-
option:
|
|
32588
|
+
option: ConnectionType,
|
|
32578
32589
|
errorStyle: !!getFieldError("applicationSelection.connectionType"),
|
|
32579
32590
|
select: props.onChange,
|
|
32580
32591
|
optionKey: "name",
|
|
32581
32592
|
onBlur: props.onBlur,
|
|
32582
32593
|
t: t
|
|
32583
32594
|
})
|
|
32584
|
-
}))), getFieldError("applicationSelection.connectionType") && /*#__PURE__*/React.createElement(CardLabelError, null, (
|
|
32595
|
+
}))), getFieldError("applicationSelection.connectionType") && /*#__PURE__*/React.createElement(CardLabelError, null, (_getFieldError6 = getFieldError("applicationSelection.connectionType")) === null || _getFieldError6 === void 0 ? void 0 : _getFieldError6.message), connectionTypeIsTemporary && /*#__PURE__*/React.createElement(LabelFieldPair, null, /*#__PURE__*/React.createElement(CardLabel, {
|
|
32585
32596
|
className: "card-label-smaller"
|
|
32586
|
-
}, "
|
|
32597
|
+
}, t("WS_TEMPORARY_CONNECTION")), /*#__PURE__*/React.createElement("div", {
|
|
32587
32598
|
className: "field"
|
|
32588
32599
|
}, /*#__PURE__*/React.createElement(Controller, {
|
|
32589
32600
|
control: control,
|
|
@@ -32603,9 +32614,9 @@ const NewApplication = () => {
|
|
|
32603
32614
|
onBlur: props.onBlur,
|
|
32604
32615
|
t: t
|
|
32605
32616
|
})
|
|
32606
|
-
}))), connectionTypeIsTemporary && getFieldError("applicationSelection.temporaryConnection") && /*#__PURE__*/React.createElement(CardLabelError, null, (
|
|
32617
|
+
}))), connectionTypeIsTemporary && getFieldError("applicationSelection.temporaryConnection") && /*#__PURE__*/React.createElement(CardLabelError, null, (_getFieldError7 = getFieldError("applicationSelection.temporaryConnection")) === null || _getFieldError7 === void 0 ? void 0 : _getFieldError7.message), /*#__PURE__*/React.createElement(LabelFieldPair, null, /*#__PURE__*/React.createElement(CardLabel, {
|
|
32607
32618
|
className: "card-label-smaller"
|
|
32608
|
-
}, "
|
|
32619
|
+
}, t("WS_CATEGORY_TYPE")), /*#__PURE__*/React.createElement("div", {
|
|
32609
32620
|
className: "field"
|
|
32610
32621
|
}, /*#__PURE__*/React.createElement(Controller, {
|
|
32611
32622
|
control: control,
|
|
@@ -32625,9 +32636,9 @@ const NewApplication = () => {
|
|
|
32625
32636
|
onBlur: props.onBlur,
|
|
32626
32637
|
t: t
|
|
32627
32638
|
})
|
|
32628
|
-
}))), getFieldError("applicationSelection.subCategory") && /*#__PURE__*/React.createElement(CardLabelError, null, (
|
|
32639
|
+
}))), getFieldError("applicationSelection.subCategory") && /*#__PURE__*/React.createElement(CardLabelError, null, (_getFieldError8 = getFieldError("applicationSelection.subCategory")) === null || _getFieldError8 === void 0 ? void 0 : _getFieldError8.message), /*#__PURE__*/React.createElement(LabelFieldPair, null, /*#__PURE__*/React.createElement(CardLabel, {
|
|
32629
32640
|
className: "card-label-smaller"
|
|
32630
|
-
}, "
|
|
32641
|
+
}, t("WS_WATER_DEMAND_TYPE")), /*#__PURE__*/React.createElement("div", {
|
|
32631
32642
|
className: "field"
|
|
32632
32643
|
}, /*#__PURE__*/React.createElement(Controller, {
|
|
32633
32644
|
control: control,
|
|
@@ -32647,9 +32658,9 @@ const NewApplication = () => {
|
|
|
32647
32658
|
onBlur: props.onBlur,
|
|
32648
32659
|
t: t
|
|
32649
32660
|
})
|
|
32650
|
-
}))), getFieldError("applicationSelection.categoryType") && /*#__PURE__*/React.createElement(CardLabelError, null, (
|
|
32661
|
+
}))), getFieldError("applicationSelection.categoryType") && /*#__PURE__*/React.createElement(CardLabelError, null, (_getFieldError9 = getFieldError("applicationSelection.categoryType")) === null || _getFieldError9 === void 0 ? void 0 : _getFieldError9.message), subCategoryIsDomestic && /*#__PURE__*/React.createElement(LabelFieldPair, null, /*#__PURE__*/React.createElement(CardLabel, {
|
|
32651
32662
|
className: "card-label-smaller"
|
|
32652
|
-
}, "
|
|
32663
|
+
}, t("WS_DOMESTIC_TYPE")), /*#__PURE__*/React.createElement("div", {
|
|
32653
32664
|
className: "field"
|
|
32654
32665
|
}, /*#__PURE__*/React.createElement(Controller, {
|
|
32655
32666
|
control: control,
|
|
@@ -32667,11 +32678,12 @@ const NewApplication = () => {
|
|
|
32667
32678
|
}, {
|
|
32668
32679
|
code: "ORGANIZATION",
|
|
32669
32680
|
name: "Organization"
|
|
32670
|
-
}]
|
|
32681
|
+
}],
|
|
32682
|
+
t: t
|
|
32671
32683
|
})
|
|
32672
|
-
}))), subCategoryIsDomestic && getFieldError("applicationSelection.domesticType") && /*#__PURE__*/React.createElement(CardLabelError, null, (
|
|
32684
|
+
}))), subCategoryIsDomestic && getFieldError("applicationSelection.domesticType") && /*#__PURE__*/React.createElement(CardLabelError, null, (_getFieldError0 = getFieldError("applicationSelection.domesticType")) === null || _getFieldError0 === void 0 ? void 0 : _getFieldError0.message), subCategoryIsCommercial && /*#__PURE__*/React.createElement(LabelFieldPair, null, /*#__PURE__*/React.createElement(CardLabel, {
|
|
32673
32685
|
className: "card-label-smaller"
|
|
32674
|
-
}, "
|
|
32686
|
+
}, t("WS_COMMERCIAL_TYPE")), /*#__PURE__*/React.createElement("div", {
|
|
32675
32687
|
className: "field"
|
|
32676
32688
|
}, /*#__PURE__*/React.createElement(Controller, {
|
|
32677
32689
|
control: control,
|
|
@@ -32694,25 +32706,25 @@ const NewApplication = () => {
|
|
|
32694
32706
|
t: t
|
|
32695
32707
|
})
|
|
32696
32708
|
}))))), /*#__PURE__*/React.createElement(SectionCard, {
|
|
32697
|
-
description: "
|
|
32709
|
+
description: t("WS_GOVT_CONNECTION_DESC"),
|
|
32698
32710
|
isOpen: collapsedSections.governmentEmployee,
|
|
32699
32711
|
onToggle: toggleSection,
|
|
32700
32712
|
sectionKey: "governmentEmployee",
|
|
32701
|
-
title: "
|
|
32713
|
+
title: t("WS_GOVERNMENT_CONNECTION"),
|
|
32702
32714
|
sectionRef: sectionRefs.governmentEmployee
|
|
32703
32715
|
}, /*#__PURE__*/React.createElement(FieldBlock, {
|
|
32704
|
-
label: "
|
|
32716
|
+
label: t("WS_GOVERNMENT_CONNECTION")
|
|
32705
32717
|
}, /*#__PURE__*/React.createElement(Controller, {
|
|
32706
32718
|
control: control,
|
|
32707
32719
|
name: "governmentEmployee.isGovernmentEmployee",
|
|
32708
32720
|
render: props => /*#__PURE__*/React.createElement(CheckBox, {
|
|
32709
32721
|
checked: !!props.value,
|
|
32710
|
-
label: "
|
|
32722
|
+
label: t("WS_APPLICANT_IS_GOVT_CONNECTION"),
|
|
32711
32723
|
onChange: event => props.onChange(event.target.checked)
|
|
32712
32724
|
})
|
|
32713
32725
|
})), isGovernmentEmployee && /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(LabelFieldPair, null, /*#__PURE__*/React.createElement(CardLabel, {
|
|
32714
32726
|
className: "card-label-smaller"
|
|
32715
|
-
}, "
|
|
32727
|
+
}, t("WS_ORGANIZATION_NAME")), /*#__PURE__*/React.createElement("div", {
|
|
32716
32728
|
className: "field"
|
|
32717
32729
|
}, /*#__PURE__*/React.createElement(TextInput, {
|
|
32718
32730
|
name: "governmentEmployee.organizationName",
|
|
@@ -32720,9 +32732,9 @@ const NewApplication = () => {
|
|
|
32720
32732
|
required: isGovernmentEmployee ? "Organization Name is required" : false
|
|
32721
32733
|
}),
|
|
32722
32734
|
errorStyle: !!getFieldError("governmentEmployee.organizationName")
|
|
32723
|
-
}))), getFieldError("governmentEmployee.organizationName") && /*#__PURE__*/React.createElement(CardLabelError, null, (
|
|
32735
|
+
}))), getFieldError("governmentEmployee.organizationName") && /*#__PURE__*/React.createElement(CardLabelError, null, (_getFieldError1 = getFieldError("governmentEmployee.organizationName")) === null || _getFieldError1 === void 0 ? void 0 : _getFieldError1.message), /*#__PURE__*/React.createElement(LabelFieldPair, null, /*#__PURE__*/React.createElement(CardLabel, {
|
|
32724
32736
|
className: "card-label-smaller"
|
|
32725
|
-
}, "
|
|
32737
|
+
}, t("WS_NATURE_OF_WORK")), /*#__PURE__*/React.createElement("div", {
|
|
32726
32738
|
className: "field"
|
|
32727
32739
|
}, /*#__PURE__*/React.createElement(TextInput, {
|
|
32728
32740
|
name: "governmentEmployee.natureOfWork",
|
|
@@ -32730,9 +32742,9 @@ const NewApplication = () => {
|
|
|
32730
32742
|
required: isGovernmentEmployee ? "Nature of Work is required" : false
|
|
32731
32743
|
}),
|
|
32732
32744
|
errorStyle: !!getFieldError("governmentEmployee.natureOfWork")
|
|
32733
|
-
}))), getFieldError("governmentEmployee.natureOfWork") && /*#__PURE__*/React.createElement(CardLabelError, null, (
|
|
32745
|
+
}))), getFieldError("governmentEmployee.natureOfWork") && /*#__PURE__*/React.createElement(CardLabelError, null, (_getFieldError10 = getFieldError("governmentEmployee.natureOfWork")) === null || _getFieldError10 === void 0 ? void 0 : _getFieldError10.message), /*#__PURE__*/React.createElement(LabelFieldPair, null, /*#__PURE__*/React.createElement(CardLabel, {
|
|
32734
32746
|
className: "card-label-smaller"
|
|
32735
|
-
}, "
|
|
32747
|
+
}, t("WS_UPLOAD_DOCUMENT")), /*#__PURE__*/React.createElement("div", {
|
|
32736
32748
|
className: "field"
|
|
32737
32749
|
}, /*#__PURE__*/React.createElement(Controller, {
|
|
32738
32750
|
control: control,
|
|
@@ -32753,11 +32765,11 @@ const NewApplication = () => {
|
|
|
32753
32765
|
display: previewMode ? "none" : "block"
|
|
32754
32766
|
}
|
|
32755
32767
|
}, /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(SectionCard, {
|
|
32756
|
-
description: "
|
|
32768
|
+
description: t("WS_APPLICANT_DETAILS_DESC"),
|
|
32757
32769
|
isOpen: collapsedSections.applicant,
|
|
32758
32770
|
onToggle: toggleSection,
|
|
32759
32771
|
sectionKey: "applicant",
|
|
32760
|
-
title: applicantSectionTitle,
|
|
32772
|
+
title: t(applicantSectionTitle),
|
|
32761
32773
|
sectionRef: sectionRefs.applicant
|
|
32762
32774
|
}, /*#__PURE__*/React.createElement(Controller, {
|
|
32763
32775
|
control: control,
|
|
@@ -32766,11 +32778,11 @@ const NewApplication = () => {
|
|
|
32766
32778
|
validate: value => !!value || "Applicant Picture is required."
|
|
32767
32779
|
},
|
|
32768
32780
|
render: props => {
|
|
32769
|
-
var
|
|
32781
|
+
var _getFieldError11;
|
|
32770
32782
|
return /*#__PURE__*/React.createElement(ProfileImageUpload, {
|
|
32771
|
-
error: (
|
|
32783
|
+
error: (_getFieldError11 = getFieldError("applicant.UploadPicture")) === null || _getFieldError11 === void 0 ? void 0 : _getFieldError11.message,
|
|
32772
32784
|
isUploading: !!uploadingFields["applicant.UploadPicture"],
|
|
32773
|
-
label: "
|
|
32785
|
+
label: "WS_UPLOAD_PICTURE",
|
|
32774
32786
|
onUpload: event => uploadFile(event, "applicant.UploadPicture", props.onChange),
|
|
32775
32787
|
required: true,
|
|
32776
32788
|
t: t,
|
|
@@ -32779,7 +32791,7 @@ const NewApplication = () => {
|
|
|
32779
32791
|
}
|
|
32780
32792
|
}), /*#__PURE__*/React.createElement(FieldBlock, {
|
|
32781
32793
|
error: getFieldError("applicant.firstName"),
|
|
32782
|
-
label: "
|
|
32794
|
+
label: t("WS_FIRST_NAME"),
|
|
32783
32795
|
required: true
|
|
32784
32796
|
}, /*#__PURE__*/React.createElement(TextInput, {
|
|
32785
32797
|
errorStyle: !!getFieldError("applicant.firstName"),
|
|
@@ -32793,7 +32805,7 @@ const NewApplication = () => {
|
|
|
32793
32805
|
name: "applicant.firstName"
|
|
32794
32806
|
})), /*#__PURE__*/React.createElement(FieldBlock, {
|
|
32795
32807
|
error: getFieldError("applicant.middleName"),
|
|
32796
|
-
label: "
|
|
32808
|
+
label: t("WS_MIDDLE_NAME")
|
|
32797
32809
|
}, /*#__PURE__*/React.createElement(TextInput, {
|
|
32798
32810
|
errorStyle: !!getFieldError("applicant.middleName"),
|
|
32799
32811
|
inputRef: register({
|
|
@@ -32805,7 +32817,7 @@ const NewApplication = () => {
|
|
|
32805
32817
|
name: "applicant.middleName"
|
|
32806
32818
|
})), /*#__PURE__*/React.createElement(FieldBlock, {
|
|
32807
32819
|
error: getFieldError("applicant.lastName"),
|
|
32808
|
-
label: "
|
|
32820
|
+
label: t("WS_LAST_NAME"),
|
|
32809
32821
|
required: true
|
|
32810
32822
|
}, /*#__PURE__*/React.createElement(TextInput, {
|
|
32811
32823
|
errorStyle: !!getFieldError("applicant.lastName"),
|
|
@@ -32819,7 +32831,7 @@ const NewApplication = () => {
|
|
|
32819
32831
|
name: "applicant.lastName"
|
|
32820
32832
|
})), /*#__PURE__*/React.createElement(FieldBlock, {
|
|
32821
32833
|
error: getFieldError("useDetails.gender"),
|
|
32822
|
-
label: "
|
|
32834
|
+
label: t("WS_GENDER"),
|
|
32823
32835
|
required: true
|
|
32824
32836
|
}, /*#__PURE__*/React.createElement(Controller, {
|
|
32825
32837
|
control: control,
|
|
@@ -32830,19 +32842,21 @@ const NewApplication = () => {
|
|
|
32830
32842
|
render: props => /*#__PURE__*/React.createElement(Dropdown, {
|
|
32831
32843
|
option: [{
|
|
32832
32844
|
name: "Male",
|
|
32833
|
-
code: "MALE"
|
|
32845
|
+
code: "MALE",
|
|
32846
|
+
i18nKey: "MALE"
|
|
32834
32847
|
}, {
|
|
32835
32848
|
name: "Female",
|
|
32836
|
-
code: "FEMALE"
|
|
32849
|
+
code: "FEMALE",
|
|
32850
|
+
i18nKey: "FEMALE"
|
|
32837
32851
|
}],
|
|
32838
|
-
optionKey: "
|
|
32852
|
+
optionKey: "i18nKey",
|
|
32839
32853
|
selected: props.value,
|
|
32840
32854
|
select: props.onChange,
|
|
32841
32855
|
t: t
|
|
32842
32856
|
})
|
|
32843
32857
|
})), /*#__PURE__*/React.createElement(FieldBlock, {
|
|
32844
32858
|
error: getFieldError("applicant.ParentorSpouse"),
|
|
32845
|
-
label: "
|
|
32859
|
+
label: t("WS_PARENT_OR_SPOUSE"),
|
|
32846
32860
|
required: true
|
|
32847
32861
|
}, /*#__PURE__*/React.createElement(TextInput, {
|
|
32848
32862
|
errorStyle: !!getFieldError("applicant.ParentorSpouse"),
|
|
@@ -32856,7 +32870,7 @@ const NewApplication = () => {
|
|
|
32856
32870
|
name: "applicant.ParentorSpouse"
|
|
32857
32871
|
})), /*#__PURE__*/React.createElement(FieldBlock, {
|
|
32858
32872
|
error: getFieldError("contact.emailId"),
|
|
32859
|
-
label: "
|
|
32873
|
+
label: t("WS_EMAIL_ID"),
|
|
32860
32874
|
required: true
|
|
32861
32875
|
}, /*#__PURE__*/React.createElement(TextInput, {
|
|
32862
32876
|
errorStyle: !!getFieldError("contact.emailId"),
|
|
@@ -32870,7 +32884,7 @@ const NewApplication = () => {
|
|
|
32870
32884
|
name: "contact.emailId"
|
|
32871
32885
|
})), /*#__PURE__*/React.createElement(FieldBlock, {
|
|
32872
32886
|
error: getFieldError("contact.mobileNumber"),
|
|
32873
|
-
label: "
|
|
32887
|
+
label: t("WS_MOBILE_NUMBER"),
|
|
32874
32888
|
required: true
|
|
32875
32889
|
}, /*#__PURE__*/React.createElement(TextInput, {
|
|
32876
32890
|
errorStyle: !!getFieldError("contact.mobileNumber"),
|
|
@@ -32885,7 +32899,7 @@ const NewApplication = () => {
|
|
|
32885
32899
|
name: "contact.mobileNumber"
|
|
32886
32900
|
})), /*#__PURE__*/React.createElement(FieldBlock, {
|
|
32887
32901
|
error: getFieldError("contact.whatsAppNumber"),
|
|
32888
|
-
label: "
|
|
32902
|
+
label: t("WS_WHATS_APP_NUMBER")
|
|
32889
32903
|
}, /*#__PURE__*/React.createElement(TextInput, {
|
|
32890
32904
|
errorStyle: !!getFieldError("contact.whatsAppNumber"),
|
|
32891
32905
|
inputRef: register({
|
|
@@ -32897,25 +32911,25 @@ const NewApplication = () => {
|
|
|
32897
32911
|
maxlength: 10,
|
|
32898
32912
|
name: "contact.whatsAppNumber"
|
|
32899
32913
|
}))), /*#__PURE__*/React.createElement(SectionCard, {
|
|
32900
|
-
description: "
|
|
32914
|
+
description: t("WS_DJB_EMPLOYEE_DESC"),
|
|
32901
32915
|
isOpen: collapsedSections.employee,
|
|
32902
32916
|
onToggle: toggleSection,
|
|
32903
32917
|
sectionKey: "djbEmployee",
|
|
32904
|
-
title: "
|
|
32918
|
+
title: t("WS_DJB_EMPLOYEE"),
|
|
32905
32919
|
sectionRef: sectionRefs.djbEmployee
|
|
32906
32920
|
}, /*#__PURE__*/React.createElement(FieldBlock, {
|
|
32907
|
-
label: "
|
|
32921
|
+
label: t("WS_DJB_EMPLOYEE")
|
|
32908
32922
|
}, /*#__PURE__*/React.createElement(Controller, {
|
|
32909
32923
|
control: control,
|
|
32910
32924
|
name: "djbEmployee.isDjbEmployee",
|
|
32911
32925
|
render: props => /*#__PURE__*/React.createElement(CheckBox, {
|
|
32912
32926
|
checked: !!props.value,
|
|
32913
|
-
label: "
|
|
32927
|
+
label: t("WS_APPLICANT_IS_DJB_EMPLOYEE"),
|
|
32914
32928
|
onChange: event => props.onChange(event.target.checked)
|
|
32915
32929
|
})
|
|
32916
32930
|
})), isDjbEmployee && /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(FieldBlock, {
|
|
32917
32931
|
error: getFieldError("djbEmployee.employeeId"),
|
|
32918
|
-
label: "
|
|
32932
|
+
label: t("WS_EMPLOYEE_ID"),
|
|
32919
32933
|
required: isDjbEmployee
|
|
32920
32934
|
}, /*#__PURE__*/React.createElement(TextInput, {
|
|
32921
32935
|
errorStyle: !!getFieldError("djbEmployee.employeeId"),
|
|
@@ -32925,7 +32939,7 @@ const NewApplication = () => {
|
|
|
32925
32939
|
name: "djbEmployee.employeeId"
|
|
32926
32940
|
})), /*#__PURE__*/React.createElement(FieldBlock, {
|
|
32927
32941
|
error: getFieldError("djbEmployee.retirementDate"),
|
|
32928
|
-
label: "
|
|
32942
|
+
label: t("WS_DATE_OF_RETIREMENT"),
|
|
32929
32943
|
required: isDjbEmployee
|
|
32930
32944
|
}, /*#__PURE__*/React.createElement(Controller, {
|
|
32931
32945
|
control: control,
|
|
@@ -32940,7 +32954,7 @@ const NewApplication = () => {
|
|
|
32940
32954
|
})), /*#__PURE__*/React.createElement(FieldBlock, {
|
|
32941
32955
|
error: getFieldError("djbEmployee.officeNameAndAddress"),
|
|
32942
32956
|
isFullWidth: true,
|
|
32943
|
-
label: "
|
|
32957
|
+
label: t("WS_OFFICE_NAME_AND_ADDRESS"),
|
|
32944
32958
|
required: isDjbEmployee
|
|
32945
32959
|
}, /*#__PURE__*/React.createElement(TextArea, {
|
|
32946
32960
|
className: getFieldError("djbEmployee.officeNameAndAddress") ? "employee-card-input-error" : "",
|
|
@@ -32952,40 +32966,15 @@ const NewApplication = () => {
|
|
|
32952
32966
|
minHeight: "96px"
|
|
32953
32967
|
}
|
|
32954
32968
|
})))), /*#__PURE__*/React.createElement(SectionCard, {
|
|
32955
|
-
description: "
|
|
32969
|
+
description: t("WS_PROPERTY_ADDRESS_DESC"),
|
|
32956
32970
|
isOpen: collapsedSections.address,
|
|
32957
32971
|
onToggle: toggleSection,
|
|
32958
32972
|
sectionKey: "propertyAddress",
|
|
32959
|
-
title: "
|
|
32973
|
+
title: t("WS_PROPERTY_ADDRESS"),
|
|
32960
32974
|
sectionRef: sectionRefs.propertyAddress
|
|
32961
32975
|
}, /*#__PURE__*/React.createElement(FieldBlock, {
|
|
32962
|
-
error: getFieldError("propertyAddress.city"),
|
|
32963
|
-
label: "City"
|
|
32964
|
-
}, /*#__PURE__*/React.createElement(Controller, {
|
|
32965
|
-
control: control,
|
|
32966
|
-
name: "propertyAddress.city",
|
|
32967
|
-
render: props => /*#__PURE__*/React.createElement(Dropdown, {
|
|
32968
|
-
className: "form-field",
|
|
32969
|
-
selected: props.value || city,
|
|
32970
|
-
select: val => {
|
|
32971
|
-
setCity(val);
|
|
32972
|
-
props.onChange(val);
|
|
32973
|
-
},
|
|
32974
|
-
option: allCities,
|
|
32975
|
-
optionCardStyles: {
|
|
32976
|
-
overflowY: "auto",
|
|
32977
|
-
maxHeight: "300px"
|
|
32978
|
-
},
|
|
32979
|
-
optionKey: "i18nKey",
|
|
32980
|
-
t: t,
|
|
32981
|
-
style: {
|
|
32982
|
-
width: "100%"
|
|
32983
|
-
},
|
|
32984
|
-
placeholder: "Select"
|
|
32985
|
-
})
|
|
32986
|
-
})), /*#__PURE__*/React.createElement(FieldBlock, {
|
|
32987
32976
|
error: getFieldError("propertyAddress.pinCode"),
|
|
32988
|
-
label: "
|
|
32977
|
+
label: t("WS_PIN_CODE"),
|
|
32989
32978
|
required: true
|
|
32990
32979
|
}, /*#__PURE__*/React.createElement(Controller, {
|
|
32991
32980
|
control: control,
|
|
@@ -33015,7 +33004,7 @@ const NewApplication = () => {
|
|
|
33015
33004
|
})
|
|
33016
33005
|
})), /*#__PURE__*/React.createElement(FieldBlock, {
|
|
33017
33006
|
error: getFieldError("propertyAddress.locality"),
|
|
33018
|
-
label: "
|
|
33007
|
+
label: t("WS_LOCALITY"),
|
|
33019
33008
|
required: true
|
|
33020
33009
|
}, /*#__PURE__*/React.createElement(Controller, {
|
|
33021
33010
|
control: control,
|
|
@@ -33043,42 +33032,60 @@ const NewApplication = () => {
|
|
|
33043
33032
|
})
|
|
33044
33033
|
})), /*#__PURE__*/React.createElement(FieldBlock, {
|
|
33045
33034
|
error: getFieldError("propertyAddress.state"),
|
|
33046
|
-
label: "
|
|
33047
|
-
}, /*#__PURE__*/React.createElement(
|
|
33048
|
-
|
|
33049
|
-
|
|
33050
|
-
|
|
33035
|
+
label: t("WS_STATE")
|
|
33036
|
+
}, /*#__PURE__*/React.createElement(Controller, {
|
|
33037
|
+
control: control,
|
|
33038
|
+
name: "propertyAddress.city",
|
|
33039
|
+
render: props => /*#__PURE__*/React.createElement(Dropdown, {
|
|
33040
|
+
className: "form-field",
|
|
33041
|
+
selected: props.value || city,
|
|
33042
|
+
select: val => {
|
|
33043
|
+
setCity(val);
|
|
33044
|
+
props.onChange(val);
|
|
33045
|
+
},
|
|
33046
|
+
option: allCities,
|
|
33047
|
+
optionCardStyles: {
|
|
33048
|
+
overflowY: "auto",
|
|
33049
|
+
maxHeight: "300px"
|
|
33050
|
+
},
|
|
33051
|
+
optionKey: "i18nKey",
|
|
33052
|
+
t: t,
|
|
33053
|
+
style: {
|
|
33054
|
+
width: "100%"
|
|
33055
|
+
},
|
|
33056
|
+
placeholder: t("WS_SELECT")
|
|
33057
|
+
})
|
|
33051
33058
|
})), /*#__PURE__*/React.createElement(FieldBlock, {
|
|
33052
33059
|
error: getFieldError("propertyAddress.street"),
|
|
33053
|
-
label: "
|
|
33060
|
+
label: t("WS_STREET")
|
|
33054
33061
|
}, /*#__PURE__*/React.createElement(TextInput, {
|
|
33055
33062
|
errorStyle: !!getFieldError("propertyAddress.street"),
|
|
33056
33063
|
inputRef: register(),
|
|
33057
33064
|
name: "propertyAddress.street"
|
|
33058
33065
|
})), /*#__PURE__*/React.createElement(FieldBlock, {
|
|
33059
33066
|
error: getFieldError("propertyAddress.houseNo"),
|
|
33060
|
-
label: "
|
|
33067
|
+
label: t("WS_HOUSE_NO")
|
|
33061
33068
|
}, /*#__PURE__*/React.createElement(TextInput, {
|
|
33062
33069
|
errorStyle: !!getFieldError("propertyAddress.houseNo"),
|
|
33063
33070
|
inputRef: register(),
|
|
33064
33071
|
name: "propertyAddress.houseNo"
|
|
33065
33072
|
})), /*#__PURE__*/React.createElement(FieldBlock, {
|
|
33066
33073
|
error: getFieldError("propertyAddress.block"),
|
|
33067
|
-
label: "
|
|
33074
|
+
label: t("WS_BLOCK")
|
|
33068
33075
|
}, /*#__PURE__*/React.createElement(TextInput, {
|
|
33069
33076
|
errorStyle: !!getFieldError("propertyAddress.block"),
|
|
33070
33077
|
inputRef: register(),
|
|
33071
33078
|
name: "propertyAddress.block"
|
|
33072
33079
|
})), /*#__PURE__*/React.createElement(FieldBlock, {
|
|
33073
33080
|
error: getFieldError("propertyAddress.zone"),
|
|
33074
|
-
label: "
|
|
33081
|
+
label: t("WS_ZONE")
|
|
33075
33082
|
}, /*#__PURE__*/React.createElement(TextInput, {
|
|
33076
33083
|
errorStyle: !!getFieldError("propertyAddress.zone"),
|
|
33077
33084
|
inputRef: register(),
|
|
33078
33085
|
name: "propertyAddress.zone"
|
|
33079
33086
|
})), /*#__PURE__*/React.createElement(FieldBlock, {
|
|
33080
33087
|
error: getFieldError("propertyAddress.landmark"),
|
|
33081
|
-
label: "
|
|
33088
|
+
label: t("WS_LANDMARK")
|
|
33082
33089
|
}, /*#__PURE__*/React.createElement(TextInput, {
|
|
33083
33090
|
errorStyle: !!getFieldError("propertyAddress.landmark"),
|
|
33084
33091
|
inputRef: register(),
|
|
@@ -33086,7 +33093,7 @@ const NewApplication = () => {
|
|
|
33086
33093
|
})), /*#__PURE__*/React.createElement(FieldBlock, {
|
|
33087
33094
|
error: getFieldError("propertyAddress.address"),
|
|
33088
33095
|
isFullWidth: true,
|
|
33089
|
-
label: "
|
|
33096
|
+
label: t("WS_ADDRESS")
|
|
33090
33097
|
}, /*#__PURE__*/React.createElement(TextArea, {
|
|
33091
33098
|
className: getFieldError("propertyAddress.address") ? "employee-card-input-error" : "",
|
|
33092
33099
|
inputRef: register({
|
|
@@ -33097,15 +33104,15 @@ const NewApplication = () => {
|
|
|
33097
33104
|
minHeight: "96px"
|
|
33098
33105
|
}
|
|
33099
33106
|
}))), /*#__PURE__*/React.createElement(SectionCard, {
|
|
33100
|
-
description: "
|
|
33107
|
+
description: t("WS_USE_DETAILS_DESC"),
|
|
33101
33108
|
isOpen: collapsedSections.usage,
|
|
33102
33109
|
onToggle: toggleSection,
|
|
33103
33110
|
sectionKey: "useDetails",
|
|
33104
|
-
title: "
|
|
33111
|
+
title: t("WS_PROPERTY_AND_WATER_CONNECTION_USE_DETAILS"),
|
|
33105
33112
|
sectionRef: sectionRefs.useDetails
|
|
33106
33113
|
}, /*#__PURE__*/React.createElement(FieldBlock, {
|
|
33107
33114
|
error: getFieldError("useDetails.propertyType"),
|
|
33108
|
-
label: "
|
|
33115
|
+
label: t("WS_PROPERTY_TYPE"),
|
|
33109
33116
|
required: true
|
|
33110
33117
|
}, /*#__PURE__*/React.createElement(Controller, {
|
|
33111
33118
|
control: control,
|
|
@@ -33122,7 +33129,7 @@ const NewApplication = () => {
|
|
|
33122
33129
|
})
|
|
33123
33130
|
})), /*#__PURE__*/React.createElement(FieldBlock, {
|
|
33124
33131
|
error: getFieldError("useDetails.plotArea"),
|
|
33125
|
-
label: "
|
|
33132
|
+
label: t("WS_PLOT_AREA"),
|
|
33126
33133
|
required: true
|
|
33127
33134
|
}, /*#__PURE__*/React.createElement(TextInput, {
|
|
33128
33135
|
errorStyle: !!getFieldError("useDetails.plotArea"),
|
|
@@ -33136,7 +33143,7 @@ const NewApplication = () => {
|
|
|
33136
33143
|
name: "useDetails.plotArea"
|
|
33137
33144
|
})), /*#__PURE__*/React.createElement(FieldBlock, {
|
|
33138
33145
|
error: getFieldError("useDetails.builtUpArea"),
|
|
33139
|
-
label: "
|
|
33146
|
+
label: t("WS_BUILT_UP_AREA"),
|
|
33140
33147
|
required: true
|
|
33141
33148
|
}, /*#__PURE__*/React.createElement(TextInput, {
|
|
33142
33149
|
errorStyle: !!getFieldError("useDetails.builtUpArea"),
|
|
@@ -33150,7 +33157,7 @@ const NewApplication = () => {
|
|
|
33150
33157
|
name: "useDetails.builtUpArea"
|
|
33151
33158
|
})), /*#__PURE__*/React.createElement(FieldBlock, {
|
|
33152
33159
|
error: getFieldError("useDetails.noOfFloors"),
|
|
33153
|
-
label: "
|
|
33160
|
+
label: t("WS_NUMBER_OF_FLOORS"),
|
|
33154
33161
|
required: true
|
|
33155
33162
|
}, /*#__PURE__*/React.createElement(TextInput, {
|
|
33156
33163
|
errorStyle: !!getFieldError("useDetails.noOfFloors"),
|
|
@@ -33164,7 +33171,7 @@ const NewApplication = () => {
|
|
|
33164
33171
|
name: "useDetails.noOfFloors"
|
|
33165
33172
|
})), /*#__PURE__*/React.createElement(FieldBlock, {
|
|
33166
33173
|
error: getFieldError("useDetails.NumberofDwellingUnits"),
|
|
33167
|
-
label: "
|
|
33174
|
+
label: t("WS_NUMBER_OF_DWELLING_UNITS"),
|
|
33168
33175
|
required: true
|
|
33169
33176
|
}, /*#__PURE__*/React.createElement(TextInput, {
|
|
33170
33177
|
errorStyle: !!getFieldError("useDetails.NumberofDwellingUnits"),
|
|
@@ -33178,7 +33185,7 @@ const NewApplication = () => {
|
|
|
33178
33185
|
name: "useDetails.NumberofDwellingUnits"
|
|
33179
33186
|
})), isHospitalProperty ? /*#__PURE__*/React.createElement(FieldBlock, {
|
|
33180
33187
|
error: getFieldError("useDetails.hospitalBeds"),
|
|
33181
|
-
label: "
|
|
33188
|
+
label: t("WS_NUMBER_OF_BEDS"),
|
|
33182
33189
|
required: true
|
|
33183
33190
|
}, /*#__PURE__*/React.createElement(TextInput, {
|
|
33184
33191
|
errorStyle: !!getFieldError("useDetails.hospitalBeds"),
|
|
@@ -33192,7 +33199,7 @@ const NewApplication = () => {
|
|
|
33192
33199
|
name: "useDetails.hospitalBeds"
|
|
33193
33200
|
})) : null, /*#__PURE__*/React.createElement(FieldBlock, {
|
|
33194
33201
|
error: getFieldError("useDetails.SelectYearofConstruction"),
|
|
33195
|
-
label: "
|
|
33202
|
+
label: t("WS_SELECT_YEAR_OF_CONSTRUCTION"),
|
|
33196
33203
|
required: true
|
|
33197
33204
|
}, /*#__PURE__*/React.createElement(Controller, {
|
|
33198
33205
|
control: control,
|
|
@@ -33209,7 +33216,7 @@ const NewApplication = () => {
|
|
|
33209
33216
|
})
|
|
33210
33217
|
})), /*#__PURE__*/React.createElement(FieldBlock, {
|
|
33211
33218
|
error: getFieldError("useDetails.WaterConnectionUsageType"),
|
|
33212
|
-
label: "
|
|
33219
|
+
label: t("WS_WATER_CONNECTION_USAGE_TYPE"),
|
|
33213
33220
|
required: true
|
|
33214
33221
|
}, /*#__PURE__*/React.createElement(Controller, {
|
|
33215
33222
|
control: control,
|
|
@@ -33428,7 +33435,7 @@ const NewApplication = () => {
|
|
|
33428
33435
|
error: getFieldError("propertyAddress.otherDocument")
|
|
33429
33436
|
}), /*#__PURE__*/React.createElement(FieldBlock, {
|
|
33430
33437
|
error: getFieldError("declaration.submittedBy"),
|
|
33431
|
-
label: "Submitted By
|
|
33438
|
+
label: "Submitted By",
|
|
33432
33439
|
required: true
|
|
33433
33440
|
}, /*#__PURE__*/React.createElement(Controller, {
|
|
33434
33441
|
control: control,
|
|
@@ -40644,7 +40651,7 @@ const ApplicationDetails = props => {
|
|
|
40644
40651
|
};
|
|
40645
40652
|
|
|
40646
40653
|
const ApplicationDetails$1 = () => {
|
|
40647
|
-
var _mdmsCommonmastersDat, _commonPayInfo, _applicationDetails$p4, _applicationDetails$p5, _applicationDetails$p6, _applicationDetails$p7, _applicationDetails$a3, _applicationDetails$a4, _applicationDetails$a5, _newValueFilter$, _applicationDetails$
|
|
40654
|
+
var _mdmsCommonmastersDat, _commonPayInfo, _applicationDetails$p4, _applicationDetails$p5, _applicationDetails$p6, _applicationDetails$p7, _applicationDetails$a3, _applicationDetails$a4, _applicationDetails$a5, _newValueFilter$, _applicationDetails$a23, _workflowDetails$data, _workflowDetails$data2, _workflowDetails$data3, _workflowDetails$data4, _workflowDetails$data5, _workflowDetails$data6, _workflowDetails$data7, _workflowDetails$data8, _workflowDetails$data9, _workflowDetails$data0, _workflowDetails$data1, _workflowDetails$data10, _workflowDetails$data11, _workflowDetails$data12, _workflowDetails$data13, _workflowDetails$data14, _workflowDetails$data15, _workflowDetails$data16, _workflowDetails$data17, _workflowDetails$data18, _workflowDetails$data21, _workflowDetails$data22, _workflowDetails$data23, _workflowDetails$data24, _workflowDetails$data25, _workflowDetails$data26, _workflowDetails$data27, _workflowDetails$data28, _workflowDetails$data29, _workflowDetails$data30, _workflowDetails$data37, _workflowDetails$data38, _workflowDetails$data39, _oldData$WaterConnect, _oldData$WaterConnect2, _oldData$SewerageConn, _oldData$SewerageConn2, _applicationDetails$a34, _applicationDetails$a35, _reciept_data2, _reciept_data2$Paymen, _applicationDetails$p15, _applicationDetails$p16, _applicationDetails$p17, _applicationDetails$p18, _applicationDetails$p19, _applicationDetails$p20;
|
|
40648
40655
|
const {
|
|
40649
40656
|
t
|
|
40650
40657
|
} = useTranslation();
|
|
@@ -40756,23 +40763,21 @@ const ApplicationDetails$1 = () => {
|
|
|
40756
40763
|
if ((applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$p8 = applicationDetails.processInstancesDetails) === null || _applicationDetails$p8 === void 0 ? void 0 : (_applicationDetails$p9 = _applicationDetails$p8[0]) === null || _applicationDetails$p9 === void 0 ? void 0 : _applicationDetails$p9.businessService) === "WSReconnection" || (applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$p0 = applicationDetails.processInstancesDetails) === null || _applicationDetails$p0 === void 0 ? void 0 : (_applicationDetails$p1 = _applicationDetails$p0[0]) === null || _applicationDetails$p1 === void 0 ? void 0 : _applicationDetails$p1.businessService) === "SWReconnection") {
|
|
40757
40764
|
return true;
|
|
40758
40765
|
} else {
|
|
40759
|
-
var _applicationDetails$a6, _applicationDetails$a7, _applicationDetails$a8, _applicationDetails$a9, _applicationDetails$a0, _applicationDetails$a1, _applicationDetails$a10, _applicationDetails$a11, _applicationDetails$a12, _applicationDetails$a13, _applicationDetails$a14, _applicationDetails$a15, _applicationDetails$a16;
|
|
40760
|
-
const connectionType = applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$a6 = applicationDetails.applicationData) === null || _applicationDetails$a6 === void 0 ? void 0 : _applicationDetails$a6.connectionType;
|
|
40761
|
-
const noOfTaps = (applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$
|
|
40762
|
-
const pipeSize = (applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$
|
|
40763
|
-
const waterSource = applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$
|
|
40764
|
-
const noOfWaterClosets = (applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$
|
|
40765
|
-
const noOfToilets = (applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$
|
|
40766
|
-
|
|
40767
|
-
const roadCuttingInfo = applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$a16 = applicationDetails.applicationData) === null || _applicationDetails$a16 === void 0 ? void 0 : _applicationDetails$a16.roadCuttingInfo;
|
|
40768
|
-
if (!connectionType || !(noOfTaps && pipeSize && waterSource || noOfWaterClosets && noOfToilets) || !plumberDetails || !roadCuttingInfo) {
|
|
40766
|
+
var _applicationDetails$a6, _applicationDetails$a7, _applicationDetails$a8, _applicationDetails$a9, _applicationDetails$a0, _applicationDetails$a1, _applicationDetails$a10, _applicationDetails$a11, _applicationDetails$a12, _applicationDetails$a13, _applicationDetails$a14, _applicationDetails$a15, _applicationDetails$a16, _applicationDetails$a17, _applicationDetails$a18, _applicationDetails$a19;
|
|
40767
|
+
const connectionType = (applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$a6 = applicationDetails.applicationData) === null || _applicationDetails$a6 === void 0 ? void 0 : _applicationDetails$a6.connectionType) || (applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$a7 = applicationDetails.applicationData) === null || _applicationDetails$a7 === void 0 ? void 0 : (_applicationDetails$a8 = _applicationDetails$a7.additionalDetails) === null || _applicationDetails$a8 === void 0 ? void 0 : _applicationDetails$a8.connectionType);
|
|
40768
|
+
const noOfTaps = ((applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$a9 = applicationDetails.applicationData) === null || _applicationDetails$a9 === void 0 ? void 0 : _applicationDetails$a9.noOfTaps) === 0 ? null : applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$a0 = applicationDetails.applicationData) === null || _applicationDetails$a0 === void 0 ? void 0 : _applicationDetails$a0.noOfTaps) || (applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$a1 = applicationDetails.applicationData) === null || _applicationDetails$a1 === void 0 ? void 0 : _applicationDetails$a1.proposedTaps);
|
|
40769
|
+
const pipeSize = ((applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$a10 = applicationDetails.applicationData) === null || _applicationDetails$a10 === void 0 ? void 0 : _applicationDetails$a10.pipeSize) === 0 ? null : applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$a11 = applicationDetails.applicationData) === null || _applicationDetails$a11 === void 0 ? void 0 : _applicationDetails$a11.pipeSize) || (applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$a12 = applicationDetails.applicationData) === null || _applicationDetails$a12 === void 0 ? void 0 : _applicationDetails$a12.proposedPipeSize);
|
|
40770
|
+
const waterSource = applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$a13 = applicationDetails.applicationData) === null || _applicationDetails$a13 === void 0 ? void 0 : _applicationDetails$a13.waterSource;
|
|
40771
|
+
const noOfWaterClosets = ((applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$a14 = applicationDetails.applicationData) === null || _applicationDetails$a14 === void 0 ? void 0 : _applicationDetails$a14.noOfWaterClosets) === 0 ? null : applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$a15 = applicationDetails.applicationData) === null || _applicationDetails$a15 === void 0 ? void 0 : _applicationDetails$a15.noOfWaterClosets) || (applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$a16 = applicationDetails.applicationData) === null || _applicationDetails$a16 === void 0 ? void 0 : _applicationDetails$a16.proposedWaterClosets);
|
|
40772
|
+
const noOfToilets = ((applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$a17 = applicationDetails.applicationData) === null || _applicationDetails$a17 === void 0 ? void 0 : _applicationDetails$a17.noOfToilets) === 0 ? null : applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$a18 = applicationDetails.applicationData) === null || _applicationDetails$a18 === void 0 ? void 0 : _applicationDetails$a18.noOfToilets) || (applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$a19 = applicationDetails.applicationData) === null || _applicationDetails$a19 === void 0 ? void 0 : _applicationDetails$a19.proposedToilets);
|
|
40773
|
+
if (!connectionType || !(noOfTaps && pipeSize && waterSource || noOfWaterClosets && noOfToilets)) {
|
|
40769
40774
|
return false;
|
|
40770
40775
|
}
|
|
40771
40776
|
return true;
|
|
40772
40777
|
}
|
|
40773
40778
|
};
|
|
40774
40779
|
let dowloadOptions = [],
|
|
40775
|
-
appStatus = (applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$
|
|
40780
|
+
appStatus = (applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$a23 = applicationDetails.applicationData) === null || _applicationDetails$a23 === void 0 ? void 0 : _applicationDetails$a23.applicationStatus) || "";
|
|
40776
40781
|
workflowDetails === null || workflowDetails === void 0 ? void 0 : (_workflowDetails$data = workflowDetails.data) === null || _workflowDetails$data === void 0 ? void 0 : (_workflowDetails$data2 = _workflowDetails$data.actionState) === null || _workflowDetails$data2 === void 0 ? void 0 : (_workflowDetails$data3 = _workflowDetails$data2.nextActions) === null || _workflowDetails$data3 === void 0 ? void 0 : _workflowDetails$data3.forEach(action => {
|
|
40777
40782
|
if ((action === null || action === void 0 ? void 0 : action.action) === "ACTIVATE_CONNECTION") {
|
|
40778
40783
|
action.redirectionUrll = {
|
|
@@ -40902,10 +40907,10 @@ const ApplicationDetails$1 = () => {
|
|
|
40902
40907
|
});
|
|
40903
40908
|
const oldApplication = serviceType === "WATER" ? oldData === null || oldData === void 0 ? void 0 : (_oldData$WaterConnect = oldData.WaterConnection) === null || _oldData$WaterConnect === void 0 ? void 0 : _oldData$WaterConnect[(oldData === null || oldData === void 0 ? void 0 : (_oldData$WaterConnect2 = oldData.WaterConnection) === null || _oldData$WaterConnect2 === void 0 ? void 0 : _oldData$WaterConnect2.length) - 1] : oldData === null || oldData === void 0 ? void 0 : (_oldData$SewerageConn = oldData.SewerageConnections) === null || _oldData$SewerageConn === void 0 ? void 0 : _oldData$SewerageConn[(oldData === null || oldData === void 0 ? void 0 : (_oldData$SewerageConn2 = oldData.SewerageConnections) === null || _oldData$SewerageConn2 === void 0 ? void 0 : _oldData$SewerageConn2.length) - 1];
|
|
40904
40909
|
const handleDownloadPdf = async () => {
|
|
40905
|
-
var _applicationDetails$
|
|
40906
|
-
const tenantInfo = applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$
|
|
40910
|
+
var _applicationDetails$a24, _applicationDetails$a25, _applicationDetails$a26;
|
|
40911
|
+
const tenantInfo = applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$a24 = applicationDetails.applicationData) === null || _applicationDetails$a24 === void 0 ? void 0 : _applicationDetails$a24.tenantId;
|
|
40907
40912
|
let result = applicationDetails === null || applicationDetails === void 0 ? void 0 : applicationDetails.applicationData;
|
|
40908
|
-
if (applicationDetails !== null && applicationDetails !== void 0 && (_applicationDetails$
|
|
40913
|
+
if (applicationDetails !== null && applicationDetails !== void 0 && (_applicationDetails$a25 = applicationDetails.applicationData) !== null && _applicationDetails$a25 !== void 0 && (_applicationDetails$a26 = _applicationDetails$a25.applicationType) !== null && _applicationDetails$a26 !== void 0 && _applicationDetails$a26.includes("MODIFY_")) {
|
|
40909
40914
|
const _PDFdata = getWSAcknowledgementData$1({
|
|
40910
40915
|
...result
|
|
40911
40916
|
}, {
|
|
@@ -40945,10 +40950,10 @@ const ApplicationDetails$1 = () => {
|
|
|
40945
40950
|
}
|
|
40946
40951
|
}
|
|
40947
40952
|
const handleEstimateDownload = async () => {
|
|
40948
|
-
var _applicationDetails$
|
|
40949
|
-
if (applicationDetails !== null && applicationDetails !== void 0 && (_applicationDetails$
|
|
40950
|
-
var _applicationDetails$
|
|
40951
|
-
getFiles([applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$
|
|
40953
|
+
var _applicationDetails$a27, _applicationDetails$a28;
|
|
40954
|
+
if (applicationDetails !== null && applicationDetails !== void 0 && (_applicationDetails$a27 = applicationDetails.applicationData) !== null && _applicationDetails$a27 !== void 0 && (_applicationDetails$a28 = _applicationDetails$a27.additionalDetails) !== null && _applicationDetails$a28 !== void 0 && _applicationDetails$a28.estimationFileStoreId) {
|
|
40955
|
+
var _applicationDetails$a29, _applicationDetails$a30;
|
|
40956
|
+
getFiles([applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$a29 = applicationDetails.applicationData) === null || _applicationDetails$a29 === void 0 ? void 0 : (_applicationDetails$a30 = _applicationDetails$a29.additionalDetails) === null || _applicationDetails$a30 === void 0 ? void 0 : _applicationDetails$a30.estimationFileStoreId], applicationDetails === null || applicationDetails === void 0 ? void 0 : applicationDetails.tenantId);
|
|
40952
40957
|
} else {
|
|
40953
40958
|
const warningCount = sessionStorage.getItem("WARINIG_COUNT") || "0";
|
|
40954
40959
|
const warningCountDetails = JSON.parse(warningCount);
|
|
@@ -40999,8 +41004,8 @@ const ApplicationDetails$1 = () => {
|
|
|
40999
41004
|
order: 2,
|
|
41000
41005
|
label: t("WS_SANCTION_LETTER"),
|
|
41001
41006
|
onClick: () => {
|
|
41002
|
-
var _applicationDetails$
|
|
41003
|
-
return getFiles([applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$
|
|
41007
|
+
var _applicationDetails$a31, _applicationDetails$a32;
|
|
41008
|
+
return getFiles([applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$a31 = applicationDetails.applicationData) === null || _applicationDetails$a31 === void 0 ? void 0 : (_applicationDetails$a32 = _applicationDetails$a31.additionalDetails) === null || _applicationDetails$a32 === void 0 ? void 0 : _applicationDetails$a32.sanctionFileStoreId], applicationDetails === null || applicationDetails === void 0 ? void 0 : applicationDetails.tenantId);
|
|
41004
41009
|
}
|
|
41005
41010
|
};
|
|
41006
41011
|
const applicationDownloadObject = {
|
|
@@ -41012,8 +41017,8 @@ const ApplicationDetails$1 = () => {
|
|
|
41012
41017
|
order: 4,
|
|
41013
41018
|
label: t("DOWNLOAD_RECEIPT_HEADER"),
|
|
41014
41019
|
onClick: () => {
|
|
41015
|
-
var _reciept_data, _reciept_data$Payment, _applicationDetails$
|
|
41016
|
-
return getRecieptSearch(Digit.ULBService.getStateId(), (_reciept_data = reciept_data) === null || _reciept_data === void 0 ? void 0 : (_reciept_data$Payment = _reciept_data.Payments) === null || _reciept_data$Payment === void 0 ? void 0 : _reciept_data$Payment[0], applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$
|
|
41020
|
+
var _reciept_data, _reciept_data$Payment, _applicationDetails$a33;
|
|
41021
|
+
return getRecieptSearch(Digit.ULBService.getStateId(), (_reciept_data = reciept_data) === null || _reciept_data === void 0 ? void 0 : (_reciept_data$Payment = _reciept_data.Payments) === null || _reciept_data$Payment === void 0 ? void 0 : _reciept_data$Payment[0], applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$a33 = applicationDetails.applicationData) === null || _applicationDetails$a33 === void 0 ? void 0 : _applicationDetails$a33.applicationNo, receiptKey);
|
|
41017
41022
|
}
|
|
41018
41023
|
};
|
|
41019
41024
|
switch (appStatus) {
|
|
@@ -41028,7 +41033,7 @@ const ApplicationDetails$1 = () => {
|
|
|
41028
41033
|
break;
|
|
41029
41034
|
case "PENDING_FOR_CONNECTION_ACTIVATION":
|
|
41030
41035
|
case "CONNECTION_ACTIVATED":
|
|
41031
|
-
if (applicationDetails !== null && applicationDetails !== void 0 && (_applicationDetails$
|
|
41036
|
+
if (applicationDetails !== null && applicationDetails !== void 0 && (_applicationDetails$a34 = applicationDetails.applicationData) !== null && _applicationDetails$a34 !== void 0 && (_applicationDetails$a35 = _applicationDetails$a34.applicationType) !== null && _applicationDetails$a35 !== void 0 && _applicationDetails$a35.includes("NEW_") && ((_reciept_data2 = reciept_data) === null || _reciept_data2 === void 0 ? void 0 : (_reciept_data2$Paymen = _reciept_data2.Payments) === null || _reciept_data2$Paymen === void 0 ? void 0 : _reciept_data2$Paymen.length) > 0) dowloadOptions = [sanctionDownloadObject, wsEstimateDownloadObject, applicationDownloadObject, appFeeDownloadReceipt];else dowloadOptions = [sanctionDownloadObject, wsEstimateDownloadObject, applicationDownloadObject];
|
|
41032
41037
|
break;
|
|
41033
41038
|
case "REJECTED":
|
|
41034
41039
|
dowloadOptions = [applicationDownloadObject];
|
|
@@ -43362,6 +43367,7 @@ const WSEditApplicationByConfig = () => {
|
|
|
43362
43367
|
enabled: propertyId && propertyId != "" ? true : false,
|
|
43363
43368
|
privacy: Digit.Utils.getPrivacyObject()
|
|
43364
43369
|
});
|
|
43370
|
+
console.log(propertyDetails, "y78u");
|
|
43365
43371
|
useEffect(() => {
|
|
43366
43372
|
if (!isConfigLoading) {
|
|
43367
43373
|
var _config$body;
|
|
@@ -44821,6 +44827,323 @@ const BulkBillGeneration = ({
|
|
|
44821
44827
|
}));
|
|
44822
44828
|
};
|
|
44823
44829
|
|
|
44830
|
+
const OLDApplication = () => {
|
|
44831
|
+
const {
|
|
44832
|
+
t
|
|
44833
|
+
} = useTranslation();
|
|
44834
|
+
const {
|
|
44835
|
+
state
|
|
44836
|
+
} = useLocation();
|
|
44837
|
+
const history = useHistory();
|
|
44838
|
+
let filters = getQueryStringParams(location.search);
|
|
44839
|
+
const [canSubmit, setSubmitValve] = useState(false);
|
|
44840
|
+
const [isEnableLoader, setIsEnableLoader] = useState(false);
|
|
44841
|
+
const [showToast, setShowToast] = useState(null);
|
|
44842
|
+
const [appDetails, setAppDetails] = useState({});
|
|
44843
|
+
const [waterAndSewerageBoth, setWaterAndSewerageBoth] = useState(null);
|
|
44844
|
+
const [config, setConfig] = useState({
|
|
44845
|
+
head: "",
|
|
44846
|
+
body: []
|
|
44847
|
+
});
|
|
44848
|
+
let tenantId = Digit.ULBService.getCurrentTenantId();
|
|
44849
|
+
if (!tenantId) {
|
|
44850
|
+
var _Digit$SessionStorage;
|
|
44851
|
+
tenantId = (_Digit$SessionStorage = Digit.SessionStorage.get("CITIZEN.COMMON.HOME.CITY")) === null || _Digit$SessionStorage === void 0 ? void 0 : _Digit$SessionStorage.code;
|
|
44852
|
+
}
|
|
44853
|
+
const stateId = Digit.ULBService.getStateId();
|
|
44854
|
+
let {
|
|
44855
|
+
data: newConfig,
|
|
44856
|
+
isLoading
|
|
44857
|
+
} = Digit.Hooks.ws.useWSConfigMDMS.WSCreateConfig(stateId, {});
|
|
44858
|
+
const [propertyId, setPropertyId] = useState(new URLSearchParams(useLocation().search).get("propertyId"));
|
|
44859
|
+
const [sessionFormData, setSessionFormData, clearSessionFormData] = Digit.Hooks.useSessionStorage("PT_CREATE_EMP_WS_NEW_FORM", {});
|
|
44860
|
+
const {
|
|
44861
|
+
data: propertyDetails
|
|
44862
|
+
} = Digit.Hooks.pt.usePropertySearch({
|
|
44863
|
+
filters: {
|
|
44864
|
+
propertyIds: propertyId
|
|
44865
|
+
},
|
|
44866
|
+
tenantId: tenantId
|
|
44867
|
+
}, {
|
|
44868
|
+
filters: {
|
|
44869
|
+
propertyIds: propertyId
|
|
44870
|
+
},
|
|
44871
|
+
tenantId: tenantId,
|
|
44872
|
+
enabled: propertyId && propertyId != "" ? true : false
|
|
44873
|
+
});
|
|
44874
|
+
useEffect(() => {
|
|
44875
|
+
sessionStorage.removeItem("FORMSTATE_ERRORS");
|
|
44876
|
+
}, []);
|
|
44877
|
+
useEffect(() => {
|
|
44878
|
+
console.log("[WS] useEffect newConfig triggered", {
|
|
44879
|
+
isLoading,
|
|
44880
|
+
newConfig
|
|
44881
|
+
});
|
|
44882
|
+
if (!isLoading && newConfig) {
|
|
44883
|
+
const config = newConfig.find(conf => conf.hideInCitizen && conf.isCreate);
|
|
44884
|
+
console.log("[WS] found config", config);
|
|
44885
|
+
if (config) {
|
|
44886
|
+
var _config$body;
|
|
44887
|
+
config.head = "WS_APP_FOR_WATER_AND_SEWERAGE_LABEL";
|
|
44888
|
+
const allCreateSections = (config === null || config === void 0 ? void 0 : (_config$body = config.body) === null || _config$body === void 0 ? void 0 : _config$body.filter(section => section === null || section === void 0 ? void 0 : section.isCreateConnection)) || [];
|
|
44889
|
+
console.log("[WS] allCreateSections", allCreateSections);
|
|
44890
|
+
const desiredComponentOrder = ["CPTPropertySearchNSummary", "WSConnectionHolderDetails", "WSConnectionDetails", "WSDocumentsEmployee"];
|
|
44891
|
+
const reorderedBody = [];
|
|
44892
|
+
desiredComponentOrder.forEach(compName => {
|
|
44893
|
+
const section = allCreateSections.find(s => {
|
|
44894
|
+
var _s$body, _s$body$;
|
|
44895
|
+
const bodyComp = (_s$body = s.body) === null || _s$body === void 0 ? void 0 : (_s$body$ = _s$body[0]) === null || _s$body$ === void 0 ? void 0 : _s$body$.component;
|
|
44896
|
+
return bodyComp === compName || compName === "WSConnectionDetails" && bodyComp === "WSConnectionDetails";
|
|
44897
|
+
});
|
|
44898
|
+
if (section) {
|
|
44899
|
+
if (compName === "CPTPropertySearchNSummary") section.head = "WS_COMMON_PROPERTY_DETAILS";
|
|
44900
|
+
if (compName === "WSConnectionHolderDetails") section.head = "WS_COMMON_CONNECTION_HOLDER_DETAILS_HEADER";
|
|
44901
|
+
if (compName === "WSConnectionDetails") section.head = "WS_COMMON_CONNECTION_DETAIL";
|
|
44902
|
+
if (compName === "WSDocumentsEmployee") section.head = "WS_COMMON_DOCS";
|
|
44903
|
+
reorderedBody.push(section);
|
|
44904
|
+
} else {
|
|
44905
|
+
console.warn(`[WS] section for component ${compName} not found in allCreateSections`);
|
|
44906
|
+
}
|
|
44907
|
+
});
|
|
44908
|
+
allCreateSections.forEach(section => {
|
|
44909
|
+
var _section$body, _section$body$;
|
|
44910
|
+
const bodyComp = (_section$body = section.body) === null || _section$body === void 0 ? void 0 : (_section$body$ = _section$body[0]) === null || _section$body$ === void 0 ? void 0 : _section$body$.component;
|
|
44911
|
+
if (!reorderedBody.find(r => {
|
|
44912
|
+
var _r$body, _r$body$;
|
|
44913
|
+
return ((_r$body = r.body) === null || _r$body === void 0 ? void 0 : (_r$body$ = _r$body[0]) === null || _r$body$ === void 0 ? void 0 : _r$body$.component) === bodyComp;
|
|
44914
|
+
})) {
|
|
44915
|
+
reorderedBody.push(section);
|
|
44916
|
+
}
|
|
44917
|
+
});
|
|
44918
|
+
console.log("[WS] reorderedBody", reorderedBody);
|
|
44919
|
+
config.body = reorderedBody;
|
|
44920
|
+
setConfig(config);
|
|
44921
|
+
}
|
|
44922
|
+
}
|
|
44923
|
+
}, [newConfig, isLoading]);
|
|
44924
|
+
useEffect(() => {
|
|
44925
|
+
var _sessionFormData$cpt, _sessionFormData$cpt$, _sessionFormData$cpt2, _sessionFormData$cpt3;
|
|
44926
|
+
!propertyId && (sessionFormData === null || sessionFormData === void 0 ? void 0 : (_sessionFormData$cpt = sessionFormData.cpt) === null || _sessionFormData$cpt === void 0 ? void 0 : (_sessionFormData$cpt$ = _sessionFormData$cpt.details) === null || _sessionFormData$cpt$ === void 0 ? void 0 : _sessionFormData$cpt$.propertyId) && setPropertyId(sessionFormData === null || sessionFormData === void 0 ? void 0 : (_sessionFormData$cpt2 = sessionFormData.cpt) === null || _sessionFormData$cpt2 === void 0 ? void 0 : (_sessionFormData$cpt3 = _sessionFormData$cpt2.details) === null || _sessionFormData$cpt3 === void 0 ? void 0 : _sessionFormData$cpt3.propertyId);
|
|
44927
|
+
}, [sessionFormData === null || sessionFormData === void 0 ? void 0 : sessionFormData.cpt]);
|
|
44928
|
+
useEffect(() => {
|
|
44929
|
+
var _propertyDetails$Prop;
|
|
44930
|
+
setSessionFormData({
|
|
44931
|
+
...sessionFormData,
|
|
44932
|
+
cpt: {
|
|
44933
|
+
details: propertyDetails === null || propertyDetails === void 0 ? void 0 : (_propertyDetails$Prop = propertyDetails.Properties) === null || _propertyDetails$Prop === void 0 ? void 0 : _propertyDetails$Prop[0]
|
|
44934
|
+
}
|
|
44935
|
+
});
|
|
44936
|
+
}, [propertyDetails]);
|
|
44937
|
+
const {
|
|
44938
|
+
isLoading: creatingWaterApplicationLoading,
|
|
44939
|
+
isError: createWaterApplicationError,
|
|
44940
|
+
data: createWaterResponse,
|
|
44941
|
+
error: createWaterError,
|
|
44942
|
+
mutate: waterMutation
|
|
44943
|
+
} = Digit.Hooks.ws.useWaterCreateAPI("WATER");
|
|
44944
|
+
const {
|
|
44945
|
+
isLoading: updatingWaterApplicationLoading,
|
|
44946
|
+
isError: updateWaterApplicationError,
|
|
44947
|
+
data: updateWaterResponse,
|
|
44948
|
+
error: updateWaterError,
|
|
44949
|
+
mutate: waterUpdateMutation
|
|
44950
|
+
} = Digit.Hooks.ws.useWSApplicationActions("WATER");
|
|
44951
|
+
const {
|
|
44952
|
+
isLoading: creatingSewerageApplicationLoading,
|
|
44953
|
+
isError: createSewerageApplicationError,
|
|
44954
|
+
data: createSewerageResponse,
|
|
44955
|
+
error: createSewerageError,
|
|
44956
|
+
mutate: sewerageMutation
|
|
44957
|
+
} = Digit.Hooks.ws.useWaterCreateAPI("SEWERAGE");
|
|
44958
|
+
const {
|
|
44959
|
+
isLoading: updatingSewerageApplicationLoading,
|
|
44960
|
+
isError: updateSewerageApplicationError,
|
|
44961
|
+
data: updateSewerageResponse,
|
|
44962
|
+
error: updateSewerageError,
|
|
44963
|
+
mutate: sewerageUpdateMutation
|
|
44964
|
+
} = Digit.Hooks.ws.useWSApplicationActions("SEWERAGE");
|
|
44965
|
+
const onFormValueChange = (setValue, formData, formState) => {
|
|
44966
|
+
var _formState$errors, _formState$errors$Con, _Object$keys, _formState$errors2, _formState$errors2$Co;
|
|
44967
|
+
if (!lodash.isEqual(sessionFormData, formData)) {
|
|
44968
|
+
setSessionFormData({
|
|
44969
|
+
...sessionFormData,
|
|
44970
|
+
...formData
|
|
44971
|
+
});
|
|
44972
|
+
sessionStorage.setItem("FORMSTATE_ERRORS", JSON.stringify(formState === null || formState === void 0 ? void 0 : formState.errors));
|
|
44973
|
+
}
|
|
44974
|
+
if (Object.keys(formState.errors).length > 0 && Object.keys(formState.errors).length == 1 && formState !== null && formState !== void 0 && (_formState$errors = formState.errors) !== null && _formState$errors !== void 0 && (_formState$errors$Con = _formState$errors["ConnectionHolderDetails"]) !== null && _formState$errors$Con !== void 0 && _formState$errors$Con.type && ((_Object$keys = Object.keys(formState === null || formState === void 0 ? void 0 : (_formState$errors2 = formState.errors) === null || _formState$errors2 === void 0 ? void 0 : (_formState$errors2$Co = _formState$errors2["ConnectionHolderDetails"]) === null || _formState$errors2$Co === void 0 ? void 0 : _formState$errors2$Co.type)) === null || _Object$keys === void 0 ? void 0 : _Object$keys.length) == 1 && formState.errors["ConnectionHolderDetails"] && Object.values(formState.errors["ConnectionHolderDetails"].type).filter(ob => {
|
|
44975
|
+
var _ob$ref;
|
|
44976
|
+
return ob.type === "required" && (ob === null || ob === void 0 ? void 0 : (_ob$ref = ob.ref) === null || _ob$ref === void 0 ? void 0 : _ob$ref.value) !== "";
|
|
44977
|
+
}).length > 0) setSubmitValve(true);else setSubmitValve(!Object.keys(formState.errors).length);
|
|
44978
|
+
};
|
|
44979
|
+
const closeToastOfError = () => {
|
|
44980
|
+
setShowToast(null);
|
|
44981
|
+
};
|
|
44982
|
+
const onSubmit = async data => {
|
|
44983
|
+
var _data$cpt, _propertyDetails$Prop2, _formStateErros$Conne, _Object$keys2, _formStateErros$Conne2, _data$cpt3, _data$ConnectionDetai, _data$ConnectionHolde, _data$ConnectionHolde2, _data$ConnectionHolde3, _data$ConnectionHolde4, _data$ConnectionHolde5, _propertyDetails$Prop4, _propertyDetails$Prop5, _propertyDetails$Prop6, _propertyDetails$Prop7, _data$ConnectionDetai2;
|
|
44984
|
+
console.log("[WS] onSubmit triggered", {
|
|
44985
|
+
data,
|
|
44986
|
+
propertyId,
|
|
44987
|
+
propertyDetails
|
|
44988
|
+
});
|
|
44989
|
+
if (!(data !== null && data !== void 0 && (_data$cpt = data.cpt) !== null && _data$cpt !== void 0 && _data$cpt.id) && !(propertyDetails !== null && propertyDetails !== void 0 && (_propertyDetails$Prop2 = propertyDetails.Properties) !== null && _propertyDetails$Prop2 !== void 0 && _propertyDetails$Prop2[0])) {
|
|
44990
|
+
var _data$cpt2;
|
|
44991
|
+
if (!(data !== null && data !== void 0 && (_data$cpt2 = data.cpt) !== null && _data$cpt2 !== void 0 && _data$cpt2.details) || !propertyDetails) {
|
|
44992
|
+
console.warn("[WS] onSubmit EXIT: invalid property", {
|
|
44993
|
+
cpt: data === null || data === void 0 ? void 0 : data.cpt,
|
|
44994
|
+
propertyDetails
|
|
44995
|
+
});
|
|
44996
|
+
setShowToast({
|
|
44997
|
+
key: "error",
|
|
44998
|
+
message: "ERR_INVALID_PROPERTY_ID"
|
|
44999
|
+
});
|
|
45000
|
+
return;
|
|
45001
|
+
}
|
|
45002
|
+
}
|
|
45003
|
+
const errors = sessionStorage.getItem("FORMSTATE_ERRORS");
|
|
45004
|
+
console.log("[WS] FORMSTATE_ERRORS from sessionStorage:", errors);
|
|
45005
|
+
const formStateErros = typeof errors === "string" && errors !== "null" ? JSON.parse(errors) : {};
|
|
45006
|
+
if (Object.keys(formStateErros).length > 0 && !(Object.keys(formStateErros).length == 1 && formStateErros !== null && formStateErros !== void 0 && (_formStateErros$Conne = formStateErros["ConnectionHolderDetails"]) !== null && _formStateErros$Conne !== void 0 && _formStateErros$Conne.type && ((_Object$keys2 = Object.keys(formStateErros === null || formStateErros === void 0 ? void 0 : (_formStateErros$Conne2 = formStateErros["ConnectionHolderDetails"]) === null || _formStateErros$Conne2 === void 0 ? void 0 : _formStateErros$Conne2.type)) === null || _Object$keys2 === void 0 ? void 0 : _Object$keys2.length) == 1 && formStateErros["ConnectionHolderDetails"] && Object.values(formStateErros["ConnectionHolderDetails"].type).filter(ob => {
|
|
45007
|
+
var _ob$ref2;
|
|
45008
|
+
return ob.type === "required" && (ob === null || ob === void 0 ? void 0 : (_ob$ref2 = ob.ref) === null || _ob$ref2 === void 0 ? void 0 : _ob$ref2.value) !== "";
|
|
45009
|
+
}).length > 0)) {
|
|
45010
|
+
console.warn("[WS] onSubmit EXIT: formState errors blocking submit", formStateErros);
|
|
45011
|
+
setShowToast({
|
|
45012
|
+
warning: true,
|
|
45013
|
+
message: "PLEASE_FILL_MANDATORY_DETAILS"
|
|
45014
|
+
});
|
|
45015
|
+
return;
|
|
45016
|
+
}
|
|
45017
|
+
if (!(data !== null && data !== void 0 && (_data$cpt3 = data.cpt) !== null && _data$cpt3 !== void 0 && _data$cpt3.details)) {
|
|
45018
|
+
var _propertyDetails$Prop3;
|
|
45019
|
+
data.cpt = {
|
|
45020
|
+
details: propertyDetails === null || propertyDetails === void 0 ? void 0 : (_propertyDetails$Prop3 = propertyDetails.Properties) === null || _propertyDetails$Prop3 === void 0 ? void 0 : _propertyDetails$Prop3[0]
|
|
45021
|
+
};
|
|
45022
|
+
}
|
|
45023
|
+
data.channel = "CITIZEN";
|
|
45024
|
+
const connDetail = (data === null || data === void 0 ? void 0 : (_data$ConnectionDetai = data.ConnectionDetails) === null || _data$ConnectionDetai === void 0 ? void 0 : _data$ConnectionDetai[0]) || {};
|
|
45025
|
+
data.applicationSelection = {
|
|
45026
|
+
serviceType: {
|
|
45027
|
+
code: "WATER"
|
|
45028
|
+
},
|
|
45029
|
+
connectionType: {
|
|
45030
|
+
code: (connDetail === null || connDetail === void 0 ? void 0 : connDetail.connectionType) || "Metered"
|
|
45031
|
+
},
|
|
45032
|
+
applicantType: {
|
|
45033
|
+
code: "NONPTPRESSURE"
|
|
45034
|
+
},
|
|
45035
|
+
categoryType: {
|
|
45036
|
+
code: (data === null || data === void 0 ? void 0 : (_data$ConnectionHolde = data.ConnectionHolderDetails) === null || _data$ConnectionHolde === void 0 ? void 0 : (_data$ConnectionHolde2 = _data$ConnectionHolde[0]) === null || _data$ConnectionHolde2 === void 0 ? void 0 : (_data$ConnectionHolde3 = _data$ConnectionHolde2.ownerType) === null || _data$ConnectionHolde3 === void 0 ? void 0 : _data$ConnectionHolde3.code) || (data === null || data === void 0 ? void 0 : (_data$ConnectionHolde4 = data.ConnectionHolderDetails) === null || _data$ConnectionHolde4 === void 0 ? void 0 : (_data$ConnectionHolde5 = _data$ConnectionHolde4[0]) === null || _data$ConnectionHolde5 === void 0 ? void 0 : _data$ConnectionHolde5.ownerType) || (propertyDetails === null || propertyDetails === void 0 ? void 0 : (_propertyDetails$Prop4 = propertyDetails.Properties) === null || _propertyDetails$Prop4 === void 0 ? void 0 : (_propertyDetails$Prop5 = _propertyDetails$Prop4[0]) === null || _propertyDetails$Prop5 === void 0 ? void 0 : (_propertyDetails$Prop6 = _propertyDetails$Prop5.owners) === null || _propertyDetails$Prop6 === void 0 ? void 0 : (_propertyDetails$Prop7 = _propertyDetails$Prop6[0]) === null || _propertyDetails$Prop7 === void 0 ? void 0 : _propertyDetails$Prop7.ownerType) || "NONE"
|
|
45037
|
+
}
|
|
45038
|
+
};
|
|
45039
|
+
if (data !== null && data !== void 0 && (_data$ConnectionDetai2 = data.ConnectionDetails) !== null && _data$ConnectionDetai2 !== void 0 && _data$ConnectionDetai2[0]) {
|
|
45040
|
+
data.ConnectionDetails[0].water = true;
|
|
45041
|
+
data.ConnectionDetails[0].sewerage = false;
|
|
45042
|
+
data.ConnectionDetails[0].service = "Water";
|
|
45043
|
+
}
|
|
45044
|
+
const allDetails = cloneDeep_1(data);
|
|
45045
|
+
const payload = await createPayloadOfWS(data);
|
|
45046
|
+
console.log("[WS] createPayloadOfWS result:", payload);
|
|
45047
|
+
if (!(payload !== null && payload !== void 0 && payload.water) && !(payload !== null && payload !== void 0 && payload.sewerage)) {
|
|
45048
|
+
console.error("[WS] onSubmit EXIT: payload has neither water nor sewerage", payload);
|
|
45049
|
+
setShowToast({
|
|
45050
|
+
key: "error",
|
|
45051
|
+
message: "ERR_CONNECTION_TYPE_MISSING"
|
|
45052
|
+
});
|
|
45053
|
+
return;
|
|
45054
|
+
}
|
|
45055
|
+
let waterAndSewerageLoader = false;
|
|
45056
|
+
if (payload !== null && payload !== void 0 && payload.water && payload !== null && payload !== void 0 && payload.sewerage) waterAndSewerageLoader = true;
|
|
45057
|
+
let waterConnection = {
|
|
45058
|
+
WaterConnection: payload,
|
|
45059
|
+
disconnectRequest: false,
|
|
45060
|
+
reconnectRequest: false
|
|
45061
|
+
};
|
|
45062
|
+
if (waterAndSewerageLoader) {
|
|
45063
|
+
setWaterAndSewerageBoth(true);
|
|
45064
|
+
sessionStorage.setItem("setWaterAndSewerageBoth", JSON.stringify(true));
|
|
45065
|
+
} else {
|
|
45066
|
+
sessionStorage.setItem("setWaterAndSewerageBoth", JSON.stringify(false));
|
|
45067
|
+
}
|
|
45068
|
+
if (payload !== null && payload !== void 0 && payload.water) {
|
|
45069
|
+
if (waterMutation) {
|
|
45070
|
+
setIsEnableLoader(true);
|
|
45071
|
+
await waterMutation(waterConnection, {
|
|
45072
|
+
onError: error => {
|
|
45073
|
+
var _error$response, _error$response$data, _error$response$data$, _error$response$data$2;
|
|
45074
|
+
setIsEnableLoader(false);
|
|
45075
|
+
console.error("[WS] waterMutation error", error);
|
|
45076
|
+
setShowToast({
|
|
45077
|
+
key: "error",
|
|
45078
|
+
message: (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) || (error === null || error === void 0 ? void 0 : error.message) || "ERR_UNKNOWN"
|
|
45079
|
+
});
|
|
45080
|
+
setTimeout(closeToastOfError, 5000);
|
|
45081
|
+
},
|
|
45082
|
+
onSuccess: async data => {
|
|
45083
|
+
var _data$WaterConnection;
|
|
45084
|
+
console.log("[WS] waterMutation success", data);
|
|
45085
|
+
let response = await updatePayloadOfWS(data === null || data === void 0 ? void 0 : (_data$WaterConnection = data.WaterConnection) === null || _data$WaterConnection === void 0 ? void 0 : _data$WaterConnection[0], "WATER");
|
|
45086
|
+
let waterConnectionUpdate = {
|
|
45087
|
+
WaterConnection: response
|
|
45088
|
+
};
|
|
45089
|
+
waterUpdateMutation(waterConnectionUpdate, {
|
|
45090
|
+
onError: error => {
|
|
45091
|
+
var _error$response2, _error$response2$data, _error$response2$data2, _error$response2$data3;
|
|
45092
|
+
setIsEnableLoader(false);
|
|
45093
|
+
console.error("[WS] waterUpdateMutation error", error);
|
|
45094
|
+
setShowToast({
|
|
45095
|
+
key: "error",
|
|
45096
|
+
message: (error === null || error === void 0 ? void 0 : (_error$response2 = error.response) === null || _error$response2 === void 0 ? void 0 : (_error$response2$data = _error$response2.data) === null || _error$response2$data === void 0 ? void 0 : (_error$response2$data2 = _error$response2$data.Errors) === null || _error$response2$data2 === void 0 ? void 0 : (_error$response2$data3 = _error$response2$data2[0]) === null || _error$response2$data3 === void 0 ? void 0 : _error$response2$data3.message) || (error === null || error === void 0 ? void 0 : error.message) || "ERR_UNKNOWN"
|
|
45097
|
+
});
|
|
45098
|
+
setTimeout(closeToastOfError, 5000);
|
|
45099
|
+
},
|
|
45100
|
+
onSuccess: data => {
|
|
45101
|
+
var _data$WaterConnection3, _data$WaterConnection4;
|
|
45102
|
+
console.log("[WS] waterUpdateMutation success", data);
|
|
45103
|
+
setAppDetails(prev => {
|
|
45104
|
+
var _data$WaterConnection2;
|
|
45105
|
+
return {
|
|
45106
|
+
...prev,
|
|
45107
|
+
waterConnection: data === null || data === void 0 ? void 0 : (_data$WaterConnection2 = data.WaterConnection) === null || _data$WaterConnection2 === void 0 ? void 0 : _data$WaterConnection2[0]
|
|
45108
|
+
};
|
|
45109
|
+
});
|
|
45110
|
+
clearSessionFormData();
|
|
45111
|
+
history.push(`/digit-ui/employee/ws/ws-response?applicationNumber=${data === null || data === void 0 ? void 0 : (_data$WaterConnection3 = data.WaterConnection) === null || _data$WaterConnection3 === void 0 ? void 0 : (_data$WaterConnection4 = _data$WaterConnection3[0]) === null || _data$WaterConnection4 === void 0 ? void 0 : _data$WaterConnection4.applicationNo}`);
|
|
45112
|
+
}
|
|
45113
|
+
});
|
|
45114
|
+
}
|
|
45115
|
+
});
|
|
45116
|
+
}
|
|
45117
|
+
}
|
|
45118
|
+
};
|
|
45119
|
+
const closeToast = () => {
|
|
45120
|
+
setShowToast(null);
|
|
45121
|
+
};
|
|
45122
|
+
if (isEnableLoader || isLoading) {
|
|
45123
|
+
return /*#__PURE__*/React.createElement(Loader, null);
|
|
45124
|
+
}
|
|
45125
|
+
return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("div", {
|
|
45126
|
+
style: {
|
|
45127
|
+
marginLeft: "15px"
|
|
45128
|
+
}
|
|
45129
|
+
}, /*#__PURE__*/React.createElement(Header, null, t(config.head))), /*#__PURE__*/React.createElement(FormComposer, {
|
|
45130
|
+
config: config.body,
|
|
45131
|
+
userType: "employee",
|
|
45132
|
+
onFormValueChange: onFormValueChange,
|
|
45133
|
+
label: creatingWaterApplicationLoading || creatingSewerageApplicationLoading || updatingWaterApplicationLoading || updatingSewerageApplicationLoading ? t("CS_COMMON_SUBMITTING") : t("CS_COMMON_SUBMIT"),
|
|
45134
|
+
onSubmit: onSubmit,
|
|
45135
|
+
defaultValues: sessionFormData,
|
|
45136
|
+
cardFormWrapperClassName: "new-application-card"
|
|
45137
|
+
}), showToast && /*#__PURE__*/React.createElement(Toast, {
|
|
45138
|
+
isDleteBtn: true,
|
|
45139
|
+
error: (showToast === null || showToast === void 0 ? void 0 : showToast.key) === "error" ? true : false,
|
|
45140
|
+
warning: showToast === null || showToast === void 0 ? void 0 : showToast.warning,
|
|
45141
|
+
label: t(showToast === null || showToast === void 0 ? void 0 : showToast.message),
|
|
45142
|
+
onClose: closeToast,
|
|
45143
|
+
isWarning: showToast === null || showToast === void 0 ? void 0 : showToast.isWarning
|
|
45144
|
+
}));
|
|
45145
|
+
};
|
|
45146
|
+
|
|
44824
45147
|
const WSModule = ({
|
|
44825
45148
|
stateCode,
|
|
44826
45149
|
userType,
|
|
@@ -44978,7 +45301,8 @@ const componentsToRegister = {
|
|
|
44978
45301
|
WSSearchWaterConnectionIntegrated: SearchWaterConnectionIntegrated,
|
|
44979
45302
|
WSSearchIntegrated: SearchIntegrated,
|
|
44980
45303
|
WSSearchWaterConnectionViewIntegrated: SearchWaterConnectionViewIntegrated,
|
|
44981
|
-
WSBulkBillGeneration: BulkBillGeneration
|
|
45304
|
+
WSBulkBillGeneration: BulkBillGeneration,
|
|
45305
|
+
WSOLDApplication: OLDApplication
|
|
44982
45306
|
};
|
|
44983
45307
|
const initWSComponents = () => {
|
|
44984
45308
|
Object.entries(componentsToRegister).forEach(([key, value]) => {
|