@djb25/digit-ui-module-ws 1.0.120 → 1.0.122
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +1117 -498
- package/dist/index.js.map +1 -1
- package/dist/index.modern.js +1117 -498
- package/dist/index.modern.js.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -279,6 +279,16 @@ const TestAcknowledgment = () => {
|
|
|
279
279
|
}, "Print"));
|
|
280
280
|
};
|
|
281
281
|
|
|
282
|
+
const isRwhDocType = doc => {
|
|
283
|
+
if (!doc) return false;
|
|
284
|
+
const str = ((typeof doc === "string" ? doc : "") + " " + ((doc === null || doc === void 0 ? void 0 : doc.documentType) || "") + " " + ((doc === null || doc === void 0 ? void 0 : doc.code) || "") + " " + ((doc === null || doc === void 0 ? void 0 : doc.i18nKey) || "") + " " + ((doc === null || doc === void 0 ? void 0 : doc.name) || "") + " " + ((doc === null || doc === void 0 ? void 0 : doc.documentName) || "")).toUpperCase();
|
|
285
|
+
return str.includes("RAIN") || str.includes("HARVEST");
|
|
286
|
+
};
|
|
287
|
+
const isStpDocType = doc => {
|
|
288
|
+
if (!doc) return false;
|
|
289
|
+
const str = ((typeof doc === "string" ? doc : "") + " " + ((doc === null || doc === void 0 ? void 0 : doc.documentType) || "") + " " + ((doc === null || doc === void 0 ? void 0 : doc.code) || "") + " " + ((doc === null || doc === void 0 ? void 0 : doc.i18nKey) || "") + " " + ((doc === null || doc === void 0 ? void 0 : doc.name) || "") + " " + ((doc === null || doc === void 0 ? void 0 : doc.documentName) || "")).toUpperCase();
|
|
290
|
+
return str.includes("SEWER") || str.includes("SEWAGE") || str.includes("STP") || str.includes("TREATMENT");
|
|
291
|
+
};
|
|
282
292
|
const stringReplaceAll = function (str, searcher, replaceWith) {
|
|
283
293
|
if (str === void 0) {
|
|
284
294
|
str = "";
|
|
@@ -682,7 +692,7 @@ const getNormalizedBankDetails = data => {
|
|
|
682
692
|
};
|
|
683
693
|
const createPayloadOfWS = function (data) {
|
|
684
694
|
try {
|
|
685
|
-
var _Digit$UserService$ge, _userInfo$roles, _data$cpt, _data$cpt$details, _data$cpt$details$own, _data$applicationSele, _data$ConnectionDetai, _data$ConnectionDetai2, _ref, _data$waterConnection, _data$ConnectionHolde, _data$documents2, _data$djbEmployee, _data$governmentEmplo, _connectionHolder$gen, _data$cpt2, _data$cpt2$details, _data$cpt2$details$ow, _data$cpt2$details$ow2, _connectionHolder$own, _connectionHolder$rel, _data$propertyAddress, _data$applicant, _data$useDetails, _data$useDetails$gend, _data$contact, _data$applicant2, _data$applicant3, _data$applicant4, _data$contact2, _data$contact3, _data$applicationSele2, _data$applicationSele3, _data$contact4, _data$cpt3, _data$cpt4, _data$cpt4$details, _data$propertyAddress2, _data$propertyAddress3, _data$propertyAddress4, _data$cpt5, _data$cpt5$details, _data$cpt5$details$ad, _data$propertyAddress5, _data$cpt6, _data$cpt6$details, _data$cpt6$details$ad, _data$propertyAddress6, _data$cpt7, _data$cpt7$details, _data$cpt7$details$ad, _data$propertyAddress7, _data$cpt8, _data$cpt8$details, _data$cpt8$details$ad, _data$propertyAddress8, _data$cpt9, _data$cpt9$details, _data$cpt9$details$ad, _data$propertyAddress9, _data$cpt0, _data$cpt0$details, _data$cpt0$details$ad, _data$propertyAddress0, _data$cpt1, _data$cpt1$details, _data$cpt1$details$ad, _data$propertyAddress1, _data$cpt10, _data$cpt10$details, _data$cpt10$details$a, _data$propertyAddress10, _data$cpt11, _data$cpt11$details, _data$cpt11$details$a, _data$cpt12, _data$cpt12$details, _data$cpt12$details$a, _data$propertyAddress11, _data$cpt13, _data$cpt13$details, _data$cpt13$details$a, _data$cpt13$details$a2, _data$propertyAddress12, _data$cpt14, _data$cpt14$details, _data$cpt14$details$a, _data$cpt14$details$a2, _data$propertyAddress13, _data$cpt15, _data$cpt15$details, _data$cpt15$details$a, _data$cpt15$details$a2, _data$cpt16, _data$cpt16$details, _data$roadCuttingDeta, _data$plumberDetails, _data$disability, _data$
|
|
695
|
+
var _Digit$UserService$ge, _userInfo$roles, _data$cpt, _data$cpt$details, _data$cpt$details$own, _data$applicationSele, _data$ConnectionDetai, _data$ConnectionDetai2, _ref, _data$waterConnection, _data$ConnectionHolde, _data$documents2, _data$DocumentsRequir, _data$djbEmployee, _data$governmentEmplo, _rwhDoc$additionalDet, _data$rainWaterHarves, _data$rainWaterHarves2, _data$rainWaterHarves3, _data$additionalDetai7, _data$additionalDetai8, _stpDoc$additionalDet, _data$sewerTreatmentP, _data$sewerTreatmentP2, _data$sewerTreatmentP3, _data$additionalDetai9, _data$additionalDetai0, _docWithValidity$addi, _data$documents3, _data$documents4, _data$documents5, _data$additionalDetai1, _data$additionalDetai10, _data$additionalDetai11, _connectionHolder$gen, _data$cpt2, _data$cpt2$details, _data$cpt2$details$ow, _data$cpt2$details$ow2, _connectionHolder$own, _connectionHolder$rel, _data$propertyAddress, _data$applicant, _data$useDetails, _data$useDetails$gend, _data$contact, _data$applicant2, _data$applicant3, _data$applicant4, _data$contact2, _data$contact3, _data$applicationSele2, _data$applicationSele3, _data$contact4, _data$cpt3, _data$cpt4, _data$cpt4$details, _data$propertyAddress2, _data$propertyAddress3, _data$propertyAddress4, _data$cpt5, _data$cpt5$details, _data$cpt5$details$ad, _data$propertyAddress5, _data$cpt6, _data$cpt6$details, _data$cpt6$details$ad, _data$propertyAddress6, _data$cpt7, _data$cpt7$details, _data$cpt7$details$ad, _data$propertyAddress7, _data$cpt8, _data$cpt8$details, _data$cpt8$details$ad, _data$propertyAddress8, _data$cpt9, _data$cpt9$details, _data$cpt9$details$ad, _data$propertyAddress9, _data$cpt0, _data$cpt0$details, _data$cpt0$details$ad, _data$propertyAddress0, _data$cpt1, _data$cpt1$details, _data$cpt1$details$ad, _data$propertyAddress1, _data$cpt10, _data$cpt10$details, _data$cpt10$details$a, _data$propertyAddress10, _data$cpt11, _data$cpt11$details, _data$cpt11$details$a, _data$cpt12, _data$cpt12$details, _data$cpt12$details$a, _data$propertyAddress11, _data$cpt13, _data$cpt13$details, _data$cpt13$details$a, _data$cpt13$details$a2, _data$propertyAddress12, _data$cpt14, _data$cpt14$details, _data$cpt14$details$a, _data$cpt14$details$a2, _data$propertyAddress13, _data$cpt15, _data$cpt15$details, _data$cpt15$details$a, _data$cpt15$details$a2, _data$cpt16, _data$cpt16$details, _data$roadCuttingDeta, _data$plumberDetails, _data$disability, _data$rainWaterHarves4, _data$rainWaterHarves5, _data$rainWaterHarves6, _data$rainWaterHarves7, _data$sewerTreatmentP4, _data$sewerTreatmentP5, _data$sewerTreatmentP6, _data$sewerTreatmentP7, _data$sewerTreatmentP8, _data$sewerTreatmentP9, _data$sewerTreatmentP0, _data$sewerTreatmentP1, _data$sewerTreatmentP10, _data$djbEmployee4, _data$djbEmployee4$do, _data$djbEmployee5, _data$djbEmployee6, _allDocuments$find, _connectionDetailsObj, _data$zro, _data$propertyAddress14, _data$propertyAddress15, _data$cpt17, _data$cpt17$details, _data$cpt17$details$a, _data$cpt17$details$a2, _data$plumberDetails2, _data$plumberDetails3, _data$plumberDetails4, _data$plumberDetails5, _data$plumberDetails6, _data$applicationSele4, _data$applicationSele5, _connectionDetailsObj2, _data$applicationSele6, _data$applicationSele7, _connectionDetailsObj3, _data$applicationSele8, _useDetailsObject$cat, _data$applicationSele9, _data$applicationSele0, _connectionHolder$own2, _useDetailsObject$noO, _data$propertyAddress16, _data$propertyAddress17, _data$propertyAddress18, _data$propertyAddress19, _data$cpt18, _data$cpt18$details, _data$cpt18$details$a, _data$cpt19, _data$cpt19$details, _data$cpt19$details$a, _data$cpt20, _data$cpt20$details, _data$propertyAddress20, _data$propertyAddress21, _data$propertyAddress22, _data$propertyAddress23, _useDetailsObject$noO2, _data$cpt21, _data$cpt21$details, _data$cpt21$details$a, _data$cpt22, _data$cpt22$details, _data$propertyAddress24, _data$propertyAddress25, _data$cpt23, _data$cpt23$details, _data$cpt23$details$a, _data$cpt24, _data$cpt24$details, _data$cpt24$details$a, _data$cpt25, _data$cpt25$details, _data$propertyAddress26, _data$propertyAddress27, _data$cpt26, _data$cpt26$details, _data$cpt26$details$a, _data$cpt27, _data$cpt27$details, _data$cpt27$details$a, _data$cpt28, _data$cpt28$details, _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$applicationSele24, _data$applicationSele25, _data$contact5, _data$documents6, _data$documents7, _data$documents8, _data$documents9, _allDocuments$find2, _allDocuments$find3, _data$cpt29, _Digit6, _Digit6$Customization, _Digit6$Customization2, _Digit7, _Digit7$Customization, _Digit7$Customization2;
|
|
686
696
|
const userInfo = (_Digit$UserService$ge = Digit.UserService.getUser()) === null || _Digit$UserService$ge === void 0 ? void 0 : _Digit$UserService$ge.info;
|
|
687
697
|
const isCitizen = (userInfo === null || userInfo === void 0 ? void 0 : userInfo.type) === "CITIZEN" || (userInfo === null || userInfo === void 0 ? void 0 : (_userInfo$roles = userInfo.roles) === null || _userInfo$roles === void 0 ? void 0 : _userInfo$roles.some(role => role.code === "CITIZEN"));
|
|
688
698
|
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 => {
|
|
@@ -697,7 +707,7 @@ const createPayloadOfWS = function (data) {
|
|
|
697
707
|
const connectionDetailsObject = connectionDetail;
|
|
698
708
|
const useDetailsObject = (data === null || data === void 0 ? void 0 : (_data$waterConnection = data.waterConnection) === null || _data$waterConnection === void 0 ? void 0 : _data$waterConnection.useDetails) || (data === null || data === void 0 ? void 0 : data.useDetails) || connectionDetailsObject || {};
|
|
699
709
|
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);
|
|
700
|
-
let allDocuments = Array.isArray(data === null || data === void 0 ? void 0 : (_data$documents2 = data.documents) === null || _data$documents2 === void 0 ? void 0 : _data$documents2.documents) ? [...data.documents.documents] : Array.isArray(data === null || data === void 0 ? void 0 : data.documents) ? [...data.documents] : [];
|
|
710
|
+
let allDocuments = Array.isArray(data === null || data === void 0 ? void 0 : (_data$documents2 = data.documents) === null || _data$documents2 === void 0 ? void 0 : _data$documents2.documents) ? [...data.documents.documents] : Array.isArray(data === null || data === void 0 ? void 0 : data.documents) ? [...data.documents] : Array.isArray(data === null || data === void 0 ? void 0 : (_data$DocumentsRequir = data.DocumentsRequired) === null || _data$DocumentsRequir === void 0 ? void 0 : _data$DocumentsRequir.documents) ? [...data.DocumentsRequired.documents] : [];
|
|
701
711
|
const {
|
|
702
712
|
signatureFileStoreId,
|
|
703
713
|
signatureFileName
|
|
@@ -762,6 +772,47 @@ const createPayloadOfWS = function (data) {
|
|
|
762
772
|
status: "ACTIVE"
|
|
763
773
|
});
|
|
764
774
|
}
|
|
775
|
+
allDocuments = allDocuments.map(doc => {
|
|
776
|
+
var _doc$additionalDetail, _doc$additionalDetail2, _doc$additionalDetail3;
|
|
777
|
+
const vDate = (doc === null || doc === void 0 ? void 0 : doc.validityDate) || (doc === null || doc === void 0 ? void 0 : doc.validityUpTo) || (doc === null || doc === void 0 ? void 0 : doc.date) || (doc === null || doc === void 0 ? void 0 : (_doc$additionalDetail = doc.additionalDetails) === null || _doc$additionalDetail === void 0 ? void 0 : _doc$additionalDetail.validityDate) || (doc === null || doc === void 0 ? void 0 : (_doc$additionalDetail2 = doc.additionalDetails) === null || _doc$additionalDetail2 === void 0 ? void 0 : _doc$additionalDetail2.validityUpTo) || (doc === null || doc === void 0 ? void 0 : (_doc$additionalDetail3 = doc.additionalDetails) === null || _doc$additionalDetail3 === void 0 ? void 0 : _doc$additionalDetail3.date);
|
|
778
|
+
const vEpoch = vDate ? convertDateToEpoch(vDate) : undefined;
|
|
779
|
+
return {
|
|
780
|
+
...doc,
|
|
781
|
+
...(vDate ? {
|
|
782
|
+
validityDate: vDate,
|
|
783
|
+
validityUpTo: vDate,
|
|
784
|
+
date: vDate
|
|
785
|
+
} : {}),
|
|
786
|
+
...(typeof vEpoch === "number" ? {
|
|
787
|
+
validityDateEpoch: vEpoch,
|
|
788
|
+
validityUpToEpoch: vEpoch
|
|
789
|
+
} : {}),
|
|
790
|
+
additionalDetails: {
|
|
791
|
+
...((doc === null || doc === void 0 ? void 0 : doc.additionalDetails) || {}),
|
|
792
|
+
...(vDate ? {
|
|
793
|
+
validityDate: vDate,
|
|
794
|
+
validityUpTo: vDate,
|
|
795
|
+
date: vDate
|
|
796
|
+
} : {}),
|
|
797
|
+
...(typeof vEpoch === "number" ? {
|
|
798
|
+
validityDateEpoch: vEpoch,
|
|
799
|
+
validityUpToEpoch: vEpoch
|
|
800
|
+
} : {})
|
|
801
|
+
}
|
|
802
|
+
};
|
|
803
|
+
});
|
|
804
|
+
const rwhDoc = allDocuments.find(d => isRwhDocType(d));
|
|
805
|
+
const stpDoc = allDocuments.find(d => isStpDocType(d));
|
|
806
|
+
const docWithValidity = allDocuments.find(d => {
|
|
807
|
+
var _d$additionalDetails, _d$additionalDetails2;
|
|
808
|
+
return (d === null || d === void 0 ? void 0 : d.validityDate) || (d === null || d === void 0 ? void 0 : d.validityUpTo) || (d === null || d === void 0 ? void 0 : d.date) || (d === null || d === void 0 ? void 0 : (_d$additionalDetails = d.additionalDetails) === null || _d$additionalDetails === void 0 ? void 0 : _d$additionalDetails.validityDate) || (d === null || d === void 0 ? void 0 : (_d$additionalDetails2 = d.additionalDetails) === null || _d$additionalDetails2 === void 0 ? void 0 : _d$additionalDetails2.validityUpTo);
|
|
809
|
+
});
|
|
810
|
+
const rwhValidityDate = (rwhDoc === null || rwhDoc === void 0 ? void 0 : rwhDoc.validityDate) || (rwhDoc === null || rwhDoc === void 0 ? void 0 : rwhDoc.validityUpTo) || (rwhDoc === null || rwhDoc === void 0 ? void 0 : rwhDoc.date) || (rwhDoc === null || rwhDoc === void 0 ? void 0 : (_rwhDoc$additionalDet = rwhDoc.additionalDetails) === null || _rwhDoc$additionalDet === void 0 ? void 0 : _rwhDoc$additionalDet.validityDate) || (data === null || data === void 0 ? void 0 : (_data$rainWaterHarves = data.rainWaterHarvesting) === null || _data$rainWaterHarves === void 0 ? void 0 : _data$rainWaterHarves.validityDate) || (data === null || data === void 0 ? void 0 : (_data$rainWaterHarves2 = data.rainWaterHarvesting) === null || _data$rainWaterHarves2 === void 0 ? void 0 : _data$rainWaterHarves2.validityUpTo) || (data === null || data === void 0 ? void 0 : (_data$rainWaterHarves3 = data.rainWaterHarvesting) === null || _data$rainWaterHarves3 === void 0 ? void 0 : _data$rainWaterHarves3.date) || (data === null || data === void 0 ? void 0 : (_data$additionalDetai7 = data.additionalDetails) === null || _data$additionalDetai7 === void 0 ? void 0 : _data$additionalDetai7.rainWaterHarvestingValidityDate) || (data === null || data === void 0 ? void 0 : (_data$additionalDetai8 = data.additionalDetails) === null || _data$additionalDetai8 === void 0 ? void 0 : _data$additionalDetai8.rwhValidityDate) || "";
|
|
811
|
+
const stpValidityDate = (stpDoc === null || stpDoc === void 0 ? void 0 : stpDoc.validityDate) || (stpDoc === null || stpDoc === void 0 ? void 0 : stpDoc.validityUpTo) || (stpDoc === null || stpDoc === void 0 ? void 0 : stpDoc.date) || (stpDoc === null || stpDoc === void 0 ? void 0 : (_stpDoc$additionalDet = stpDoc.additionalDetails) === null || _stpDoc$additionalDet === void 0 ? void 0 : _stpDoc$additionalDet.validityDate) || (data === null || data === void 0 ? void 0 : (_data$sewerTreatmentP = data.sewerTreatmentPlant) === null || _data$sewerTreatmentP === void 0 ? void 0 : _data$sewerTreatmentP.validityDate) || (data === null || data === void 0 ? void 0 : (_data$sewerTreatmentP2 = data.sewerTreatmentPlant) === null || _data$sewerTreatmentP2 === void 0 ? void 0 : _data$sewerTreatmentP2.validityUpTo) || (data === null || data === void 0 ? void 0 : (_data$sewerTreatmentP3 = data.sewerTreatmentPlant) === null || _data$sewerTreatmentP3 === void 0 ? void 0 : _data$sewerTreatmentP3.date) || (data === null || data === void 0 ? void 0 : (_data$additionalDetai9 = data.additionalDetails) === null || _data$additionalDetai9 === void 0 ? void 0 : _data$additionalDetai9.sewerTreatmentPlantValidityDate) || (data === null || data === void 0 ? void 0 : (_data$additionalDetai0 = data.additionalDetails) === null || _data$additionalDetai0 === void 0 ? void 0 : _data$additionalDetai0.stpValidityDate) || "";
|
|
812
|
+
const overallValidityDate = (docWithValidity === null || docWithValidity === void 0 ? void 0 : docWithValidity.validityDate) || (docWithValidity === null || docWithValidity === void 0 ? void 0 : docWithValidity.validityUpTo) || (docWithValidity === null || docWithValidity === void 0 ? void 0 : docWithValidity.date) || (docWithValidity === null || docWithValidity === void 0 ? void 0 : (_docWithValidity$addi = docWithValidity.additionalDetails) === null || _docWithValidity$addi === void 0 ? void 0 : _docWithValidity$addi.validityDate) || rwhValidityDate || stpValidityDate || (data === null || data === void 0 ? void 0 : (_data$documents3 = data.documents) === null || _data$documents3 === void 0 ? void 0 : _data$documents3.validityDate) || (data === null || data === void 0 ? void 0 : (_data$documents4 = data.documents) === null || _data$documents4 === void 0 ? void 0 : _data$documents4.validityUpTo) || (data === null || data === void 0 ? void 0 : (_data$documents5 = data.documents) === null || _data$documents5 === void 0 ? void 0 : _data$documents5.date) || (data === null || data === void 0 ? void 0 : (_data$additionalDetai1 = data.additionalDetails) === null || _data$additionalDetai1 === void 0 ? void 0 : _data$additionalDetai1.validityDate) || (data === null || data === void 0 ? void 0 : (_data$additionalDetai10 = data.additionalDetails) === null || _data$additionalDetai10 === void 0 ? void 0 : _data$additionalDetai10.validityUpTo) || (data === null || data === void 0 ? void 0 : (_data$additionalDetai11 = data.additionalDetails) === null || _data$additionalDetai11 === void 0 ? void 0 : _data$additionalDetai11.date) || "";
|
|
813
|
+
const overallValidityEpoch = overallValidityDate ? convertDateToEpoch(overallValidityDate) : undefined;
|
|
814
|
+
const rwhValidityEpoch = rwhValidityDate ? convertDateToEpoch(rwhValidityDate) : undefined;
|
|
815
|
+
const stpValidityEpoch = stpValidityDate ? convertDateToEpoch(stpValidityDate) : undefined;
|
|
765
816
|
let payload = {
|
|
766
817
|
water: !!isWater,
|
|
767
818
|
sewerage: !!isSewerage,
|
|
@@ -847,9 +898,13 @@ const createPayloadOfWS = function (data) {
|
|
|
847
898
|
...(data === null || data === void 0 ? void 0 : data.djbEmployee),
|
|
848
899
|
...(data === null || data === void 0 ? void 0 : data.disability),
|
|
849
900
|
...(data === null || data === void 0 ? void 0 : data.rainWaterHarvesting),
|
|
901
|
+
...(data === null || data === void 0 ? void 0 : data.sewerTreatmentPlant),
|
|
850
902
|
isDivyangjan: !!(data !== null && data !== void 0 && (_data$disability = data.disability) !== null && _data$disability !== void 0 && _data$disability.isDivyangjan),
|
|
851
|
-
hasRainWaterHarvestingCertificate: !!(data !== null && data !== void 0 && (_data$
|
|
852
|
-
isRainwaterHarvesting: !!(data !== null && data !== void 0 && (_data$
|
|
903
|
+
hasRainWaterHarvestingCertificate: !!(data !== null && data !== void 0 && (_data$rainWaterHarves4 = data.rainWaterHarvesting) !== null && _data$rainWaterHarves4 !== void 0 && _data$rainWaterHarves4.hasCertificate || data !== null && data !== void 0 && (_data$rainWaterHarves5 = data.rainWaterHarvesting) !== null && _data$rainWaterHarves5 !== void 0 && _data$rainWaterHarves5.isRainwaterHarvesting),
|
|
904
|
+
isRainwaterHarvesting: !!(data !== null && data !== void 0 && (_data$rainWaterHarves6 = data.rainWaterHarvesting) !== null && _data$rainWaterHarves6 !== void 0 && _data$rainWaterHarves6.hasCertificate || data !== null && data !== void 0 && (_data$rainWaterHarves7 = data.rainWaterHarvesting) !== null && _data$rainWaterHarves7 !== void 0 && _data$rainWaterHarves7.isRainwaterHarvesting),
|
|
905
|
+
hasSewerTreatmentPlant: !!(data !== null && data !== void 0 && (_data$sewerTreatmentP4 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP4 !== void 0 && _data$sewerTreatmentP4.hasCertificate || data !== null && data !== void 0 && (_data$sewerTreatmentP5 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP5 !== void 0 && _data$sewerTreatmentP5.hasStp || data !== null && data !== void 0 && (_data$sewerTreatmentP6 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP6 !== void 0 && _data$sewerTreatmentP6.isSewerTreatmentPlant),
|
|
906
|
+
isSewerTreatmentPlant: !!(data !== null && data !== void 0 && (_data$sewerTreatmentP7 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP7 !== void 0 && _data$sewerTreatmentP7.hasCertificate || data !== null && data !== void 0 && (_data$sewerTreatmentP8 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP8 !== void 0 && _data$sewerTreatmentP8.hasStp || data !== null && data !== void 0 && (_data$sewerTreatmentP9 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP9 !== void 0 && _data$sewerTreatmentP9.isSewerTreatmentPlant),
|
|
907
|
+
hasStp: !!(data !== null && data !== void 0 && (_data$sewerTreatmentP0 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP0 !== void 0 && _data$sewerTreatmentP0.hasCertificate || data !== null && data !== void 0 && (_data$sewerTreatmentP1 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP1 !== void 0 && _data$sewerTreatmentP1.hasStp || data !== null && data !== void 0 && (_data$sewerTreatmentP10 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP10 !== void 0 && _data$sewerTreatmentP10.isSewerTreatmentPlant),
|
|
853
908
|
document: (data === null || data === void 0 ? void 0 : (_data$djbEmployee4 = data.djbEmployee) === null || _data$djbEmployee4 === void 0 ? void 0 : (_data$djbEmployee4$do = _data$djbEmployee4.document) === null || _data$djbEmployee4$do === void 0 ? void 0 : _data$djbEmployee4$do.fileStoreId) || (typeof (data === null || data === void 0 ? void 0 : (_data$djbEmployee5 = data.djbEmployee) === null || _data$djbEmployee5 === void 0 ? void 0 : _data$djbEmployee5.document) === "string" ? data === null || data === void 0 ? void 0 : (_data$djbEmployee6 = data.djbEmployee) === null || _data$djbEmployee6 === void 0 ? void 0 : _data$djbEmployee6.document : null) || ((_allDocuments$find = allDocuments.find(d => {
|
|
854
909
|
var _d$documentType5;
|
|
855
910
|
return (d === null || d === void 0 ? void 0 : d.documentType) === "OWNER.DJB_EMPLOYEE_ID" || (d === null || d === void 0 ? void 0 : (_d$documentType5 = d.documentType) === null || _d$documentType5 === void 0 ? void 0 : _d$documentType5.includes("DJB_EMPLOYEE_ID"));
|
|
@@ -900,16 +955,43 @@ const createPayloadOfWS = function (data) {
|
|
|
900
955
|
departmentType: data === null || data === void 0 ? void 0 : (_data$applicationSele24 = data.applicationSelection) === null || _data$applicationSele24 === void 0 ? void 0 : (_data$applicationSele25 = _data$applicationSele24.departmentType) === null || _data$applicationSele25 === void 0 ? void 0 : _data$applicationSele25.code,
|
|
901
956
|
governmentEmployee: data === null || data === void 0 ? void 0 : data.governmentEmployee,
|
|
902
957
|
whatsAppNumber: data === null || data === void 0 ? void 0 : (_data$contact5 = data.contact) === null || _data$contact5 === void 0 ? void 0 : _data$contact5.whatsAppNumber,
|
|
903
|
-
identityProofNumber: data === null || data === void 0 ? void 0 : (_data$
|
|
904
|
-
ownershipDocumentNumber: data === null || data === void 0 ? void 0 : (_data$
|
|
905
|
-
otherDocumentNumber: data === null || data === void 0 ? void 0 : (_data$
|
|
906
|
-
otherDocumentRemark: (data === null || data === void 0 ? void 0 : (_data$
|
|
958
|
+
identityProofNumber: data === null || data === void 0 ? void 0 : (_data$documents6 = data.documents) === null || _data$documents6 === void 0 ? void 0 : _data$documents6.identityProofNumber,
|
|
959
|
+
ownershipDocumentNumber: data === null || data === void 0 ? void 0 : (_data$documents7 = data.documents) === null || _data$documents7 === void 0 ? void 0 : _data$documents7.ownershipDocumentNumber,
|
|
960
|
+
otherDocumentNumber: data === null || data === void 0 ? void 0 : (_data$documents8 = data.documents) === null || _data$documents8 === void 0 ? void 0 : _data$documents8.otherDocumentNumber,
|
|
961
|
+
otherDocumentRemark: (data === null || data === void 0 ? void 0 : (_data$documents9 = data.documents) === null || _data$documents9 === void 0 ? void 0 : _data$documents9.otherDocumentRemark) || ((_allDocuments$find2 = allDocuments.find(d => {
|
|
907
962
|
var _d$documentType6, _d$documentType7;
|
|
908
963
|
return (d === null || d === void 0 ? void 0 : (_d$documentType6 = d.documentType) === null || _d$documentType6 === void 0 ? void 0 : _d$documentType6.includes("OTHER_DOCUMENTS")) || (d === null || d === void 0 ? void 0 : (_d$documentType7 = d.documentType) === null || _d$documentType7 === void 0 ? void 0 : _d$documentType7.includes("OTHERDOCUMENTS"));
|
|
909
964
|
})) === null || _allDocuments$find2 === void 0 ? void 0 : _allDocuments$find2.documentUid) || ((_allDocuments$find3 = allDocuments.find(d => {
|
|
910
965
|
var _d$documentType8, _d$documentType9;
|
|
911
966
|
return (d === null || d === void 0 ? void 0 : (_d$documentType8 = d.documentType) === null || _d$documentType8 === void 0 ? void 0 : _d$documentType8.includes("OTHER_DOCUMENTS")) || (d === null || d === void 0 ? void 0 : (_d$documentType9 = d.documentType) === null || _d$documentType9 === void 0 ? void 0 : _d$documentType9.includes("OTHERDOCUMENTS"));
|
|
912
967
|
})) === null || _allDocuments$find3 === void 0 ? void 0 : _allDocuments$find3.remarks),
|
|
968
|
+
validityDate: overallValidityDate || undefined,
|
|
969
|
+
validityUpTo: overallValidityDate || undefined,
|
|
970
|
+
date: overallValidityDate || undefined,
|
|
971
|
+
...(typeof overallValidityEpoch === "number" ? {
|
|
972
|
+
validityDateEpoch: overallValidityEpoch,
|
|
973
|
+
validityUpToEpoch: overallValidityEpoch
|
|
974
|
+
} : {}),
|
|
975
|
+
...(rwhValidityDate ? {
|
|
976
|
+
rwhValidityDate: rwhValidityDate,
|
|
977
|
+
rwhValidityUpTo: rwhValidityDate,
|
|
978
|
+
rainWaterHarvestingValidityDate: rwhValidityDate,
|
|
979
|
+
rainWaterHarvestingValidityUpTo: rwhValidityDate,
|
|
980
|
+
...(typeof rwhValidityEpoch === "number" ? {
|
|
981
|
+
rwhValidityDateEpoch: rwhValidityEpoch,
|
|
982
|
+
rwhValidityUpToEpoch: rwhValidityEpoch
|
|
983
|
+
} : {})
|
|
984
|
+
} : {}),
|
|
985
|
+
...(stpValidityDate ? {
|
|
986
|
+
stpValidityDate: stpValidityDate,
|
|
987
|
+
stpValidityUpTo: stpValidityDate,
|
|
988
|
+
sewerTreatmentPlantValidityDate: stpValidityDate,
|
|
989
|
+
sewerTreatmentPlantValidityUpTo: stpValidityDate,
|
|
990
|
+
...(typeof stpValidityEpoch === "number" ? {
|
|
991
|
+
stpValidityDateEpoch: stpValidityEpoch,
|
|
992
|
+
stpValidityUpToEpoch: stpValidityEpoch
|
|
993
|
+
} : {})
|
|
994
|
+
} : {}),
|
|
913
995
|
...(getNormalizedBankDetails(data) ? {
|
|
914
996
|
...getNormalizedBankDetails(data),
|
|
915
997
|
bankDetails: getNormalizedBankDetails(data)
|
|
@@ -938,7 +1020,7 @@ const createPayloadOfWS = function (data) {
|
|
|
938
1020
|
};
|
|
939
1021
|
const updatePayloadOfWS = function (data, type) {
|
|
940
1022
|
try {
|
|
941
|
-
var _data$
|
|
1023
|
+
var _data$additionalDetai12, _data$additionalDetai13, _Digit8, _Digit8$Customization, _Digit8$Customization2, _Digit9, _Digit9$Customization, _Digit9$Customization2;
|
|
942
1024
|
const {
|
|
943
1025
|
signatureFileStoreId,
|
|
944
1026
|
signatureFileName
|
|
@@ -980,8 +1062,8 @@ const updatePayloadOfWS = function (data, type) {
|
|
|
980
1062
|
fileName: signatureFileName
|
|
981
1063
|
}
|
|
982
1064
|
} : {}),
|
|
983
|
-
connectionType: (data === null || data === void 0 ? void 0 : (_data$
|
|
984
|
-
waterDemandType: (data === null || data === void 0 ? void 0 : (_data$
|
|
1065
|
+
connectionType: (data === null || data === void 0 ? void 0 : (_data$additionalDetai12 = data.additionalDetails) === null || _data$additionalDetai12 === void 0 ? void 0 : _data$additionalDetai12.connectionType) || "Permanent",
|
|
1066
|
+
waterDemandType: (data === null || data === void 0 ? void 0 : (_data$additionalDetai13 = data.additionalDetails) === null || _data$additionalDetai13 === void 0 ? void 0 : _data$additionalDetai13.waterDemandType) || {
|
|
985
1067
|
code: "NON_BULK",
|
|
986
1068
|
i18nKey: "WS_WATER_DEMAND_NON_BULK"
|
|
987
1069
|
}
|
|
@@ -994,8 +1076,8 @@ const updatePayloadOfWS = function (data, type) {
|
|
|
994
1076
|
}
|
|
995
1077
|
};
|
|
996
1078
|
const getAllDocumentsForUpdate = data => {
|
|
997
|
-
var _data$
|
|
998
|
-
let allDocuments = Array.isArray(data === null || data === void 0 ? void 0 : (_data$
|
|
1079
|
+
var _data$documents0, _data$governmentEmplo5;
|
|
1080
|
+
let allDocuments = Array.isArray(data === null || data === void 0 ? void 0 : (_data$documents0 = data.documents) === null || _data$documents0 === void 0 ? void 0 : _data$documents0.documents) ? [...data.documents.documents] : Array.isArray(data === null || data === void 0 ? void 0 : data.documents) ? [...data.documents] : [];
|
|
999
1081
|
const {
|
|
1000
1082
|
signatureFileStoreId,
|
|
1001
1083
|
signatureFileName
|
|
@@ -1097,7 +1179,7 @@ const getAllDocumentsForUpdate = data => {
|
|
|
1097
1179
|
return allDocuments;
|
|
1098
1180
|
};
|
|
1099
1181
|
const convertToWSUpdate = data => {
|
|
1100
|
-
var _data$WaterConnection, _data$WaterConnection2, _data$cpt30, _data$WaterConnection3, _data$WaterConnection4, _data$WaterConnection5, _data$WaterConnection6, _data$WaterConnection7, _data$WaterConnection8, _data$djbEmployee12, _data$djbEmployee13, _data$djbEmployee14, _data$djbEmployee15, _data$djbEmployee16, _data$djbEmployee17, _data$djbEmployee18, _data$djbEmployee19, _data$djbEmployee20, _data$djbEmployee21, _data$djbEmployee22, _data$djbEmployee23, _data$djbEmployee24, _data$djbEmployee25, _data$djbEmployee25$d, _data$djbEmployee26, _data$disability2, _data$
|
|
1182
|
+
var _data$WaterConnection, _data$WaterConnection2, _data$cpt30, _data$WaterConnection3, _data$WaterConnection4, _data$WaterConnection5, _data$WaterConnection6, _data$WaterConnection7, _data$WaterConnection8, _data$djbEmployee12, _data$djbEmployee13, _data$djbEmployee14, _data$djbEmployee15, _data$djbEmployee16, _data$djbEmployee17, _data$djbEmployee18, _data$djbEmployee19, _data$djbEmployee20, _data$djbEmployee21, _data$djbEmployee22, _data$djbEmployee23, _data$djbEmployee24, _data$djbEmployee25, _data$djbEmployee25$d, _data$djbEmployee26, _data$disability2, _data$rainWaterHarves8, _data$rainWaterHarves9, _data$rainWaterHarves0, _data$rainWaterHarves1, _data$sewerTreatmentP11, _data$sewerTreatmentP12, _data$sewerTreatmentP13, _data$sewerTreatmentP14, _data$sewerTreatmentP15, _data$sewerTreatmentP16, _data$sewerTreatmentP17, _data$sewerTreatmentP18, _data$sewerTreatmentP19, _Digit0, _Digit0$Customization, _Digit0$Customization2, _Digit1, _Digit1$Customization, _Digit1$Customization2;
|
|
1101
1183
|
const {
|
|
1102
1184
|
signatureFileStoreId,
|
|
1103
1185
|
signatureFileName
|
|
@@ -1137,8 +1219,14 @@ const convertToWSUpdate = data => {
|
|
|
1137
1219
|
} : {}),
|
|
1138
1220
|
...((data === null || data === void 0 ? void 0 : data.rainWaterHarvesting) !== undefined ? {
|
|
1139
1221
|
...(data === null || data === void 0 ? void 0 : data.rainWaterHarvesting),
|
|
1140
|
-
hasRainWaterHarvestingCertificate: !!(data !== null && data !== void 0 && (_data$
|
|
1141
|
-
isRainwaterHarvesting: !!(data !== null && data !== void 0 && (_data$
|
|
1222
|
+
hasRainWaterHarvestingCertificate: !!(data !== null && data !== void 0 && (_data$rainWaterHarves8 = data.rainWaterHarvesting) !== null && _data$rainWaterHarves8 !== void 0 && _data$rainWaterHarves8.hasCertificate || data !== null && data !== void 0 && (_data$rainWaterHarves9 = data.rainWaterHarvesting) !== null && _data$rainWaterHarves9 !== void 0 && _data$rainWaterHarves9.isRainwaterHarvesting),
|
|
1223
|
+
isRainwaterHarvesting: !!(data !== null && data !== void 0 && (_data$rainWaterHarves0 = data.rainWaterHarvesting) !== null && _data$rainWaterHarves0 !== void 0 && _data$rainWaterHarves0.hasCertificate || data !== null && data !== void 0 && (_data$rainWaterHarves1 = data.rainWaterHarvesting) !== null && _data$rainWaterHarves1 !== void 0 && _data$rainWaterHarves1.isRainwaterHarvesting)
|
|
1224
|
+
} : {}),
|
|
1225
|
+
...((data === null || data === void 0 ? void 0 : data.sewerTreatmentPlant) !== undefined ? {
|
|
1226
|
+
...(data === null || data === void 0 ? void 0 : data.sewerTreatmentPlant),
|
|
1227
|
+
hasSewerTreatmentPlant: !!(data !== null && data !== void 0 && (_data$sewerTreatmentP11 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP11 !== void 0 && _data$sewerTreatmentP11.hasCertificate || data !== null && data !== void 0 && (_data$sewerTreatmentP12 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP12 !== void 0 && _data$sewerTreatmentP12.hasStp || data !== null && data !== void 0 && (_data$sewerTreatmentP13 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP13 !== void 0 && _data$sewerTreatmentP13.isSewerTreatmentPlant),
|
|
1228
|
+
isSewerTreatmentPlant: !!(data !== null && data !== void 0 && (_data$sewerTreatmentP14 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP14 !== void 0 && _data$sewerTreatmentP14.hasCertificate || data !== null && data !== void 0 && (_data$sewerTreatmentP15 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP15 !== void 0 && _data$sewerTreatmentP15.hasStp || data !== null && data !== void 0 && (_data$sewerTreatmentP16 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP16 !== void 0 && _data$sewerTreatmentP16.isSewerTreatmentPlant),
|
|
1229
|
+
hasStp: !!(data !== null && data !== void 0 && (_data$sewerTreatmentP17 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP17 !== void 0 && _data$sewerTreatmentP17.hasCertificate || data !== null && data !== void 0 && (_data$sewerTreatmentP18 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP18 !== void 0 && _data$sewerTreatmentP18.hasStp || data !== null && data !== void 0 && (_data$sewerTreatmentP19 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP19 !== void 0 && _data$sewerTreatmentP19.isSewerTreatmentPlant)
|
|
1142
1230
|
} : {}),
|
|
1143
1231
|
...(getNormalizedBankDetails(data) ? {
|
|
1144
1232
|
...getNormalizedBankDetails(data),
|
|
@@ -1154,7 +1242,7 @@ const convertToWSUpdate = data => {
|
|
|
1154
1242
|
return formdata;
|
|
1155
1243
|
};
|
|
1156
1244
|
const convertToEditWSUpdate = data => {
|
|
1157
|
-
var _data$WaterConnection9, _data$WaterConnection0, _data$property, _data$property$auditD, _waterResult$property, _waterResult$property2, _data$property2, _data$property2$audit, _waterResult$auditDet, _data$
|
|
1245
|
+
var _data$WaterConnection9, _data$WaterConnection0, _data$property, _data$property$auditD, _waterResult$property, _waterResult$property2, _data$property2, _data$property2$audit, _waterResult$auditDet, _data$additionalDetai14, _data$additionalDetai15, _waterResult$addition, _data$ConnectionDetai3, _data$ConnectionDetai4, _data$ConnectionDetai5, _data$ConnectionDetai6, _data$ConnectionDetai7, _data$additionalDetai16, _waterResult$addition2, _data$ConnectionDetai8, _data$ConnectionDetai9, _data$additionalDetai17, _waterResult$addition3, _data$djbEmployee27, _data$djbEmployee28, _data$djbEmployee29, _data$djbEmployee30, _data$djbEmployee31, _data$djbEmployee32, _data$djbEmployee33, _data$djbEmployee34, _data$djbEmployee35, _data$djbEmployee36, _data$djbEmployee37, _data$djbEmployee38, _data$djbEmployee39, _data$djbEmployee40, _data$djbEmployee40$d, _data$djbEmployee41, _data$disability3, _data$rainWaterHarves10, _data$rainWaterHarves11, _data$rainWaterHarves12, _data$rainWaterHarves13, _data$sewerTreatmentP20, _data$sewerTreatmentP21, _data$sewerTreatmentP22, _data$sewerTreatmentP23, _data$sewerTreatmentP24, _data$sewerTreatmentP25, _data$sewerTreatmentP26, _data$sewerTreatmentP27, _data$sewerTreatmentP28, _data$waterConnection2, _data$additionalDetai18, _waterResult$addition4, _data$additionalDetai19, _waterResult$addition5, _data$additionalDetai20, _waterResult$addition6, _data$additionalDetai21, _waterResult$addition7, _data$waterConnection3, _data$additionalDetai22, _waterResult$addition8, _data$waterConnection4, _data$additionalDetai23, _waterResult$addition9, _data$waterConnection5, _data$additionalDetai24, _waterResult$addition0, _data$waterConnection6, _data$additionalDetai25, _waterResult$addition1, _data$additionalDetai26, _data$property3, _data$property3$addit, _data$cpt31, _data$cpt31$details, _data$cpt31$details$a, _waterResult$addition10, _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$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$ConnectionHolde26, _data$ConnectionHolde27, _data$ConnectionHolde28, _Digit$UserService$ge2, _Digit$UserService$ge3, _Digit$UserService$ge4, _data$waterConectionD, _data$waterConectionD2, _data$waterConectionD3, _data$applicationType, _data$applicationType2, _data$applicationType3, _data$serviceName, _waterResult$serviceN, _data$sewerageConnect, _data$sewerageConnect2, _Digit10, _Digit10$Customizatio, _Digit10$Customizatio2, _Digit11, _Digit11$Customizatio, _Digit11$Customizatio2;
|
|
1158
1246
|
const {
|
|
1159
1247
|
signatureFileStoreId,
|
|
1160
1248
|
signatureFileName
|
|
@@ -1192,9 +1280,9 @@ const convertToEditWSUpdate = data => {
|
|
|
1192
1280
|
fileName: signatureFileName
|
|
1193
1281
|
}
|
|
1194
1282
|
} : {}),
|
|
1195
|
-
CompletelySatisfied: (data === null || data === void 0 ? void 0 : (_data$
|
|
1196
|
-
addressType: (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$ConnectionDetai5 = _data$ConnectionDetai4.addressType) === null || _data$ConnectionDetai5 === void 0 ? void 0 : _data$ConnectionDetai5.code) || (data === null || data === void 0 ? void 0 : (_data$ConnectionDetai6 = data.ConnectionDetails) === null || _data$ConnectionDetai6 === void 0 ? void 0 : (_data$ConnectionDetai7 = _data$ConnectionDetai6[0]) === null || _data$ConnectionDetai7 === void 0 ? void 0 : _data$ConnectionDetai7.addressType) || (data !== null && data !== void 0 && data.isEditApplication ? data === null || data === void 0 ? void 0 : (_data$
|
|
1197
|
-
completeAddress: (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$ConnectionDetai9.completeAddress) || (data !== null && data !== void 0 && data.isEditApplication ? data === null || data === void 0 ? void 0 : (_data$
|
|
1283
|
+
CompletelySatisfied: (data === null || data === void 0 ? void 0 : (_data$additionalDetai14 = data.additionalDetails) === null || _data$additionalDetai14 === void 0 ? void 0 : _data$additionalDetai14.CompletelySatisfied) !== undefined ? data === null || data === void 0 ? void 0 : (_data$additionalDetai15 = data.additionalDetails) === null || _data$additionalDetai15 === void 0 ? void 0 : _data$additionalDetai15.CompletelySatisfied : waterResult === null || waterResult === void 0 ? void 0 : (_waterResult$addition = waterResult.additionalDetails) === null || _waterResult$addition === void 0 ? void 0 : _waterResult$addition.CompletelySatisfied,
|
|
1284
|
+
addressType: (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$ConnectionDetai5 = _data$ConnectionDetai4.addressType) === null || _data$ConnectionDetai5 === void 0 ? void 0 : _data$ConnectionDetai5.code) || (data === null || data === void 0 ? void 0 : (_data$ConnectionDetai6 = data.ConnectionDetails) === null || _data$ConnectionDetai6 === void 0 ? void 0 : (_data$ConnectionDetai7 = _data$ConnectionDetai6[0]) === null || _data$ConnectionDetai7 === void 0 ? void 0 : _data$ConnectionDetai7.addressType) || (data !== null && data !== void 0 && data.isEditApplication ? data === null || data === void 0 ? void 0 : (_data$additionalDetai16 = data.additionalDetails) === null || _data$additionalDetai16 === void 0 ? void 0 : _data$additionalDetai16.addressType : waterResult === null || waterResult === void 0 ? void 0 : (_waterResult$addition2 = waterResult.additionalDetails) === null || _waterResult$addition2 === void 0 ? void 0 : _waterResult$addition2.addressType) || "",
|
|
1285
|
+
completeAddress: (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$ConnectionDetai9.completeAddress) || (data !== null && data !== void 0 && data.isEditApplication ? data === null || data === void 0 ? void 0 : (_data$additionalDetai17 = data.additionalDetails) === null || _data$additionalDetai17 === void 0 ? void 0 : _data$additionalDetai17.completeAddress : waterResult === null || waterResult === void 0 ? void 0 : (_waterResult$addition3 = waterResult.additionalDetails) === null || _waterResult$addition3 === void 0 ? void 0 : _waterResult$addition3.completeAddress) || "",
|
|
1198
1286
|
...((data === null || data === void 0 ? void 0 : data.djbEmployee) !== undefined ? {
|
|
1199
1287
|
...(data === null || data === void 0 ? void 0 : data.djbEmployee),
|
|
1200
1288
|
isDjbEmployee: String(data === null || data === void 0 ? void 0 : (_data$djbEmployee27 = data.djbEmployee) === null || _data$djbEmployee27 === void 0 ? void 0 : _data$djbEmployee27.isDjbEmployee) === "true" || (data === null || data === void 0 ? void 0 : (_data$djbEmployee28 = data.djbEmployee) === null || _data$djbEmployee28 === void 0 ? void 0 : _data$djbEmployee28.isDjbEmployee) === true,
|
|
@@ -1209,23 +1297,29 @@ const convertToEditWSUpdate = data => {
|
|
|
1209
1297
|
} : {}),
|
|
1210
1298
|
...((data === null || data === void 0 ? void 0 : data.rainWaterHarvesting) !== undefined ? {
|
|
1211
1299
|
...(data === null || data === void 0 ? void 0 : data.rainWaterHarvesting),
|
|
1212
|
-
hasRainWaterHarvestingCertificate: !!(data !== null && data !== void 0 && (_data$
|
|
1213
|
-
isRainwaterHarvesting: !!(data !== null && data !== void 0 && (_data$
|
|
1300
|
+
hasRainWaterHarvestingCertificate: !!(data !== null && data !== void 0 && (_data$rainWaterHarves10 = data.rainWaterHarvesting) !== null && _data$rainWaterHarves10 !== void 0 && _data$rainWaterHarves10.hasCertificate || data !== null && data !== void 0 && (_data$rainWaterHarves11 = data.rainWaterHarvesting) !== null && _data$rainWaterHarves11 !== void 0 && _data$rainWaterHarves11.isRainwaterHarvesting),
|
|
1301
|
+
isRainwaterHarvesting: !!(data !== null && data !== void 0 && (_data$rainWaterHarves12 = data.rainWaterHarvesting) !== null && _data$rainWaterHarves12 !== void 0 && _data$rainWaterHarves12.hasCertificate || data !== null && data !== void 0 && (_data$rainWaterHarves13 = data.rainWaterHarvesting) !== null && _data$rainWaterHarves13 !== void 0 && _data$rainWaterHarves13.isRainwaterHarvesting)
|
|
1302
|
+
} : {}),
|
|
1303
|
+
...((data === null || data === void 0 ? void 0 : data.sewerTreatmentPlant) !== undefined ? {
|
|
1304
|
+
...(data === null || data === void 0 ? void 0 : data.sewerTreatmentPlant),
|
|
1305
|
+
hasSewerTreatmentPlant: !!(data !== null && data !== void 0 && (_data$sewerTreatmentP20 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP20 !== void 0 && _data$sewerTreatmentP20.hasCertificate || data !== null && data !== void 0 && (_data$sewerTreatmentP21 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP21 !== void 0 && _data$sewerTreatmentP21.hasStp || data !== null && data !== void 0 && (_data$sewerTreatmentP22 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP22 !== void 0 && _data$sewerTreatmentP22.isSewerTreatmentPlant),
|
|
1306
|
+
isSewerTreatmentPlant: !!(data !== null && data !== void 0 && (_data$sewerTreatmentP23 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP23 !== void 0 && _data$sewerTreatmentP23.hasCertificate || data !== null && data !== void 0 && (_data$sewerTreatmentP24 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP24 !== void 0 && _data$sewerTreatmentP24.hasStp || data !== null && data !== void 0 && (_data$sewerTreatmentP25 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP25 !== void 0 && _data$sewerTreatmentP25.isSewerTreatmentPlant),
|
|
1307
|
+
hasStp: !!(data !== null && data !== void 0 && (_data$sewerTreatmentP26 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP26 !== void 0 && _data$sewerTreatmentP26.hasCertificate || data !== null && data !== void 0 && (_data$sewerTreatmentP27 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP27 !== void 0 && _data$sewerTreatmentP27.hasStp || data !== null && data !== void 0 && (_data$sewerTreatmentP28 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP28 !== void 0 && _data$sewerTreatmentP28.isSewerTreatmentPlant)
|
|
1214
1308
|
} : {}),
|
|
1215
1309
|
...(getNormalizedBankDetails(data) ? {
|
|
1216
1310
|
...getNormalizedBankDetails(data),
|
|
1217
1311
|
bankDetails: getNormalizedBankDetails(data)
|
|
1218
1312
|
} : {}),
|
|
1219
1313
|
...(data !== null && data !== void 0 && (_data$waterConnection2 = data.waterConnection) !== null && _data$waterConnection2 !== void 0 && _data$waterConnection2.useDetails ? {
|
|
1220
|
-
plotArea: data.waterConnection.useDetails.plotArea || (data === null || data === void 0 ? void 0 : (_data$
|
|
1221
|
-
plotSize: data.waterConnection.useDetails.plotArea || (data === null || data === void 0 ? void 0 : (_data$
|
|
1222
|
-
builtUpArea: data.waterConnection.useDetails.builtUpArea || (data === null || data === void 0 ? void 0 : (_data$
|
|
1223
|
-
heightOfTheBuilding: data.waterConnection.useDetails.heightOfTheBuilding || (data === null || data === void 0 ? void 0 : (_data$
|
|
1224
|
-
categoryType: ((_data$waterConnection3 = data.waterConnection.useDetails.categoryType) === null || _data$waterConnection3 === void 0 ? void 0 : _data$waterConnection3.code) || data.waterConnection.useDetails.categoryType || (data === null || data === void 0 ? void 0 : (_data$
|
|
1225
|
-
propertyCategory: ((_data$waterConnection4 = data.waterConnection.useDetails.propertyCategory) === null || _data$waterConnection4 === void 0 ? void 0 : _data$waterConnection4.code) || data.waterConnection.useDetails.propertyCategory || (data === null || data === void 0 ? void 0 : (_data$
|
|
1226
|
-
propertyType: ((_data$waterConnection5 = data.waterConnection.useDetails.propertyType) === null || _data$waterConnection5 === void 0 ? void 0 : _data$waterConnection5.code) || data.waterConnection.useDetails.propertyType || (data === null || data === void 0 ? void 0 : (_data$
|
|
1227
|
-
waterConnectionUsageType: ((_data$waterConnection6 = data.waterConnection.useDetails.WaterConnectionUsageType) === null || _data$waterConnection6 === void 0 ? void 0 : _data$waterConnection6.code) || data.waterConnection.useDetails.WaterConnectionUsageType || (data === null || data === void 0 ? void 0 : (_data$
|
|
1228
|
-
numberOfDwellingUnits: data.waterConnection.useDetails.NumberofDwellingUnits || (data === null || data === void 0 ? void 0 : (_data$
|
|
1314
|
+
plotArea: data.waterConnection.useDetails.plotArea || (data === null || data === void 0 ? void 0 : (_data$additionalDetai18 = data.additionalDetails) === null || _data$additionalDetai18 === void 0 ? void 0 : _data$additionalDetai18.plotArea) || (waterResult === null || waterResult === void 0 ? void 0 : (_waterResult$addition4 = waterResult.additionalDetails) === null || _waterResult$addition4 === void 0 ? void 0 : _waterResult$addition4.plotArea),
|
|
1315
|
+
plotSize: data.waterConnection.useDetails.plotArea || (data === null || data === void 0 ? void 0 : (_data$additionalDetai19 = data.additionalDetails) === null || _data$additionalDetai19 === void 0 ? void 0 : _data$additionalDetai19.plotSize) || (waterResult === null || waterResult === void 0 ? void 0 : (_waterResult$addition5 = waterResult.additionalDetails) === null || _waterResult$addition5 === void 0 ? void 0 : _waterResult$addition5.plotSize),
|
|
1316
|
+
builtUpArea: data.waterConnection.useDetails.builtUpArea || (data === null || data === void 0 ? void 0 : (_data$additionalDetai20 = data.additionalDetails) === null || _data$additionalDetai20 === void 0 ? void 0 : _data$additionalDetai20.builtUpArea) || (waterResult === null || waterResult === void 0 ? void 0 : (_waterResult$addition6 = waterResult.additionalDetails) === null || _waterResult$addition6 === void 0 ? void 0 : _waterResult$addition6.builtUpArea),
|
|
1317
|
+
heightOfTheBuilding: data.waterConnection.useDetails.heightOfTheBuilding || (data === null || data === void 0 ? void 0 : (_data$additionalDetai21 = data.additionalDetails) === null || _data$additionalDetai21 === void 0 ? void 0 : _data$additionalDetai21.heightOfTheBuilding) || (waterResult === null || waterResult === void 0 ? void 0 : (_waterResult$addition7 = waterResult.additionalDetails) === null || _waterResult$addition7 === void 0 ? void 0 : _waterResult$addition7.heightOfTheBuilding),
|
|
1318
|
+
categoryType: ((_data$waterConnection3 = data.waterConnection.useDetails.categoryType) === null || _data$waterConnection3 === void 0 ? void 0 : _data$waterConnection3.code) || data.waterConnection.useDetails.categoryType || (data === null || data === void 0 ? void 0 : (_data$additionalDetai22 = data.additionalDetails) === null || _data$additionalDetai22 === void 0 ? void 0 : _data$additionalDetai22.categoryType) || (waterResult === null || waterResult === void 0 ? void 0 : (_waterResult$addition8 = waterResult.additionalDetails) === null || _waterResult$addition8 === void 0 ? void 0 : _waterResult$addition8.categoryType),
|
|
1319
|
+
propertyCategory: ((_data$waterConnection4 = data.waterConnection.useDetails.propertyCategory) === null || _data$waterConnection4 === void 0 ? void 0 : _data$waterConnection4.code) || data.waterConnection.useDetails.propertyCategory || (data === null || data === void 0 ? void 0 : (_data$additionalDetai23 = data.additionalDetails) === null || _data$additionalDetai23 === void 0 ? void 0 : _data$additionalDetai23.propertyCategory) || (waterResult === null || waterResult === void 0 ? void 0 : (_waterResult$addition9 = waterResult.additionalDetails) === null || _waterResult$addition9 === void 0 ? void 0 : _waterResult$addition9.propertyCategory),
|
|
1320
|
+
propertyType: ((_data$waterConnection5 = data.waterConnection.useDetails.propertyType) === null || _data$waterConnection5 === void 0 ? void 0 : _data$waterConnection5.code) || data.waterConnection.useDetails.propertyType || (data === null || data === void 0 ? void 0 : (_data$additionalDetai24 = data.additionalDetails) === null || _data$additionalDetai24 === void 0 ? void 0 : _data$additionalDetai24.propertyType) || (waterResult === null || waterResult === void 0 ? void 0 : (_waterResult$addition0 = waterResult.additionalDetails) === null || _waterResult$addition0 === void 0 ? void 0 : _waterResult$addition0.propertyType),
|
|
1321
|
+
waterConnectionUsageType: ((_data$waterConnection6 = data.waterConnection.useDetails.WaterConnectionUsageType) === null || _data$waterConnection6 === void 0 ? void 0 : _data$waterConnection6.code) || data.waterConnection.useDetails.WaterConnectionUsageType || (data === null || data === void 0 ? void 0 : (_data$additionalDetai25 = data.additionalDetails) === null || _data$additionalDetai25 === void 0 ? void 0 : _data$additionalDetai25.waterConnectionUsageType) || (waterResult === null || waterResult === void 0 ? void 0 : (_waterResult$addition1 = waterResult.additionalDetails) === null || _waterResult$addition1 === void 0 ? void 0 : _waterResult$addition1.waterConnectionUsageType),
|
|
1322
|
+
numberOfDwellingUnits: data.waterConnection.useDetails.NumberofDwellingUnits || (data === null || data === void 0 ? void 0 : (_data$additionalDetai26 = data.additionalDetails) === null || _data$additionalDetai26 === void 0 ? void 0 : _data$additionalDetai26.numberOfDwellingUnits) || (data === null || data === void 0 ? void 0 : (_data$property3 = data.property) === null || _data$property3 === void 0 ? void 0 : (_data$property3$addit = _data$property3.additionalDetails) === null || _data$property3$addit === void 0 ? void 0 : _data$property3$addit.numberOfDwellingUnits) || (data === null || data === void 0 ? void 0 : (_data$cpt31 = data.cpt) === null || _data$cpt31 === void 0 ? void 0 : (_data$cpt31$details = _data$cpt31.details) === null || _data$cpt31$details === void 0 ? void 0 : (_data$cpt31$details$a = _data$cpt31$details.additionalDetails) === null || _data$cpt31$details$a === void 0 ? void 0 : _data$cpt31$details$a.numberOfDwellingUnits) || (waterResult === null || waterResult === void 0 ? void 0 : (_waterResult$addition10 = waterResult.additionalDetails) === null || _waterResult$addition10 === void 0 ? void 0 : _waterResult$addition10.numberOfDwellingUnits) || ""
|
|
1229
1323
|
} : {})
|
|
1230
1324
|
},
|
|
1231
1325
|
auditDetails: data !== null && data !== void 0 && data.isEditApplication ? data === null || data === void 0 ? void 0 : data.auditDetails : waterResult === null || waterResult === void 0 ? void 0 : waterResult.auditDetails,
|
|
@@ -1311,7 +1405,7 @@ const convertToEditWSUpdate = data => {
|
|
|
1311
1405
|
})(),
|
|
1312
1406
|
dueVerification: data !== null && data !== void 0 && data.isEditApplication ? data === null || data === void 0 ? void 0 : data.dueVerification : waterResult === null || waterResult === void 0 ? void 0 : waterResult.dueVerification,
|
|
1313
1407
|
water: data !== null && data !== void 0 && (_data$applicationType = data.applicationType) !== null && _data$applicationType !== void 0 && _data$applicationType.includes("WATER") ? true : false,
|
|
1314
|
-
sewerage: data !== null && data !== void 0 && (_data$applicationType2 = data.applicationType) !== null && _data$applicationType2 !== void 0 && _data$applicationType2.includes("
|
|
1408
|
+
sewerage: data !== null && data !== void 0 && (_data$applicationType2 = data.applicationType) !== null && _data$applicationType2 !== void 0 && _data$applicationType2.includes("SEWERAGE") || data !== null && data !== void 0 && (_data$applicationType3 = data.applicationType) !== null && _data$applicationType3 !== void 0 && _data$applicationType3.includes("SW") ? true : false,
|
|
1315
1409
|
service: data !== null && data !== void 0 && data.isEditApplication ? data === null || data === void 0 ? void 0 : (_data$serviceName = data.serviceName) === null || _data$serviceName === void 0 ? void 0 : _data$serviceName.code : waterResult === null || waterResult === void 0 ? void 0 : (_waterResult$serviceN = waterResult.serviceName) === null || _waterResult$serviceN === void 0 ? void 0 : _waterResult$serviceN.code,
|
|
1316
1410
|
reviewDocData: [...getAllDocumentsForUpdate(data)],
|
|
1317
1411
|
proposedWaterClosets: data === null || data === void 0 ? void 0 : (_data$sewerageConnect = data.sewerageConnectionDetails) === null || _data$sewerageConnect === void 0 ? void 0 : _data$sewerageConnect.proposedWaterClosets,
|
|
@@ -1327,7 +1421,7 @@ const convertToEditWSUpdate = data => {
|
|
|
1327
1421
|
return formdata;
|
|
1328
1422
|
};
|
|
1329
1423
|
const convertToEditSWUpdate = data => {
|
|
1330
|
-
var _data$SewerageConnect, _data$SewerageConnect2, _data$
|
|
1424
|
+
var _data$SewerageConnect, _data$SewerageConnect2, _data$additionalDetai27, _data$additionalDetai28, _SewerageResult$addit, _data$ConnectionDetai0, _data$ConnectionDetai1, _data$ConnectionDetai10, _data$ConnectionDetai11, _data$ConnectionDetai12, _data$additionalDetai29, _SewerageResult$addit2, _data$ConnectionDetai13, _data$ConnectionDetai14, _data$additionalDetai30, _SewerageResult$addit3, _data$djbEmployee42, _data$djbEmployee43, _data$djbEmployee44, _data$djbEmployee45, _data$djbEmployee46, _data$djbEmployee47, _data$djbEmployee48, _data$djbEmployee49, _data$djbEmployee50, _data$djbEmployee51, _data$djbEmployee52, _data$djbEmployee53, _data$djbEmployee54, _data$djbEmployee55, _data$djbEmployee55$d, _data$djbEmployee56, _data$disability4, _data$rainWaterHarves14, _data$rainWaterHarves15, _data$rainWaterHarves16, _data$rainWaterHarves17, _data$sewerTreatmentP29, _data$sewerTreatmentP30, _data$sewerTreatmentP31, _data$sewerTreatmentP32, _data$sewerTreatmentP33, _data$sewerTreatmentP34, _data$sewerTreatmentP35, _data$sewerTreatmentP36, _data$sewerTreatmentP37, _data$waterConnection8, _data$additionalDetai31, _SewerageResult$addit4, _data$additionalDetai32, _SewerageResult$addit5, _data$additionalDetai33, _SewerageResult$addit6, _data$additionalDetai34, _SewerageResult$addit7, _data$waterConnection9, _data$additionalDetai35, _SewerageResult$addit8, _data$waterConnection0, _data$additionalDetai36, _SewerageResult$addit9, _data$waterConnection1, _data$additionalDetai37, _SewerageResult$addit0, _data$waterConnection10, _data$additionalDetai38, _SewerageResult$addit1, _data$additionalDetai39, _data$property4, _data$property4$addit, _data$cpt33, _data$cpt33$details, _data$cpt33$details$a, _SewerageResult$addit10, _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$ConnectionHolde49, _data$ConnectionHolde50, _data$ConnectionHolde51, _data$ConnectionHolde52, _data$ConnectionHolde53, _data$ConnectionHolde54, _data$ConnectionHolde55, _data$ConnectionHolde56, _data$ConnectionHolde57, _Digit$UserService$ge5, _Digit$UserService$ge6, _Digit$UserService$ge7, _data$waterConectionD4, _data$waterConectionD5, _data$waterConectionD6, _data$applicationType4, _data$applicationType5, _data$applicationType6, _data$applicationType7, _data$serviceName2, _SewerageResult$servi, _data$sewerageConnect3, _data$sewerageConnect4, _Digit12, _Digit12$Customizatio, _Digit12$Customizatio2, _Digit13, _Digit13$Customizatio, _Digit13$Customizatio2;
|
|
1331
1425
|
const {
|
|
1332
1426
|
signatureFileStoreId,
|
|
1333
1427
|
signatureFileName
|
|
@@ -1364,9 +1458,9 @@ const convertToEditSWUpdate = data => {
|
|
|
1364
1458
|
fileName: signatureFileName
|
|
1365
1459
|
}
|
|
1366
1460
|
} : {}),
|
|
1367
|
-
CompletelySatisfied: (data === null || data === void 0 ? void 0 : (_data$
|
|
1368
|
-
addressType: (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.addressType) === null || _data$ConnectionDetai10 === void 0 ? void 0 : _data$ConnectionDetai10.code) || (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.addressType) || (data !== null && data !== void 0 && data.isEditApplication ? data === null || data === void 0 ? void 0 : (_data$
|
|
1369
|
-
completeAddress: (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.completeAddress) || (data !== null && data !== void 0 && data.isEditApplication ? data === null || data === void 0 ? void 0 : (_data$
|
|
1461
|
+
CompletelySatisfied: (data === null || data === void 0 ? void 0 : (_data$additionalDetai27 = data.additionalDetails) === null || _data$additionalDetai27 === void 0 ? void 0 : _data$additionalDetai27.CompletelySatisfied) !== undefined ? data === null || data === void 0 ? void 0 : (_data$additionalDetai28 = data.additionalDetails) === null || _data$additionalDetai28 === void 0 ? void 0 : _data$additionalDetai28.CompletelySatisfied : SewerageResult === null || SewerageResult === void 0 ? void 0 : (_SewerageResult$addit = SewerageResult.additionalDetails) === null || _SewerageResult$addit === void 0 ? void 0 : _SewerageResult$addit.CompletelySatisfied,
|
|
1462
|
+
addressType: (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.addressType) === null || _data$ConnectionDetai10 === void 0 ? void 0 : _data$ConnectionDetai10.code) || (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.addressType) || (data !== null && data !== void 0 && data.isEditApplication ? data === null || data === void 0 ? void 0 : (_data$additionalDetai29 = data.additionalDetails) === null || _data$additionalDetai29 === void 0 ? void 0 : _data$additionalDetai29.addressType : SewerageResult === null || SewerageResult === void 0 ? void 0 : (_SewerageResult$addit2 = SewerageResult.additionalDetails) === null || _SewerageResult$addit2 === void 0 ? void 0 : _SewerageResult$addit2.addressType) || "",
|
|
1463
|
+
completeAddress: (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.completeAddress) || (data !== null && data !== void 0 && data.isEditApplication ? data === null || data === void 0 ? void 0 : (_data$additionalDetai30 = data.additionalDetails) === null || _data$additionalDetai30 === void 0 ? void 0 : _data$additionalDetai30.completeAddress : SewerageResult === null || SewerageResult === void 0 ? void 0 : (_SewerageResult$addit3 = SewerageResult.additionalDetails) === null || _SewerageResult$addit3 === void 0 ? void 0 : _SewerageResult$addit3.completeAddress) || "",
|
|
1370
1464
|
...((data === null || data === void 0 ? void 0 : data.djbEmployee) !== undefined ? {
|
|
1371
1465
|
...(data === null || data === void 0 ? void 0 : data.djbEmployee),
|
|
1372
1466
|
isDjbEmployee: String(data === null || data === void 0 ? void 0 : (_data$djbEmployee42 = data.djbEmployee) === null || _data$djbEmployee42 === void 0 ? void 0 : _data$djbEmployee42.isDjbEmployee) === "true" || (data === null || data === void 0 ? void 0 : (_data$djbEmployee43 = data.djbEmployee) === null || _data$djbEmployee43 === void 0 ? void 0 : _data$djbEmployee43.isDjbEmployee) === true,
|
|
@@ -1381,23 +1475,29 @@ const convertToEditSWUpdate = data => {
|
|
|
1381
1475
|
} : {}),
|
|
1382
1476
|
...((data === null || data === void 0 ? void 0 : data.rainWaterHarvesting) !== undefined ? {
|
|
1383
1477
|
...(data === null || data === void 0 ? void 0 : data.rainWaterHarvesting),
|
|
1384
|
-
hasRainWaterHarvestingCertificate: !!(data !== null && data !== void 0 && (_data$
|
|
1385
|
-
isRainwaterHarvesting: !!(data !== null && data !== void 0 && (_data$
|
|
1478
|
+
hasRainWaterHarvestingCertificate: !!(data !== null && data !== void 0 && (_data$rainWaterHarves14 = data.rainWaterHarvesting) !== null && _data$rainWaterHarves14 !== void 0 && _data$rainWaterHarves14.hasCertificate || data !== null && data !== void 0 && (_data$rainWaterHarves15 = data.rainWaterHarvesting) !== null && _data$rainWaterHarves15 !== void 0 && _data$rainWaterHarves15.isRainwaterHarvesting),
|
|
1479
|
+
isRainwaterHarvesting: !!(data !== null && data !== void 0 && (_data$rainWaterHarves16 = data.rainWaterHarvesting) !== null && _data$rainWaterHarves16 !== void 0 && _data$rainWaterHarves16.hasCertificate || data !== null && data !== void 0 && (_data$rainWaterHarves17 = data.rainWaterHarvesting) !== null && _data$rainWaterHarves17 !== void 0 && _data$rainWaterHarves17.isRainwaterHarvesting)
|
|
1480
|
+
} : {}),
|
|
1481
|
+
...((data === null || data === void 0 ? void 0 : data.sewerTreatmentPlant) !== undefined ? {
|
|
1482
|
+
...(data === null || data === void 0 ? void 0 : data.sewerTreatmentPlant),
|
|
1483
|
+
hasSewerTreatmentPlant: !!(data !== null && data !== void 0 && (_data$sewerTreatmentP29 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP29 !== void 0 && _data$sewerTreatmentP29.hasCertificate || data !== null && data !== void 0 && (_data$sewerTreatmentP30 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP30 !== void 0 && _data$sewerTreatmentP30.hasStp || data !== null && data !== void 0 && (_data$sewerTreatmentP31 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP31 !== void 0 && _data$sewerTreatmentP31.isSewerTreatmentPlant),
|
|
1484
|
+
isSewerTreatmentPlant: !!(data !== null && data !== void 0 && (_data$sewerTreatmentP32 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP32 !== void 0 && _data$sewerTreatmentP32.hasCertificate || data !== null && data !== void 0 && (_data$sewerTreatmentP33 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP33 !== void 0 && _data$sewerTreatmentP33.hasStp || data !== null && data !== void 0 && (_data$sewerTreatmentP34 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP34 !== void 0 && _data$sewerTreatmentP34.isSewerTreatmentPlant),
|
|
1485
|
+
hasStp: !!(data !== null && data !== void 0 && (_data$sewerTreatmentP35 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP35 !== void 0 && _data$sewerTreatmentP35.hasCertificate || data !== null && data !== void 0 && (_data$sewerTreatmentP36 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP36 !== void 0 && _data$sewerTreatmentP36.hasStp || data !== null && data !== void 0 && (_data$sewerTreatmentP37 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP37 !== void 0 && _data$sewerTreatmentP37.isSewerTreatmentPlant)
|
|
1386
1486
|
} : {}),
|
|
1387
1487
|
...(getNormalizedBankDetails(data) ? {
|
|
1388
1488
|
...getNormalizedBankDetails(data),
|
|
1389
1489
|
bankDetails: getNormalizedBankDetails(data)
|
|
1390
1490
|
} : {}),
|
|
1391
1491
|
...(data !== null && data !== void 0 && (_data$waterConnection8 = data.waterConnection) !== null && _data$waterConnection8 !== void 0 && _data$waterConnection8.useDetails ? {
|
|
1392
|
-
plotArea: data.waterConnection.useDetails.plotArea || (data === null || data === void 0 ? void 0 : (_data$
|
|
1393
|
-
plotSize: data.waterConnection.useDetails.plotArea || (data === null || data === void 0 ? void 0 : (_data$
|
|
1394
|
-
builtUpArea: data.waterConnection.useDetails.builtUpArea || (data === null || data === void 0 ? void 0 : (_data$
|
|
1395
|
-
heightOfTheBuilding: data.waterConnection.useDetails.heightOfTheBuilding || (data === null || data === void 0 ? void 0 : (_data$
|
|
1396
|
-
categoryType: ((_data$waterConnection9 = data.waterConnection.useDetails.categoryType) === null || _data$waterConnection9 === void 0 ? void 0 : _data$waterConnection9.code) || data.waterConnection.useDetails.categoryType || (data === null || data === void 0 ? void 0 : (_data$
|
|
1397
|
-
propertyCategory: ((_data$waterConnection0 = data.waterConnection.useDetails.propertyCategory) === null || _data$waterConnection0 === void 0 ? void 0 : _data$waterConnection0.code) || data.waterConnection.useDetails.propertyCategory || (data === null || data === void 0 ? void 0 : (_data$
|
|
1398
|
-
propertyType: ((_data$waterConnection1 = data.waterConnection.useDetails.propertyType) === null || _data$waterConnection1 === void 0 ? void 0 : _data$waterConnection1.code) || data.waterConnection.useDetails.propertyType || (data === null || data === void 0 ? void 0 : (_data$
|
|
1399
|
-
waterConnectionUsageType: ((_data$waterConnection10 = data.waterConnection.useDetails.WaterConnectionUsageType) === null || _data$waterConnection10 === void 0 ? void 0 : _data$waterConnection10.code) || data.waterConnection.useDetails.WaterConnectionUsageType || (data === null || data === void 0 ? void 0 : (_data$
|
|
1400
|
-
numberOfDwellingUnits: data.waterConnection.useDetails.NumberofDwellingUnits || (data === null || data === void 0 ? void 0 : (_data$
|
|
1492
|
+
plotArea: data.waterConnection.useDetails.plotArea || (data === null || data === void 0 ? void 0 : (_data$additionalDetai31 = data.additionalDetails) === null || _data$additionalDetai31 === void 0 ? void 0 : _data$additionalDetai31.plotArea) || (SewerageResult === null || SewerageResult === void 0 ? void 0 : (_SewerageResult$addit4 = SewerageResult.additionalDetails) === null || _SewerageResult$addit4 === void 0 ? void 0 : _SewerageResult$addit4.plotArea),
|
|
1493
|
+
plotSize: data.waterConnection.useDetails.plotArea || (data === null || data === void 0 ? void 0 : (_data$additionalDetai32 = data.additionalDetails) === null || _data$additionalDetai32 === void 0 ? void 0 : _data$additionalDetai32.plotSize) || (SewerageResult === null || SewerageResult === void 0 ? void 0 : (_SewerageResult$addit5 = SewerageResult.additionalDetails) === null || _SewerageResult$addit5 === void 0 ? void 0 : _SewerageResult$addit5.plotSize),
|
|
1494
|
+
builtUpArea: data.waterConnection.useDetails.builtUpArea || (data === null || data === void 0 ? void 0 : (_data$additionalDetai33 = data.additionalDetails) === null || _data$additionalDetai33 === void 0 ? void 0 : _data$additionalDetai33.builtUpArea) || (SewerageResult === null || SewerageResult === void 0 ? void 0 : (_SewerageResult$addit6 = SewerageResult.additionalDetails) === null || _SewerageResult$addit6 === void 0 ? void 0 : _SewerageResult$addit6.builtUpArea),
|
|
1495
|
+
heightOfTheBuilding: data.waterConnection.useDetails.heightOfTheBuilding || (data === null || data === void 0 ? void 0 : (_data$additionalDetai34 = data.additionalDetails) === null || _data$additionalDetai34 === void 0 ? void 0 : _data$additionalDetai34.heightOfTheBuilding) || (SewerageResult === null || SewerageResult === void 0 ? void 0 : (_SewerageResult$addit7 = SewerageResult.additionalDetails) === null || _SewerageResult$addit7 === void 0 ? void 0 : _SewerageResult$addit7.heightOfTheBuilding),
|
|
1496
|
+
categoryType: ((_data$waterConnection9 = data.waterConnection.useDetails.categoryType) === null || _data$waterConnection9 === void 0 ? void 0 : _data$waterConnection9.code) || data.waterConnection.useDetails.categoryType || (data === null || data === void 0 ? void 0 : (_data$additionalDetai35 = data.additionalDetails) === null || _data$additionalDetai35 === void 0 ? void 0 : _data$additionalDetai35.categoryType) || (SewerageResult === null || SewerageResult === void 0 ? void 0 : (_SewerageResult$addit8 = SewerageResult.additionalDetails) === null || _SewerageResult$addit8 === void 0 ? void 0 : _SewerageResult$addit8.categoryType),
|
|
1497
|
+
propertyCategory: ((_data$waterConnection0 = data.waterConnection.useDetails.propertyCategory) === null || _data$waterConnection0 === void 0 ? void 0 : _data$waterConnection0.code) || data.waterConnection.useDetails.propertyCategory || (data === null || data === void 0 ? void 0 : (_data$additionalDetai36 = data.additionalDetails) === null || _data$additionalDetai36 === void 0 ? void 0 : _data$additionalDetai36.propertyCategory) || (SewerageResult === null || SewerageResult === void 0 ? void 0 : (_SewerageResult$addit9 = SewerageResult.additionalDetails) === null || _SewerageResult$addit9 === void 0 ? void 0 : _SewerageResult$addit9.propertyCategory),
|
|
1498
|
+
propertyType: ((_data$waterConnection1 = data.waterConnection.useDetails.propertyType) === null || _data$waterConnection1 === void 0 ? void 0 : _data$waterConnection1.code) || data.waterConnection.useDetails.propertyType || (data === null || data === void 0 ? void 0 : (_data$additionalDetai37 = data.additionalDetails) === null || _data$additionalDetai37 === void 0 ? void 0 : _data$additionalDetai37.propertyType) || (SewerageResult === null || SewerageResult === void 0 ? void 0 : (_SewerageResult$addit0 = SewerageResult.additionalDetails) === null || _SewerageResult$addit0 === void 0 ? void 0 : _SewerageResult$addit0.propertyType),
|
|
1499
|
+
waterConnectionUsageType: ((_data$waterConnection10 = data.waterConnection.useDetails.WaterConnectionUsageType) === null || _data$waterConnection10 === void 0 ? void 0 : _data$waterConnection10.code) || data.waterConnection.useDetails.WaterConnectionUsageType || (data === null || data === void 0 ? void 0 : (_data$additionalDetai38 = data.additionalDetails) === null || _data$additionalDetai38 === void 0 ? void 0 : _data$additionalDetai38.waterConnectionUsageType) || (SewerageResult === null || SewerageResult === void 0 ? void 0 : (_SewerageResult$addit1 = SewerageResult.additionalDetails) === null || _SewerageResult$addit1 === void 0 ? void 0 : _SewerageResult$addit1.waterConnectionUsageType),
|
|
1500
|
+
numberOfDwellingUnits: data.waterConnection.useDetails.NumberofDwellingUnits || (data === null || data === void 0 ? void 0 : (_data$additionalDetai39 = data.additionalDetails) === null || _data$additionalDetai39 === void 0 ? void 0 : _data$additionalDetai39.numberOfDwellingUnits) || (data === null || data === void 0 ? void 0 : (_data$property4 = data.property) === null || _data$property4 === void 0 ? void 0 : (_data$property4$addit = _data$property4.additionalDetails) === null || _data$property4$addit === void 0 ? void 0 : _data$property4$addit.numberOfDwellingUnits) || (data === null || data === void 0 ? void 0 : (_data$cpt33 = data.cpt) === null || _data$cpt33 === void 0 ? void 0 : (_data$cpt33$details = _data$cpt33.details) === null || _data$cpt33$details === void 0 ? void 0 : (_data$cpt33$details$a = _data$cpt33$details.additionalDetails) === null || _data$cpt33$details$a === void 0 ? void 0 : _data$cpt33$details$a.numberOfDwellingUnits) || (SewerageResult === null || SewerageResult === void 0 ? void 0 : (_SewerageResult$addit10 = SewerageResult.additionalDetails) === null || _SewerageResult$addit10 === void 0 ? void 0 : _SewerageResult$addit10.numberOfDwellingUnits) || ""
|
|
1401
1501
|
} : {})
|
|
1402
1502
|
},
|
|
1403
1503
|
auditDetails: data !== null && data !== void 0 && data.isEditApplication ? data === null || data === void 0 ? void 0 : data.auditDetails : SewerageResult === null || SewerageResult === void 0 ? void 0 : SewerageResult.auditDetails,
|
|
@@ -1482,8 +1582,8 @@ const convertToEditSWUpdate = data => {
|
|
|
1482
1582
|
};
|
|
1483
1583
|
})(),
|
|
1484
1584
|
dueVerification: data !== null && data !== void 0 && data.isEditApplication ? data === null || data === void 0 ? void 0 : data.dueVerification : SewerageResult === null || SewerageResult === void 0 ? void 0 : SewerageResult.dueVerification,
|
|
1485
|
-
water: data !== null && data !== void 0 && (_data$
|
|
1486
|
-
sewerage: data !== null && data !== void 0 && (_data$
|
|
1585
|
+
water: data !== null && data !== void 0 && (_data$applicationType4 = data.applicationType) !== null && _data$applicationType4 !== void 0 && _data$applicationType4.includes("WATER") || data !== null && data !== void 0 && (_data$applicationType5 = data.applicationType) !== null && _data$applicationType5 !== void 0 && _data$applicationType5.includes("WS") ? true : false,
|
|
1586
|
+
sewerage: data !== null && data !== void 0 && (_data$applicationType6 = data.applicationType) !== null && _data$applicationType6 !== void 0 && _data$applicationType6.includes("SEWERAGE") || data !== null && data !== void 0 && (_data$applicationType7 = data.applicationType) !== null && _data$applicationType7 !== void 0 && _data$applicationType7.includes("SW") ? true : false,
|
|
1487
1587
|
service: data !== null && data !== void 0 && data.isEditApplication ? data === null || data === void 0 ? void 0 : (_data$serviceName2 = data.serviceName) === null || _data$serviceName2 === void 0 ? void 0 : _data$serviceName2.code : SewerageResult === null || SewerageResult === void 0 ? void 0 : (_SewerageResult$servi = SewerageResult.serviceName) === null || _SewerageResult$servi === void 0 ? void 0 : _SewerageResult$servi.code,
|
|
1488
1588
|
reviewDocData: [...getAllDocumentsForUpdate(data)],
|
|
1489
1589
|
proposedWaterClosets: data === null || data === void 0 ? void 0 : (_data$sewerageConnect3 = data.sewerageConnectionDetails) === null || _data$sewerageConnect3 === void 0 ? void 0 : _data$sewerageConnect3.proposedWaterClosets,
|
|
@@ -1499,7 +1599,7 @@ const convertToEditSWUpdate = data => {
|
|
|
1499
1599
|
return formdata;
|
|
1500
1600
|
};
|
|
1501
1601
|
const convertToSWUpdate = data => {
|
|
1502
|
-
var _data$SewerageConnect3, _data$SewerageConnect4, _data$cpt35, _data$SewerageConnect5, _data$SewerageConnect6, _data$SewerageConnect7, _data$SewerageConnect8, _data$SewerageConnect9, _data$SewerageConnect0, _data$djbEmployee57, _data$djbEmployee58, _data$djbEmployee59, _data$djbEmployee60, _data$djbEmployee61, _data$djbEmployee62, _data$djbEmployee63, _data$djbEmployee64, _data$djbEmployee65, _data$djbEmployee66, _data$djbEmployee67, _data$djbEmployee68, _data$djbEmployee69, _data$djbEmployee70, _data$djbEmployee70$d, _data$djbEmployee71, _data$disability5, _data$
|
|
1602
|
+
var _data$SewerageConnect3, _data$SewerageConnect4, _data$cpt35, _data$SewerageConnect5, _data$SewerageConnect6, _data$SewerageConnect7, _data$SewerageConnect8, _data$SewerageConnect9, _data$SewerageConnect0, _data$djbEmployee57, _data$djbEmployee58, _data$djbEmployee59, _data$djbEmployee60, _data$djbEmployee61, _data$djbEmployee62, _data$djbEmployee63, _data$djbEmployee64, _data$djbEmployee65, _data$djbEmployee66, _data$djbEmployee67, _data$djbEmployee68, _data$djbEmployee69, _data$djbEmployee70, _data$djbEmployee70$d, _data$djbEmployee71, _data$disability5, _data$rainWaterHarves18, _data$rainWaterHarves19, _data$rainWaterHarves20, _data$rainWaterHarves21, _data$sewerTreatmentP38, _data$sewerTreatmentP39, _data$sewerTreatmentP40, _data$sewerTreatmentP41, _data$sewerTreatmentP42, _data$sewerTreatmentP43, _data$sewerTreatmentP44, _data$sewerTreatmentP45, _data$sewerTreatmentP46, _Digit14, _Digit14$Customizatio, _Digit14$Customizatio2, _Digit15, _Digit15$Customizatio, _Digit15$Customizatio2;
|
|
1503
1603
|
const {
|
|
1504
1604
|
signatureFileStoreId,
|
|
1505
1605
|
signatureFileName
|
|
@@ -1540,8 +1640,14 @@ const convertToSWUpdate = data => {
|
|
|
1540
1640
|
} : {}),
|
|
1541
1641
|
...((data === null || data === void 0 ? void 0 : data.rainWaterHarvesting) !== undefined ? {
|
|
1542
1642
|
...(data === null || data === void 0 ? void 0 : data.rainWaterHarvesting),
|
|
1543
|
-
hasRainWaterHarvestingCertificate: !!(data !== null && data !== void 0 && (_data$
|
|
1544
|
-
isRainwaterHarvesting: !!(data !== null && data !== void 0 && (_data$
|
|
1643
|
+
hasRainWaterHarvestingCertificate: !!(data !== null && data !== void 0 && (_data$rainWaterHarves18 = data.rainWaterHarvesting) !== null && _data$rainWaterHarves18 !== void 0 && _data$rainWaterHarves18.hasCertificate || data !== null && data !== void 0 && (_data$rainWaterHarves19 = data.rainWaterHarvesting) !== null && _data$rainWaterHarves19 !== void 0 && _data$rainWaterHarves19.isRainwaterHarvesting),
|
|
1644
|
+
isRainwaterHarvesting: !!(data !== null && data !== void 0 && (_data$rainWaterHarves20 = data.rainWaterHarvesting) !== null && _data$rainWaterHarves20 !== void 0 && _data$rainWaterHarves20.hasCertificate || data !== null && data !== void 0 && (_data$rainWaterHarves21 = data.rainWaterHarvesting) !== null && _data$rainWaterHarves21 !== void 0 && _data$rainWaterHarves21.isRainwaterHarvesting)
|
|
1645
|
+
} : {}),
|
|
1646
|
+
...((data === null || data === void 0 ? void 0 : data.sewerTreatmentPlant) !== undefined ? {
|
|
1647
|
+
...(data === null || data === void 0 ? void 0 : data.sewerTreatmentPlant),
|
|
1648
|
+
hasSewerTreatmentPlant: !!(data !== null && data !== void 0 && (_data$sewerTreatmentP38 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP38 !== void 0 && _data$sewerTreatmentP38.hasCertificate || data !== null && data !== void 0 && (_data$sewerTreatmentP39 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP39 !== void 0 && _data$sewerTreatmentP39.hasStp || data !== null && data !== void 0 && (_data$sewerTreatmentP40 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP40 !== void 0 && _data$sewerTreatmentP40.isSewerTreatmentPlant),
|
|
1649
|
+
isSewerTreatmentPlant: !!(data !== null && data !== void 0 && (_data$sewerTreatmentP41 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP41 !== void 0 && _data$sewerTreatmentP41.hasCertificate || data !== null && data !== void 0 && (_data$sewerTreatmentP42 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP42 !== void 0 && _data$sewerTreatmentP42.hasStp || data !== null && data !== void 0 && (_data$sewerTreatmentP43 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP43 !== void 0 && _data$sewerTreatmentP43.isSewerTreatmentPlant),
|
|
1650
|
+
hasStp: !!(data !== null && data !== void 0 && (_data$sewerTreatmentP44 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP44 !== void 0 && _data$sewerTreatmentP44.hasCertificate || data !== null && data !== void 0 && (_data$sewerTreatmentP45 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP45 !== void 0 && _data$sewerTreatmentP45.hasStp || data !== null && data !== void 0 && (_data$sewerTreatmentP46 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP46 !== void 0 && _data$sewerTreatmentP46.isSewerTreatmentPlant)
|
|
1545
1651
|
} : {}),
|
|
1546
1652
|
...(getNormalizedBankDetails(data) ? {
|
|
1547
1653
|
...getNormalizedBankDetails(data),
|
|
@@ -1558,7 +1664,7 @@ const convertToSWUpdate = data => {
|
|
|
1558
1664
|
};
|
|
1559
1665
|
const createPayloadOfWSDisconnection = function (data, storeData, service) {
|
|
1560
1666
|
try {
|
|
1561
|
-
var _Digit$UserService$ge8, _Digit$UserService$ge9, _storeData$applicatio, _storeData$applicatio2, _storeData$applicatio25, _storeData$applicatio26, _storeData$applicatio27, _storeData$applicatio28, _storeData$applicatio29, _storeData$applicatio30, _data$type, _data$type$value, _data$type2, _data$type2$value, _data$reason, _data$reason$value, _data$reason2, _data$reason3, _storeData$applicatio31, _storeData$applicatio32, _storeData$applicatio33, _storeData$applicatio34, _storeData$applicatio35, _storeData$applicatio36, _storeData$applicatio37, _storeData$applicatio38, _storeData$applicatio39, _storeData$applicatio40, _plumberInfo, _storeData$applicatio41, _storeData$applicatio42, _storeData$applicatio43, _storeData$applicatio44, _storeData$applicatio45, _storeData$applicatio46, _storeData$applicatio47, _storeData$applicatio48, _storeData$applicatio49, _storeData$applicatio54, _storeData$applicatio55, _storeData$applicatio56, _storeData$applicatio57, _storeData$applicatio58, _storeData$applicatio59, _data$type3, _data$type3$value, _data$reason4, _data$reason4$value, _data$reason5, _data$reason6, _storeData$applicatio60, _storeData$applicatio61, _storeData$applicatio62, _storeData$applicatio63, _storeData$applicatio64, _storeData$applicatio65, _storeData$applicatio66, _storeData$applicatio67, _plumberInfo2, _storeData$applicatio68, _storeData$applicatio69, _storeData$applicatio70, _storeData$applicatio71, _storeData$applicatio72, _storeData$applicatio73, _storeData$applicatio74, _storeData$applicatio75, _Digit16, _Digit16$Customizatio, _Digit16$Customizatio2, _Digit17, _Digit17$Customizatio, _Digit17$Customizatio2;
|
|
1667
|
+
var _Digit$UserService$ge8, _Digit$UserService$ge9, _storeData$applicatio, _storeData$applicatio2, _storeData$applicatio25, _storeData$applicatio26, _storeData$applicatio27, _storeData$applicatio28, _storeData$applicatio29, _storeData$applicatio30, _data$type, _data$type$value, _data$type2, _data$type2$value, _data$reason, _data$reason$value, _data$reason2, _data$reason3, _storeData$applicatio31, _storeData$applicatio32, _storeData$applicatio33, _storeData$applicatio34, _storeData$applicatio35, _storeData$applicatio36, _storeData$applicatio37, _storeData$applicatio38, _storeData$applicatio39, _storeData$applicatio40, _plumberInfo, _storeData$applicatio41, _storeData$applicatio42, _storeData$applicatio43, _storeData$applicatio44, _storeData$applicatio45, _storeData$applicatio46, _storeData$applicatio47, _storeData$applicatio48, _storeData$applicatio49, _storeData$applicatio54, _storeData$applicatio55, _storeData$applicatio56, _storeData$applicatio57, _storeData$applicatio58, _storeData$applicatio59, _data$type3, _data$type3$value, _data$reason4, _data$reason4$value, _data$reason5, _data$reason6, _storeData$applicatio60, _storeData$applicatio61, _storeData$applicatio62, _storeData$applicatio63, _storeData$applicatio64, _storeData$applicatio65, _storeData$applicatio66, _storeData$applicatio67, _plumberInfo2, _storeData$applicatio68, _storeData$applicatio69, _storeData$applicatio70, _storeData$applicatio71, _storeData$applicatio72, _storeData$applicatio73, _storeData$applicatio74, _storeData$applicatio75, _storeData$applicatio76, _storeData$applicatio77, _storeData$applicatio78, _storeData$applicatio79, _storeData$applicatio80, _Digit16, _Digit16$Customizatio, _Digit16$Customizatio2, _Digit17, _Digit17$Customizatio, _Digit17$Customizatio2;
|
|
1562
1668
|
const user = (_Digit$UserService$ge8 = Digit.UserService.getUser()) === null || _Digit$UserService$ge8 === void 0 ? void 0 : (_Digit$UserService$ge9 = _Digit$UserService$ge8.info) === null || _Digit$UserService$ge9 === void 0 ? void 0 : _Digit$UserService$ge9.type;
|
|
1563
1669
|
let plumberInfo = [];
|
|
1564
1670
|
if ((storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio = storeData.applicationData) === null || _storeData$applicatio === void 0 ? void 0 : (_storeData$applicatio2 = _storeData$applicatio.plumberInfo) === null || _storeData$applicatio2 === void 0 ? void 0 : _storeData$applicatio2.length) > 0) {
|
|
@@ -1658,7 +1764,8 @@ const createPayloadOfWSDisconnection = function (data, storeData, service) {
|
|
|
1658
1764
|
},
|
|
1659
1765
|
disconnectRequest: true
|
|
1660
1766
|
};
|
|
1661
|
-
|
|
1767
|
+
const isSewerageService = ((service === null || service === void 0 ? void 0 : service.toUpperCase()) === "SEWERAGE" || (service === null || service === void 0 ? void 0 : service.toUpperCase()) === "SW") && !(storeData !== null && storeData !== void 0 && (_storeData$applicatio76 = storeData.applicationData) !== null && _storeData$applicatio76 !== void 0 && _storeData$applicatio76.water) && !(storeData !== null && storeData !== void 0 && (_storeData$applicatio77 = storeData.applicationData) !== null && _storeData$applicatio77 !== void 0 && (_storeData$applicatio78 = _storeData$applicatio77.connectionNo) !== null && _storeData$applicatio78 !== void 0 && _storeData$applicatio78.includes("WS")) && !(storeData !== null && storeData !== void 0 && (_storeData$applicatio79 = storeData.applicationData) !== null && _storeData$applicatio79 !== void 0 && (_storeData$applicatio80 = _storeData$applicatio79.applicationNo) !== null && _storeData$applicatio80 !== void 0 && _storeData$applicatio80.includes("WS"));
|
|
1768
|
+
let returnObject = isSewerageService ? swPayload : wsPayload;
|
|
1662
1769
|
returnObject = (_Digit16 = Digit) !== null && _Digit16 !== void 0 && (_Digit16$Customizatio = _Digit16.Customizations) !== null && _Digit16$Customizatio !== void 0 && (_Digit16$Customizatio2 = _Digit16$Customizatio.WS) !== null && _Digit16$Customizatio2 !== void 0 && _Digit16$Customizatio2.customiseCreatePayloadOfWSDisconnection ? (_Digit17 = Digit) === null || _Digit17 === void 0 ? void 0 : (_Digit17$Customizatio = _Digit17.Customizations) === null || _Digit17$Customizatio === void 0 ? void 0 : (_Digit17$Customizatio2 = _Digit17$Customizatio.WS) === null || _Digit17$Customizatio2 === void 0 ? void 0 : _Digit17$Customizatio2.customiseCreatePayloadOfWSDisconnection(data, returnObject, service) : returnObject;
|
|
1663
1770
|
return Promise.resolve(returnObject);
|
|
1664
1771
|
} catch (e) {
|
|
@@ -1667,26 +1774,26 @@ const createPayloadOfWSDisconnection = function (data, storeData, service) {
|
|
|
1667
1774
|
};
|
|
1668
1775
|
const createPayloadOfWSReconnection = function (data, storeData, service) {
|
|
1669
1776
|
try {
|
|
1670
|
-
var _Digit$UserService$ge0, _Digit$UserService$ge1, _storeData$
|
|
1777
|
+
var _Digit$UserService$ge0, _Digit$UserService$ge1, _storeData$applicatio81, _storeData$applicatio82, _storeData$applicatio107, _storeData$applicatio108, _storeData$applicatio109, _storeData$applicatio110, _storeData$applicatio111, _storeData$applicatio112, _data$reason7, _data$reason7$value, _data$reason8, _data$reason9, _data$reason0, _storeData$applicatio113, _storeData$applicatio114, _storeData$applicatio115, _storeData$applicatio116, _storeData$applicatio117, _storeData$applicatio118, _storeData$applicatio119, _storeData$applicatio120, _plumberInfo3, _storeData$applicatio121, _storeData$applicatio122, _storeData$applicatio123, _storeData$applicatio124, _storeData$applicatio125, _storeData$applicatio126, _storeData$applicatio127, _storeData$applicatio128, _storeData$applicatio129, _storeData$applicatio134, _storeData$applicatio135, _storeData$applicatio136, _storeData$applicatio137, _storeData$applicatio138, _storeData$applicatio139, _data$reason1, _data$reason1$value, _data$reason10, _data$reason11, _data$reason12, _storeData$applicatio140, _storeData$applicatio141, _storeData$applicatio142, _storeData$applicatio143, _storeData$applicatio144, _storeData$applicatio145, _plumberInfo4, _storeData$applicatio146, _storeData$applicatio147, _storeData$applicatio148, _storeData$applicatio149, _storeData$applicatio150, _storeData$applicatio151, _storeData$applicatio152, _storeData$applicatio153, _storeData$applicatio154, _storeData$applicatio155, _storeData$applicatio156, _storeData$applicatio157, _storeData$applicatio158;
|
|
1671
1778
|
const user = (_Digit$UserService$ge0 = Digit.UserService.getUser()) === null || _Digit$UserService$ge0 === void 0 ? void 0 : (_Digit$UserService$ge1 = _Digit$UserService$ge0.info) === null || _Digit$UserService$ge1 === void 0 ? void 0 : _Digit$UserService$ge1.type;
|
|
1672
1779
|
let plumberInfo = [];
|
|
1673
|
-
if ((storeData === null || storeData === void 0 ? void 0 : (_storeData$
|
|
1674
|
-
var _storeData$
|
|
1780
|
+
if ((storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio81 = storeData.applicationData) === null || _storeData$applicatio81 === void 0 ? void 0 : (_storeData$applicatio82 = _storeData$applicatio81.plumberInfo) === null || _storeData$applicatio82 === void 0 ? void 0 : _storeData$applicatio82.length) > 0) {
|
|
1781
|
+
var _storeData$applicatio83, _storeData$applicatio84, _storeData$applicatio85, _storeData$applicatio86, _storeData$applicatio87, _storeData$applicatio88, _storeData$applicatio89, _storeData$applicatio90, _storeData$applicatio91, _storeData$applicatio92, _storeData$applicatio93, _storeData$applicatio94, _storeData$applicatio95, _storeData$applicatio96, _storeData$applicatio97, _storeData$applicatio98, _storeData$applicatio99, _storeData$applicatio100, _storeData$applicatio101, _storeData$applicatio102, _storeData$applicatio103, _storeData$applicatio104, _storeData$applicatio105, _storeData$applicatio106;
|
|
1675
1782
|
let plumberInfoData = {};
|
|
1676
|
-
if (storeData !== null && storeData !== void 0 && (_storeData$
|
|
1677
|
-
if (storeData !== null && storeData !== void 0 && (_storeData$
|
|
1678
|
-
if (storeData !== null && storeData !== void 0 && (_storeData$
|
|
1679
|
-
if (storeData !== null && storeData !== void 0 && (_storeData$
|
|
1783
|
+
if (storeData !== null && storeData !== void 0 && (_storeData$applicatio83 = storeData.applicationData) !== null && _storeData$applicatio83 !== void 0 && (_storeData$applicatio84 = _storeData$applicatio83.plumberInfo) !== null && _storeData$applicatio84 !== void 0 && (_storeData$applicatio85 = _storeData$applicatio84[0]) !== null && _storeData$applicatio85 !== void 0 && _storeData$applicatio85.licenseNo) plumberInfoData.licenseNo = storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio86 = storeData.applicationData) === null || _storeData$applicatio86 === void 0 ? void 0 : (_storeData$applicatio87 = _storeData$applicatio86.plumberInfo) === null || _storeData$applicatio87 === void 0 ? void 0 : (_storeData$applicatio88 = _storeData$applicatio87[0]) === null || _storeData$applicatio88 === void 0 ? void 0 : _storeData$applicatio88.licenseNo;
|
|
1784
|
+
if (storeData !== null && storeData !== void 0 && (_storeData$applicatio89 = storeData.applicationData) !== null && _storeData$applicatio89 !== void 0 && (_storeData$applicatio90 = _storeData$applicatio89.plumberInfo) !== null && _storeData$applicatio90 !== void 0 && (_storeData$applicatio91 = _storeData$applicatio90[0]) !== null && _storeData$applicatio91 !== void 0 && _storeData$applicatio91.mobileNumber) plumberInfoData.mobileNumber = storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio92 = storeData.applicationData) === null || _storeData$applicatio92 === void 0 ? void 0 : (_storeData$applicatio93 = _storeData$applicatio92.plumberInfo) === null || _storeData$applicatio93 === void 0 ? void 0 : (_storeData$applicatio94 = _storeData$applicatio93[0]) === null || _storeData$applicatio94 === void 0 ? void 0 : _storeData$applicatio94.mobileNumber;
|
|
1785
|
+
if (storeData !== null && storeData !== void 0 && (_storeData$applicatio95 = storeData.applicationData) !== null && _storeData$applicatio95 !== void 0 && (_storeData$applicatio96 = _storeData$applicatio95.plumberInfo) !== null && _storeData$applicatio96 !== void 0 && (_storeData$applicatio97 = _storeData$applicatio96[0]) !== null && _storeData$applicatio97 !== void 0 && _storeData$applicatio97.id) plumberInfoData.id = storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio98 = storeData.applicationData) === null || _storeData$applicatio98 === void 0 ? void 0 : (_storeData$applicatio99 = _storeData$applicatio98.plumberInfo) === null || _storeData$applicatio99 === void 0 ? void 0 : (_storeData$applicatio100 = _storeData$applicatio99[0]) === null || _storeData$applicatio100 === void 0 ? void 0 : _storeData$applicatio100.id;
|
|
1786
|
+
if (storeData !== null && storeData !== void 0 && (_storeData$applicatio101 = storeData.applicationData) !== null && _storeData$applicatio101 !== void 0 && (_storeData$applicatio102 = _storeData$applicatio101.plumberInfo) !== null && _storeData$applicatio102 !== void 0 && (_storeData$applicatio103 = _storeData$applicatio102[0]) !== null && _storeData$applicatio103 !== void 0 && _storeData$applicatio103.name) plumberInfoData.name = storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio104 = storeData.applicationData) === null || _storeData$applicatio104 === void 0 ? void 0 : (_storeData$applicatio105 = _storeData$applicatio104.plumberInfo) === null || _storeData$applicatio105 === void 0 ? void 0 : (_storeData$applicatio106 = _storeData$applicatio105[0]) === null || _storeData$applicatio106 === void 0 ? void 0 : _storeData$applicatio106.name;
|
|
1680
1787
|
plumberInfo = [plumberInfoData];
|
|
1681
1788
|
}
|
|
1682
1789
|
let wsPayload = {
|
|
1683
1790
|
WaterConnection: {
|
|
1684
|
-
id: storeData === null || storeData === void 0 ? void 0 : (_storeData$
|
|
1685
|
-
applicationNo: storeData === null || storeData === void 0 ? void 0 : (_storeData$
|
|
1686
|
-
applicationStatus: storeData === null || storeData === void 0 ? void 0 : (_storeData$
|
|
1687
|
-
status: storeData === null || storeData === void 0 ? void 0 : (_storeData$
|
|
1688
|
-
connectionNo: storeData === null || storeData === void 0 ? void 0 : (_storeData$
|
|
1689
|
-
connectionHolders: storeData === null || storeData === void 0 ? void 0 : (_storeData$
|
|
1791
|
+
id: storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio107 = storeData.applicationData) === null || _storeData$applicatio107 === void 0 ? void 0 : _storeData$applicatio107.id,
|
|
1792
|
+
applicationNo: storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio108 = storeData.applicationData) === null || _storeData$applicatio108 === void 0 ? void 0 : _storeData$applicatio108.applicationNo,
|
|
1793
|
+
applicationStatus: storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio109 = storeData.applicationData) === null || _storeData$applicatio109 === void 0 ? void 0 : _storeData$applicatio109.applicationStatus,
|
|
1794
|
+
status: storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio110 = storeData.applicationData) === null || _storeData$applicatio110 === void 0 ? void 0 : _storeData$applicatio110.status,
|
|
1795
|
+
connectionNo: storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio111 = storeData.applicationData) === null || _storeData$applicatio111 === void 0 ? void 0 : _storeData$applicatio111.connectionNo,
|
|
1796
|
+
connectionHolders: storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio112 = storeData.applicationData) === null || _storeData$applicatio112 === void 0 ? void 0 : _storeData$applicatio112.connectionHolders,
|
|
1690
1797
|
applicationType: "WATER_RECONNECTION",
|
|
1691
1798
|
dateEffectiveFrom: convertDateToEpoch(data === null || data === void 0 ? void 0 : data.date),
|
|
1692
1799
|
isdisconnection: false,
|
|
@@ -1696,24 +1803,24 @@ const createPayloadOfWSReconnection = function (data, storeData, service) {
|
|
|
1696
1803
|
documents: data === null || data === void 0 ? void 0 : data.documents,
|
|
1697
1804
|
water: true,
|
|
1698
1805
|
sewerage: false,
|
|
1699
|
-
proposedTaps: (storeData === null || storeData === void 0 ? void 0 : (_storeData$
|
|
1700
|
-
proposedPipeSize: (storeData === null || storeData === void 0 ? void 0 : (_storeData$
|
|
1806
|
+
proposedTaps: (storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio113 = storeData.applicationData) === null || _storeData$applicatio113 === void 0 ? void 0 : _storeData$applicatio113.proposedTaps) && Number(storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio114 = storeData.applicationData) === null || _storeData$applicatio114 === void 0 ? void 0 : _storeData$applicatio114.proposedTaps),
|
|
1807
|
+
proposedPipeSize: (storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio115 = storeData.applicationData) === null || _storeData$applicatio115 === void 0 ? void 0 : (_storeData$applicatio116 = _storeData$applicatio115.proposedPipeSize) === null || _storeData$applicatio116 === void 0 ? void 0 : _storeData$applicatio116.size) && Number(storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio117 = storeData.applicationData) === null || _storeData$applicatio117 === void 0 ? void 0 : (_storeData$applicatio118 = _storeData$applicatio117.proposedPipeSize) === null || _storeData$applicatio118 === void 0 ? void 0 : _storeData$applicatio118.size),
|
|
1701
1808
|
service: "Water",
|
|
1702
|
-
property: storeData === null || storeData === void 0 ? void 0 : (_storeData$
|
|
1703
|
-
propertyId: storeData === null || storeData === void 0 ? void 0 : (_storeData$
|
|
1809
|
+
property: storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio119 = storeData.applicationData) === null || _storeData$applicatio119 === void 0 ? void 0 : _storeData$applicatio119.property,
|
|
1810
|
+
propertyId: storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio120 = storeData.applicationData) === null || _storeData$applicatio120 === void 0 ? void 0 : _storeData$applicatio120.propertyId,
|
|
1704
1811
|
oldConnectionNo: null,
|
|
1705
1812
|
plumberInfo: ((_plumberInfo3 = plumberInfo) === null || _plumberInfo3 === void 0 ? void 0 : _plumberInfo3.length) > 0 ? plumberInfo : null,
|
|
1706
|
-
roadCuttingInfo: storeData === null || storeData === void 0 ? void 0 : (_storeData$
|
|
1813
|
+
roadCuttingInfo: storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio121 = storeData.applicationData) === null || _storeData$applicatio121 === void 0 ? void 0 : _storeData$applicatio121.roadCuttingInfo,
|
|
1707
1814
|
roadCuttingArea: null,
|
|
1708
1815
|
roadType: null,
|
|
1709
|
-
connectionExecutionDate: storeData === null || storeData === void 0 ? void 0 : (_storeData$
|
|
1710
|
-
noOfTaps: storeData === null || storeData === void 0 ? void 0 : (_storeData$
|
|
1711
|
-
additionalDetails: storeData === null || storeData === void 0 ? void 0 : (_storeData$
|
|
1712
|
-
tenantId: storeData === null || storeData === void 0 ? void 0 : (_storeData$
|
|
1713
|
-
connectionType: (storeData === null || storeData === void 0 ? void 0 : (_storeData$
|
|
1714
|
-
waterSource: (storeData === null || storeData === void 0 ? void 0 : (_storeData$
|
|
1816
|
+
connectionExecutionDate: storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio122 = storeData.applicationData) === null || _storeData$applicatio122 === void 0 ? void 0 : _storeData$applicatio122.connectionExecutionDate,
|
|
1817
|
+
noOfTaps: storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio123 = storeData.applicationData) === null || _storeData$applicatio123 === void 0 ? void 0 : _storeData$applicatio123.noOfTaps,
|
|
1818
|
+
additionalDetails: storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio124 = storeData.applicationData) === null || _storeData$applicatio124 === void 0 ? void 0 : _storeData$applicatio124.additionalDetails,
|
|
1819
|
+
tenantId: storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio125 = storeData.applicationData) === null || _storeData$applicatio125 === void 0 ? void 0 : _storeData$applicatio125.tenantId,
|
|
1820
|
+
connectionType: (storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio126 = storeData.applicationData) === null || _storeData$applicatio126 === void 0 ? void 0 : _storeData$applicatio126.connectionType) || null,
|
|
1821
|
+
waterSource: (storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio127 = storeData.applicationData) === null || _storeData$applicatio127 === void 0 ? void 0 : _storeData$applicatio127.waterSource) || null,
|
|
1715
1822
|
processInstance: {
|
|
1716
|
-
...(storeData === null || storeData === void 0 ? void 0 : (_storeData$
|
|
1823
|
+
...(storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio128 = storeData.applicationData) === null || _storeData$applicatio128 === void 0 ? void 0 : _storeData$applicatio128.processInstance),
|
|
1717
1824
|
action: "INITIATE",
|
|
1718
1825
|
businessService: "WSReconnection"
|
|
1719
1826
|
},
|
|
@@ -1721,19 +1828,19 @@ const createPayloadOfWSReconnection = function (data, storeData, service) {
|
|
|
1721
1828
|
},
|
|
1722
1829
|
disconnectRequest: false
|
|
1723
1830
|
};
|
|
1724
|
-
if (storeData !== null && storeData !== void 0 && (_storeData$
|
|
1725
|
-
var _storeData$
|
|
1726
|
-
if (storeData !== null && storeData !== void 0 && (_storeData$
|
|
1727
|
-
if (storeData !== null && storeData !== void 0 && (_storeData$
|
|
1831
|
+
if (storeData !== null && storeData !== void 0 && (_storeData$applicatio129 = storeData.applicationData) !== null && _storeData$applicatio129 !== void 0 && _storeData$applicatio129.connectionType) {
|
|
1832
|
+
var _storeData$applicatio130, _storeData$applicatio131, _storeData$applicatio132, _storeData$applicatio133;
|
|
1833
|
+
if (storeData !== null && storeData !== void 0 && (_storeData$applicatio130 = storeData.applicationData) !== null && _storeData$applicatio130 !== void 0 && _storeData$applicatio130.meterInstallationDate) wsPayload.WaterConnection.meterInstallationDate = storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio131 = storeData.applicationData) === null || _storeData$applicatio131 === void 0 ? void 0 : _storeData$applicatio131.meterInstallationDate;
|
|
1834
|
+
if (storeData !== null && storeData !== void 0 && (_storeData$applicatio132 = storeData.applicationData) !== null && _storeData$applicatio132 !== void 0 && _storeData$applicatio132.meterId) wsPayload.WaterConnection.meterId = storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio133 = storeData.applicationData) === null || _storeData$applicatio133 === void 0 ? void 0 : _storeData$applicatio133.meterId;
|
|
1728
1835
|
}
|
|
1729
1836
|
let swPayload = {
|
|
1730
1837
|
SewerageConnection: {
|
|
1731
|
-
id: storeData === null || storeData === void 0 ? void 0 : (_storeData$
|
|
1732
|
-
applicationNo: storeData === null || storeData === void 0 ? void 0 : (_storeData$
|
|
1733
|
-
applicationStatus: storeData === null || storeData === void 0 ? void 0 : (_storeData$
|
|
1734
|
-
status: storeData === null || storeData === void 0 ? void 0 : (_storeData$
|
|
1735
|
-
connectionNo: storeData === null || storeData === void 0 ? void 0 : (_storeData$
|
|
1736
|
-
connectionHolders: storeData === null || storeData === void 0 ? void 0 : (_storeData$
|
|
1838
|
+
id: storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio134 = storeData.applicationData) === null || _storeData$applicatio134 === void 0 ? void 0 : _storeData$applicatio134.id,
|
|
1839
|
+
applicationNo: storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio135 = storeData.applicationData) === null || _storeData$applicatio135 === void 0 ? void 0 : _storeData$applicatio135.applicationNo,
|
|
1840
|
+
applicationStatus: storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio136 = storeData.applicationData) === null || _storeData$applicatio136 === void 0 ? void 0 : _storeData$applicatio136.applicationStatus,
|
|
1841
|
+
status: storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio137 = storeData.applicationData) === null || _storeData$applicatio137 === void 0 ? void 0 : _storeData$applicatio137.status,
|
|
1842
|
+
connectionNo: storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio138 = storeData.applicationData) === null || _storeData$applicatio138 === void 0 ? void 0 : _storeData$applicatio138.connectionNo,
|
|
1843
|
+
connectionHolders: storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio139 = storeData.applicationData) === null || _storeData$applicatio139 === void 0 ? void 0 : _storeData$applicatio139.connectionHolders,
|
|
1737
1844
|
applicationType: "WATER_RECONNECTION",
|
|
1738
1845
|
dateEffectiveFrom: convertDateToEpoch(data === null || data === void 0 ? void 0 : data.date),
|
|
1739
1846
|
isdisconnection: false,
|
|
@@ -1743,25 +1850,25 @@ const createPayloadOfWSReconnection = function (data, storeData, service) {
|
|
|
1743
1850
|
documents: data === null || data === void 0 ? void 0 : data.documents,
|
|
1744
1851
|
water: false,
|
|
1745
1852
|
sewerage: true,
|
|
1746
|
-
proposedWaterClosets: (storeData === null || storeData === void 0 ? void 0 : (_storeData$
|
|
1747
|
-
proposedToilets: (storeData === null || storeData === void 0 ? void 0 : (_storeData$
|
|
1853
|
+
proposedWaterClosets: (storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio140 = storeData.applicationData) === null || _storeData$applicatio140 === void 0 ? void 0 : _storeData$applicatio140.proposedWaterClosets) && Number(storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio141 = storeData.applicationData) === null || _storeData$applicatio141 === void 0 ? void 0 : _storeData$applicatio141.proposedWaterClosets),
|
|
1854
|
+
proposedToilets: (storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio142 = storeData.applicationData) === null || _storeData$applicatio142 === void 0 ? void 0 : _storeData$applicatio142.proposedToilets) && Number(storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio143 = storeData.applicationData) === null || _storeData$applicatio143 === void 0 ? void 0 : _storeData$applicatio143.proposedToilets),
|
|
1748
1855
|
service: "Sewerage",
|
|
1749
|
-
property: storeData === null || storeData === void 0 ? void 0 : (_storeData$
|
|
1750
|
-
propertyId: storeData === null || storeData === void 0 ? void 0 : (_storeData$
|
|
1856
|
+
property: storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio144 = storeData.applicationData) === null || _storeData$applicatio144 === void 0 ? void 0 : _storeData$applicatio144.property,
|
|
1857
|
+
propertyId: storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio145 = storeData.applicationData) === null || _storeData$applicatio145 === void 0 ? void 0 : _storeData$applicatio145.propertyId,
|
|
1751
1858
|
oldConnectionNo: null,
|
|
1752
1859
|
plumberInfo: ((_plumberInfo4 = plumberInfo) === null || _plumberInfo4 === void 0 ? void 0 : _plumberInfo4.length) > 0 ? plumberInfo : null,
|
|
1753
|
-
roadCuttingInfo: storeData === null || storeData === void 0 ? void 0 : (_storeData$
|
|
1860
|
+
roadCuttingInfo: storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio146 = storeData.applicationData) === null || _storeData$applicatio146 === void 0 ? void 0 : _storeData$applicatio146.roadCuttingInfo,
|
|
1754
1861
|
roadCuttingArea: null,
|
|
1755
1862
|
roadType: null,
|
|
1756
|
-
connectionExecutionDate: storeData === null || storeData === void 0 ? void 0 : (_storeData$
|
|
1757
|
-
noOfWaterClosets: storeData === null || storeData === void 0 ? void 0 : (_storeData$
|
|
1758
|
-
noOfToilets: storeData === null || storeData === void 0 ? void 0 : (_storeData$
|
|
1759
|
-
additionalDetails: storeData === null || storeData === void 0 ? void 0 : (_storeData$
|
|
1760
|
-
tenantId: storeData === null || storeData === void 0 ? void 0 : (_storeData$
|
|
1863
|
+
connectionExecutionDate: storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio147 = storeData.applicationData) === null || _storeData$applicatio147 === void 0 ? void 0 : _storeData$applicatio147.connectionExecutionDate,
|
|
1864
|
+
noOfWaterClosets: storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio148 = storeData.applicationData) === null || _storeData$applicatio148 === void 0 ? void 0 : _storeData$applicatio148.noOfWaterClosets,
|
|
1865
|
+
noOfToilets: storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio149 = storeData.applicationData) === null || _storeData$applicatio149 === void 0 ? void 0 : _storeData$applicatio149.noOfToilets,
|
|
1866
|
+
additionalDetails: storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio150 = storeData.applicationData) === null || _storeData$applicatio150 === void 0 ? void 0 : _storeData$applicatio150.additionalDetails,
|
|
1867
|
+
tenantId: storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio151 = storeData.applicationData) === null || _storeData$applicatio151 === void 0 ? void 0 : _storeData$applicatio151.tenantId,
|
|
1761
1868
|
connectionType: "Non Metered",
|
|
1762
|
-
waterSource: (storeData === null || storeData === void 0 ? void 0 : (_storeData$
|
|
1869
|
+
waterSource: (storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio152 = storeData.applicationData) === null || _storeData$applicatio152 === void 0 ? void 0 : _storeData$applicatio152.waterSource) || null,
|
|
1763
1870
|
processInstance: {
|
|
1764
|
-
...(storeData === null || storeData === void 0 ? void 0 : (_storeData$
|
|
1871
|
+
...(storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio153 = storeData.applicationData) === null || _storeData$applicatio153 === void 0 ? void 0 : _storeData$applicatio153.processInstance),
|
|
1765
1872
|
action: "INITIATE",
|
|
1766
1873
|
businessService: "SWReconnection"
|
|
1767
1874
|
},
|
|
@@ -1769,7 +1876,8 @@ const createPayloadOfWSReconnection = function (data, storeData, service) {
|
|
|
1769
1876
|
},
|
|
1770
1877
|
disconnectRequest: false
|
|
1771
1878
|
};
|
|
1772
|
-
|
|
1879
|
+
const isSewerageService = ((service === null || service === void 0 ? void 0 : service.toUpperCase()) === "SEWERAGE" || (service === null || service === void 0 ? void 0 : service.toUpperCase()) === "SW") && !(storeData !== null && storeData !== void 0 && (_storeData$applicatio154 = storeData.applicationData) !== null && _storeData$applicatio154 !== void 0 && _storeData$applicatio154.water) && !(storeData !== null && storeData !== void 0 && (_storeData$applicatio155 = storeData.applicationData) !== null && _storeData$applicatio155 !== void 0 && (_storeData$applicatio156 = _storeData$applicatio155.connectionNo) !== null && _storeData$applicatio156 !== void 0 && _storeData$applicatio156.includes("WS")) && !(storeData !== null && storeData !== void 0 && (_storeData$applicatio157 = storeData.applicationData) !== null && _storeData$applicatio157 !== void 0 && (_storeData$applicatio158 = _storeData$applicatio157.applicationNo) !== null && _storeData$applicatio158 !== void 0 && _storeData$applicatio158.includes("WS"));
|
|
1880
|
+
let returnObject = isSewerageService ? swPayload : wsPayload;
|
|
1773
1881
|
return Promise.resolve(returnObject);
|
|
1774
1882
|
} catch (e) {
|
|
1775
1883
|
return Promise.reject(e);
|
|
@@ -1777,7 +1885,7 @@ const createPayloadOfWSReconnection = function (data, storeData, service) {
|
|
|
1777
1885
|
};
|
|
1778
1886
|
const createPayloadOfWSReSubmitDisconnection = function (data, storeData, service) {
|
|
1779
1887
|
try {
|
|
1780
|
-
var _Digit$UserService$ge10, _Digit$UserService$ge11, _data$type4, _data$type4$value, _data$reason13, _data$reason13$value, _data$reason14, _data$reason15, _storeData$
|
|
1888
|
+
var _Digit$UserService$ge10, _Digit$UserService$ge11, _data$type4, _data$type4$value, _data$reason13, _data$reason13$value, _data$reason14, _data$reason15, _storeData$applicatio159, _storeData$applicatio160, _storeData$applicatio161, _storeData$applicatio162, _data$type5, _data$type5$value, _data$reason16, _data$reason16$value, _data$reason17, _data$reason18, _storeData$applicatio167, _storeData$applicatio168, _storeData$applicatio169, _storeData$applicatio170, _storeData$applicatio171, _storeData$applicatio172, _storeData$applicatio173, _storeData$applicatio174, _Digit18, _Digit18$Customizatio, _Digit18$Customizatio2, _Digit19, _Digit19$Customizatio, _Digit19$Customizatio2;
|
|
1781
1889
|
const user = (_Digit$UserService$ge10 = Digit.UserService.getUser()) === null || _Digit$UserService$ge10 === void 0 ? void 0 : (_Digit$UserService$ge11 = _Digit$UserService$ge10.info) === null || _Digit$UserService$ge11 === void 0 ? void 0 : _Digit$UserService$ge11.type;
|
|
1782
1890
|
let wsPayload = {
|
|
1783
1891
|
WaterConnection: {
|
|
@@ -1787,13 +1895,13 @@ const createPayloadOfWSReSubmitDisconnection = function (data, storeData, servic
|
|
|
1787
1895
|
dateEffectiveFrom: convertDateToEpoch(data === null || data === void 0 ? void 0 : data.date),
|
|
1788
1896
|
isdisconnection: true,
|
|
1789
1897
|
isDisconnectionTemporary: (data === null || data === void 0 ? void 0 : (_data$type4 = data.type) === null || _data$type4 === void 0 ? void 0 : (_data$type4$value = _data$type4.value) === null || _data$type4$value === void 0 ? void 0 : _data$type4$value.code) === "Temporary" ? true : false,
|
|
1790
|
-
disconnectionReason: (data === null || data === void 0 ? void 0 : (_data$reason13 = data.reason) === null || _data$reason13 === void 0 ? void 0 : (_data$reason13$value = _data$reason13.value) === null || _data$reason13$value === void 0 ? void 0 : _data$reason13$value.code) || (data === null || data === void 0 ? void 0 : (_data$reason14 = data.reason) === null || _data$reason14 === void 0 ? void 0 : _data$reason14.value) || (data === null || data === void 0 ? void 0 : (_data$reason15 = data.reason) === null || _data$reason15 === void 0 ? void 0 : _data$reason15.code) || (data === null || data === void 0 ? void 0 : data.reason) || (storeData === null || storeData === void 0 ? void 0 : (_storeData$
|
|
1791
|
-
documents: (data === null || data === void 0 ? void 0 : data.documents) || (storeData === null || storeData === void 0 ? void 0 : (_storeData$
|
|
1898
|
+
disconnectionReason: (data === null || data === void 0 ? void 0 : (_data$reason13 = data.reason) === null || _data$reason13 === void 0 ? void 0 : (_data$reason13$value = _data$reason13.value) === null || _data$reason13$value === void 0 ? void 0 : _data$reason13$value.code) || (data === null || data === void 0 ? void 0 : (_data$reason14 = data.reason) === null || _data$reason14 === void 0 ? void 0 : _data$reason14.value) || (data === null || data === void 0 ? void 0 : (_data$reason15 = data.reason) === null || _data$reason15 === void 0 ? void 0 : _data$reason15.code) || (data === null || data === void 0 ? void 0 : data.reason) || (storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio159 = storeData.applicationData) === null || _storeData$applicatio159 === void 0 ? void 0 : _storeData$applicatio159.disconnectionReason),
|
|
1899
|
+
documents: (data === null || data === void 0 ? void 0 : data.documents) || (storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio160 = storeData.applicationData) === null || _storeData$applicatio160 === void 0 ? void 0 : _storeData$applicatio160.documents),
|
|
1792
1900
|
water: true,
|
|
1793
1901
|
sewerage: false,
|
|
1794
1902
|
service: "Water",
|
|
1795
1903
|
processInstance: {
|
|
1796
|
-
...(storeData === null || storeData === void 0 ? void 0 : (_storeData$
|
|
1904
|
+
...(storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio161 = storeData.applicationData) === null || _storeData$applicatio161 === void 0 ? void 0 : _storeData$applicatio161.processInstance),
|
|
1797
1905
|
businessService: "DisconnectWSConnection",
|
|
1798
1906
|
action: "RESUBMIT_APPLICATION"
|
|
1799
1907
|
},
|
|
@@ -1801,10 +1909,10 @@ const createPayloadOfWSReSubmitDisconnection = function (data, storeData, servic
|
|
|
1801
1909
|
},
|
|
1802
1910
|
disconnectRequest: true
|
|
1803
1911
|
};
|
|
1804
|
-
if (storeData !== null && storeData !== void 0 && (_storeData$
|
|
1805
|
-
var _storeData$
|
|
1806
|
-
if (storeData !== null && storeData !== void 0 && (_storeData$
|
|
1807
|
-
if (storeData !== null && storeData !== void 0 && (_storeData$
|
|
1912
|
+
if (storeData !== null && storeData !== void 0 && (_storeData$applicatio162 = storeData.applicationData) !== null && _storeData$applicatio162 !== void 0 && _storeData$applicatio162.connectionType) {
|
|
1913
|
+
var _storeData$applicatio163, _storeData$applicatio164, _storeData$applicatio165, _storeData$applicatio166;
|
|
1914
|
+
if (storeData !== null && storeData !== void 0 && (_storeData$applicatio163 = storeData.applicationData) !== null && _storeData$applicatio163 !== void 0 && _storeData$applicatio163.meterInstallationDate) wsPayload.WaterConnection.meterInstallationDate = storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio164 = storeData.applicationData) === null || _storeData$applicatio164 === void 0 ? void 0 : _storeData$applicatio164.meterInstallationDate;
|
|
1915
|
+
if (storeData !== null && storeData !== void 0 && (_storeData$applicatio165 = storeData.applicationData) !== null && _storeData$applicatio165 !== void 0 && _storeData$applicatio165.meterId) wsPayload.WaterConnection.meterId = storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio166 = storeData.applicationData) === null || _storeData$applicatio166 === void 0 ? void 0 : _storeData$applicatio166.meterId;
|
|
1808
1916
|
}
|
|
1809
1917
|
let swPayload = {
|
|
1810
1918
|
SewerageConnection: {
|
|
@@ -1814,13 +1922,13 @@ const createPayloadOfWSReSubmitDisconnection = function (data, storeData, servic
|
|
|
1814
1922
|
dateEffectiveFrom: convertDateToEpoch(data === null || data === void 0 ? void 0 : data.date),
|
|
1815
1923
|
isdisconnection: true,
|
|
1816
1924
|
isDisconnectionTemporary: (data === null || data === void 0 ? void 0 : (_data$type5 = data.type) === null || _data$type5 === void 0 ? void 0 : (_data$type5$value = _data$type5.value) === null || _data$type5$value === void 0 ? void 0 : _data$type5$value.code) === "Temporary" ? true : false,
|
|
1817
|
-
disconnectionReason: (data === null || data === void 0 ? void 0 : (_data$reason16 = data.reason) === null || _data$reason16 === void 0 ? void 0 : (_data$reason16$value = _data$reason16.value) === null || _data$reason16$value === void 0 ? void 0 : _data$reason16$value.code) || (data === null || data === void 0 ? void 0 : (_data$reason17 = data.reason) === null || _data$reason17 === void 0 ? void 0 : _data$reason17.value) || (data === null || data === void 0 ? void 0 : (_data$reason18 = data.reason) === null || _data$reason18 === void 0 ? void 0 : _data$reason18.code) || (data === null || data === void 0 ? void 0 : data.reason) || (storeData === null || storeData === void 0 ? void 0 : (_storeData$
|
|
1818
|
-
documents: (data === null || data === void 0 ? void 0 : data.documents) || (storeData === null || storeData === void 0 ? void 0 : (_storeData$
|
|
1925
|
+
disconnectionReason: (data === null || data === void 0 ? void 0 : (_data$reason16 = data.reason) === null || _data$reason16 === void 0 ? void 0 : (_data$reason16$value = _data$reason16.value) === null || _data$reason16$value === void 0 ? void 0 : _data$reason16$value.code) || (data === null || data === void 0 ? void 0 : (_data$reason17 = data.reason) === null || _data$reason17 === void 0 ? void 0 : _data$reason17.value) || (data === null || data === void 0 ? void 0 : (_data$reason18 = data.reason) === null || _data$reason18 === void 0 ? void 0 : _data$reason18.code) || (data === null || data === void 0 ? void 0 : data.reason) || (storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio167 = storeData.applicationData) === null || _storeData$applicatio167 === void 0 ? void 0 : _storeData$applicatio167.disconnectionReason),
|
|
1926
|
+
documents: (data === null || data === void 0 ? void 0 : data.documents) || (storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio168 = storeData.applicationData) === null || _storeData$applicatio168 === void 0 ? void 0 : _storeData$applicatio168.documents),
|
|
1819
1927
|
water: false,
|
|
1820
1928
|
sewerage: true,
|
|
1821
1929
|
service: "Sewerage",
|
|
1822
1930
|
processInstance: {
|
|
1823
|
-
...(storeData === null || storeData === void 0 ? void 0 : (_storeData$
|
|
1931
|
+
...(storeData === null || storeData === void 0 ? void 0 : (_storeData$applicatio169 = storeData.applicationData) === null || _storeData$applicatio169 === void 0 ? void 0 : _storeData$applicatio169.processInstance),
|
|
1824
1932
|
businessService: "DisconnectSWConnection",
|
|
1825
1933
|
action: "RESUBMIT_APPLICATION"
|
|
1826
1934
|
},
|
|
@@ -1828,7 +1936,8 @@ const createPayloadOfWSReSubmitDisconnection = function (data, storeData, servic
|
|
|
1828
1936
|
},
|
|
1829
1937
|
disconnectRequest: true
|
|
1830
1938
|
};
|
|
1831
|
-
|
|
1939
|
+
const isSewerageService = ((service === null || service === void 0 ? void 0 : service.toUpperCase()) === "SEWERAGE" || (service === null || service === void 0 ? void 0 : service.toUpperCase()) === "SW") && !(storeData !== null && storeData !== void 0 && (_storeData$applicatio170 = storeData.applicationData) !== null && _storeData$applicatio170 !== void 0 && _storeData$applicatio170.water) && !(storeData !== null && storeData !== void 0 && (_storeData$applicatio171 = storeData.applicationData) !== null && _storeData$applicatio171 !== void 0 && (_storeData$applicatio172 = _storeData$applicatio171.connectionNo) !== null && _storeData$applicatio172 !== void 0 && _storeData$applicatio172.includes("WS")) && !(storeData !== null && storeData !== void 0 && (_storeData$applicatio173 = storeData.applicationData) !== null && _storeData$applicatio173 !== void 0 && (_storeData$applicatio174 = _storeData$applicatio173.applicationNo) !== null && _storeData$applicatio174 !== void 0 && _storeData$applicatio174.includes("WS"));
|
|
1940
|
+
let returnObject = isSewerageService ? swPayload : wsPayload;
|
|
1832
1941
|
returnObject = (_Digit18 = Digit) !== null && _Digit18 !== void 0 && (_Digit18$Customizatio = _Digit18.Customizations) !== null && _Digit18$Customizatio !== void 0 && (_Digit18$Customizatio2 = _Digit18$Customizatio.WS) !== null && _Digit18$Customizatio2 !== void 0 && _Digit18$Customizatio2.customiseCreatePayloadOfWSReSubmitDisconnection ? (_Digit19 = Digit) === null || _Digit19 === void 0 ? void 0 : (_Digit19$Customizatio = _Digit19.Customizations) === null || _Digit19$Customizatio === void 0 ? void 0 : (_Digit19$Customizatio2 = _Digit19$Customizatio.WS) === null || _Digit19$Customizatio2 === void 0 ? void 0 : _Digit19$Customizatio2.customiseCreatePayloadOfWSReSubmitDisconnection(data, returnObject, service) : returnObject;
|
|
1833
1942
|
return Promise.resolve(returnObject);
|
|
1834
1943
|
} catch (e) {
|
|
@@ -2359,12 +2468,12 @@ const mapExistingDocIdsToPayload = function (uploadingDocs, existingDocs) {
|
|
|
2359
2468
|
};
|
|
2360
2469
|
const convertEditApplicationDetails = function (data, appData, actionData) {
|
|
2361
2470
|
try {
|
|
2362
|
-
var _data$cpt47, _data$cpt47$details, _data$cpt47$details$o, _appData$applicationD, _data$
|
|
2471
|
+
var _data$cpt47, _data$cpt47$details, _data$cpt47$details$o, _appData$applicationD, _data$DocumentsRequir2, _data$cpt48, _data$cpt48$details, _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$ConnectionDetai29, _data$ConnectionDetai30, _data$ConnectionDetai31, _data$ConnectionDetai32, _data$ConnectionHolde58, _data$ConnectionHolde59, _appData$applicationD2, _appData$applicationD3, _data$ConnectionHolde60, _data$ConnectionHolde61, _data$ConnectionHolde62, _data$ConnectionHolde63, _data$ConnectionHolde64, _data$ConnectionHolde65, _data$ConnectionHolde66, _data$ConnectionHolde67, _data$ConnectionHolde68, _data$ConnectionHolde69, _data$ConnectionHolde70, _data$ConnectionHolde71, _data$ConnectionHolde72, _data$ConnectionHolde73, _data$ConnectionHolde74, _data$ConnectionHolde75, _data$ConnectionHolde76, _data$ConnectionHolde77, _data$ConnectionHolde78, _data$ConnectionHolde79, _data$ConnectionHolde80, _data$ConnectionHolde81, _data$ConnectionHolde82, _data$ConnectionHolde83, _data$ConnectionHolde84, _data$ConnectionHolde85, _data$ConnectionHolde86, _data$cpt49;
|
|
2363
2472
|
data === null || data === void 0 ? void 0 : (_data$cpt47 = data.cpt) === null || _data$cpt47 === void 0 ? void 0 : (_data$cpt47$details = _data$cpt47.details) === null || _data$cpt47$details === void 0 ? void 0 : (_data$cpt47$details$o = _data$cpt47$details.owners) === null || _data$cpt47$details$o === void 0 ? void 0 : _data$cpt47$details$o.forEach(owner => {
|
|
2364
2473
|
if (owner !== null && owner !== void 0 && owner.permanentAddress) owner.correspondenceAddress = owner === null || owner === void 0 ? void 0 : owner.permanentAddress;
|
|
2365
2474
|
});
|
|
2366
2475
|
const existingDocs = (appData === null || appData === void 0 ? void 0 : (_appData$applicationD = appData.applicationData) === null || _appData$applicationD === void 0 ? void 0 : _appData$applicationD.documents) || (appData === null || appData === void 0 ? void 0 : appData.documents) || [];
|
|
2367
|
-
let docs = (data === null || data === void 0 ? void 0 : (_data$
|
|
2476
|
+
let docs = (data === null || data === void 0 ? void 0 : (_data$DocumentsRequir2 = data.DocumentsRequired) === null || _data$DocumentsRequir2 === void 0 ? void 0 : _data$DocumentsRequir2.documents) || [];
|
|
2368
2477
|
if (docs && docs.length > 0 && existingDocs && existingDocs.length > 0) {
|
|
2369
2478
|
docs = mapExistingDocIdsToPayload(docs, existingDocs);
|
|
2370
2479
|
}
|
|
@@ -2458,7 +2567,7 @@ const convertDisonnectApplicationData = function (data, serviceType, editByConfi
|
|
|
2458
2567
|
};
|
|
2459
2568
|
const convertDisonnectEditApplicationDetails = function (data, appData, actionData) {
|
|
2460
2569
|
try {
|
|
2461
|
-
var _data$plumberDetails7, _data$plumberDetails8, _data$plumberDetails9, _data$plumberDetails0, _data$plumberDetails1, _data$plumberDetails10, _appData$applicationD6, _appData$applicationD7, _appData$applicationD8, _data$disConnectionDe, _data$disConnectionDe2, _data$disConnectionDe3, _data$disConnectionDe4, _data$
|
|
2570
|
+
var _data$plumberDetails7, _data$plumberDetails8, _data$plumberDetails9, _data$plumberDetails0, _data$plumberDetails1, _data$plumberDetails10, _appData$applicationD6, _appData$applicationD7, _appData$applicationD8, _data$disConnectionDe, _data$disConnectionDe2, _data$disConnectionDe3, _data$disConnectionDe4, _data$DocumentsRequir3, _data$disConnectionDe5, _data$disConnectionDe6;
|
|
2462
2571
|
const docs = sessionStorage.getItem("DISCONNECTION_EDIT_DOCS");
|
|
2463
2572
|
const docsData = docs ? JSON.parse(docs) : "";
|
|
2464
2573
|
const documentsData = [];
|
|
@@ -2486,7 +2595,7 @@ const convertDisonnectEditApplicationDetails = function (data, appData, actionDa
|
|
|
2486
2595
|
}];
|
|
2487
2596
|
const _temp5 = (data === null || data === void 0 ? void 0 : (_data$disConnectionDe = data.disConnectionDetails) === null || _data$disConnectionDe === void 0 ? void 0 : (_data$disConnectionDe2 = _data$disConnectionDe[0]) === null || _data$disConnectionDe2 === void 0 ? void 0 : _data$disConnectionDe2.disConnectionReason) || "",
|
|
2488
2597
|
_temp4 = (data === null || data === void 0 ? void 0 : (_data$disConnectionDe3 = data.disConnectionDetails) === null || _data$disConnectionDe3 === void 0 ? void 0 : (_data$disConnectionDe4 = _data$disConnectionDe3[0]) === null || _data$disConnectionDe4 === void 0 ? void 0 : _data$disConnectionDe4.disConnectionType) == "TEMPORARY" ? true : false,
|
|
2489
|
-
_temp3 = (documentsData === null || documentsData === void 0 ? void 0 : documentsData.length) > 0 ? documentsData : data === null || data === void 0 ? void 0 : (_data$
|
|
2598
|
+
_temp3 = (documentsData === null || documentsData === void 0 ? void 0 : documentsData.length) > 0 ? documentsData : data === null || data === void 0 ? void 0 : (_data$DocumentsRequir3 = data.DocumentsRequired) === null || _data$DocumentsRequir3 === void 0 ? void 0 : _data$DocumentsRequir3.documents;
|
|
2490
2599
|
return Promise.resolve(getConvertedDate(data === null || data === void 0 ? void 0 : (_data$disConnectionDe5 = data.disConnectionDetails) === null || _data$disConnectionDe5 === void 0 ? void 0 : (_data$disConnectionDe6 = _data$disConnectionDe5[0]) === null || _data$disConnectionDe6 === void 0 ? void 0 : _data$disConnectionDe6.disConnectionProposeDate)).then(function (_getConvertedDate) {
|
|
2491
2600
|
var _data$plumberDetails11, _data$plumberDetails12, _data$plumberDetails13;
|
|
2492
2601
|
let payload = {
|
|
@@ -2540,8 +2649,8 @@ const convertModifyApplicationDetails = function (data, appData, actionData) {
|
|
|
2540
2649
|
var _data$activationDetai5, _data$activationDetai6, _data$activationDetai7, _data$activationDetai8;
|
|
2541
2650
|
function _temp9() {
|
|
2542
2651
|
function _temp7() {
|
|
2543
|
-
var _data$
|
|
2544
|
-
if (data !== null && data !== void 0 && (_data$
|
|
2652
|
+
var _data$DocumentsRequir4, _data$DocumentsRequir5, _data$DocumentsRequir6, _appData$applicationD9, _data$ConnectionHolde87, _data$ConnectionHolde88, _Digit$UserService$ge12, _Digit$UserService$ge13, _Digit$UserService$ge14, _data$DocumentsRequir7, _data$cpt50;
|
|
2653
|
+
if (data !== null && data !== void 0 && (_data$DocumentsRequir4 = data.DocumentsRequired) !== null && _data$DocumentsRequir4 !== void 0 && (_data$DocumentsRequir5 = _data$DocumentsRequir4.documents) !== null && _data$DocumentsRequir5 !== void 0 && _data$DocumentsRequir5.length) formData.documents = data === null || data === void 0 ? void 0 : (_data$DocumentsRequir6 = data.DocumentsRequired) === null || _data$DocumentsRequir6 === void 0 ? void 0 : _data$DocumentsRequir6.documents;else formData.documents = null;
|
|
2545
2654
|
const existingDocs = (appData === null || appData === void 0 ? void 0 : (_appData$applicationD9 = appData.applicationData) === null || _appData$applicationD9 === void 0 ? void 0 : _appData$applicationD9.documents) || (appData === null || appData === void 0 ? void 0 : appData.documents) || [];
|
|
2546
2655
|
if (formData.documents && formData.documents.length > 0 && existingDocs && existingDocs.length > 0) {
|
|
2547
2656
|
formData.documents = mapExistingDocIdsToPayload(formData.documents, existingDocs);
|
|
@@ -2569,7 +2678,7 @@ const convertModifyApplicationDetails = function (data, appData, actionData) {
|
|
|
2569
2678
|
};
|
|
2570
2679
|
formData.action = actionData;
|
|
2571
2680
|
formData.channel = ((_Digit$UserService$ge12 = Digit.UserService.getUser()) === null || _Digit$UserService$ge12 === void 0 ? void 0 : (_Digit$UserService$ge13 = _Digit$UserService$ge12.info) === null || _Digit$UserService$ge13 === void 0 ? void 0 : (_Digit$UserService$ge14 = _Digit$UserService$ge13.type) === null || _Digit$UserService$ge14 === void 0 ? void 0 : _Digit$UserService$ge14.toUpperCase()) === "CITIZEN" ? "CITIZEN" : "CFC_COUNTER";
|
|
2572
|
-
sessionStorage.setItem("WS_DOCUMENTS_INOF", JSON.stringify((data === null || data === void 0 ? void 0 : (_data$
|
|
2681
|
+
sessionStorage.setItem("WS_DOCUMENTS_INOF", JSON.stringify((data === null || data === void 0 ? void 0 : (_data$DocumentsRequir7 = data.DocumentsRequired) === null || _data$DocumentsRequir7 === void 0 ? void 0 : _data$DocumentsRequir7.documents) || []));
|
|
2573
2682
|
sessionStorage.setItem("WS_PROPERTY_INOF", JSON.stringify(data === null || data === void 0 ? void 0 : (_data$cpt50 = data.cpt) === null || _data$cpt50 === void 0 ? void 0 : _data$cpt50.details));
|
|
2574
2683
|
return formData;
|
|
2575
2684
|
}
|
|
@@ -11378,7 +11487,7 @@ const configNOCApproverApplication = _ref => {
|
|
|
11378
11487
|
};
|
|
11379
11488
|
|
|
11380
11489
|
const configWSApproverApplication = _ref => {
|
|
11381
|
-
var _action$action;
|
|
11490
|
+
var _action$action, _businessService$toUp;
|
|
11382
11491
|
let {
|
|
11383
11492
|
t,
|
|
11384
11493
|
action,
|
|
@@ -11444,12 +11553,16 @@ const configWSApproverApplication = _ref => {
|
|
|
11444
11553
|
}
|
|
11445
11554
|
}];
|
|
11446
11555
|
const isActivate = (action === null || action === void 0 ? void 0 : action.action) === "ACTIVATE_CONNECTION";
|
|
11556
|
+
const isAmendment = businessService === null || businessService === void 0 ? void 0 : (_businessService$toUp = businessService.toUpperCase()) === null || _businessService$toUp === void 0 ? void 0 : _businessService$toUp.includes("AMENDMENT");
|
|
11447
11557
|
const getHeadingLabel = () => {
|
|
11448
11558
|
if (isActivate) {
|
|
11449
11559
|
const translated = t("WF_APPROVE_APPLICATION");
|
|
11450
11560
|
if (translated && translated !== "WF_APPROVE_APPLICATION") return translated;
|
|
11451
11561
|
return "Approve Application";
|
|
11452
11562
|
}
|
|
11563
|
+
if (isAmendment) {
|
|
11564
|
+
return `WF_EMPLOYEE_${businessService === null || businessService === void 0 ? void 0 : businessService.toUpperCase()}_${action === null || action === void 0 ? void 0 : action.action}`;
|
|
11565
|
+
}
|
|
11453
11566
|
return `WF_${action === null || action === void 0 ? void 0 : action.action}_APPLICATION`;
|
|
11454
11567
|
};
|
|
11455
11568
|
const getSubmitLabel = () => {
|
|
@@ -11462,6 +11575,9 @@ const configWSApproverApplication = _ref => {
|
|
|
11462
11575
|
}
|
|
11463
11576
|
return "Approve Connection";
|
|
11464
11577
|
}
|
|
11578
|
+
if (isAmendment) {
|
|
11579
|
+
return `WF_EMPLOYEE_${businessService === null || businessService === void 0 ? void 0 : businessService.toUpperCase()}_${action === null || action === void 0 ? void 0 : action.action}`;
|
|
11580
|
+
}
|
|
11465
11581
|
return `WF_${businessService === null || businessService === void 0 ? void 0 : businessService.toUpperCase()}_${action === null || action === void 0 ? void 0 : action.action}`;
|
|
11466
11582
|
};
|
|
11467
11583
|
return {
|
|
@@ -16605,7 +16721,7 @@ function PropertyDocuments(_ref) {
|
|
|
16605
16721
|
return t("NA");
|
|
16606
16722
|
};
|
|
16607
16723
|
const renderDocumentRow = (value, index) => {
|
|
16608
|
-
var _pdfFiles$value$fileS;
|
|
16724
|
+
var _pdfFiles$value$fileS, _value$documentType, _value$documentType2, _value$documentType5, _value$documentType6;
|
|
16609
16725
|
const fileUrl = (_pdfFiles$value$fileS = pdfFiles[value.fileStoreId]) === null || _pdfFiles$value$fileS === void 0 ? void 0 : _pdfFiles$value$fileS.split(",")[0];
|
|
16610
16726
|
const docSubType = getDocSubType(value === null || value === void 0 ? void 0 : value.documentType);
|
|
16611
16727
|
const docUid = getDocNumber(value);
|
|
@@ -16621,10 +16737,14 @@ function PropertyDocuments(_ref) {
|
|
|
16621
16737
|
typeLabel = "Ownership Proof*";
|
|
16622
16738
|
numLabel = "Ownership Proof Document Number";
|
|
16623
16739
|
uploadLabel = "Upload Ownership Proof*";
|
|
16740
|
+
} else if (value.title === "WS_DJB_EMPLOYEE_ID" || value !== null && value !== void 0 && (_value$documentType = value.documentType) !== null && _value$documentType !== void 0 && _value$documentType.includes("DJB_EMPLOYEE") || value !== null && value !== void 0 && (_value$documentType2 = value.documentType) !== null && _value$documentType2 !== void 0 && _value$documentType2.includes("EMPLOYEE_ID")) {
|
|
16741
|
+
typeLabel = "";
|
|
16742
|
+
numLabel = "";
|
|
16743
|
+
uploadLabel = "Upload Employee ID Document*";
|
|
16624
16744
|
} else if (value.title === "WS_OTHER_DOCUMENTS") {
|
|
16625
|
-
var _value$
|
|
16745
|
+
var _value$documentType3, _value$documentType4;
|
|
16626
16746
|
typeLabel = "Other Documents*";
|
|
16627
|
-
const isOtherDocRemark = (value === null || value === void 0 ? void 0 : (_value$
|
|
16747
|
+
const isOtherDocRemark = (value === null || value === void 0 ? void 0 : (_value$documentType3 = value.documentType) === null || _value$documentType3 === void 0 ? void 0 : _value$documentType3.includes("OTHER_DOCUMENTS")) || (value === null || value === void 0 ? void 0 : (_value$documentType4 = value.documentType) === null || _value$documentType4 === void 0 ? void 0 : _value$documentType4.includes("OTHERDOCUMENTS")) || String(docSubType).toUpperCase().includes("OTHER_DOCUMENTS") || String(docSubType).toUpperCase().includes("OTHER DOCUMENT");
|
|
16628
16748
|
numLabel = isOtherDocRemark ? "Other Document Remark" : value.numberLabel || "Other Document Number";
|
|
16629
16749
|
uploadLabel = "Upload Other Documents*";
|
|
16630
16750
|
} else if (value.title === "WS_APPLICANT_PHOTO") {
|
|
@@ -16641,13 +16761,13 @@ function PropertyDocuments(_ref) {
|
|
|
16641
16761
|
style: {
|
|
16642
16762
|
marginBottom: "24px"
|
|
16643
16763
|
}
|
|
16644
|
-
}, /*#__PURE__*/React__default.createElement(digitUiReactComponents.StatusTable, null, !isPhoto && value.title !== "WS_APPLICANT_SIGNATURE" && /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
|
|
16764
|
+
}, /*#__PURE__*/React__default.createElement(digitUiReactComponents.StatusTable, null, !isPhoto && value.title !== "WS_APPLICANT_SIGNATURE" && value.title !== "WS_DJB_EMPLOYEE_ID" && !(value !== null && value !== void 0 && (_value$documentType5 = value.documentType) !== null && _value$documentType5 !== void 0 && _value$documentType5.includes("DJB_EMPLOYEE")) && !(value !== null && value !== void 0 && (_value$documentType6 = value.documentType) !== null && _value$documentType6 !== void 0 && _value$documentType6.includes("EMPLOYEE_ID")) && /*#__PURE__*/React__default.createElement(React__default.Fragment, null, typeLabel ? /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
|
|
16645
16765
|
label: typeLabel,
|
|
16646
16766
|
text: docSubType || t("NA")
|
|
16647
|
-
}), /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
|
|
16767
|
+
}) : null, numLabel ? /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
|
|
16648
16768
|
label: numLabel,
|
|
16649
16769
|
text: docUid || t("NA")
|
|
16650
|
-
})), /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
|
|
16770
|
+
}) : null), /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
|
|
16651
16771
|
label: uploadLabel,
|
|
16652
16772
|
text: /*#__PURE__*/React__default.createElement("div", {
|
|
16653
16773
|
style: {
|
|
@@ -16784,7 +16904,7 @@ function PropertyDocuments(_ref) {
|
|
|
16784
16904
|
justifyContent: "flex-start"
|
|
16785
16905
|
}
|
|
16786
16906
|
}, document !== null && document !== void 0 && document.values && (document === null || document === void 0 ? void 0 : document.values.length) > 0 ? document === null || document === void 0 ? void 0 : (_document$values2 = document.values) === null || _document$values2 === void 0 ? void 0 : _document$values2.map((value, index) => {
|
|
16787
|
-
var _pdfFiles$value$fileS2, _value$
|
|
16907
|
+
var _pdfFiles$value$fileS2, _value$documentType7;
|
|
16788
16908
|
return /*#__PURE__*/React__default.createElement("a", {
|
|
16789
16909
|
target: "_",
|
|
16790
16910
|
href: (_pdfFiles$value$fileS2 = pdfFiles[value.fileStoreId]) === null || _pdfFiles$value$fileS2 === void 0 ? void 0 : _pdfFiles$value$fileS2.split(",")[0],
|
|
@@ -16812,7 +16932,7 @@ function PropertyDocuments(_ref) {
|
|
|
16812
16932
|
marginTop: "8px",
|
|
16813
16933
|
fontWeight: "bold"
|
|
16814
16934
|
}
|
|
16815
|
-
}, t(value === null || value === void 0 ? void 0 : value.title)), isSendBackFlow ? value !== null && value !== void 0 && (_value$
|
|
16935
|
+
}, t(value === null || value === void 0 ? void 0 : value.title)), isSendBackFlow ? value !== null && value !== void 0 && (_value$documentType7 = value.documentType) !== null && _value$documentType7 !== void 0 && _value$documentType7.includes("NOC") ? /*#__PURE__*/React__default.createElement("p", {
|
|
16816
16936
|
style: {
|
|
16817
16937
|
textAlign: "center"
|
|
16818
16938
|
}
|
|
@@ -20864,6 +20984,118 @@ const ApplicationDetails = props => {
|
|
|
20864
20984
|
})) : /*#__PURE__*/React__default.createElement(digitUiReactComponents.Loader, null));
|
|
20865
20985
|
};
|
|
20866
20986
|
|
|
20987
|
+
const CheckIcon = () => /*#__PURE__*/React__default.createElement("svg", {
|
|
20988
|
+
width: "14",
|
|
20989
|
+
height: "14",
|
|
20990
|
+
viewBox: "0 0 24 24",
|
|
20991
|
+
fill: "none",
|
|
20992
|
+
stroke: "currentColor",
|
|
20993
|
+
strokeWidth: "3",
|
|
20994
|
+
strokeLinecap: "round",
|
|
20995
|
+
strokeLinejoin: "round"
|
|
20996
|
+
}, /*#__PURE__*/React__default.createElement("polyline", {
|
|
20997
|
+
points: "20 6 9 17 4 12"
|
|
20998
|
+
}));
|
|
20999
|
+
const ClockIcon = () => /*#__PURE__*/React__default.createElement("svg", {
|
|
21000
|
+
width: "14",
|
|
21001
|
+
height: "14",
|
|
21002
|
+
viewBox: "0 0 24 24",
|
|
21003
|
+
fill: "none",
|
|
21004
|
+
stroke: "currentColor",
|
|
21005
|
+
strokeWidth: "2",
|
|
21006
|
+
strokeLinecap: "round",
|
|
21007
|
+
strokeLinejoin: "round"
|
|
21008
|
+
}, /*#__PURE__*/React__default.createElement("circle", {
|
|
21009
|
+
cx: "12",
|
|
21010
|
+
cy: "12",
|
|
21011
|
+
r: "10"
|
|
21012
|
+
}), /*#__PURE__*/React__default.createElement("polyline", {
|
|
21013
|
+
className: "clock-hands2",
|
|
21014
|
+
points: "12 6 12 12 16 14"
|
|
21015
|
+
}));
|
|
21016
|
+
const WorkflowTimeline = _ref => {
|
|
21017
|
+
var _workflowDetails$data;
|
|
21018
|
+
let {
|
|
21019
|
+
workflowDetails,
|
|
21020
|
+
hideTimeline,
|
|
21021
|
+
setHideTimeline
|
|
21022
|
+
} = _ref;
|
|
21023
|
+
const {
|
|
21024
|
+
t
|
|
21025
|
+
} = reactI18next.useTranslation();
|
|
21026
|
+
const timeline = workflowDetails === null || workflowDetails === void 0 ? void 0 : (_workflowDetails$data = workflowDetails.data) === null || _workflowDetails$data === void 0 ? void 0 : _workflowDetails$data.processInstances;
|
|
21027
|
+
if (!timeline || timeline.length === 0) {
|
|
21028
|
+
return null;
|
|
21029
|
+
}
|
|
21030
|
+
const getStatusClass = (index, checkpoint) => {
|
|
21031
|
+
var _checkpoint$state, _checkpoint$state2, _checkpoint$state3, _checkpoint$state4;
|
|
21032
|
+
const isTerminal = (checkpoint === null || checkpoint === void 0 ? void 0 : (_checkpoint$state = checkpoint.state) === null || _checkpoint$state === void 0 ? void 0 : _checkpoint$state.state) === "CONNECTION_ACTIVATED" || (checkpoint === null || checkpoint === void 0 ? void 0 : (_checkpoint$state2 = checkpoint.state) === null || _checkpoint$state2 === void 0 ? void 0 : _checkpoint$state2.applicationStatus) === "CONNECTION_ACTIVATED" || (checkpoint === null || checkpoint === void 0 ? void 0 : (_checkpoint$state3 = checkpoint.state) === null || _checkpoint$state3 === void 0 ? void 0 : _checkpoint$state3.status) === "ACTIVE" || (checkpoint === null || checkpoint === void 0 ? void 0 : (_checkpoint$state4 = checkpoint.state) === null || _checkpoint$state4 === void 0 ? void 0 : _checkpoint$state4.isTerminateState);
|
|
21033
|
+
if (index === 0 && !isTerminal) return "current2";
|
|
21034
|
+
return "completed2";
|
|
21035
|
+
};
|
|
21036
|
+
const convertEpochToDateTime = epoch => {
|
|
21037
|
+
if (!epoch) return "N/A";
|
|
21038
|
+
const date = new Date(epoch);
|
|
21039
|
+
const day = String(date.getDate()).padStart(2, "0");
|
|
21040
|
+
const month = String(date.getMonth() + 1).padStart(2, "0");
|
|
21041
|
+
const year = date.getFullYear().toString().slice(-2);
|
|
21042
|
+
const hours = String(date.getHours()).padStart(2, "0");
|
|
21043
|
+
const minutes = String(date.getMinutes()).padStart(2, "0");
|
|
21044
|
+
return `${day}/${month}/${year} ${hours}:${minutes}`;
|
|
21045
|
+
};
|
|
21046
|
+
return /*#__PURE__*/React__default.createElement(digitUiReactComponents.Card, {
|
|
21047
|
+
className: "workflow-timeline-card2 digit-form-composer",
|
|
21048
|
+
style: {
|
|
21049
|
+
background: "#fff",
|
|
21050
|
+
padding: "16px",
|
|
21051
|
+
height: hideTimeline ? "100%" : ""
|
|
21052
|
+
}
|
|
21053
|
+
}, /*#__PURE__*/React__default.createElement("div", {
|
|
21054
|
+
className: `timeline-header-wrapper ${hideTimeline ? "collapsed" : ""}`
|
|
21055
|
+
}, /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardSubHeader, {
|
|
21056
|
+
style: {
|
|
21057
|
+
marginBottom: "0",
|
|
21058
|
+
fontSize: "16px",
|
|
21059
|
+
fontWeight: "700",
|
|
21060
|
+
color: "#374151"
|
|
21061
|
+
},
|
|
21062
|
+
className: hideTimeline ? "hidden-content" : ""
|
|
21063
|
+
}, t("WORKFLOW_TIMELINE"))), /*#__PURE__*/React__default.createElement("div", {
|
|
21064
|
+
className: hideTimeline ? "hidden-content" : "timeline-container2"
|
|
21065
|
+
}, timeline.map((checkpoint, index) => {
|
|
21066
|
+
var _checkpoint$auditDeta, _checkpoint$auditDeta2, _checkpoint$state5, _checkpoint$state6, _checkpoint$state7, _checkpoint$assigner, _checkpoint$assigner2;
|
|
21067
|
+
const statusClass = getStatusClass(index, checkpoint);
|
|
21068
|
+
const showLine = index !== timeline.length - 1 && timeline.length > 1;
|
|
21069
|
+
const epochTime = (checkpoint === null || checkpoint === void 0 ? void 0 : (_checkpoint$auditDeta = checkpoint.auditDetails) === null || _checkpoint$auditDeta === void 0 ? void 0 : _checkpoint$auditDeta.lastModifiedTime) || (checkpoint === null || checkpoint === void 0 ? void 0 : (_checkpoint$auditDeta2 = checkpoint.auditDetails) === null || _checkpoint$auditDeta2 === void 0 ? void 0 : _checkpoint$auditDeta2.createdTime);
|
|
21070
|
+
return /*#__PURE__*/React__default.createElement("div", {
|
|
21071
|
+
key: index,
|
|
21072
|
+
className: `timeline-item2 ${statusClass}`
|
|
21073
|
+
}, /*#__PURE__*/React__default.createElement("div", {
|
|
21074
|
+
className: "timeline-marker2"
|
|
21075
|
+
}, /*#__PURE__*/React__default.createElement("div", {
|
|
21076
|
+
className: "timeline-circle2"
|
|
21077
|
+
}, statusClass === "completed2" ? /*#__PURE__*/React__default.createElement(CheckIcon, null) : /*#__PURE__*/React__default.createElement(ClockIcon, null)), showLine && /*#__PURE__*/React__default.createElement("div", {
|
|
21078
|
+
className: "timeline-line2"
|
|
21079
|
+
})), /*#__PURE__*/React__default.createElement("div", {
|
|
21080
|
+
className: "timeline-content2"
|
|
21081
|
+
}, /*#__PURE__*/React__default.createElement("div", {
|
|
21082
|
+
className: "timeline-header2"
|
|
21083
|
+
}, /*#__PURE__*/React__default.createElement("div", {
|
|
21084
|
+
className: "timeline-title2"
|
|
21085
|
+
}, t(`WF_${checkpoint === null || checkpoint === void 0 ? void 0 : (_checkpoint$state5 = checkpoint.state) === null || _checkpoint$state5 === void 0 ? void 0 : _checkpoint$state5.state}`)), /*#__PURE__*/React__default.createElement("span", {
|
|
21086
|
+
className: "timeline-date2"
|
|
21087
|
+
}, convertEpochToDateTime(epochTime))), /*#__PURE__*/React__default.createElement("div", {
|
|
21088
|
+
className: "timeline-body2"
|
|
21089
|
+
}, /*#__PURE__*/React__default.createElement("div", {
|
|
21090
|
+
className: `timeline-status-tag2 status-${statusClass}`
|
|
21091
|
+
}, t((checkpoint === null || checkpoint === void 0 ? void 0 : (_checkpoint$state6 = checkpoint.state) === null || _checkpoint$state6 === void 0 ? void 0 : _checkpoint$state6.applicationStatus) || (checkpoint === null || checkpoint === void 0 ? void 0 : (_checkpoint$state7 = checkpoint.state) === null || _checkpoint$state7 === void 0 ? void 0 : _checkpoint$state7.state))), (checkpoint === null || checkpoint === void 0 ? void 0 : checkpoint.comment) && /*#__PURE__*/React__default.createElement("div", {
|
|
21092
|
+
className: "timeline-comment2"
|
|
21093
|
+
}, checkpoint.comment)), (checkpoint === null || checkpoint === void 0 ? void 0 : (_checkpoint$assigner = checkpoint.assigner) === null || _checkpoint$assigner === void 0 ? void 0 : _checkpoint$assigner.name) && /*#__PURE__*/React__default.createElement("div", {
|
|
21094
|
+
className: "timeline-footer2"
|
|
21095
|
+
}, /*#__PURE__*/React__default.createElement("span", null, t("ES_COMMON_ASSIGNED_TO"), ": ", /*#__PURE__*/React__default.createElement("strong", null, checkpoint === null || checkpoint === void 0 ? void 0 : (_checkpoint$assigner2 = checkpoint.assigner) === null || _checkpoint$assigner2 === void 0 ? void 0 : _checkpoint$assigner2.name)))));
|
|
21096
|
+
})));
|
|
21097
|
+
};
|
|
21098
|
+
|
|
20867
21099
|
const ApplicationDetailsBillAmendment = () => {
|
|
20868
21100
|
var _applicationDetails$p, _applicationDetails$p2, _workflowDetails$data, _workflowDetails$data2, _workflowDetails$data3, _applicationDetails$a3;
|
|
20869
21101
|
const queryParams = Digit.Hooks.useQueryParams();
|
|
@@ -20876,6 +21108,8 @@ const ApplicationDetailsBillAmendment = () => {
|
|
|
20876
21108
|
let serviceType = "WATER";
|
|
20877
21109
|
if (applicationNumber !== null && applicationNumber !== void 0 && applicationNumber.includes("SW")) serviceType = "SEWERAGE";
|
|
20878
21110
|
const [showToast, setShowToast] = React.useState(false);
|
|
21111
|
+
const [hideTimeline, setHideTimeline] = React__default.useState(typeof window !== "undefined" ? window.innerWidth < 768 : false);
|
|
21112
|
+
const menuRef = React.useRef();
|
|
20879
21113
|
const {
|
|
20880
21114
|
isLoading,
|
|
20881
21115
|
isError,
|
|
@@ -20922,6 +21156,10 @@ const ApplicationDetailsBillAmendment = () => {
|
|
|
20922
21156
|
}
|
|
20923
21157
|
}, [showToast]);
|
|
20924
21158
|
const [showOptions, setShowOptions] = React.useState(false);
|
|
21159
|
+
const closeMenu = () => {
|
|
21160
|
+
setShowOptions(false);
|
|
21161
|
+
};
|
|
21162
|
+
Digit.Hooks.useClickOutside(menuRef, closeMenu, showOptions);
|
|
20925
21163
|
const getAckPdf = function (amendment, tenantId, t, tableData, app) {
|
|
20926
21164
|
try {
|
|
20927
21165
|
const PDFdata = getWSAcknowledgementData$2(amendment, tenantId, t, tableData, app);
|
|
@@ -20941,25 +21179,42 @@ const ApplicationDetailsBillAmendment = () => {
|
|
|
20941
21179
|
onClick: () => getAckPdf(applicationDetails === null || applicationDetails === void 0 ? void 0 : applicationDetails.amendment, tenantId, t, applicationDetails === null || applicationDetails === void 0 ? void 0 : applicationDetails.applicationDetails, applicationDetails)
|
|
20942
21180
|
}];
|
|
20943
21181
|
return /*#__PURE__*/React__default.createElement(React.Fragment, null, /*#__PURE__*/React__default.createElement("div", {
|
|
20944
|
-
className: "employee-main-application-details"
|
|
20945
|
-
}, /*#__PURE__*/React__default.createElement("div", {
|
|
20946
|
-
className: "employee-application-details",
|
|
21182
|
+
className: "employee-main-application-details",
|
|
20947
21183
|
style: {
|
|
20948
|
-
|
|
21184
|
+
display: "flex",
|
|
21185
|
+
gap: "20px"
|
|
20949
21186
|
}
|
|
20950
|
-
}, /*#__PURE__*/React__default.createElement(
|
|
20951
|
-
|
|
20952
|
-
|
|
20953
|
-
|
|
20954
|
-
|
|
21187
|
+
}, isEmployee && /*#__PURE__*/React__default.createElement("div", {
|
|
21188
|
+
className: `workflow-timeline-wrapper no-scrollbar ${hideTimeline ? "hide-workflow" : ""}`,
|
|
21189
|
+
style: {
|
|
21190
|
+
flex: "1 1 300px",
|
|
21191
|
+
maxWidth: hideTimeline ? "fit-content" : "400px",
|
|
21192
|
+
transition: "max-width 0.3s"
|
|
20955
21193
|
}
|
|
20956
|
-
},
|
|
20957
|
-
|
|
21194
|
+
}, /*#__PURE__*/React__default.createElement(WorkflowTimeline, {
|
|
21195
|
+
workflowDetails: workflowDetails,
|
|
21196
|
+
hideTimeline: hideTimeline,
|
|
21197
|
+
setHideTimeline: setHideTimeline
|
|
21198
|
+
})), /*#__PURE__*/React__default.createElement("div", {
|
|
21199
|
+
style: {
|
|
21200
|
+
flex: "2 1 500px",
|
|
21201
|
+
minWidth: "300px",
|
|
21202
|
+
position: "relative"
|
|
21203
|
+
}
|
|
21204
|
+
}, dowloadOptions && dowloadOptions.length > 0 && /*#__PURE__*/React__default.createElement("div", {
|
|
21205
|
+
style: {
|
|
21206
|
+
position: "absolute",
|
|
21207
|
+
right: "24px",
|
|
21208
|
+
zIndex: 11
|
|
21209
|
+
}
|
|
21210
|
+
}, /*#__PURE__*/React__default.createElement(digitUiReactComponents.MultiLink, {
|
|
21211
|
+
className: "multilinkWrapper employee-mulitlink-main-divNew",
|
|
20958
21212
|
onHeadClick: () => setShowOptions(!showOptions),
|
|
20959
21213
|
displayOptions: showOptions,
|
|
20960
21214
|
options: dowloadOptions,
|
|
20961
21215
|
downloadBtnClassName: "employee-download-btn-className",
|
|
20962
|
-
optionsClassName: "employee-options-btn-className"
|
|
21216
|
+
optionsClassName: "employee-options-btn-className",
|
|
21217
|
+
ref: menuRef
|
|
20963
21218
|
})), /*#__PURE__*/React__default.createElement(ApplicationDetails, {
|
|
20964
21219
|
applicationDetails: applicationDetails,
|
|
20965
21220
|
isLoading: isLoading,
|
|
@@ -20972,8 +21227,9 @@ const ApplicationDetailsBillAmendment = () => {
|
|
|
20972
21227
|
showToast: showToast,
|
|
20973
21228
|
setShowToast: setShowToast,
|
|
20974
21229
|
closeToast: () => setShowToast(null),
|
|
20975
|
-
timelineStatusPrefix: `WF_${businessService === null || businessService === void 0 ? void 0 : businessService.toUpperCase()}_
|
|
20976
|
-
|
|
21230
|
+
timelineStatusPrefix: `WF_${businessService === null || businessService === void 0 ? void 0 : businessService.toUpperCase()}_`,
|
|
21231
|
+
showTimeLine: !isEmployee
|
|
21232
|
+
}))), showToast ? /*#__PURE__*/React__default.createElement(digitUiReactComponents.Toast, {
|
|
20977
21233
|
isDleteBtn: true,
|
|
20978
21234
|
error: updateApplicationError ? "WS_APPLICATION_UPDATE_ERROR" : null,
|
|
20979
21235
|
label: isSuccess ? showToast === null || showToast === void 0 ? void 0 : showToast.label : updateError === null || updateError === void 0 ? void 0 : updateError.Error
|
|
@@ -25470,8 +25726,9 @@ const BILLSBreadCrumbs = _ref => {
|
|
|
25470
25726
|
isclickable: false
|
|
25471
25727
|
}, {
|
|
25472
25728
|
path: "/digit-ui/employee/ws/generate-note-bill-amendment",
|
|
25473
|
-
label: t("
|
|
25474
|
-
show: location.pathname.includes("/generate-note-bill-amendment") ? true : false
|
|
25729
|
+
label: fromScreen ? `${t(fromScreen)} / ${t("WS_APPLICATION_DETAILS_HEADER")}` : t("WS_APPLICATION_DETAILS_HEADER"),
|
|
25730
|
+
show: location.pathname.includes("/generate-note-bill-amendment") ? true : false,
|
|
25731
|
+
isBack: fromScreen && true
|
|
25475
25732
|
}, {
|
|
25476
25733
|
path: "/digit-ui/employee/ws/water/bulk-bil",
|
|
25477
25734
|
label: t("CS_TITLE_BULK_BILL"),
|
|
@@ -25700,9 +25957,11 @@ const App$1 = _ref2 => {
|
|
|
25700
25957
|
})
|
|
25701
25958
|
}), /*#__PURE__*/React__default.createElement(digitUiReactComponents.PrivateRoute, {
|
|
25702
25959
|
path: `${path}/generate-note-bill-amendment`,
|
|
25703
|
-
component: () => /*#__PURE__*/React__default.createElement(
|
|
25960
|
+
component: () => /*#__PURE__*/React__default.createElement(digitUiReactComponents.LayoutWrapper, {
|
|
25961
|
+
layoutClass: "action"
|
|
25962
|
+
}, /*#__PURE__*/React__default.createElement(WSApplicationDetailsBillAmendment, {
|
|
25704
25963
|
path
|
|
25705
|
-
})
|
|
25964
|
+
}))
|
|
25706
25965
|
}), /*#__PURE__*/React__default.createElement(digitUiReactComponents.PrivateRoute, {
|
|
25707
25966
|
path: `${path}/response`,
|
|
25708
25967
|
component: () => /*#__PURE__*/React__default.createElement(Response, {
|
|
@@ -31628,11 +31887,16 @@ const isOtherDocument = function (code) {
|
|
|
31628
31887
|
}
|
|
31629
31888
|
return code.toUpperCase().includes("OTHER");
|
|
31630
31889
|
};
|
|
31631
|
-
const isRwhDocType = doc => {
|
|
31890
|
+
const isRwhDocType$1 = doc => {
|
|
31632
31891
|
if (!doc) return false;
|
|
31633
31892
|
const str = ((typeof doc === "string" ? doc : "") + " " + ((doc === null || doc === void 0 ? void 0 : doc.documentType) || "") + " " + ((doc === null || doc === void 0 ? void 0 : doc.code) || "") + " " + ((doc === null || doc === void 0 ? void 0 : doc.i18nKey) || "") + " " + ((doc === null || doc === void 0 ? void 0 : doc.name) || "") + " " + ((doc === null || doc === void 0 ? void 0 : doc.documentName) || "")).toUpperCase();
|
|
31634
31893
|
return str.includes("RAIN") || str.includes("HARVEST");
|
|
31635
31894
|
};
|
|
31895
|
+
const isStpDocType$1 = doc => {
|
|
31896
|
+
if (!doc) return false;
|
|
31897
|
+
const str = ((typeof doc === "string" ? doc : "") + " " + ((doc === null || doc === void 0 ? void 0 : doc.documentType) || "") + " " + ((doc === null || doc === void 0 ? void 0 : doc.code) || "") + " " + ((doc === null || doc === void 0 ? void 0 : doc.i18nKey) || "") + " " + ((doc === null || doc === void 0 ? void 0 : doc.name) || "") + " " + ((doc === null || doc === void 0 ? void 0 : doc.documentName) || "")).toUpperCase();
|
|
31898
|
+
return str.includes("SEWER") || str.includes("SEWAGE") || str.includes("STP") || str.includes("TREATMENT");
|
|
31899
|
+
};
|
|
31636
31900
|
const removeDuplicateOtherDocuments = function (documentList) {
|
|
31637
31901
|
if (documentList === void 0) {
|
|
31638
31902
|
documentList = [];
|
|
@@ -31709,6 +31973,7 @@ const WSDocumentsEmployee = _ref => {
|
|
|
31709
31973
|
};
|
|
31710
31974
|
const isTenant = checkIsTenant(formData === null || formData === void 0 ? void 0 : (_formData$ConnectionD = formData.ConnectionDetails) === null || _formData$ConnectionD === void 0 ? void 0 : (_formData$ConnectionD2 = _formData$ConnectionD[0]) === null || _formData$ConnectionD2 === void 0 ? void 0 : _formData$ConnectionD2.applicantType) || checkIsTenant(formData === null || formData === void 0 ? void 0 : (_formData$ConnectionD3 = formData.ConnectionDetails) === null || _formData$ConnectionD3 === void 0 ? void 0 : _formData$ConnectionD3.applicantType) || checkIsTenant(formData === null || formData === void 0 ? void 0 : (_formData$application = formData.applicationSelection) === null || _formData$application === void 0 ? void 0 : _formData$application.applicantType) || checkIsTenant(formData === null || formData === void 0 ? void 0 : (_formData$application2 = formData.applicationSelection) === null || _formData$application2 === void 0 ? void 0 : (_formData$application3 = _formData$application2[0]) === null || _formData$application3 === void 0 ? void 0 : _formData$application3.applicantType) || checkIsTenant(formData === null || formData === void 0 ? void 0 : (_formData$connectionH = formData.connectionHolders) === null || _formData$connectionH === void 0 ? void 0 : (_formData$connectionH2 = _formData$connectionH[0]) === null || _formData$connectionH2 === void 0 ? void 0 : _formData$connectionH2.applicantType) || checkIsTenant(formData === null || formData === void 0 ? void 0 : (_formData$ConnectionH = formData.ConnectionHolderDetails) === null || _formData$ConnectionH === void 0 ? void 0 : (_formData$ConnectionH2 = _formData$ConnectionH[0]) === null || _formData$ConnectionH2 === void 0 ? void 0 : _formData$ConnectionH2.applicantType) || checkIsTenant(formData === null || formData === void 0 ? void 0 : (_formData$additionalD = formData.additionalDetails) === null || _formData$additionalD === void 0 ? void 0 : _formData$additionalD.applicantType);
|
|
31711
31975
|
const isRwhMandatory = !!((formData === null || formData === void 0 ? void 0 : (_formData$rainWaterHa = formData.rainWaterHarvesting) === null || _formData$rainWaterHa === void 0 ? void 0 : _formData$rainWaterHa.hasCertificate) === true || String(formData === null || formData === void 0 ? void 0 : (_formData$rainWaterHa2 = formData.rainWaterHarvesting) === null || _formData$rainWaterHa2 === void 0 ? void 0 : _formData$rainWaterHa2.hasCertificate) === "true" || (formData === null || formData === void 0 ? void 0 : (_formData$rainWaterHa3 = formData.rainWaterHarvesting) === null || _formData$rainWaterHa3 === void 0 ? void 0 : _formData$rainWaterHa3.isRainwaterHarvesting) === true || String(formData === null || formData === void 0 ? void 0 : (_formData$rainWaterHa4 = formData.rainWaterHarvesting) === null || _formData$rainWaterHa4 === void 0 ? void 0 : _formData$rainWaterHa4.isRainwaterHarvesting) === "true" || (formData === null || formData === void 0 ? void 0 : (_formData$additionalD2 = formData.additionalDetails) === null || _formData$additionalD2 === void 0 ? void 0 : _formData$additionalD2.hasRainWaterHarvestingCertificate) === true || (formData === null || formData === void 0 ? void 0 : (_formData$additionalD3 = formData.additionalDetails) === null || _formData$additionalD3 === void 0 ? void 0 : _formData$additionalD3.isRainwaterHarvesting) === true);
|
|
31976
|
+
const isStpMandatory = false;
|
|
31712
31977
|
const sessionDjb = (_Digit$SessionStorage = Digit.SessionStorage.get("PT_CREATE_EMP_WS_NEW_FORM")) === null || _Digit$SessionStorage === void 0 ? void 0 : _Digit$SessionStorage.djbEmployee;
|
|
31713
31978
|
const djbData = (formData === null || formData === void 0 ? void 0 : formData.djbEmployee) || sessionDjb || (formData === null || formData === void 0 ? void 0 : formData.additionalDetails);
|
|
31714
31979
|
const isDjbEmployee = (djbData === null || djbData === void 0 ? void 0 : djbData.isDjbEmployee) === true || String(djbData === null || djbData === void 0 ? void 0 : djbData.isDjbEmployee) === "true";
|
|
@@ -31735,7 +32000,8 @@ const WSDocumentsEmployee = _ref => {
|
|
|
31735
32000
|
});
|
|
31736
32001
|
const [enableSubmit, setEnableSubmit] = React.useState(true);
|
|
31737
32002
|
const [error, setError] = React.useState(null);
|
|
31738
|
-
const hasRwhUploaded = documents === null || documents === void 0 ? void 0 : documents.some(item => isRwhDocType(item) && (item === null || item === void 0 ? void 0 : item.fileStoreId));
|
|
32003
|
+
const hasRwhUploaded = documents === null || documents === void 0 ? void 0 : documents.some(item => isRwhDocType$1(item) && (item === null || item === void 0 ? void 0 : item.fileStoreId));
|
|
32004
|
+
const hasStpUploaded = documents === null || documents === void 0 ? void 0 : documents.some(item => isStpDocType$1(item) && (item === null || item === void 0 ? void 0 : item.fileStoreId));
|
|
31739
32005
|
const wsDocsData = window.location.href.includes("modify") ? "ModifyConnectionDocuments" : window.location.href.includes("disconnection") ? "DisconnectionDocuments" : "NewWSDocuments";
|
|
31740
32006
|
let action = "create";
|
|
31741
32007
|
const {
|
|
@@ -31962,6 +32228,8 @@ const WSDocumentsEmployee = _ref => {
|
|
|
31962
32228
|
isOtherDocument: isOther,
|
|
31963
32229
|
isRwhMandatory: isRwhMandatory,
|
|
31964
32230
|
hasRwhUploaded: hasRwhUploaded,
|
|
32231
|
+
isStpMandatory: isStpMandatory,
|
|
32232
|
+
hasStpUploaded: hasStpUploaded,
|
|
31965
32233
|
isTenant: isTenant
|
|
31966
32234
|
});
|
|
31967
32235
|
}), isDjbEmployee && /*#__PURE__*/React__default.createElement(EmployeeIdDocumentUpload, {
|
|
@@ -31990,6 +32258,24 @@ const WSDocumentsEmployee = _ref => {
|
|
|
31990
32258
|
fontWeight: "600"
|
|
31991
32259
|
}
|
|
31992
32260
|
}, "\u26A0\uFE0F", " ", t("WS_RWH_CERTIFICATE_MANDATORY_INSTRUCTION") || "Rain Water Harvesting Certificate is mandatory to upload. Please upload it under Other Documents.")) : null;
|
|
32261
|
+
const stpAlertBanner = !isTenant && isStpMandatory && !hasStpUploaded ? /*#__PURE__*/React__default.createElement("div", {
|
|
32262
|
+
style: {
|
|
32263
|
+
display: "flex",
|
|
32264
|
+
alignItems: "center",
|
|
32265
|
+
gap: "10px",
|
|
32266
|
+
marginBottom: "16px",
|
|
32267
|
+
padding: "10px 14px",
|
|
32268
|
+
backgroundColor: "#fff2f0",
|
|
32269
|
+
borderLeft: "4px solid #ff4d4f",
|
|
32270
|
+
borderRadius: "4px"
|
|
32271
|
+
}
|
|
32272
|
+
}, /*#__PURE__*/React__default.createElement("span", {
|
|
32273
|
+
style: {
|
|
32274
|
+
fontSize: "14px",
|
|
32275
|
+
color: "#d32f2f",
|
|
32276
|
+
fontWeight: "600"
|
|
32277
|
+
}
|
|
32278
|
+
}, "\u26A0\uFE0F", " ", t("WS_STP_CERTIFICATE_MANDATORY_INSTRUCTION") || "Sewer Treatment Plant (STP) Certificate is mandatory to upload. Please upload it under Other Documents.")) : null;
|
|
31993
32279
|
const nocDownloadSection = isTenant ? /*#__PURE__*/React__default.createElement("div", {
|
|
31994
32280
|
style: {
|
|
31995
32281
|
marginBottom: "20px",
|
|
@@ -32032,7 +32318,7 @@ const WSDocumentsEmployee = _ref => {
|
|
|
32032
32318
|
onSelect: goNext,
|
|
32033
32319
|
onSkip: () => onSelect(),
|
|
32034
32320
|
isDisabled: enableSubmit
|
|
32035
|
-
}, rwhAlertBanner, nocDownloadSection, innerContent, error && /*#__PURE__*/React__default.createElement(digitUiReactComponents.Toast, {
|
|
32321
|
+
}, rwhAlertBanner, stpAlertBanner, nocDownloadSection, innerContent, error && /*#__PURE__*/React__default.createElement(digitUiReactComponents.Toast, {
|
|
32036
32322
|
label: error,
|
|
32037
32323
|
onClose: () => setError(null),
|
|
32038
32324
|
error: true,
|
|
@@ -32043,7 +32329,7 @@ const WSDocumentsEmployee = _ref => {
|
|
|
32043
32329
|
return /*#__PURE__*/React__default.createElement(digitUiReactComponents.CollapsibleCardPage, {
|
|
32044
32330
|
title: t("WS_DOCUMENTS"),
|
|
32045
32331
|
defaultOpen: true
|
|
32046
|
-
}, rwhAlertBanner, nocDownloadSection, innerContent, error && /*#__PURE__*/React__default.createElement(digitUiReactComponents.Toast, {
|
|
32332
|
+
}, rwhAlertBanner, stpAlertBanner, nocDownloadSection, innerContent, error && /*#__PURE__*/React__default.createElement(digitUiReactComponents.Toast, {
|
|
32047
32333
|
label: error,
|
|
32048
32334
|
onClose: () => setError(null),
|
|
32049
32335
|
error: true,
|
|
@@ -32347,6 +32633,8 @@ function SelectDocument$2(_ref3) {
|
|
|
32347
32633
|
isOtherDocument: isOther = false,
|
|
32348
32634
|
isRwhMandatory = false,
|
|
32349
32635
|
hasRwhUploaded = false,
|
|
32636
|
+
isStpMandatory = false,
|
|
32637
|
+
hasStpUploaded = false,
|
|
32350
32638
|
isTenant: isTenantProp
|
|
32351
32639
|
} = _ref3;
|
|
32352
32640
|
const fileRef = React.useRef();
|
|
@@ -32366,7 +32654,7 @@ function SelectDocument$2(_ref3) {
|
|
|
32366
32654
|
const isOwnershipProof = (doc === null || doc === void 0 ? void 0 : doc.code) === "OWNER.ADDRESSPROOF" || (doc === null || doc === void 0 ? void 0 : doc.code) === "OWNER.OWNERSHIPPROOF" || (doc === null || doc === void 0 ? void 0 : (_doc$code6 = doc.code) === null || _doc$code6 === void 0 ? void 0 : _doc$code6.includes("ADDRESSPROOF")) || (doc === null || doc === void 0 ? void 0 : (_doc$code7 = doc.code) === null || _doc$code7 === void 0 ? void 0 : _doc$code7.includes("OWNERSHIP"));
|
|
32367
32655
|
const isDocNumberMandatory = isIdentityProof || isOwnershipProof;
|
|
32368
32656
|
const [selectedDocument, setSelectedDocument] = React.useState(() => {
|
|
32369
|
-
var _filteredDocument$doc, _doc$
|
|
32657
|
+
var _filteredDocument$doc, _doc$dropdownData4, _doc$dropdownData5;
|
|
32370
32658
|
if (filteredDocument && doc !== null && doc !== void 0 && doc.dropdownData) {
|
|
32371
32659
|
var _doc$dropdownData;
|
|
32372
32660
|
const match = doc === null || doc === void 0 ? void 0 : (_doc$dropdownData = doc.dropdownData) === null || _doc$dropdownData === void 0 ? void 0 : _doc$dropdownData.find(d => d.code === filteredDocument.documentType);
|
|
@@ -32377,12 +32665,20 @@ function SelectDocument$2(_ref3) {
|
|
|
32377
32665
|
}
|
|
32378
32666
|
if (isOther && isRwhMandatory && !hasRwhUploaded && doc !== null && doc !== void 0 && doc.dropdownData) {
|
|
32379
32667
|
var _doc$dropdownData2, _rwhMatch$code;
|
|
32380
|
-
const rwhMatch = doc === null || doc === void 0 ? void 0 : (_doc$dropdownData2 = doc.dropdownData) === null || _doc$dropdownData2 === void 0 ? void 0 : _doc$dropdownData2.find(d => isRwhDocType(d));
|
|
32668
|
+
const rwhMatch = doc === null || doc === void 0 ? void 0 : (_doc$dropdownData2 = doc.dropdownData) === null || _doc$dropdownData2 === void 0 ? void 0 : _doc$dropdownData2.find(d => isRwhDocType$1(d));
|
|
32381
32669
|
if (rwhMatch) return {
|
|
32382
32670
|
...rwhMatch,
|
|
32383
32671
|
i18nKey: (_rwhMatch$code = rwhMatch.code) === null || _rwhMatch$code === void 0 ? void 0 : _rwhMatch$code.replaceAll(".", "_")
|
|
32384
32672
|
};
|
|
32385
32673
|
}
|
|
32674
|
+
if (isOther && isStpMandatory && !hasStpUploaded && doc !== null && doc !== void 0 && doc.dropdownData) {
|
|
32675
|
+
var _doc$dropdownData3, _stpMatch$code;
|
|
32676
|
+
const stpMatch = doc === null || doc === void 0 ? void 0 : (_doc$dropdownData3 = doc.dropdownData) === null || _doc$dropdownData3 === void 0 ? void 0 : _doc$dropdownData3.find(d => isStpDocType$1(d));
|
|
32677
|
+
if (stpMatch) return {
|
|
32678
|
+
...stpMatch,
|
|
32679
|
+
i18nKey: (_stpMatch$code = stpMatch.code) === null || _stpMatch$code === void 0 ? void 0 : _stpMatch$code.replaceAll(".", "_")
|
|
32680
|
+
};
|
|
32681
|
+
}
|
|
32386
32682
|
if (isApplicantPhoto) {
|
|
32387
32683
|
return filteredDocument ? {
|
|
32388
32684
|
...filteredDocument,
|
|
@@ -32398,10 +32694,14 @@ function SelectDocument$2(_ref3) {
|
|
|
32398
32694
|
...filteredDocument,
|
|
32399
32695
|
code: filteredDocument === null || filteredDocument === void 0 ? void 0 : filteredDocument.documentType,
|
|
32400
32696
|
i18nKey: filteredDocument === null || filteredDocument === void 0 ? void 0 : (_filteredDocument$doc = filteredDocument.documentType) === null || _filteredDocument$doc === void 0 ? void 0 : _filteredDocument$doc.replaceAll(".", "_")
|
|
32401
|
-
} : doc !== null && doc !== void 0 && doc.hasDropdown && Array.isArray(doc === null || doc === void 0 ? void 0 : doc.dropdownData) && (doc === null || doc === void 0 ? void 0 : (_doc$
|
|
32697
|
+
} : doc !== null && doc !== void 0 && doc.hasDropdown && Array.isArray(doc === null || doc === void 0 ? void 0 : doc.dropdownData) && (doc === null || doc === void 0 ? void 0 : (_doc$dropdownData4 = doc.dropdownData) === null || _doc$dropdownData4 === void 0 ? void 0 : _doc$dropdownData4.length) > 0 ? (doc === null || doc === void 0 ? void 0 : (_doc$dropdownData5 = doc.dropdownData) === null || _doc$dropdownData5 === void 0 ? void 0 : _doc$dropdownData5.length) === 1 ? doc === null || doc === void 0 ? void 0 : doc.dropdownData[0] : {} : doc;
|
|
32402
32698
|
});
|
|
32403
32699
|
const [file, setFile] = React.useState(null);
|
|
32404
32700
|
const [uploadedFile, setUploadedFile] = React.useState(() => isOther ? null : (filteredDocument === null || filteredDocument === void 0 ? void 0 : filteredDocument.fileStoreId) || null);
|
|
32701
|
+
const [validityDate, setValidityDate] = React.useState(() => {
|
|
32702
|
+
var _filteredDocument$add;
|
|
32703
|
+
return (filteredDocument === null || filteredDocument === void 0 ? void 0 : filteredDocument.validityDate) || (filteredDocument === null || filteredDocument === void 0 ? void 0 : filteredDocument.validityUpTo) || (filteredDocument === null || filteredDocument === void 0 ? void 0 : (_filteredDocument$add = filteredDocument.additionalDetails) === null || _filteredDocument$add === void 0 ? void 0 : _filteredDocument$add.validityDate) || "";
|
|
32704
|
+
});
|
|
32405
32705
|
const [documentUid, setDocumentUid] = React.useState(() => {
|
|
32406
32706
|
if (isOther) return "";
|
|
32407
32707
|
const num = (filteredDocument === null || filteredDocument === void 0 ? void 0 : filteredDocument.documentNumber) || "";
|
|
@@ -32420,6 +32720,8 @@ function SelectDocument$2(_ref3) {
|
|
|
32420
32720
|
const [docFileType, setDocFileType] = React.useState("");
|
|
32421
32721
|
const [digiLockerUpload, setDigilockerUpload] = React.useState(false);
|
|
32422
32722
|
const [docNumberError, setDocNumberError] = React.useState(null);
|
|
32723
|
+
const isSelectedRwh = isRwhDocType$1(selectedDocument);
|
|
32724
|
+
const isSelectedStp = isStpDocType$1(selectedDocument);
|
|
32423
32725
|
const isOtherDocumentsRemark = Boolean(isOther && selectedDocument && ((selectedDocument === null || selectedDocument === void 0 ? void 0 : selectedDocument.code) === "OWNER.OTHERDOCUMENTS.OTHER_DOCUMENTS" || (selectedDocument === null || selectedDocument === void 0 ? void 0 : selectedDocument.code) === "OWNER_OTHERDOCUMENTS_OTHER_DOCUMENTS" || (selectedDocument === null || selectedDocument === void 0 ? void 0 : selectedDocument.i18nKey) === "OWNER_OTHERDOCUMENTS_OTHER_DOCUMENTS" || (selectedDocument === null || selectedDocument === void 0 ? void 0 : (_selectedDocument$cod = selectedDocument.code) === null || _selectedDocument$cod === void 0 ? void 0 : _selectedDocument$cod.endsWith(".OTHER_DOCUMENTS")) || (selectedDocument === null || selectedDocument === void 0 ? void 0 : (_selectedDocument$cod2 = selectedDocument.code) === null || _selectedDocument$cod2 === void 0 ? void 0 : _selectedDocument$cod2.includes("OTHER_DOCUMENTS")) || (selectedDocument === null || selectedDocument === void 0 ? void 0 : (_selectedDocument$nam = selectedDocument.name) === null || _selectedDocument$nam === void 0 ? void 0 : (_selectedDocument$nam2 = _selectedDocument$nam.toUpperCase()) === null || _selectedDocument$nam2 === void 0 ? void 0 : _selectedDocument$nam2.includes("OTHER DOCUMENT")) || (selectedDocument === null || selectedDocument === void 0 ? void 0 : (_selectedDocument$i = selectedDocument.i18nKey) === null || _selectedDocument$i === void 0 ? void 0 : _selectedDocument$i.includes("OTHER_DOCUMENTS"))));
|
|
32424
32726
|
const validateDocumentNumber = (value, docTypeCode, isReq, hasFile) => {
|
|
32425
32727
|
const trimmed = (value || "").trim();
|
|
@@ -32473,6 +32775,7 @@ function SelectDocument$2(_ref3) {
|
|
|
32473
32775
|
setUploadedFile(null);
|
|
32474
32776
|
setFile(null);
|
|
32475
32777
|
setDocumentUid("");
|
|
32778
|
+
setValidityDate("");
|
|
32476
32779
|
if (isOther && doc !== null && doc !== void 0 && doc.hasDropdown) {
|
|
32477
32780
|
setSelectedDocument({});
|
|
32478
32781
|
}
|
|
@@ -32514,11 +32817,11 @@ function SelectDocument$2(_ref3) {
|
|
|
32514
32817
|
};
|
|
32515
32818
|
React.useEffect(() => {
|
|
32516
32819
|
if (filteredDocument) {
|
|
32517
|
-
var _filteredDocument$doc2, _doc$
|
|
32820
|
+
var _filteredDocument$doc2, _doc$dropdownData7, _doc$dropdownData8;
|
|
32518
32821
|
let match = null;
|
|
32519
32822
|
if (doc !== null && doc !== void 0 && doc.dropdownData) {
|
|
32520
|
-
var _doc$
|
|
32521
|
-
match = doc === null || doc === void 0 ? void 0 : (_doc$
|
|
32823
|
+
var _doc$dropdownData6;
|
|
32824
|
+
match = doc === null || doc === void 0 ? void 0 : (_doc$dropdownData6 = doc.dropdownData) === null || _doc$dropdownData6 === void 0 ? void 0 : _doc$dropdownData6.find(d => d.code === filteredDocument.documentType);
|
|
32522
32825
|
}
|
|
32523
32826
|
setSelectedDocument(match ? {
|
|
32524
32827
|
...filteredDocument,
|
|
@@ -32531,7 +32834,7 @@ function SelectDocument$2(_ref3) {
|
|
|
32531
32834
|
...doc,
|
|
32532
32835
|
code: (doc === null || doc === void 0 ? void 0 : doc.code) || "OWNER.APPLICANTPHOTO",
|
|
32533
32836
|
i18nKey: "OWNER_APPLICANTPHOTO"
|
|
32534
|
-
} : doc !== null && doc !== void 0 && doc.hasDropdown && Array.isArray(doc === null || doc === void 0 ? void 0 : doc.dropdownData) && (doc === null || doc === void 0 ? void 0 : (_doc$
|
|
32837
|
+
} : doc !== null && doc !== void 0 && doc.hasDropdown && Array.isArray(doc === null || doc === void 0 ? void 0 : doc.dropdownData) && (doc === null || doc === void 0 ? void 0 : (_doc$dropdownData7 = doc.dropdownData) === null || _doc$dropdownData7 === void 0 ? void 0 : _doc$dropdownData7.length) > 0 ? (doc === null || doc === void 0 ? void 0 : (_doc$dropdownData8 = doc.dropdownData) === null || _doc$dropdownData8 === void 0 ? void 0 : _doc$dropdownData8.length) === 1 ? doc === null || doc === void 0 ? void 0 : doc.dropdownData[0] : {} : doc);
|
|
32535
32838
|
}
|
|
32536
32839
|
}, []);
|
|
32537
32840
|
function selectfile(e, newFile) {
|
|
@@ -32593,7 +32896,7 @@ function SelectDocument$2(_ref3) {
|
|
|
32593
32896
|
const name = d.name || "";
|
|
32594
32897
|
return !(code.includes("NOC_FROM_OWNER") || code === "NOC from Owner" || name.includes("NOC from Owner"));
|
|
32595
32898
|
});
|
|
32596
|
-
if (dropDownData && !dropDownData.some(d => isRwhDocType(d))) {
|
|
32899
|
+
if (dropDownData && !dropDownData.some(d => isRwhDocType$1(d))) {
|
|
32597
32900
|
dropDownData = [...dropDownData, {
|
|
32598
32901
|
code: "OWNER.OTHERDOCUMENTS.RAINWATER_HARVESTING",
|
|
32599
32902
|
i18nKey: "OWNER_OTHERDOCUMENTS_RAINWATER_HARVESTING",
|
|
@@ -32626,9 +32929,9 @@ function SelectDocument$2(_ref3) {
|
|
|
32626
32929
|
setFile(null);
|
|
32627
32930
|
} else if (isRwhMandatory && !hasRwhUploaded) {
|
|
32628
32931
|
var _dropDownData4;
|
|
32629
|
-
const isCurrentRwh = (selectedDocument === null || selectedDocument === void 0 ? void 0 : selectedDocument.code) && isRwhDocType(selectedDocument);
|
|
32932
|
+
const isCurrentRwh = (selectedDocument === null || selectedDocument === void 0 ? void 0 : selectedDocument.code) && isRwhDocType$1(selectedDocument);
|
|
32630
32933
|
if (!isCurrentRwh && ((_dropDownData4 = dropDownData) === null || _dropDownData4 === void 0 ? void 0 : _dropDownData4.length) > 0) {
|
|
32631
|
-
const rwhMatch = dropDownData.find(d => isRwhDocType(d));
|
|
32934
|
+
const rwhMatch = dropDownData.find(d => isRwhDocType$1(d));
|
|
32632
32935
|
if (rwhMatch && (!uploadedFile || !(selectedDocument !== null && selectedDocument !== void 0 && selectedDocument.code))) {
|
|
32633
32936
|
var _rwhMatch$code2;
|
|
32634
32937
|
setSelectedDocument({
|
|
@@ -32637,10 +32940,23 @@ function SelectDocument$2(_ref3) {
|
|
|
32637
32940
|
});
|
|
32638
32941
|
}
|
|
32639
32942
|
}
|
|
32943
|
+
} else if (isStpMandatory && !hasStpUploaded) {
|
|
32944
|
+
var _dropDownData5;
|
|
32945
|
+
const isCurrentStp = (selectedDocument === null || selectedDocument === void 0 ? void 0 : selectedDocument.code) && isStpDocType$1(selectedDocument);
|
|
32946
|
+
if (!isCurrentStp && ((_dropDownData5 = dropDownData) === null || _dropDownData5 === void 0 ? void 0 : _dropDownData5.length) > 0) {
|
|
32947
|
+
const stpMatch = dropDownData.find(d => isStpDocType$1(d));
|
|
32948
|
+
if (stpMatch && (!uploadedFile || !(selectedDocument !== null && selectedDocument !== void 0 && selectedDocument.code))) {
|
|
32949
|
+
var _stpMatch$code2;
|
|
32950
|
+
setSelectedDocument({
|
|
32951
|
+
...stpMatch,
|
|
32952
|
+
i18nKey: (_stpMatch$code2 = stpMatch.code) === null || _stpMatch$code2 === void 0 ? void 0 : _stpMatch$code2.replaceAll(".", "_")
|
|
32953
|
+
});
|
|
32954
|
+
}
|
|
32955
|
+
}
|
|
32640
32956
|
}
|
|
32641
32957
|
}
|
|
32642
32958
|
}
|
|
32643
|
-
}, [isTenant, isOther, isRwhMandatory, hasRwhUploaded, dropDownData]);
|
|
32959
|
+
}, [isTenant, isOther, isRwhMandatory, hasRwhUploaded, isStpMandatory, hasStpUploaded, dropDownData]);
|
|
32644
32960
|
const [isHidden, setHidden] = React.useState(false);
|
|
32645
32961
|
const documentDisplayName = (selectedDocument === null || selectedDocument === void 0 ? void 0 : selectedDocument.i18nKey) || (selectedDocument === null || selectedDocument === void 0 ? void 0 : selectedDocument.name) || (selectedDocument === null || selectedDocument === void 0 ? void 0 : selectedDocument.code) || (doc === null || doc === void 0 ? void 0 : doc.i18nKey) || (doc === null || doc === void 0 ? void 0 : doc.name) || (doc === null || doc === void 0 ? void 0 : doc.code);
|
|
32646
32962
|
const addError = () => {
|
|
@@ -32698,10 +33014,20 @@ function SelectDocument$2(_ref3) {
|
|
|
32698
33014
|
documentName: (selectedDocument === null || selectedDocument === void 0 ? void 0 : selectedDocument.i18nKey) || (selectedDocument === null || selectedDocument === void 0 ? void 0 : selectedDocument.code) || "",
|
|
32699
33015
|
documentUid: documentUid,
|
|
32700
33016
|
documentNumber: documentUid,
|
|
33017
|
+
validityDate: validityDate || undefined,
|
|
33018
|
+
validityUpTo: validityDate || undefined,
|
|
33019
|
+
date: validityDate || undefined,
|
|
32701
33020
|
remarks: isOtherDocumentsRemark ? documentUid : undefined,
|
|
32702
|
-
additionalDetails:
|
|
32703
|
-
|
|
32704
|
-
|
|
33021
|
+
additionalDetails: {
|
|
33022
|
+
...(isOtherDocumentsRemark ? {
|
|
33023
|
+
remark: documentUid
|
|
33024
|
+
} : {}),
|
|
33025
|
+
...(validityDate ? {
|
|
33026
|
+
validityDate,
|
|
33027
|
+
validityUpTo: validityDate,
|
|
33028
|
+
date: validityDate
|
|
33029
|
+
} : {})
|
|
33030
|
+
},
|
|
32705
33031
|
i18nKey: selectedDocument === null || selectedDocument === void 0 ? void 0 : selectedDocument.code,
|
|
32706
33032
|
id: selectedDocument === null || selectedDocument === void 0 ? void 0 : selectedDocument.id,
|
|
32707
33033
|
status: "ACTIVE",
|
|
@@ -32712,8 +33038,11 @@ function SelectDocument$2(_ref3) {
|
|
|
32712
33038
|
});
|
|
32713
33039
|
}
|
|
32714
33040
|
const isRwhRequired = isOther && isRwhMandatory;
|
|
32715
|
-
const isRwhSatisfied = hasRwhUploaded || uploadedFile && isRwhDocType(selectedDocument);
|
|
33041
|
+
const isRwhSatisfied = hasRwhUploaded || uploadedFile && isRwhDocType$1(selectedDocument);
|
|
32716
33042
|
const rwhMissing = isRwhRequired && !isRwhSatisfied;
|
|
33043
|
+
const isStpRequired = isOther && isStpMandatory;
|
|
33044
|
+
const isStpSatisfied = hasStpUploaded || uploadedFile && isStpDocType$1(selectedDocument);
|
|
33045
|
+
const stpMissing = isStpRequired && !isStpSatisfied;
|
|
32717
33046
|
const hasOtherUploaded = isOther && (documents === null || documents === void 0 ? void 0 : documents.some(item => {
|
|
32718
33047
|
var _item$documentType4;
|
|
32719
33048
|
return item === null || item === void 0 ? void 0 : (_item$documentType4 = item.documentType) === null || _item$documentType4 === void 0 ? void 0 : _item$documentType4.includes(doc === null || doc === void 0 ? void 0 : doc.code);
|
|
@@ -32722,7 +33051,7 @@ function SelectDocument$2(_ref3) {
|
|
|
32722
33051
|
const isDocNumberMissing = isDocNumberMandatory && (!documentUid || !documentUid.trim());
|
|
32723
33052
|
const isDocMissing = (doc === null || doc === void 0 ? void 0 : doc.required) && !hasOtherUploaded && (!uploadedFile || !(selectedDocument !== null && selectedDocument !== void 0 && selectedDocument.code));
|
|
32724
33053
|
const isPartiallyFilled = isApplicantPhoto ? false : isDocNumberMandatory ? !uploadedFile || !(selectedDocument !== null && selectedDocument !== void 0 && selectedDocument.code) || isDocNumberMissing : !isCompletelyEmpty && !(uploadedFile && selectedDocument !== null && selectedDocument !== void 0 && selectedDocument.code);
|
|
32725
|
-
const effectiveRequired = (doc === null || doc === void 0 ? void 0 : doc.required) && !hasOtherUploaded || isPartiallyFilled || isOther && isRwhMandatory && !hasRwhUploaded || isDocNumberMandatory;
|
|
33054
|
+
const effectiveRequired = (doc === null || doc === void 0 ? void 0 : doc.required) && !hasOtherUploaded || isPartiallyFilled || isOther && isRwhMandatory && !hasRwhUploaded || isOther && isStpMandatory && !hasStpUploaded || isDocNumberMandatory;
|
|
32726
33055
|
const err = validateDocumentNumber(documentUid, selectedDocument === null || selectedDocument === void 0 ? void 0 : selectedDocument.code, isDocNumberMandatory || effectiveRequired, !!uploadedFile);
|
|
32727
33056
|
if (!isHidden) {
|
|
32728
33057
|
if (err) {
|
|
@@ -32733,13 +33062,15 @@ function SelectDocument$2(_ref3) {
|
|
|
32733
33062
|
addError();
|
|
32734
33063
|
} else if (rwhMissing) {
|
|
32735
33064
|
addError();
|
|
33065
|
+
} else if (stpMissing) {
|
|
33066
|
+
addError();
|
|
32736
33067
|
} else {
|
|
32737
33068
|
removeError();
|
|
32738
33069
|
}
|
|
32739
33070
|
} else if (isHidden) {
|
|
32740
33071
|
removeError();
|
|
32741
33072
|
}
|
|
32742
|
-
}, [uploadedFile, selectedDocument, documentUid, isHidden, effectiveRequired, isPartiallyFilled, hasOtherUploaded, formData === null || formData === void 0 ? void 0 : (_formData$ConnectionD7 = formData.ConnectionDetails) === null || _formData$ConnectionD7 === void 0 ? void 0 : _formData$ConnectionD7[0], isRwhMandatory, hasRwhUploaded]);
|
|
33073
|
+
}, [uploadedFile, selectedDocument, documentUid, validityDate, isHidden, effectiveRequired, isPartiallyFilled, hasOtherUploaded, formData === null || formData === void 0 ? void 0 : (_formData$ConnectionD7 = formData.ConnectionDetails) === null || _formData$ConnectionD7 === void 0 ? void 0 : _formData$ConnectionD7[0], isRwhMandatory, hasRwhUploaded, isStpMandatory, hasStpUploaded]);
|
|
32743
33074
|
React.useEffect(() => {
|
|
32744
33075
|
(function () {
|
|
32745
33076
|
try {
|
|
@@ -32830,15 +33161,21 @@ function SelectDocument$2(_ref3) {
|
|
|
32830
33161
|
style: {
|
|
32831
33162
|
margin: 0
|
|
32832
33163
|
}
|
|
32833
|
-
}, t(doc === null || doc === void 0 ? void 0 : doc.i18nKey), ((doc === null || doc === void 0 ? void 0 : doc.required) || !isTenant && isOther && isRwhMandatory) && /*#__PURE__*/React__default.createElement("span", {
|
|
33164
|
+
}, t(doc === null || doc === void 0 ? void 0 : doc.i18nKey), ((doc === null || doc === void 0 ? void 0 : doc.required) || !isTenant && isOther && (isRwhMandatory || isStpMandatory)) && /*#__PURE__*/React__default.createElement("span", {
|
|
32834
33165
|
className: "check-page-link-button"
|
|
32835
|
-
}, "*")), " ", !isTenant && isOther && isRwhMandatory && !hasRwhUploaded && !(uploadedFile && isRwhDocType(selectedDocument)) && /*#__PURE__*/React__default.createElement("div", {
|
|
33166
|
+
}, "*")), " ", !isTenant && isOther && isRwhMandatory && !hasRwhUploaded && !(uploadedFile && isRwhDocType$1(selectedDocument)) && /*#__PURE__*/React__default.createElement("div", {
|
|
32836
33167
|
style: {
|
|
32837
33168
|
fontSize: "12px",
|
|
32838
33169
|
color: "#d32f2f",
|
|
32839
33170
|
marginTop: "-4px"
|
|
32840
33171
|
}
|
|
32841
|
-
}, "* ", t("WS_RWH_CERTIFICATE_MANDATORY_MSG") || "Rain Water Harvesting Certificate is mandatory to upload."), /*#__PURE__*/React__default.createElement(
|
|
33172
|
+
}, "* ", t("WS_RWH_CERTIFICATE_MANDATORY_MSG") || "Rain Water Harvesting Certificate is mandatory to upload."), !isTenant && isOther && isStpMandatory && !hasStpUploaded && !(uploadedFile && isStpDocType$1(selectedDocument)) && /*#__PURE__*/React__default.createElement("div", {
|
|
33173
|
+
style: {
|
|
33174
|
+
fontSize: "12px",
|
|
33175
|
+
color: "#d32f2f",
|
|
33176
|
+
marginTop: "-4px"
|
|
33177
|
+
}
|
|
33178
|
+
}, "* ", t("WS_STP_CERTIFICATE_MANDATORY_MSG") || "Sewer Treatment Plant (STP) Certificate is mandatory to upload."), /*#__PURE__*/React__default.createElement(digitUiReactComponents.Dropdown, {
|
|
32842
33179
|
id: `doc-${doc === null || doc === void 0 ? void 0 : doc.code}`,
|
|
32843
33180
|
key: `doc-${doc === null || doc === void 0 ? void 0 : doc.code}`,
|
|
32844
33181
|
className: "form-field",
|
|
@@ -32984,6 +33321,7 @@ function SelectDocument$2(_ref3) {
|
|
|
32984
33321
|
setIsCameraFile(false);
|
|
32985
33322
|
setIsDocumentUidLocked(false);
|
|
32986
33323
|
setDocumentUid("");
|
|
33324
|
+
setValidityDate("");
|
|
32987
33325
|
if (isOther && doc !== null && doc !== void 0 && doc.hasDropdown) {
|
|
32988
33326
|
setSelectedDocument({});
|
|
32989
33327
|
}
|
|
@@ -33016,6 +33354,7 @@ function SelectDocument$2(_ref3) {
|
|
|
33016
33354
|
setIsCameraFile(false);
|
|
33017
33355
|
setIsDocumentUidLocked(false);
|
|
33018
33356
|
setDocumentUid("");
|
|
33357
|
+
setValidityDate("");
|
|
33019
33358
|
if (isOther && doc !== null && doc !== void 0 && doc.hasDropdown) {
|
|
33020
33359
|
setSelectedDocument({});
|
|
33021
33360
|
}
|
|
@@ -33035,6 +33374,7 @@ function SelectDocument$2(_ref3) {
|
|
|
33035
33374
|
setIsCameraFile(false);
|
|
33036
33375
|
setIsDocumentUidLocked(false);
|
|
33037
33376
|
setDocumentUid("");
|
|
33377
|
+
setValidityDate("");
|
|
33038
33378
|
if (isOther && doc !== null && doc !== void 0 && doc.hasDropdown) {
|
|
33039
33379
|
setSelectedDocument({});
|
|
33040
33380
|
}
|
|
@@ -33060,6 +33400,7 @@ function SelectDocument$2(_ref3) {
|
|
|
33060
33400
|
setIsCameraFile(false);
|
|
33061
33401
|
setIsDocumentUidLocked(false);
|
|
33062
33402
|
setDocumentUid("");
|
|
33403
|
+
setValidityDate("");
|
|
33063
33404
|
if (isOther && doc !== null && doc !== void 0 && doc.hasDropdown) {
|
|
33064
33405
|
setSelectedDocument({});
|
|
33065
33406
|
}
|
|
@@ -33086,6 +33427,7 @@ function SelectDocument$2(_ref3) {
|
|
|
33086
33427
|
setFileError(null);
|
|
33087
33428
|
setSelectedDocument(doc !== null && doc !== void 0 && doc.hasDropdown ? {} : doc);
|
|
33088
33429
|
setDocumentUid("");
|
|
33430
|
+
setValidityDate("");
|
|
33089
33431
|
setDocNumberError(null);
|
|
33090
33432
|
setIsDocumentUidLocked(false);
|
|
33091
33433
|
},
|
|
@@ -33108,7 +33450,8 @@ function SelectDocument$2(_ref3) {
|
|
|
33108
33450
|
}, fileError), (isOther ? otherUploadedDocuments : uploadedFile ? [{
|
|
33109
33451
|
fileStoreId: uploadedFile,
|
|
33110
33452
|
fileName: (file === null || file === void 0 ? void 0 : file.name) || (filteredDocument === null || filteredDocument === void 0 ? void 0 : filteredDocument.fileName),
|
|
33111
|
-
documentNumber: documentUid
|
|
33453
|
+
documentNumber: documentUid,
|
|
33454
|
+
validityDate: validityDate
|
|
33112
33455
|
}] : []).map((uploadedDocument, index) => /*#__PURE__*/React__default.createElement("div", {
|
|
33113
33456
|
key: uploadedDocument.fileStoreId || index,
|
|
33114
33457
|
style: {
|
|
@@ -33942,7 +34285,9 @@ const WSDisconnectionKNumber = _ref => {
|
|
|
33942
34285
|
setIsLoading(true);
|
|
33943
34286
|
return Promise.resolve(_finallyRethrows(function () {
|
|
33944
34287
|
return _catch(function () {
|
|
33945
|
-
|
|
34288
|
+
var _Digit$SessionStorage;
|
|
34289
|
+
const currentTenant = Digit.ULBService.getCurrentTenantId();
|
|
34290
|
+
const tenantId = currentTenant && currentTenant !== "dl" ? currentTenant : ((_Digit$SessionStorage = Digit.SessionStorage.get("CITIZEN.COMMON.HOME.CITY")) === null || _Digit$SessionStorage === void 0 ? void 0 : _Digit$SessionStorage.code) || "dl.djb";
|
|
33946
34291
|
const params = {
|
|
33947
34292
|
connectionNumber: trimmed,
|
|
33948
34293
|
searchType: "CONNECTION",
|
|
@@ -33960,85 +34305,107 @@ const WSDisconnectionKNumber = _ref => {
|
|
|
33960
34305
|
filters: params,
|
|
33961
34306
|
businessService: "WS"
|
|
33962
34307
|
}).catch(() => null)).then(function (wsResponse) {
|
|
33963
|
-
var _waterResponse$WaterC,
|
|
33964
|
-
function
|
|
33965
|
-
|
|
33966
|
-
|
|
33967
|
-
|
|
33968
|
-
|
|
33969
|
-
|
|
33970
|
-
|
|
33971
|
-
|
|
33972
|
-
|
|
33973
|
-
|
|
33974
|
-
|
|
34308
|
+
var _wsResponse, _waterResponse, _waterResponse$WaterC, _waterResponse2, _waterResponse2$Water;
|
|
34309
|
+
function _temp5() {
|
|
34310
|
+
function _temp3() {
|
|
34311
|
+
var _connection9, _connection0;
|
|
34312
|
+
function _temp(propertyResponse) {
|
|
34313
|
+
var _propertyResponse$Pro, _connection, _connection$connectio, _connection$connectio2, _connection2;
|
|
34314
|
+
const property = propertyResponse === null || propertyResponse === void 0 ? void 0 : (_propertyResponse$Pro = propertyResponse.Properties) === null || _propertyResponse$Pro === void 0 ? void 0 : _propertyResponse$Pro[0];
|
|
34315
|
+
if (property) connection = {
|
|
34316
|
+
...connection,
|
|
34317
|
+
property
|
|
34318
|
+
};
|
|
34319
|
+
const fetchedMobileNumber = ((_connection = connection) === null || _connection === void 0 ? void 0 : (_connection$connectio = _connection.connectionHolders) === null || _connection$connectio === void 0 ? void 0 : (_connection$connectio2 = _connection$connectio[0]) === null || _connection$connectio2 === void 0 ? void 0 : _connection$connectio2.mobileNumber) || ((_connection2 = connection) === null || _connection2 === void 0 ? void 0 : _connection2.mobileNumber);
|
|
34320
|
+
if (!fetchedMobileNumber || fetchedMobileNumber.length !== 10) {
|
|
34321
|
+
setIsLoading(false);
|
|
34322
|
+
setShowToast({
|
|
34323
|
+
key: "error",
|
|
34324
|
+
message: "No valid registered mobile number found for this connection"
|
|
34325
|
+
});
|
|
34326
|
+
return;
|
|
34327
|
+
}
|
|
34328
|
+
const userType = Digit.UserService.getType().toUpperCase();
|
|
34329
|
+
const payload = {
|
|
34330
|
+
otp: {
|
|
34331
|
+
mobileNumber: fetchedMobileNumber,
|
|
34332
|
+
tenantId: "dl",
|
|
34333
|
+
type: "register",
|
|
34334
|
+
userType: Digit.UserService.getType().toUpperCase()
|
|
34335
|
+
}
|
|
34336
|
+
};
|
|
34337
|
+
return Promise.resolve(Digit.UserService.sendOtp(payload, "dl")).then(function () {
|
|
34338
|
+
var _connection3, _connection4, _connection4$service, _connection5, _connection5$connecti, _connection6, _connection6$applicat, _connection7, _connection7$connecti, _connection8;
|
|
34339
|
+
const existingData = Digit.SessionStorage.get("WS_DISCONNECTION") || {};
|
|
34340
|
+
const isWaterConn = detectedServiceType === "WATER" || ((_connection3 = connection) === null || _connection3 === void 0 ? void 0 : _connection3.water) === true || ((_connection4 = connection) === null || _connection4 === void 0 ? void 0 : (_connection4$service = _connection4.service) === null || _connection4$service === void 0 ? void 0 : _connection4$service.toLowerCase()) === "water" || ((_connection5 = connection) === null || _connection5 === void 0 ? void 0 : (_connection5$connecti = _connection5.connectionNo) === null || _connection5$connecti === void 0 ? void 0 : _connection5$connecti.includes("WS")) || ((_connection6 = connection) === null || _connection6 === void 0 ? void 0 : (_connection6$applicat = _connection6.applicationNo) === null || _connection6$applicat === void 0 ? void 0 : _connection6$applicat.includes("WS")) || !((_connection7 = connection) !== null && _connection7 !== void 0 && (_connection7$connecti = _connection7.connectionNo) !== null && _connection7$connecti !== void 0 && _connection7$connecti.includes("SW"));
|
|
34341
|
+
const finalServiceType = isWaterConn ? "WATER" : "SEWERAGE";
|
|
34342
|
+
connection.serviceType = finalServiceType;
|
|
34343
|
+
Digit.SessionStorage.set("WS_DISCONNECTION", {
|
|
34344
|
+
...existingData,
|
|
34345
|
+
kNumber: trimmed,
|
|
34346
|
+
serviceType: finalServiceType,
|
|
34347
|
+
applicationData: connection,
|
|
34348
|
+
connectionNo: (_connection8 = connection) === null || _connection8 === void 0 ? void 0 : _connection8.connectionNo
|
|
34349
|
+
});
|
|
34350
|
+
setIsLoading(false);
|
|
34351
|
+
history.push(match.path.replace("k-number", "consumer-details"), {
|
|
34352
|
+
connection
|
|
34353
|
+
});
|
|
34354
|
+
});
|
|
34355
|
+
}
|
|
34356
|
+
if (!connection) {
|
|
33975
34357
|
setIsLoading(false);
|
|
33976
34358
|
setShowToast({
|
|
33977
34359
|
key: "error",
|
|
33978
|
-
message: "
|
|
34360
|
+
message: isReconnection ? "Disconnected connection not found for the given K Number" : "Active connection not found for the given K Number"
|
|
33979
34361
|
});
|
|
33980
34362
|
return;
|
|
33981
34363
|
}
|
|
33982
|
-
const
|
|
33983
|
-
|
|
33984
|
-
|
|
33985
|
-
|
|
33986
|
-
|
|
33987
|
-
|
|
33988
|
-
|
|
33989
|
-
|
|
33990
|
-
};
|
|
33991
|
-
return Promise.resolve(Digit.UserService.sendOtp(payload, "dl")).then(function () {
|
|
33992
|
-
var _connection3;
|
|
33993
|
-
const existingData = Digit.SessionStorage.get("WS_DISCONNECTION") || {};
|
|
33994
|
-
connection.serviceType = detectedServiceType;
|
|
33995
|
-
Digit.SessionStorage.set("WS_DISCONNECTION", {
|
|
33996
|
-
...existingData,
|
|
33997
|
-
kNumber: trimmed,
|
|
33998
|
-
serviceType: detectedServiceType,
|
|
33999
|
-
applicationData: connection,
|
|
34000
|
-
connectionNo: (_connection3 = connection) === null || _connection3 === void 0 ? void 0 : _connection3.connectionNo
|
|
34001
|
-
});
|
|
34002
|
-
setIsLoading(false);
|
|
34003
|
-
history.push(match.path.replace("k-number", "consumer-details"), {
|
|
34004
|
-
connection
|
|
34005
|
-
});
|
|
34006
|
-
});
|
|
34007
|
-
}
|
|
34008
|
-
if (!connection) {
|
|
34009
|
-
setIsLoading(false);
|
|
34010
|
-
setShowToast({
|
|
34011
|
-
key: "error",
|
|
34012
|
-
message: isReconnection ? "Disconnected connection not found for the given K Number" : "Active connection not found for the given K Number"
|
|
34013
|
-
});
|
|
34014
|
-
return;
|
|
34364
|
+
const _connection$propertyI = (_connection9 = connection) === null || _connection9 === void 0 ? void 0 : _connection9.propertyId;
|
|
34365
|
+
return _connection$propertyI ? Promise.resolve(Digit.PTService.search({
|
|
34366
|
+
tenantId: ((_connection0 = connection) === null || _connection0 === void 0 ? void 0 : _connection0.tenantId) || tenantId,
|
|
34367
|
+
filters: {
|
|
34368
|
+
propertyIds: connection.propertyId
|
|
34369
|
+
},
|
|
34370
|
+
auth: true
|
|
34371
|
+
}).catch(() => null)).then(_temp) : _temp(null);
|
|
34015
34372
|
}
|
|
34016
|
-
const
|
|
34017
|
-
|
|
34018
|
-
|
|
34019
|
-
|
|
34020
|
-
|
|
34021
|
-
|
|
34022
|
-
|
|
34023
|
-
|
|
34373
|
+
const _temp2 = function () {
|
|
34374
|
+
if (!connection) {
|
|
34375
|
+
return Promise.resolve(Digit.WSService.search({
|
|
34376
|
+
tenantId,
|
|
34377
|
+
filters: params,
|
|
34378
|
+
businessService: "SW"
|
|
34379
|
+
}).catch(() => null)).then(function (swResponse) {
|
|
34380
|
+
var _sewerageResponse$Sew, _sewerageResponse$Sew2;
|
|
34381
|
+
const sewerageResponse = (swResponse === null || swResponse === void 0 ? void 0 : swResponse.data) || swResponse;
|
|
34382
|
+
connection = (sewerageResponse === null || sewerageResponse === void 0 ? void 0 : (_sewerageResponse$Sew = sewerageResponse.SewerageConnections) === null || _sewerageResponse$Sew === void 0 ? void 0 : _sewerageResponse$Sew.find(isEligibleConnection)) || (!isReconnection ? sewerageResponse === null || sewerageResponse === void 0 ? void 0 : (_sewerageResponse$Sew2 = sewerageResponse.SewerageConnections) === null || _sewerageResponse$Sew2 === void 0 ? void 0 : _sewerageResponse$Sew2[0] : null);
|
|
34383
|
+
if (connection) {
|
|
34384
|
+
var _connection1, _connection1$connecti, _connection10;
|
|
34385
|
+
detectedServiceType = (_connection1 = connection) !== null && _connection1 !== void 0 && (_connection1$connecti = _connection1.connectionNo) !== null && _connection1$connecti !== void 0 && _connection1$connecti.includes("WS") || ((_connection10 = connection) === null || _connection10 === void 0 ? void 0 : _connection10.water) === true ? "WATER" : "SEWERAGE";
|
|
34386
|
+
}
|
|
34387
|
+
});
|
|
34388
|
+
}
|
|
34389
|
+
}();
|
|
34390
|
+
return _temp2 && _temp2.then ? _temp2.then(_temp3) : _temp3(_temp2);
|
|
34024
34391
|
}
|
|
34025
|
-
|
|
34026
|
-
let connection = (waterResponse === null ||
|
|
34027
|
-
const
|
|
34028
|
-
if (!connection) {
|
|
34392
|
+
let waterResponse = ((_wsResponse = wsResponse) === null || _wsResponse === void 0 ? void 0 : _wsResponse.data) || wsResponse;
|
|
34393
|
+
let connection = ((_waterResponse = waterResponse) === null || _waterResponse === void 0 ? void 0 : (_waterResponse$WaterC = _waterResponse.WaterConnection) === null || _waterResponse$WaterC === void 0 ? void 0 : _waterResponse$WaterC.find(isEligibleConnection)) || (!isReconnection ? (_waterResponse2 = waterResponse) === null || _waterResponse2 === void 0 ? void 0 : (_waterResponse2$Water = _waterResponse2.WaterConnection) === null || _waterResponse2$Water === void 0 ? void 0 : _waterResponse2$Water[0] : null);
|
|
34394
|
+
const _temp4 = function () {
|
|
34395
|
+
if (!connection && tenantId !== "dl") {
|
|
34029
34396
|
return Promise.resolve(Digit.WSService.search({
|
|
34030
|
-
tenantId,
|
|
34397
|
+
tenantId: "dl",
|
|
34031
34398
|
filters: params,
|
|
34032
|
-
businessService: "
|
|
34033
|
-
}).catch(() => null)).then(function (
|
|
34034
|
-
var
|
|
34035
|
-
|
|
34036
|
-
|
|
34037
|
-
|
|
34399
|
+
businessService: "WS"
|
|
34400
|
+
}).catch(() => null)).then(function (_Digit$WSService$sear) {
|
|
34401
|
+
var _wsResponse2, _waterResponse3, _waterResponse3$Water, _waterResponse4, _waterResponse4$Water;
|
|
34402
|
+
wsResponse = _Digit$WSService$sear;
|
|
34403
|
+
waterResponse = ((_wsResponse2 = wsResponse) === null || _wsResponse2 === void 0 ? void 0 : _wsResponse2.data) || wsResponse;
|
|
34404
|
+
connection = ((_waterResponse3 = waterResponse) === null || _waterResponse3 === void 0 ? void 0 : (_waterResponse3$Water = _waterResponse3.WaterConnection) === null || _waterResponse3$Water === void 0 ? void 0 : _waterResponse3$Water.find(isEligibleConnection)) || (!isReconnection ? (_waterResponse4 = waterResponse) === null || _waterResponse4 === void 0 ? void 0 : (_waterResponse4$Water = _waterResponse4.WaterConnection) === null || _waterResponse4$Water === void 0 ? void 0 : _waterResponse4$Water[0] : null);
|
|
34038
34405
|
});
|
|
34039
34406
|
}
|
|
34040
34407
|
}();
|
|
34041
|
-
return
|
|
34408
|
+
return _temp4 && _temp4.then ? _temp4.then(_temp5) : _temp5(_temp4);
|
|
34042
34409
|
});
|
|
34043
34410
|
}, function (err) {
|
|
34044
34411
|
var _err$response, _err$response$data, _err$response$data$Er, _err$response$data$Er2;
|
|
@@ -34240,12 +34607,14 @@ const WSDisconnectionConsumerDetails = _ref => {
|
|
|
34240
34607
|
}
|
|
34241
34608
|
};
|
|
34242
34609
|
return Promise.resolve(Digit.UserService.validateOtp(payload)).then(function () {
|
|
34243
|
-
var _connection$additiona2, _connection$additiona3;
|
|
34610
|
+
var _connection$service, _connection$connectio2, _connection$applicati, _connection$connectio3, _connection$additiona2, _connection$additiona3;
|
|
34611
|
+
const isWaterConn = (connection === null || connection === void 0 ? void 0 : connection.water) === true || (connection === null || connection === void 0 ? void 0 : (_connection$service = connection.service) === null || _connection$service === void 0 ? void 0 : _connection$service.toLowerCase()) === "water" || (connection === null || connection === void 0 ? void 0 : (_connection$connectio2 = connection.connectionNo) === null || _connection$connectio2 === void 0 ? void 0 : _connection$connectio2.includes("WS")) || (connection === null || connection === void 0 ? void 0 : (_connection$applicati = connection.applicationNo) === null || _connection$applicati === void 0 ? void 0 : _connection$applicati.includes("WS")) || (applicationData === null || applicationData === void 0 ? void 0 : applicationData.serviceType) === "WATER" || !(connection !== null && connection !== void 0 && (_connection$connectio3 = connection.connectionNo) !== null && _connection$connectio3 !== void 0 && _connection$connectio3.includes("SW"));
|
|
34612
|
+
const finalServiceType = isWaterConn ? "WATER" : (connection === null || connection === void 0 ? void 0 : (_connection$additiona2 = connection.additionalDetails) === null || _connection$additiona2 === void 0 ? void 0 : (_connection$additiona3 = _connection$additiona2.serviceType) === null || _connection$additiona3 === void 0 ? void 0 : _connection$additiona3.code) || (applicationData === null || applicationData === void 0 ? void 0 : applicationData.serviceType) || "WATER";
|
|
34244
34613
|
Digit.SessionStorage.set("WS_DISCONNECTION", {
|
|
34245
34614
|
...applicationData,
|
|
34246
34615
|
applicationData: connection,
|
|
34247
34616
|
connectionNo: connection === null || connection === void 0 ? void 0 : connection.connectionNo,
|
|
34248
|
-
serviceType:
|
|
34617
|
+
serviceType: finalServiceType
|
|
34249
34618
|
});
|
|
34250
34619
|
setIsLoading(false);
|
|
34251
34620
|
history.push(match.path.replace("consumer-details", isReconnection ? "new-restoration" : "application-form"), {
|
|
@@ -36078,7 +36447,7 @@ const DISCONNECTION_REASONS = {
|
|
|
36078
36447
|
}]
|
|
36079
36448
|
};
|
|
36080
36449
|
const WSDisconnectionForm = _ref => {
|
|
36081
|
-
var _location$state, _applicationData$appl, _applicationData$appl2, _applicationData$appl3, _applicationData$appl4, _applicationData$appl5, _applicationData$appl6, _disconnectionData$ty10, _disconnectionData$ty11, _disconnectionData$ty12, _disconnectionData$ty13, _disconnectionData$ty14, _disconnectionData$ty15, _disconnectionData$ty16, _disconnectionData$ty17, _disconnectionData$ty18, _disconnectionData$re4, _disconnectionData$re5, _disconnectionData$re6;
|
|
36450
|
+
var _location$state, _applicationData$appl, _applicationData$appl2, _applicationData$appl3, _applicationData$appl4, _applicationData$appl5, _applicationData$appl6, _applicationData$appl7, _applicationData$appl8, _applicationData$appl9, _applicationData$appl0, _disconnectionData$ty10, _disconnectionData$ty11, _disconnectionData$ty12, _disconnectionData$ty13, _disconnectionData$ty14, _disconnectionData$ty15, _disconnectionData$ty16, _disconnectionData$ty17, _disconnectionData$ty18, _disconnectionData$re4, _disconnectionData$re5, _disconnectionData$re6;
|
|
36082
36451
|
let {
|
|
36083
36452
|
t,
|
|
36084
36453
|
config,
|
|
@@ -36094,7 +36463,8 @@ const WSDisconnectionForm = _ref => {
|
|
|
36094
36463
|
...storedApplicationData,
|
|
36095
36464
|
applicationData: ((_location$state = location.state) === null || _location$state === void 0 ? void 0 : _location$state.connection) || storedApplicationData.applicationData || {}
|
|
36096
36465
|
};
|
|
36097
|
-
const
|
|
36466
|
+
const isWaterConn = (applicationData === null || applicationData === void 0 ? void 0 : applicationData.serviceType) === "WATER" || (applicationData === null || applicationData === void 0 ? void 0 : applicationData.serviceType) === "WS" || (applicationData === null || applicationData === void 0 ? void 0 : (_applicationData$appl = applicationData.applicationData) === null || _applicationData$appl === void 0 ? void 0 : _applicationData$appl.water) === true || (applicationData === null || applicationData === void 0 ? void 0 : (_applicationData$appl2 = applicationData.applicationData) === null || _applicationData$appl2 === void 0 ? void 0 : (_applicationData$appl3 = _applicationData$appl2.service) === null || _applicationData$appl3 === void 0 ? void 0 : _applicationData$appl3.toLowerCase()) === "water" || (applicationData === null || applicationData === void 0 ? void 0 : (_applicationData$appl4 = applicationData.applicationData) === null || _applicationData$appl4 === void 0 ? void 0 : (_applicationData$appl5 = _applicationData$appl4.connectionNo) === null || _applicationData$appl5 === void 0 ? void 0 : _applicationData$appl5.includes("WS")) || (applicationData === null || applicationData === void 0 ? void 0 : (_applicationData$appl6 = applicationData.applicationData) === null || _applicationData$appl6 === void 0 ? void 0 : (_applicationData$appl7 = _applicationData$appl6.applicationNo) === null || _applicationData$appl7 === void 0 ? void 0 : _applicationData$appl7.includes("WS")) || !(applicationData !== null && applicationData !== void 0 && (_applicationData$appl8 = applicationData.applicationData) !== null && _applicationData$appl8 !== void 0 && (_applicationData$appl9 = _applicationData$appl8.connectionNo) !== null && _applicationData$appl9 !== void 0 && _applicationData$appl9.includes("SW"));
|
|
36467
|
+
const serviceType = isWaterConn ? "WATER" : "SEWERAGE";
|
|
36098
36468
|
const history = reactRouterDom.useHistory();
|
|
36099
36469
|
const match = reactRouterDom.useRouteMatch();
|
|
36100
36470
|
const [disconnectionData, setDisconnectionData] = React.useState(() => {
|
|
@@ -36578,7 +36948,7 @@ const WSDisconnectionForm = _ref => {
|
|
|
36578
36948
|
}, t("CS_TITLE_APPLICATION_DETAILS"))), /*#__PURE__*/React__default.createElement(digitUiReactComponents.StatusTable, null, /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
|
|
36579
36949
|
key: t("PDF_STATIC_LABEL_CONSUMER_NUMBER_LABEL"),
|
|
36580
36950
|
label: t("PDF_STATIC_LABEL_CONSUMER_NUMBER_LABEL"),
|
|
36581
|
-
text: applicationData === null || applicationData === void 0 ? void 0 : (_applicationData$
|
|
36951
|
+
text: applicationData === null || applicationData === void 0 ? void 0 : (_applicationData$appl0 = applicationData.applicationData) === null || _applicationData$appl0 === void 0 ? void 0 : _applicationData$appl0.connectionNo,
|
|
36582
36952
|
className: "border-none"
|
|
36583
36953
|
}))), /*#__PURE__*/React__default.createElement("div", {
|
|
36584
36954
|
style: sectionStyle
|
|
@@ -39908,7 +40278,7 @@ const WSDivyangjan = _ref => {
|
|
|
39908
40278
|
};
|
|
39909
40279
|
|
|
39910
40280
|
const WSRainWaterHarvesting = _ref => {
|
|
39911
|
-
var _formData$
|
|
40281
|
+
var _formData$additionalD, _formData$configKey2;
|
|
39912
40282
|
let {
|
|
39913
40283
|
config,
|
|
39914
40284
|
onSelect,
|
|
@@ -39918,17 +40288,36 @@ const WSRainWaterHarvesting = _ref => {
|
|
|
39918
40288
|
const {
|
|
39919
40289
|
t
|
|
39920
40290
|
} = reactI18next.useTranslation();
|
|
40291
|
+
const getInitialValue = () => {
|
|
40292
|
+
const configKey = (config === null || config === void 0 ? void 0 : config.key) || "rainWaterHarvesting";
|
|
40293
|
+
const rwh = formData === null || formData === void 0 ? void 0 : formData[configKey];
|
|
40294
|
+
const add = formData === null || formData === void 0 ? void 0 : formData.additionalDetails;
|
|
40295
|
+
if ((rwh === null || rwh === void 0 ? void 0 : rwh.hasCertificate) !== undefined) {
|
|
40296
|
+
return String(rwh.hasCertificate) === "true" || rwh.hasCertificate === true;
|
|
40297
|
+
}
|
|
40298
|
+
if ((rwh === null || rwh === void 0 ? void 0 : rwh.isRainwaterHarvesting) !== undefined) {
|
|
40299
|
+
return String(rwh.isRainwaterHarvesting) === "true" || rwh.isRainwaterHarvesting === true;
|
|
40300
|
+
}
|
|
40301
|
+
if ((add === null || add === void 0 ? void 0 : add.hasRainWaterHarvestingCertificate) !== undefined) {
|
|
40302
|
+
return String(add.hasRainWaterHarvestingCertificate) === "true" || add.hasRainWaterHarvestingCertificate === true;
|
|
40303
|
+
}
|
|
40304
|
+
if ((add === null || add === void 0 ? void 0 : add.isRainwaterHarvesting) !== undefined) {
|
|
40305
|
+
return String(add.isRainwaterHarvesting) === "true" || add.isRainwaterHarvesting === true;
|
|
40306
|
+
}
|
|
40307
|
+
return false;
|
|
40308
|
+
};
|
|
39921
40309
|
const {
|
|
39922
40310
|
control,
|
|
39923
|
-
watch
|
|
40311
|
+
watch,
|
|
40312
|
+
setValue
|
|
39924
40313
|
} = reactHookForm.useForm({
|
|
39925
40314
|
defaultValues: {
|
|
39926
|
-
hasCertificate:
|
|
40315
|
+
hasCertificate: getInitialValue()
|
|
39927
40316
|
}
|
|
39928
40317
|
});
|
|
39929
40318
|
const formValue = watch();
|
|
39930
40319
|
const onSelectRef = React.useRef(onSelect);
|
|
39931
|
-
const goNext = () => onSelect(config.key, {
|
|
40320
|
+
const goNext = () => onSelect((config === null || config === void 0 ? void 0 : config.key) || "rainWaterHarvesting", {
|
|
39932
40321
|
hasCertificate: !!formValue.hasCertificate,
|
|
39933
40322
|
isRainwaterHarvesting: !!formValue.hasCertificate
|
|
39934
40323
|
});
|
|
@@ -39936,33 +40325,193 @@ const WSRainWaterHarvesting = _ref => {
|
|
|
39936
40325
|
React.useEffect(() => {
|
|
39937
40326
|
onSelectRef.current = onSelect;
|
|
39938
40327
|
}, [onSelect]);
|
|
40328
|
+
const configKey = (config === null || config === void 0 ? void 0 : config.key) || "rainWaterHarvesting";
|
|
40329
|
+
const hasData = !!((formData === null || formData === void 0 ? void 0 : formData[configKey]) !== undefined || (formData === null || formData === void 0 ? void 0 : (_formData$additionalD = formData.additionalDetails) === null || _formData$additionalD === void 0 ? void 0 : _formData$additionalD.hasRainWaterHarvestingCertificate) !== undefined);
|
|
40330
|
+
const isInitializedRef = React.useRef(hasData);
|
|
39939
40331
|
React.useEffect(() => {
|
|
39940
|
-
|
|
39941
|
-
|
|
39942
|
-
|
|
40332
|
+
var _formData$additionalD2;
|
|
40333
|
+
if (!isInitializedRef.current && ((formData === null || formData === void 0 ? void 0 : formData[configKey]) !== undefined || (formData === null || formData === void 0 ? void 0 : (_formData$additionalD2 = formData.additionalDetails) === null || _formData$additionalD2 === void 0 ? void 0 : _formData$additionalD2.hasRainWaterHarvestingCertificate) !== undefined)) {
|
|
40334
|
+
setValue("hasCertificate", getInitialValue());
|
|
40335
|
+
isInitializedRef.current = true;
|
|
40336
|
+
}
|
|
40337
|
+
}, [formData === null || formData === void 0 ? void 0 : formData[configKey], formData === null || formData === void 0 ? void 0 : formData.additionalDetails]);
|
|
40338
|
+
React.useEffect(() => {
|
|
40339
|
+
const isEmployeeMode = userType === "employee" || window.location.href.includes("edit-application") || window.location.href.includes("modify-connection") || window.location.href.includes("old-application");
|
|
40340
|
+
if (isEmployeeMode) {
|
|
40341
|
+
var _formData$configKey;
|
|
40342
|
+
const currentVal = formData === null || formData === void 0 ? void 0 : (_formData$configKey = formData[configKey]) === null || _formData$configKey === void 0 ? void 0 : _formData$configKey.hasCertificate;
|
|
39943
40343
|
const newVal = !!formValue.hasCertificate;
|
|
39944
40344
|
if (currentVal !== newVal) {
|
|
39945
|
-
onSelectRef.current(
|
|
40345
|
+
onSelectRef.current(configKey, {
|
|
39946
40346
|
hasCertificate: newVal,
|
|
39947
40347
|
isRainwaterHarvesting: newVal
|
|
39948
40348
|
});
|
|
39949
40349
|
}
|
|
39950
40350
|
}
|
|
39951
|
-
}, [
|
|
40351
|
+
}, [configKey, formValue.hasCertificate, userType, formData === null || formData === void 0 ? void 0 : (_formData$configKey2 = formData[configKey]) === null || _formData$configKey2 === void 0 ? void 0 : _formData$configKey2.hasCertificate]);
|
|
39952
40352
|
const content = /*#__PURE__*/React__default.createElement(digitUiReactComponents.CollapsibleCardPage, {
|
|
39953
40353
|
title: t("Rain Water Harvesting Certificate"),
|
|
39954
40354
|
defaultOpen: true
|
|
39955
40355
|
}, /*#__PURE__*/React__default.createElement("div", {
|
|
39956
40356
|
className: "formcomposer-section-grid"
|
|
39957
|
-
}, /*#__PURE__*/React__default.createElement(digitUiReactComponents.LabelFieldPair, null, /*#__PURE__*/React__default.createElement("div", {
|
|
40357
|
+
}, /*#__PURE__*/React__default.createElement(digitUiReactComponents.LabelFieldPair, null, /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardLabel, null, t("Rain Water Harvesting Certificate")), /*#__PURE__*/React__default.createElement("div", {
|
|
39958
40358
|
className: "field"
|
|
39959
40359
|
}, /*#__PURE__*/React__default.createElement(reactHookForm.Controller, {
|
|
39960
40360
|
control: control,
|
|
39961
40361
|
name: "hasCertificate",
|
|
39962
|
-
render: props => /*#__PURE__*/React__default.createElement(digitUiReactComponents.
|
|
39963
|
-
|
|
39964
|
-
|
|
39965
|
-
|
|
40362
|
+
render: props => /*#__PURE__*/React__default.createElement(digitUiReactComponents.RadioButtons, {
|
|
40363
|
+
className: "form-field",
|
|
40364
|
+
style: {
|
|
40365
|
+
display: "flex",
|
|
40366
|
+
gap: "2rem",
|
|
40367
|
+
alignItems: "center"
|
|
40368
|
+
},
|
|
40369
|
+
name: "hasRainWaterHarvestingCertificateRadio",
|
|
40370
|
+
options: [{
|
|
40371
|
+
i18nKey: "CORE_COMMON_YES",
|
|
40372
|
+
code: true
|
|
40373
|
+
}, {
|
|
40374
|
+
i18nKey: "CORE_COMMON_NO",
|
|
40375
|
+
code: false
|
|
40376
|
+
}],
|
|
40377
|
+
optionsKey: "i18nKey",
|
|
40378
|
+
selectedOption: props.value ? {
|
|
40379
|
+
i18nKey: "CORE_COMMON_YES",
|
|
40380
|
+
code: true
|
|
40381
|
+
} : {
|
|
40382
|
+
i18nKey: "CORE_COMMON_NO",
|
|
40383
|
+
code: false
|
|
40384
|
+
},
|
|
40385
|
+
onSelect: e => props.onChange(e.code),
|
|
40386
|
+
t: t
|
|
40387
|
+
})
|
|
40388
|
+
})))));
|
|
40389
|
+
return userType === "citizen" ? /*#__PURE__*/React__default.createElement(digitUiReactComponents.FormStep, {
|
|
40390
|
+
t: t,
|
|
40391
|
+
config: config,
|
|
40392
|
+
onSelect: goNext,
|
|
40393
|
+
onSkip: onSkip
|
|
40394
|
+
}, content) : content;
|
|
40395
|
+
};
|
|
40396
|
+
|
|
40397
|
+
const WSSewerTreatmentPlant = _ref => {
|
|
40398
|
+
var _formData$additionalD, _formData$additionalD2, _formData$configKey3, _formData$configKey4;
|
|
40399
|
+
let {
|
|
40400
|
+
config,
|
|
40401
|
+
onSelect,
|
|
40402
|
+
userType,
|
|
40403
|
+
formData
|
|
40404
|
+
} = _ref;
|
|
40405
|
+
const {
|
|
40406
|
+
t
|
|
40407
|
+
} = reactI18next.useTranslation();
|
|
40408
|
+
const getInitialValue = () => {
|
|
40409
|
+
const configKey = (config === null || config === void 0 ? void 0 : config.key) || "sewerTreatmentPlant";
|
|
40410
|
+
const stp = (formData === null || formData === void 0 ? void 0 : formData[configKey]) || (formData === null || formData === void 0 ? void 0 : formData.sewageTreatmentPlant);
|
|
40411
|
+
const add = formData === null || formData === void 0 ? void 0 : formData.additionalDetails;
|
|
40412
|
+
if ((stp === null || stp === void 0 ? void 0 : stp.hasCertificate) !== undefined) {
|
|
40413
|
+
return String(stp.hasCertificate) === "true" || stp.hasCertificate === true;
|
|
40414
|
+
}
|
|
40415
|
+
if ((stp === null || stp === void 0 ? void 0 : stp.hasStp) !== undefined) {
|
|
40416
|
+
return String(stp.hasStp) === "true" || stp.hasStp === true;
|
|
40417
|
+
}
|
|
40418
|
+
if ((stp === null || stp === void 0 ? void 0 : stp.isSewerTreatmentPlant) !== undefined) {
|
|
40419
|
+
return String(stp.isSewerTreatmentPlant) === "true" || stp.isSewerTreatmentPlant === true;
|
|
40420
|
+
}
|
|
40421
|
+
if ((add === null || add === void 0 ? void 0 : add.hasSewerTreatmentPlant) !== undefined) {
|
|
40422
|
+
return String(add.hasSewerTreatmentPlant) === "true" || add.hasSewerTreatmentPlant === true;
|
|
40423
|
+
}
|
|
40424
|
+
if ((add === null || add === void 0 ? void 0 : add.hasSewageTreatmentPlant) !== undefined) {
|
|
40425
|
+
return String(add.hasSewageTreatmentPlant) === "true" || add.hasSewageTreatmentPlant === true;
|
|
40426
|
+
}
|
|
40427
|
+
if ((add === null || add === void 0 ? void 0 : add.hasStp) !== undefined) {
|
|
40428
|
+
return String(add.hasStp) === "true" || add.hasStp === true;
|
|
40429
|
+
}
|
|
40430
|
+
if ((add === null || add === void 0 ? void 0 : add.isSewerTreatmentPlant) !== undefined) {
|
|
40431
|
+
return String(add.isSewerTreatmentPlant) === "true" || add.isSewerTreatmentPlant === true;
|
|
40432
|
+
}
|
|
40433
|
+
return false;
|
|
40434
|
+
};
|
|
40435
|
+
const {
|
|
40436
|
+
control,
|
|
40437
|
+
watch,
|
|
40438
|
+
setValue
|
|
40439
|
+
} = reactHookForm.useForm({
|
|
40440
|
+
defaultValues: {
|
|
40441
|
+
hasCertificate: getInitialValue()
|
|
40442
|
+
}
|
|
40443
|
+
});
|
|
40444
|
+
const formValue = watch();
|
|
40445
|
+
const onSelectRef = React.useRef(onSelect);
|
|
40446
|
+
const goNext = () => onSelect((config === null || config === void 0 ? void 0 : config.key) || "sewerTreatmentPlant", {
|
|
40447
|
+
hasCertificate: !!formValue.hasCertificate,
|
|
40448
|
+
hasStp: !!formValue.hasCertificate,
|
|
40449
|
+
isSewerTreatmentPlant: !!formValue.hasCertificate
|
|
40450
|
+
});
|
|
40451
|
+
const onSkip = () => onSelect();
|
|
40452
|
+
React.useEffect(() => {
|
|
40453
|
+
onSelectRef.current = onSelect;
|
|
40454
|
+
}, [onSelect]);
|
|
40455
|
+
const configKey = (config === null || config === void 0 ? void 0 : config.key) || "sewerTreatmentPlant";
|
|
40456
|
+
const hasData = !!((formData === null || formData === void 0 ? void 0 : formData[configKey]) !== undefined || (formData === null || formData === void 0 ? void 0 : formData.sewageTreatmentPlant) !== undefined || (formData === null || formData === void 0 ? void 0 : (_formData$additionalD = formData.additionalDetails) === null || _formData$additionalD === void 0 ? void 0 : _formData$additionalD.hasSewerTreatmentPlant) !== undefined || (formData === null || formData === void 0 ? void 0 : (_formData$additionalD2 = formData.additionalDetails) === null || _formData$additionalD2 === void 0 ? void 0 : _formData$additionalD2.hasStp) !== undefined);
|
|
40457
|
+
const isInitializedRef = React.useRef(hasData);
|
|
40458
|
+
React.useEffect(() => {
|
|
40459
|
+
var _formData$additionalD3, _formData$additionalD4;
|
|
40460
|
+
if (!isInitializedRef.current && ((formData === null || formData === void 0 ? void 0 : formData[configKey]) !== undefined || (formData === null || formData === void 0 ? void 0 : formData.sewageTreatmentPlant) !== undefined || (formData === null || formData === void 0 ? void 0 : (_formData$additionalD3 = formData.additionalDetails) === null || _formData$additionalD3 === void 0 ? void 0 : _formData$additionalD3.hasSewerTreatmentPlant) !== undefined || (formData === null || formData === void 0 ? void 0 : (_formData$additionalD4 = formData.additionalDetails) === null || _formData$additionalD4 === void 0 ? void 0 : _formData$additionalD4.hasStp) !== undefined)) {
|
|
40461
|
+
setValue("hasCertificate", getInitialValue());
|
|
40462
|
+
isInitializedRef.current = true;
|
|
40463
|
+
}
|
|
40464
|
+
}, [formData === null || formData === void 0 ? void 0 : formData[configKey], formData === null || formData === void 0 ? void 0 : formData.sewageTreatmentPlant, formData === null || formData === void 0 ? void 0 : formData.additionalDetails]);
|
|
40465
|
+
React.useEffect(() => {
|
|
40466
|
+
const isEmployeeMode = userType === "employee" || window.location.href.includes("edit-application") || window.location.href.includes("modify-connection") || window.location.href.includes("old-application");
|
|
40467
|
+
if (isEmployeeMode) {
|
|
40468
|
+
var _formData$configKey, _formData$configKey2;
|
|
40469
|
+
const currentVal = (formData === null || formData === void 0 ? void 0 : (_formData$configKey = formData[configKey]) === null || _formData$configKey === void 0 ? void 0 : _formData$configKey.hasCertificate) ?? (formData === null || formData === void 0 ? void 0 : (_formData$configKey2 = formData[configKey]) === null || _formData$configKey2 === void 0 ? void 0 : _formData$configKey2.hasStp);
|
|
40470
|
+
const newVal = !!formValue.hasCertificate;
|
|
40471
|
+
if (currentVal !== newVal) {
|
|
40472
|
+
onSelectRef.current(configKey, {
|
|
40473
|
+
hasCertificate: newVal,
|
|
40474
|
+
hasStp: newVal,
|
|
40475
|
+
isSewerTreatmentPlant: newVal
|
|
40476
|
+
});
|
|
40477
|
+
}
|
|
40478
|
+
}
|
|
40479
|
+
}, [configKey, formValue.hasCertificate, userType, formData === null || formData === void 0 ? void 0 : (_formData$configKey3 = formData[configKey]) === null || _formData$configKey3 === void 0 ? void 0 : _formData$configKey3.hasCertificate, formData === null || formData === void 0 ? void 0 : (_formData$configKey4 = formData[configKey]) === null || _formData$configKey4 === void 0 ? void 0 : _formData$configKey4.hasStp]);
|
|
40480
|
+
const content = /*#__PURE__*/React__default.createElement(digitUiReactComponents.CollapsibleCardPage, {
|
|
40481
|
+
title: t("Sewer Treatment Plant (STP)"),
|
|
40482
|
+
defaultOpen: true
|
|
40483
|
+
}, /*#__PURE__*/React__default.createElement("div", {
|
|
40484
|
+
className: "formcomposer-section-grid"
|
|
40485
|
+
}, /*#__PURE__*/React__default.createElement(digitUiReactComponents.LabelFieldPair, null, /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardLabel, null, t("Sewer Treatment Plant (STP)")), /*#__PURE__*/React__default.createElement("div", {
|
|
40486
|
+
className: "field"
|
|
40487
|
+
}, /*#__PURE__*/React__default.createElement(reactHookForm.Controller, {
|
|
40488
|
+
control: control,
|
|
40489
|
+
name: "hasCertificate",
|
|
40490
|
+
render: props => /*#__PURE__*/React__default.createElement(digitUiReactComponents.RadioButtons, {
|
|
40491
|
+
className: "form-field",
|
|
40492
|
+
style: {
|
|
40493
|
+
display: "flex",
|
|
40494
|
+
gap: "2rem",
|
|
40495
|
+
alignItems: "center"
|
|
40496
|
+
},
|
|
40497
|
+
name: "hasSewerTreatmentPlantRadio",
|
|
40498
|
+
options: [{
|
|
40499
|
+
i18nKey: "CORE_COMMON_YES",
|
|
40500
|
+
code: true
|
|
40501
|
+
}, {
|
|
40502
|
+
i18nKey: "CORE_COMMON_NO",
|
|
40503
|
+
code: false
|
|
40504
|
+
}],
|
|
40505
|
+
optionsKey: "i18nKey",
|
|
40506
|
+
selectedOption: props.value ? {
|
|
40507
|
+
i18nKey: "CORE_COMMON_YES",
|
|
40508
|
+
code: true
|
|
40509
|
+
} : {
|
|
40510
|
+
i18nKey: "CORE_COMMON_NO",
|
|
40511
|
+
code: false
|
|
40512
|
+
},
|
|
40513
|
+
onSelect: e => props.onChange(e.code),
|
|
40514
|
+
t: t
|
|
39966
40515
|
})
|
|
39967
40516
|
})))));
|
|
39968
40517
|
return userType === "citizen" ? /*#__PURE__*/React__default.createElement(digitUiReactComponents.FormStep, {
|
|
@@ -44085,22 +44634,26 @@ const useInboxTableConfig$1 = _ref => {
|
|
|
44085
44634
|
Header: t("WS_MYCONNECTIONS_APPLICATION_NO"),
|
|
44086
44635
|
disableSortBy: true,
|
|
44087
44636
|
Cell: _ref3 => {
|
|
44088
|
-
var _row$original2;
|
|
44637
|
+
var _row$original2, _row$original2$servic, _row$original3, _row$original4;
|
|
44089
44638
|
let {
|
|
44090
44639
|
row
|
|
44091
44640
|
} = _ref3;
|
|
44641
|
+
const service = row !== null && row !== void 0 && (_row$original2 = row.original) !== null && _row$original2 !== void 0 && (_row$original2$servic = _row$original2.service) !== null && _row$original2$servic !== void 0 && _row$original2$servic.includes("SW") ? "SEWERAGE" : "WATER";
|
|
44642
|
+
const fromScreen = service === "WATER" ? "ES_COMMON_BILL_AMEND_WATER_INBOX_LABEL" : "ES_COMMON_BILL_AMEND_SEWERAGE_INBOX_LABEL";
|
|
44643
|
+
const applicationNo = row === null || row === void 0 ? void 0 : (_row$original3 = row.original) === null || _row$original3 === void 0 ? void 0 : _row$original3["applicationNo"];
|
|
44644
|
+
const linkUrl = `/digit-ui/employee/ws/generate-note-bill-amendment?applicationNumber=${applicationNo}&tenantId=${tenantId}&service=${service}&from=${fromScreen}`;
|
|
44092
44645
|
return /*#__PURE__*/React__default.createElement("div", {
|
|
44093
44646
|
style: {
|
|
44094
44647
|
display: "flex",
|
|
44095
44648
|
flexDirection: "column"
|
|
44096
44649
|
}
|
|
44097
44650
|
}, /*#__PURE__*/React__default.createElement(reactRouterDom.Link, {
|
|
44098
|
-
to:
|
|
44651
|
+
to: linkUrl
|
|
44099
44652
|
}, /*#__PURE__*/React__default.createElement("span", {
|
|
44100
44653
|
className: "link"
|
|
44101
|
-
},
|
|
44654
|
+
}, applicationNo)), GetCell(t(`BILLAMENDMENT_${row === null || row === void 0 ? void 0 : (_row$original4 = row.original) === null || _row$original4 === void 0 ? void 0 : _row$original4.amendmentReason}_HEADING`)));
|
|
44102
44655
|
}
|
|
44103
|
-
}
|
|
44656
|
+
}, {
|
|
44104
44657
|
Header: t("CORE_COMMON_NAME"),
|
|
44105
44658
|
disableSortBy: true,
|
|
44106
44659
|
accessor: "owner"
|
|
@@ -44196,14 +44749,17 @@ const useInboxMobileCardsData$1 = _ref => {
|
|
|
44196
44749
|
const GetCell = value => /*#__PURE__*/React__default.createElement("span", {
|
|
44197
44750
|
className: "cell-text styled-cell"
|
|
44198
44751
|
}, value);
|
|
44199
|
-
const getApplicationNumberCell = (value, amendmentReason) => {
|
|
44752
|
+
const getApplicationNumberCell = (value, amendmentReason, tenantId, service) => {
|
|
44753
|
+
const serviceType = service !== null && service !== void 0 && service.includes("SW") ? "SEWERAGE" : "WATER";
|
|
44754
|
+
const fromScreen = serviceType === "WATER" ? "ES_COMMON_BILL_AMEND_WATER_INBOX_LABEL" : "ES_COMMON_BILL_AMEND_SEWERAGE_INBOX_LABEL";
|
|
44755
|
+
const linkUrl = `/digit-ui/employee/ws/generate-note-bill-amendment?applicationNumber=${value}&tenantId=${tenantId}&service=${serviceType}&from=${fromScreen}`;
|
|
44200
44756
|
return /*#__PURE__*/React__default.createElement("div", {
|
|
44201
44757
|
style: {
|
|
44202
44758
|
display: "flex",
|
|
44203
44759
|
flexDirection: "column"
|
|
44204
44760
|
}
|
|
44205
44761
|
}, /*#__PURE__*/React__default.createElement(reactRouterDom.Link, {
|
|
44206
|
-
to:
|
|
44762
|
+
to: linkUrl
|
|
44207
44763
|
}, /*#__PURE__*/React__default.createElement("span", {
|
|
44208
44764
|
className: "link"
|
|
44209
44765
|
}, value)), GetCell(t(`BILLAMENDMENT_${amendmentReason}_HEADING`)));
|
|
@@ -44221,7 +44777,7 @@ const useInboxMobileCardsData$1 = _ref => {
|
|
|
44221
44777
|
} = _ref2;
|
|
44222
44778
|
return {
|
|
44223
44779
|
[t("WS_COMMON_TABLE_COL_SERVICE_LABEL")]: t(`ACTION_TEST_${service}`),
|
|
44224
|
-
[t("WS_MYCONNECTIONS_APPLICATION_NO")]: getApplicationNumberCell(applicationNo, amendmentReason),
|
|
44780
|
+
[t("WS_MYCONNECTIONS_APPLICATION_NO")]: getApplicationNumberCell(applicationNo, amendmentReason, tenantId, service),
|
|
44225
44781
|
[t("CORE_COMMON_NAME")]: owner,
|
|
44226
44782
|
[t("WS_COMMON_TABLE_COL_ADDRESS")]: t(Digit.Utils.locale.getRevenueLocalityCode(address, tenantId)),
|
|
44227
44783
|
[t("WS_COMMON_TABLE_COL_APPLICATION_STATUS")]: t(status),
|
|
@@ -44639,13 +45195,15 @@ const SearchBillAmendment = () => {
|
|
|
44639
45195
|
Header: t("WS_ACK_COMMON_APP_NO_LABEL", "Application No"),
|
|
44640
45196
|
accessor: "amendmentId",
|
|
44641
45197
|
Cell: _ref => {
|
|
45198
|
+
var _row$original, _row$original$busines;
|
|
44642
45199
|
let {
|
|
44643
45200
|
row
|
|
44644
45201
|
} = _ref;
|
|
45202
|
+
const service = (_row$original = row.original) !== null && _row$original !== void 0 && (_row$original$busines = _row$original.businessService) !== null && _row$original$busines !== void 0 && _row$original$busines.includes("SW") ? "SEWERAGE" : "WATER";
|
|
44645
45203
|
return /*#__PURE__*/React__default.createElement("span", {
|
|
44646
45204
|
className: "link"
|
|
44647
45205
|
}, /*#__PURE__*/React__default.createElement(reactRouterDom.Link, {
|
|
44648
|
-
to: `/digit-ui/employee/ws/generate-note-bill-amendment?applicationNumber=${row.original.amendmentId}`
|
|
45206
|
+
to: `/digit-ui/employee/ws/generate-note-bill-amendment?applicationNumber=${row.original.amendmentId}&tenantId=${tenantId}&service=${service}&from=WS_BILL_AMENDMENT_SEARCH_APPLICATION`
|
|
44649
45207
|
}, row.original.amendmentId));
|
|
44650
45208
|
}
|
|
44651
45209
|
}, {
|
|
@@ -44676,13 +45234,15 @@ const SearchBillAmendment = () => {
|
|
|
44676
45234
|
}, {
|
|
44677
45235
|
Header: t("WS_COMMON_TABLE_COL_ACTION", "Action"),
|
|
44678
45236
|
Cell: _ref3 => {
|
|
45237
|
+
var _row$original2, _row$original2$busine;
|
|
44679
45238
|
let {
|
|
44680
45239
|
row
|
|
44681
45240
|
} = _ref3;
|
|
45241
|
+
const service = (_row$original2 = row.original) !== null && _row$original2 !== void 0 && (_row$original2$busine = _row$original2.businessService) !== null && _row$original2$busine !== void 0 && _row$original2$busine.includes("SW") ? "SEWERAGE" : "WATER";
|
|
44682
45242
|
return /*#__PURE__*/React__default.createElement("span", {
|
|
44683
45243
|
className: "link"
|
|
44684
45244
|
}, /*#__PURE__*/React__default.createElement(reactRouterDom.Link, {
|
|
44685
|
-
to: `/digit-ui/employee/ws/generate-note-bill-amendment?applicationNumber=${row.original.amendmentId}`
|
|
45245
|
+
to: `/digit-ui/employee/ws/generate-note-bill-amendment?applicationNumber=${row.original.amendmentId}&tenantId=${tenantId}&service=${service}&from=WS_BILL_AMENDMENT_SEARCH_APPLICATION`
|
|
44686
45246
|
}, t("ES_COMMON_VIEW", "View")));
|
|
44687
45247
|
}
|
|
44688
45248
|
}], [t, tenantId]);
|
|
@@ -48718,10 +49278,10 @@ const WSApplicationDetails = () => {
|
|
|
48718
49278
|
}
|
|
48719
49279
|
return null;
|
|
48720
49280
|
})(), /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
|
|
48721
|
-
label: t("WS_DIVYANGJAN"),
|
|
49281
|
+
label: t("WS_DIVYANGJAN") && t("WS_DIVYANGJAN") !== "WS_DIVYANGJAN" ? t("WS_DIVYANGJAN") : "Divyangjan/Person with Disability?",
|
|
48722
49282
|
text: `${connectionDetails !== null && connectionDetails !== void 0 && connectionDetails.isDivyangjan ? t("CORE_COMMON_YES") : t("CORE_COMMON_NO")}`
|
|
48723
49283
|
}), /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
|
|
48724
|
-
label: t("WS_RAIN_WATER_HARVESTING_CERTIFICATE")
|
|
49284
|
+
label: t("WS_RAIN_WATER_HARVESTING_CERTIFICATE") && t("WS_RAIN_WATER_HARVESTING_CERTIFICATE") !== "WS_RAIN_WATER_HARVESTING_CERTIFICATE" ? t("WS_RAIN_WATER_HARVESTING_CERTIFICATE") : "Rain Water Harvesting Certificate",
|
|
48725
49285
|
text: `${connectionDetails !== null && connectionDetails !== void 0 && connectionDetails.hasRainWaterHarvestingCertificate || connectionDetails !== null && connectionDetails !== void 0 && connectionDetails.isRainwaterHarvesting ? t("CORE_COMMON_YES") : t("CORE_COMMON_NO")}`
|
|
48726
49286
|
}), (connectionDetails === null || connectionDetails === void 0 ? void 0 : (_connectionDetails$do = connectionDetails.domesticType) === null || _connectionDetails$do === void 0 ? void 0 : _connectionDetails$do.code) === "ORGANIZATION" && /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
|
|
48727
49287
|
label: t("WS_DEPARTMENT_TYPE"),
|
|
@@ -49800,7 +50360,7 @@ const getConnectionDetailsPDF = function (application, property, tenantInfo, t)
|
|
|
49800
50360
|
};
|
|
49801
50361
|
|
|
49802
50362
|
const ConnectionDetails$5 = () => {
|
|
49803
|
-
var _Digit$SessionStorage, _user$info, _data$SewerageConnect, _data$SewerageConnect2, _data$WaterConnection, _data$WaterConnection2, _Object$keys, _connectionData$Water, _connectionData$Water2, _connectionData$Sewer, _connectionData$Sewer2, _data$WaterConnection3, _data$WaterConnection4, _data$SewerageConnect3, _data$SewerageConnect4, _data$WaterConnection5, _data$WaterConnection6, _data$SewerageConnect5, _data$SewerageConnect6, _data$WaterConnection7, _data$WaterConnection8, _data$WaterConnection9, _data$WaterConnection0, _data$SewerageConnect7, _data$SewerageConnect8, _data$SewerageConnect9, _data$SewerageConnect0, _state, _state$applicationNo, _state2, _state5, _state6, _state6$
|
|
50363
|
+
var _Digit$SessionStorage, _user$info, _data$SewerageConnect, _data$SewerageConnect2, _data$WaterConnection, _data$WaterConnection2, _Object$keys, _connectionData$Water, _connectionData$Water2, _connectionData$Sewer, _connectionData$Sewer2, _data$WaterConnection3, _data$WaterConnection4, _data$SewerageConnect3, _data$SewerageConnect4, _data$WaterConnection5, _data$WaterConnection6, _data$SewerageConnect5, _data$SewerageConnect6, _data$WaterConnection7, _data$WaterConnection8, _data$WaterConnection9, _data$WaterConnection0, _data$SewerageConnect7, _data$SewerageConnect8, _data$SewerageConnect9, _data$SewerageConnect0, _state, _state$applicationNo, _state2, _state2$connectionNo, _state3, _state3$applicationNo, _state4, _state4$connectionNo, _state5, _state5$applicationTy, _state6, _state6$applicationNo, _state7, _state7$connectionNo, _state8, _state9, _state10, _state13, _state14, _state15, _state16, _state17, _state17$applicationT, _state18, _state19, _state20, _state21, _state21$applicationT, _state22, _state23, _state24, _state25, _state26, _state26$applicationT, _state27, _state27$waterSource, _state27$waterSource$, _state28, _state29, _state29$waterSource, _state29$waterSource$, _state30, _state31, _state32, _state33, _state33$additionalDe, _state34, _state34$applicationT, _state35, _state35$additionalDe, _state35$additionalDe2, _state36, _state36$additionalDe, _state36$additionalDe2, _state37, _state37$additionalDe, _state38, _state38$additionalDe, _state39, _state39$additionalDe, _state39$additionalDe2, _state40, _state40$additionalDe, _state41, _state42, _state43, _state43$property, _state43$property$own, _PTData$Properties2, _PTData$Properties2$, _PTData$Properties3, _PTData$Properties3$, _PTData$Properties3$$, _PTData$Properties3$$2, _PTData$Properties4, _PTData$Properties4$, _user$info2, _user$info2$userName, _user$info3, _user$info4, _state44, _state44$additionalDe, _state44$additionalDe2, _state45, _state45$additionalDe, _state45$additionalDe2, _state46, _state46$additionalDe, _state47, _state47$additionalDe, _state48, _state48$additionalDe, _state49, _state49$additionalDe, _state49$additionalDe2, _state50, _state50$additionalDe, _state50$additionalDe2, _state51, _state51$additionalDe, _state52, _state52$additionalDe, _state53, _state53$additionalDe, _state54, _state54$additionalDe, _state55, _state55$additionalDe, _state56, _state56$additionalDe, _state57, _state57$additionalDe, _state58, _state59, _state60, _state61, _state61$connectionHo, _state61$connectionHo2, _data$WaterConnection16, _data$WaterConnection17, _data$WaterConnection18, _data$WaterConnection19, _data$SewerageConnect12, _data$SewerageConnect13, _data$SewerageConnect14, _data$SewerageConnect15, _data$WaterConnection20, _data$WaterConnection21, _data$WaterConnection22, _data$WaterConnection23, _data$SewerageConnect16, _data$SewerageConnect17, _data$SewerageConnect18, _data$SewerageConnect19, _data$WaterConnection24, _data$WaterConnection25, _data$WaterConnection26, _data$WaterConnection27, _data$SewerageConnect20, _data$SewerageConnect21, _data$SewerageConnect22, _data$SewerageConnect23, _data$WaterConnection28, _data$WaterConnection29, _data$WaterConnection30, _data$WaterConnection31, _data$SewerageConnect24, _data$SewerageConnect25, _data$SewerageConnect26, _data$SewerageConnect27, _data$WaterConnection32, _data$WaterConnection33, _data$WaterConnection34, _data$WaterConnection35, _data$SewerageConnect28, _data$SewerageConnect29, _data$SewerageConnect30, _data$SewerageConnect31, _data$WaterConnection36, _data$WaterConnection37, _data$WaterConnection38, _data$WaterConnection39, _data$SewerageConnect32, _data$SewerageConnect33, _data$SewerageConnect34, _data$SewerageConnect35, _data$WaterConnection40, _data$WaterConnection41, _data$WaterConnection42, _data$WaterConnection43, _data$SewerageConnect36, _data$SewerageConnect37, _data$SewerageConnect38, _data$SewerageConnect39, _data$WaterConnection44, _data$WaterConnection45, _data$WaterConnection46, _data$WaterConnection47, _data$SewerageConnect40, _data$SewerageConnect41, _data$SewerageConnect42, _data$SewerageConnect43, _data$WaterConnection48, _data$WaterConnection49, _data$WaterConnection50, _data$WaterConnection51, _data$SewerageConnect44, _data$SewerageConnect45, _data$SewerageConnect46, _data$SewerageConnect47, _data$WaterConnection52, _data$WaterConnection53, _data$WaterConnection54, _data$WaterConnection55, _data$SewerageConnect48, _data$SewerageConnect49, _data$SewerageConnect50, _data$SewerageConnect51, _state62, _state63, _state66, _state66$status, _state67, _state67$applicationS, _state68, _paymentDetails$data17, _paymentDetails$data18;
|
|
49804
50364
|
const {
|
|
49805
50365
|
t
|
|
49806
50366
|
} = reactI18next.useTranslation();
|
|
@@ -49815,6 +50375,7 @@ const ConnectionDetails$5 = () => {
|
|
|
49815
50375
|
} = reactRouterDom.useLocation();
|
|
49816
50376
|
const [showModal, setshowModal] = React.useState(false);
|
|
49817
50377
|
const [showActionToast, setshowActionToast] = React.useState(null);
|
|
50378
|
+
const [activeAmendment, setActiveAmendment] = React.useState(null);
|
|
49818
50379
|
const mobileView = Digit.Utils.browser.isMobile();
|
|
49819
50380
|
const getAddress = address => {
|
|
49820
50381
|
var _address$locality, _address$locality2, _address$city;
|
|
@@ -49976,9 +50537,11 @@ const ConnectionDetails$5 = () => {
|
|
|
49976
50537
|
downloadOptions.sort(function (a, b) {
|
|
49977
50538
|
return a.order - b.order;
|
|
49978
50539
|
});
|
|
49979
|
-
const isSW = (_state = state) === null || _state === void 0 ? void 0 : (_state$applicationNo = _state.applicationNo) === null || _state$applicationNo === void 0 ? void 0 : _state$applicationNo.includes("SW");
|
|
50540
|
+
const isSW = (((_state = state) === null || _state === void 0 ? void 0 : (_state$applicationNo = _state.applicationNo) === null || _state$applicationNo === void 0 ? void 0 : _state$applicationNo.includes("SW")) || (applicationNobyData === null || applicationNobyData === void 0 ? void 0 : applicationNobyData.includes("SW")) || ((_state2 = state) === null || _state2 === void 0 ? void 0 : (_state2$connectionNo = _state2.connectionNo) === null || _state2$connectionNo === void 0 ? void 0 : _state2$connectionNo.includes("SW"))) && !((_state3 = state) !== null && _state3 !== void 0 && (_state3$applicationNo = _state3.applicationNo) !== null && _state3$applicationNo !== void 0 && _state3$applicationNo.includes("WS")) && !((_state4 = state) !== null && _state4 !== void 0 && (_state4$connectionNo = _state4.connectionNo) !== null && _state4$connectionNo !== void 0 && _state4$connectionNo.includes("WS"));
|
|
50541
|
+
const isWS = ((_state5 = state) === null || _state5 === void 0 ? void 0 : (_state5$applicationTy = _state5.applicationType) === null || _state5$applicationTy === void 0 ? void 0 : _state5$applicationTy.includes("WATER")) || ((_state6 = state) === null || _state6 === void 0 ? void 0 : (_state6$applicationNo = _state6.applicationNo) === null || _state6$applicationNo === void 0 ? void 0 : _state6$applicationNo.includes("WS")) || (applicationNobyData === null || applicationNobyData === void 0 ? void 0 : applicationNobyData.includes("WS")) || ((_state7 = state) === null || _state7 === void 0 ? void 0 : (_state7$connectionNo = _state7.connectionNo) === null || _state7$connectionNo === void 0 ? void 0 : _state7$connectionNo.includes("WS")) || ((_state8 = state) === null || _state8 === void 0 ? void 0 : _state8.water) === true;
|
|
50542
|
+
const serviceType = isWS || !isSW ? "WATER" : "SEWERAGE";
|
|
49980
50543
|
const fetchBillParams = {
|
|
49981
|
-
consumerCode: (
|
|
50544
|
+
consumerCode: (_state9 = state) === null || _state9 === void 0 ? void 0 : _state9.connectionNo
|
|
49982
50545
|
};
|
|
49983
50546
|
const paymentDetails = Digit.Hooks.useFetchBillsForBuissnessService({
|
|
49984
50547
|
businessService: isSW ? "SW" : "WS",
|
|
@@ -50054,11 +50617,45 @@ const ConnectionDetails$5 = () => {
|
|
|
50054
50617
|
}
|
|
50055
50618
|
}
|
|
50056
50619
|
};
|
|
50620
|
+
React.useEffect(() => {
|
|
50621
|
+
let isMounted = true;
|
|
50622
|
+
const checkActiveAmendment = function () {
|
|
50623
|
+
try {
|
|
50624
|
+
var _state0, _state1;
|
|
50625
|
+
const connNo = (_state0 = state) === null || _state0 === void 0 ? void 0 : _state0.connectionNo;
|
|
50626
|
+
if (!connNo) return Promise.resolve();
|
|
50627
|
+
const finalTenantId = tenantId || ((_state1 = state) === null || _state1 === void 0 ? void 0 : _state1.tenantId) || "dl.djb";
|
|
50628
|
+
const finalServiceType = serviceType || (connNo !== null && connNo !== void 0 && connNo.includes("SW") ? "SEWERAGE" : "WATER");
|
|
50629
|
+
const businessService = finalServiceType === "WATER" ? "WS" : "SW";
|
|
50630
|
+
const _temp3 = _catch(function () {
|
|
50631
|
+
return Promise.resolve(Digit.PaymentService.searchAmendment(finalTenantId, {
|
|
50632
|
+
consumerCode: connNo,
|
|
50633
|
+
businessService
|
|
50634
|
+
})).then(function (res) {
|
|
50635
|
+
var _res$Amendments;
|
|
50636
|
+
const inWorkflow = res === null || res === void 0 ? void 0 : (_res$Amendments = res.Amendments) === null || _res$Amendments === void 0 ? void 0 : _res$Amendments.find(item => (item === null || item === void 0 ? void 0 : item.status) === "INWORKFLOW");
|
|
50637
|
+
if (isMounted && inWorkflow) {
|
|
50638
|
+
setActiveAmendment(inWorkflow);
|
|
50639
|
+
}
|
|
50640
|
+
});
|
|
50641
|
+
}, function (e) {
|
|
50642
|
+
console.warn("Could not check active amendment in connection details", e);
|
|
50643
|
+
});
|
|
50644
|
+
return Promise.resolve(_temp3 && _temp3.then ? _temp3.then(function () {}) : void 0);
|
|
50645
|
+
} catch (e) {
|
|
50646
|
+
return Promise.reject(e);
|
|
50647
|
+
}
|
|
50648
|
+
};
|
|
50649
|
+
checkActiveAmendment();
|
|
50650
|
+
return () => {
|
|
50651
|
+
isMounted = false;
|
|
50652
|
+
};
|
|
50653
|
+
}, [(_state10 = state) === null || _state10 === void 0 ? void 0 : _state10.connectionNo, applicationNobyData, serviceType, tenantId]);
|
|
50057
50654
|
const getBillAmendmentButton = function () {
|
|
50058
50655
|
try {
|
|
50059
|
-
var
|
|
50656
|
+
var _state11, _state12;
|
|
50060
50657
|
let _exit = false;
|
|
50061
|
-
function
|
|
50658
|
+
function _temp5(_result) {
|
|
50062
50659
|
if (_exit) return _result;
|
|
50063
50660
|
history.push(`/digit-ui/citizen/ws/bill-amendment?connectionNumber=${connNo}&tenantId=${finalTenantId}&service=${finalServiceType}`, JSON.stringify({
|
|
50064
50661
|
data: {
|
|
@@ -50067,32 +50664,26 @@ const ConnectionDetails$5 = () => {
|
|
|
50067
50664
|
}
|
|
50068
50665
|
}));
|
|
50069
50666
|
}
|
|
50070
|
-
const connNo = ((
|
|
50071
|
-
const finalTenantId = tenantId || ((
|
|
50667
|
+
const connNo = ((_state11 = state) === null || _state11 === void 0 ? void 0 : _state11.connectionNo) || applicationNobyData;
|
|
50668
|
+
const finalTenantId = tenantId || ((_state12 = state) === null || _state12 === void 0 ? void 0 : _state12.tenantId) || "dl.djb";
|
|
50072
50669
|
const finalServiceType = serviceType || (connNo !== null && connNo !== void 0 && connNo.includes("SW") ? "SEWERAGE" : "WATER");
|
|
50073
50670
|
const businessService = finalServiceType === "WATER" ? "WS" : "SW";
|
|
50074
|
-
const
|
|
50671
|
+
const _temp4 = _catch(function () {
|
|
50075
50672
|
return Promise.resolve(Digit.PaymentService.searchAmendment(finalTenantId, {
|
|
50076
50673
|
consumerCode: connNo,
|
|
50077
50674
|
businessService
|
|
50078
50675
|
})).then(function (res) {
|
|
50079
|
-
var _res$
|
|
50080
|
-
const inWorkflow = res === null || res === void 0 ? void 0 : (_res$
|
|
50676
|
+
var _res$Amendments2;
|
|
50677
|
+
const inWorkflow = res === null || res === void 0 ? void 0 : (_res$Amendments2 = res.Amendments) === null || _res$Amendments2 === void 0 ? void 0 : _res$Amendments2.find(item => (item === null || item === void 0 ? void 0 : item.status) === "INWORKFLOW");
|
|
50081
50678
|
if (inWorkflow) {
|
|
50082
|
-
|
|
50083
|
-
key: "error",
|
|
50084
|
-
label: "WORKFLOW_IN_PROGRESS"
|
|
50085
|
-
});
|
|
50086
|
-
setTimeout(() => {
|
|
50087
|
-
closeBillToast();
|
|
50088
|
-
}, 5000);
|
|
50679
|
+
history.push(`/digit-ui/citizen/ws/bill-amendment/application-details?applicationNumber=${inWorkflow.amendmentId}`);
|
|
50089
50680
|
_exit = true;
|
|
50090
50681
|
}
|
|
50091
50682
|
});
|
|
50092
50683
|
}, function (e) {
|
|
50093
50684
|
console.error("Error searching amendment", e);
|
|
50094
50685
|
});
|
|
50095
|
-
return Promise.resolve(
|
|
50686
|
+
return Promise.resolve(_temp4 && _temp4.then ? _temp4.then(_temp5) : _temp5(_temp4));
|
|
50096
50687
|
} catch (e) {
|
|
50097
50688
|
return Promise.reject(e);
|
|
50098
50689
|
}
|
|
@@ -50130,8 +50721,7 @@ const ConnectionDetails$5 = () => {
|
|
|
50130
50721
|
if (isLoading || isPTLoading) {
|
|
50131
50722
|
return /*#__PURE__*/React__default.createElement(digitUiReactComponents.Loader, null);
|
|
50132
50723
|
}
|
|
50133
|
-
sessionStorage.setItem("ApplicationNoState", (
|
|
50134
|
-
let serviceType = (_state6 = state) !== null && _state6 !== void 0 && (_state6$applicationTy = _state6.applicationType) !== null && _state6$applicationTy !== void 0 && _state6$applicationTy.includes("WATER") ? "WATER" : "SEWERAGE";
|
|
50724
|
+
sessionStorage.setItem("ApplicationNoState", (_state13 = state) === null || _state13 === void 0 ? void 0 : _state13.applicationNo);
|
|
50135
50725
|
return /*#__PURE__*/React__default.createElement(React__default.Fragment, null, checkifPrivacyenabled && /*#__PURE__*/React__default.createElement(WSInfoLabel, {
|
|
50136
50726
|
t: t
|
|
50137
50727
|
}), /*#__PURE__*/React__default.createElement("div", {
|
|
@@ -50152,21 +50742,64 @@ const ConnectionDetails$5 = () => {
|
|
|
50152
50742
|
options: downloadOptions,
|
|
50153
50743
|
downloadBtnClassName: "employee-download-btn-className",
|
|
50154
50744
|
optionsClassName: "employee-options-btn-className"
|
|
50155
|
-
}))),
|
|
50745
|
+
}))), activeAmendment && /*#__PURE__*/React__default.createElement("div", {
|
|
50746
|
+
style: {
|
|
50747
|
+
padding: "14px 16px",
|
|
50748
|
+
backgroundColor: "#EFF6FF",
|
|
50749
|
+
border: "1px solid #BFDBFE",
|
|
50750
|
+
borderRadius: "8px",
|
|
50751
|
+
marginBottom: "20px"
|
|
50752
|
+
}
|
|
50753
|
+
}, /*#__PURE__*/React__default.createElement("div", {
|
|
50754
|
+
style: {
|
|
50755
|
+
display: "flex",
|
|
50756
|
+
justifyContent: "space-between",
|
|
50757
|
+
alignItems: "center",
|
|
50758
|
+
flexWrap: "wrap",
|
|
50759
|
+
gap: "10px"
|
|
50760
|
+
}
|
|
50761
|
+
}, /*#__PURE__*/React__default.createElement("div", null, /*#__PURE__*/React__default.createElement("div", {
|
|
50762
|
+
style: {
|
|
50763
|
+
fontWeight: "700",
|
|
50764
|
+
color: "#1E40AF",
|
|
50765
|
+
fontSize: "16px"
|
|
50766
|
+
}
|
|
50767
|
+
}, t("WS_ACTIVE_BILL_AMENDMENT_LABEL", "Active Bill Correction / Amendment Request")), /*#__PURE__*/React__default.createElement("div", {
|
|
50768
|
+
style: {
|
|
50769
|
+
color: "#1E3A8A",
|
|
50770
|
+
fontSize: "14px",
|
|
50771
|
+
marginTop: "4px"
|
|
50772
|
+
}
|
|
50773
|
+
}, t("WS_APPLICATION_NO_LABEL", "Application No:"), " ", /*#__PURE__*/React__default.createElement("strong", null, activeAmendment.amendmentId), " | ", t("WS_STATUS_LABEL", "Status:"), " ", /*#__PURE__*/React__default.createElement("span", {
|
|
50774
|
+
style: {
|
|
50775
|
+
fontWeight: "600",
|
|
50776
|
+
color: "#B45309"
|
|
50777
|
+
}
|
|
50778
|
+
}, t(`CS_${activeAmendment.status}`, activeAmendment.status)))), /*#__PURE__*/React__default.createElement(reactRouterDom.Link, {
|
|
50779
|
+
to: `/digit-ui/citizen/ws/bill-amendment/application-details?applicationNumber=${activeAmendment.amendmentId}`
|
|
50780
|
+
}, /*#__PURE__*/React__default.createElement("button", {
|
|
50781
|
+
className: "selector-button-border",
|
|
50782
|
+
style: {
|
|
50783
|
+
height: "36px",
|
|
50784
|
+
padding: "0 16px",
|
|
50785
|
+
margin: 0,
|
|
50786
|
+
cursor: "pointer"
|
|
50787
|
+
}
|
|
50788
|
+
}, t("WS_TRACK_OR_RESUBMIT_LABEL", "View Details & Track / Re-Submit"))))), /*#__PURE__*/React__default.createElement(digitUiReactComponents.StatusTable, null, /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
|
|
50156
50789
|
className: "border-none",
|
|
50157
50790
|
label: t("WS_MYCONNECTIONS_CONSUMER_NO"),
|
|
50158
|
-
text: (
|
|
50791
|
+
text: (_state14 = state) === null || _state14 === void 0 ? void 0 : _state14.connectionNo
|
|
50159
50792
|
}), /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
|
|
50160
50793
|
className: "border-none",
|
|
50161
50794
|
label: t("WS_SERVICE_NAME_LABEL"),
|
|
50162
|
-
text: t(`WS_APPLICATION_TYPE_${(
|
|
50795
|
+
text: t(`WS_APPLICATION_TYPE_${(_state15 = state) === null || _state15 === void 0 ? void 0 : _state15.applicationType}`),
|
|
50163
50796
|
textStyle: {
|
|
50164
50797
|
wordBreak: "break-word"
|
|
50165
50798
|
}
|
|
50166
50799
|
}), /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
|
|
50167
50800
|
className: "border-none",
|
|
50168
50801
|
label: t("WS_STATUS"),
|
|
50169
|
-
text: ((
|
|
50802
|
+
text: ((_state16 = state) === null || _state16 === void 0 ? void 0 : _state16.status) || "NA",
|
|
50170
50803
|
textStyle: {
|
|
50171
50804
|
whiteSpace: "pre"
|
|
50172
50805
|
}
|
|
@@ -50174,127 +50807,127 @@ const ConnectionDetails$5 = () => {
|
|
|
50174
50807
|
styles: {
|
|
50175
50808
|
fontSize: "28px"
|
|
50176
50809
|
}
|
|
50177
|
-
}, t("WS_COMMON_CONNECTION_DETAIL")), /*#__PURE__*/React__default.createElement(digitUiReactComponents.StatusTable, null, ((
|
|
50810
|
+
}, t("WS_COMMON_CONNECTION_DETAIL")), /*#__PURE__*/React__default.createElement(digitUiReactComponents.StatusTable, null, ((_state17 = state) === null || _state17 === void 0 ? void 0 : (_state17$applicationT = _state17.applicationType) === null || _state17$applicationT === void 0 ? void 0 : _state17$applicationT.includes("WATER")) && /*#__PURE__*/React__default.createElement("div", null, /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
|
|
50178
50811
|
className: "border-none",
|
|
50179
50812
|
label: t("WS_COMMON_TABLE_COL_CONNECTIONTYPE_LABEL"),
|
|
50180
|
-
text: ((
|
|
50813
|
+
text: ((_state18 = state) === null || _state18 === void 0 ? void 0 : _state18.connectionType) || t("NA"),
|
|
50181
50814
|
textStyle: {
|
|
50182
50815
|
whiteSpace: "pre"
|
|
50183
50816
|
}
|
|
50184
50817
|
}), /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
|
|
50185
50818
|
className: "border-none",
|
|
50186
50819
|
label: t("WS_SERV_DETAIL_NO_OF_TAPS"),
|
|
50187
|
-
text: (
|
|
50820
|
+
text: (_state19 = state) === null || _state19 === void 0 ? void 0 : _state19.noOfTaps,
|
|
50188
50821
|
textStyle: {
|
|
50189
50822
|
whiteSpace: "pre"
|
|
50190
50823
|
}
|
|
50191
50824
|
}), /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
|
|
50192
50825
|
className: "border-none",
|
|
50193
50826
|
label: t("WS_PIPE_SIZE_IN_INCHES_LABEL"),
|
|
50194
|
-
text: ((
|
|
50827
|
+
text: ((_state20 = state) === null || _state20 === void 0 ? void 0 : _state20.pipeSize) || "NA",
|
|
50195
50828
|
textStyle: {
|
|
50196
50829
|
whiteSpace: "pre"
|
|
50197
50830
|
}
|
|
50198
|
-
})), ((
|
|
50831
|
+
})), ((_state21 = state) === null || _state21 === void 0 ? void 0 : (_state21$applicationT = _state21.applicationType) === null || _state21$applicationT === void 0 ? void 0 : _state21$applicationT.includes("SEWERAGE")) && /*#__PURE__*/React__default.createElement("div", null, /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
|
|
50199
50832
|
className: "border-none",
|
|
50200
50833
|
label: t("WS_CONN_DETAIL_WATER_CLOSETS"),
|
|
50201
|
-
text: (
|
|
50834
|
+
text: (_state22 = state) === null || _state22 === void 0 ? void 0 : _state22.proposedWaterClosets,
|
|
50202
50835
|
textStyle: {
|
|
50203
50836
|
whiteSpace: "pre"
|
|
50204
50837
|
}
|
|
50205
50838
|
}), /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
|
|
50206
50839
|
className: "border-none",
|
|
50207
50840
|
label: t("WS_SERV_DETAIL_NO_OF_TOILETS"),
|
|
50208
|
-
text: ((
|
|
50841
|
+
text: ((_state23 = state) === null || _state23 === void 0 ? void 0 : _state23.proposedToilets) || t("CS_NA"),
|
|
50209
50842
|
textStyle: {
|
|
50210
50843
|
whiteSpace: "pre"
|
|
50211
50844
|
}
|
|
50212
50845
|
}), /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
|
|
50213
50846
|
className: "border-none",
|
|
50214
50847
|
label: t("WS_SERV_DETAIL_CONN_EXECUTION_DATE"),
|
|
50215
|
-
text: (
|
|
50848
|
+
text: (_state24 = state) !== null && _state24 !== void 0 && _state24.connectionExecutionDate ? Digit.DateUtils.ConvertEpochToDate((_state25 = state) === null || _state25 === void 0 ? void 0 : _state25.connectionExecutionDate) : t("CS_NA"),
|
|
50216
50849
|
textStyle: {
|
|
50217
50850
|
whiteSpace: "pre"
|
|
50218
50851
|
}
|
|
50219
|
-
})), ((
|
|
50852
|
+
})), ((_state26 = state) === null || _state26 === void 0 ? void 0 : (_state26$applicationT = _state26.applicationType) === null || _state26$applicationT === void 0 ? void 0 : _state26$applicationT.includes("WATER")) && /*#__PURE__*/React__default.createElement("div", null, /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
|
|
50220
50853
|
className: "border-none",
|
|
50221
50854
|
label: t("WS_SERV_DETAIL_WATER_SOURCE"),
|
|
50222
|
-
text: t(`WS_SERVICES_MASTERS_WATERSOURCE_${stringReplaceAll((
|
|
50855
|
+
text: t(`WS_SERVICES_MASTERS_WATERSOURCE_${stringReplaceAll((_state27 = state) === null || _state27 === void 0 ? void 0 : (_state27$waterSource = _state27.waterSource) === null || _state27$waterSource === void 0 ? void 0 : (_state27$waterSource$ = _state27$waterSource.split(".")) === null || _state27$waterSource$ === void 0 ? void 0 : _state27$waterSource$[0], ".", "_")}`) || t(`WS_SERVICES_MASTERS_WATERSOURCE_${stringReplaceAll((_state28 = state) === null || _state28 === void 0 ? void 0 : _state28.waterSource, ".", "_")}`) || t("CS_NA"),
|
|
50223
50856
|
textStyle: {
|
|
50224
50857
|
whiteSpace: "pre"
|
|
50225
50858
|
}
|
|
50226
50859
|
}), /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
|
|
50227
50860
|
className: "border-none",
|
|
50228
50861
|
label: t("WS_SERV_DETAIL_WATER_SUB_SOURCE"),
|
|
50229
|
-
text: t((
|
|
50862
|
+
text: t((_state29 = state) === null || _state29 === void 0 ? void 0 : (_state29$waterSource = _state29.waterSource) === null || _state29$waterSource === void 0 ? void 0 : (_state29$waterSource$ = _state29$waterSource.split(".")) === null || _state29$waterSource$ === void 0 ? void 0 : _state29$waterSource$[1]) || t("CS_NA"),
|
|
50230
50863
|
textStyle: {
|
|
50231
50864
|
whiteSpace: "pre"
|
|
50232
50865
|
}
|
|
50233
50866
|
}), /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
|
|
50234
50867
|
className: "border-none",
|
|
50235
50868
|
label: t("WS_SERV_DETAIL_CONN_EXECUTION_DATE"),
|
|
50236
|
-
text: Digit.DateUtils.ConvertEpochToDate((
|
|
50869
|
+
text: Digit.DateUtils.ConvertEpochToDate((_state30 = state) === null || _state30 === void 0 ? void 0 : _state30.connectionExecutionDate) || t("NA"),
|
|
50237
50870
|
textStyle: {
|
|
50238
50871
|
whiteSpace: "pre"
|
|
50239
50872
|
}
|
|
50240
50873
|
}), /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
|
|
50241
50874
|
className: "border-none",
|
|
50242
50875
|
label: t("WS_SERV_DETAIL_METER_ID"),
|
|
50243
|
-
text: (
|
|
50876
|
+
text: (_state31 = state) === null || _state31 === void 0 ? void 0 : _state31.meterId,
|
|
50244
50877
|
textStyle: {
|
|
50245
50878
|
whiteSpace: "pre"
|
|
50246
50879
|
}
|
|
50247
50880
|
}), /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
|
|
50248
50881
|
className: "border-none",
|
|
50249
50882
|
label: t("WS_ADDN_DETAIL_METER_INSTALL_DATE"),
|
|
50250
|
-
text: Digit.DateUtils.ConvertEpochToDate((
|
|
50883
|
+
text: Digit.DateUtils.ConvertEpochToDate((_state32 = state) === null || _state32 === void 0 ? void 0 : _state32.meterInstallationDate) || "NA",
|
|
50251
50884
|
textStyle: {
|
|
50252
50885
|
whiteSpace: "pre"
|
|
50253
50886
|
}
|
|
50254
50887
|
}), /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
|
|
50255
50888
|
className: "border-none",
|
|
50256
50889
|
label: t("WS_ADDN_DETAILS_INITIAL_METER_READING"),
|
|
50257
|
-
text: ((
|
|
50890
|
+
text: ((_state33 = state) === null || _state33 === void 0 ? void 0 : (_state33$additionalDe = _state33.additionalDetails) === null || _state33$additionalDe === void 0 ? void 0 : _state33$additionalDe.initialMeterReading) || "NA",
|
|
50258
50891
|
textStyle: {
|
|
50259
50892
|
whiteSpace: "pre"
|
|
50260
50893
|
}
|
|
50261
|
-
})), ((
|
|
50894
|
+
})), ((_state34 = state) === null || _state34 === void 0 ? void 0 : (_state34$applicationT = _state34.applicationType) === null || _state34$applicationT === void 0 ? void 0 : _state34$applicationT.includes("WATER")) && /*#__PURE__*/React__default.createElement("div", null, /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
|
|
50262
50895
|
className: "border-none",
|
|
50263
50896
|
label: t("WS_WATER_DEMAND_TYPE"),
|
|
50264
|
-
text: (
|
|
50897
|
+
text: (_state35 = state) !== null && _state35 !== void 0 && (_state35$additionalDe = _state35.additionalDetails) !== null && _state35$additionalDe !== void 0 && (_state35$additionalDe2 = _state35$additionalDe.waterDemandType) !== null && _state35$additionalDe2 !== void 0 && _state35$additionalDe2.i18nKey ? t((_state36 = state) === null || _state36 === void 0 ? void 0 : (_state36$additionalDe = _state36.additionalDetails) === null || _state36$additionalDe === void 0 ? void 0 : (_state36$additionalDe2 = _state36$additionalDe.waterDemandType) === null || _state36$additionalDe2 === void 0 ? void 0 : _state36$additionalDe2.i18nKey) : "NA",
|
|
50265
50898
|
textStyle: {
|
|
50266
50899
|
whiteSpace: "pre"
|
|
50267
50900
|
}
|
|
50268
50901
|
}), /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
|
|
50269
50902
|
className: "border-none",
|
|
50270
50903
|
label: t("WS_CATEGORY_TYPE"),
|
|
50271
|
-
text: ((
|
|
50904
|
+
text: ((_state37 = state) === null || _state37 === void 0 ? void 0 : (_state37$additionalDe = _state37.additionalDetails) === null || _state37$additionalDe === void 0 ? void 0 : _state37$additionalDe.categoryType) || "NA",
|
|
50272
50905
|
textStyle: {
|
|
50273
50906
|
whiteSpace: "pre"
|
|
50274
50907
|
}
|
|
50275
50908
|
}), /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
|
|
50276
50909
|
className: "border-none",
|
|
50277
50910
|
label: t("WS_ZRO_NAME"),
|
|
50278
|
-
text: ((
|
|
50911
|
+
text: ((_state38 = state) === null || _state38 === void 0 ? void 0 : (_state38$additionalDe = _state38.additionalDetails) === null || _state38$additionalDe === void 0 ? void 0 : _state38$additionalDe.zro) || "NA",
|
|
50279
50912
|
textStyle: {
|
|
50280
50913
|
whiteSpace: "pre"
|
|
50281
50914
|
}
|
|
50282
50915
|
}), /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
|
|
50283
50916
|
className: "border-none",
|
|
50284
50917
|
label: t("WS_CONNECTION_USAGE_TYPE"),
|
|
50285
|
-
text: ((
|
|
50918
|
+
text: ((_state39 = state) === null || _state39 === void 0 ? void 0 : (_state39$additionalDe = _state39.additionalDetails) === null || _state39$additionalDe === void 0 ? void 0 : (_state39$additionalDe2 = _state39$additionalDe.WaterConnectionUsageType) === null || _state39$additionalDe2 === void 0 ? void 0 : _state39$additionalDe2.name) || "NA",
|
|
50286
50919
|
textStyle: {
|
|
50287
50920
|
whiteSpace: "pre"
|
|
50288
50921
|
}
|
|
50289
50922
|
}), /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
|
|
50290
50923
|
className: "border-none",
|
|
50291
50924
|
label: t("WS_TEMPORARY_CONNECTION"),
|
|
50292
|
-
text: ((
|
|
50925
|
+
text: ((_state40 = state) === null || _state40 === void 0 ? void 0 : (_state40$additionalDe = _state40.additionalDetails) === null || _state40$additionalDe === void 0 ? void 0 : _state40$additionalDe.temporaryConnection) || "NA",
|
|
50293
50926
|
textStyle: {
|
|
50294
50927
|
whiteSpace: "pre"
|
|
50295
50928
|
}
|
|
50296
|
-
})), ((
|
|
50297
|
-
to: `/digit-ui/citizen/ws/consumption/details?applicationNo=${(
|
|
50929
|
+
})), ((_state41 = state) === null || _state41 === void 0 ? void 0 : _state41.connectionType) === "Metered" && /*#__PURE__*/React__default.createElement(reactRouterDom.Link, {
|
|
50930
|
+
to: `/digit-ui/citizen/ws/consumption/details?applicationNo=${(_state42 = state) === null || _state42 === void 0 ? void 0 : _state42.connectionNo}`
|
|
50298
50931
|
}, /*#__PURE__*/React__default.createElement(digitUiReactComponents.LinkButton, {
|
|
50299
50932
|
style: {
|
|
50300
50933
|
textAlign: "left",
|
|
@@ -50309,7 +50942,7 @@ const ConnectionDetails$5 = () => {
|
|
|
50309
50942
|
}, t("WS_COMMON_PROPERTY_DETAILS")), /*#__PURE__*/React__default.createElement(digitUiReactComponents.StatusTable, null, /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
|
|
50310
50943
|
className: "border-none",
|
|
50311
50944
|
label: t("WS_OWN_DETAIL_OWN_NAME_LABEL"),
|
|
50312
|
-
text: (
|
|
50945
|
+
text: (_state43 = state) === null || _state43 === void 0 ? void 0 : (_state43$property = _state43.property) === null || _state43$property === void 0 ? void 0 : (_state43$property$own = _state43$property.owners) === null || _state43$property$own === void 0 ? void 0 : _state43$property$own.map(owner => owner.name).join(","),
|
|
50313
50946
|
textStyle: {
|
|
50314
50947
|
whiteSpace: "pre"
|
|
50315
50948
|
}
|
|
@@ -50344,32 +50977,32 @@ const ConnectionDetails$5 = () => {
|
|
|
50344
50977
|
}), /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
|
|
50345
50978
|
className: "border-none",
|
|
50346
50979
|
label: t("WS_PROPERTY_TYPE"),
|
|
50347
|
-
text: ((
|
|
50980
|
+
text: ((_state44 = state) === null || _state44 === void 0 ? void 0 : (_state44$additionalDe = _state44.additionalDetails) === null || _state44$additionalDe === void 0 ? void 0 : (_state44$additionalDe2 = _state44$additionalDe.propertyType) === null || _state44$additionalDe2 === void 0 ? void 0 : _state44$additionalDe2.name) || "NA"
|
|
50348
50981
|
}), /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
|
|
50349
50982
|
className: "border-none",
|
|
50350
50983
|
label: t("WS_PROPERTY_CATEGORY"),
|
|
50351
|
-
text: ((
|
|
50984
|
+
text: ((_state45 = state) === null || _state45 === void 0 ? void 0 : (_state45$additionalDe = _state45.additionalDetails) === null || _state45$additionalDe === void 0 ? void 0 : (_state45$additionalDe2 = _state45$additionalDe.propertyCategory) === null || _state45$additionalDe2 === void 0 ? void 0 : _state45$additionalDe2.name) || "NA"
|
|
50352
50985
|
}), /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
|
|
50353
50986
|
className: "border-none",
|
|
50354
50987
|
label: t("WS_PLOT_AREA"),
|
|
50355
|
-
text: ((
|
|
50988
|
+
text: ((_state46 = state) === null || _state46 === void 0 ? void 0 : (_state46$additionalDe = _state46.additionalDetails) === null || _state46$additionalDe === void 0 ? void 0 : _state46$additionalDe.plotArea) || "NA"
|
|
50356
50989
|
}), /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
|
|
50357
50990
|
className: "border-none",
|
|
50358
50991
|
label: t("WS_BUILT_UP_AREA"),
|
|
50359
|
-
text: ((
|
|
50992
|
+
text: ((_state47 = state) === null || _state47 === void 0 ? void 0 : (_state47$additionalDe = _state47.additionalDetails) === null || _state47$additionalDe === void 0 ? void 0 : _state47$additionalDe.builtUpArea) || "NA"
|
|
50360
50993
|
}), /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
|
|
50361
50994
|
className: "border-none",
|
|
50362
50995
|
label: t("WS_NO_OF_FLOORS"),
|
|
50363
|
-
text: ((
|
|
50364
|
-
}), String(((
|
|
50996
|
+
text: ((_state48 = state) === null || _state48 === void 0 ? void 0 : (_state48$additionalDe = _state48.additionalDetails) === null || _state48$additionalDe === void 0 ? void 0 : _state48$additionalDe.noOfFloors) || "NA"
|
|
50997
|
+
}), String(((_state49 = state) === null || _state49 === void 0 ? void 0 : (_state49$additionalDe = _state49.additionalDetails) === null || _state49$additionalDe === void 0 ? void 0 : (_state49$additionalDe2 = _state49$additionalDe.propertyCategory) === null || _state49$additionalDe2 === void 0 ? void 0 : _state49$additionalDe2.code) || ((_state50 = state) === null || _state50 === void 0 ? void 0 : (_state50$additionalDe = _state50.additionalDetails) === null || _state50$additionalDe === void 0 ? void 0 : (_state50$additionalDe2 = _state50$additionalDe.propertyCategory) === null || _state50$additionalDe2 === void 0 ? void 0 : _state50$additionalDe2.name) || ((_state51 = state) === null || _state51 === void 0 ? void 0 : (_state51$additionalDe = _state51.additionalDetails) === null || _state51$additionalDe === void 0 ? void 0 : _state51$additionalDe.propertyCategory) || "").toUpperCase().includes("RESIDENTIAL") && /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
|
|
50365
50998
|
className: "border-none",
|
|
50366
50999
|
label: t("WS_NO_OF_DWELLING_UNITS"),
|
|
50367
|
-
text: ((
|
|
51000
|
+
text: ((_state52 = state) === null || _state52 === void 0 ? void 0 : (_state52$additionalDe = _state52.additionalDetails) === null || _state52$additionalDe === void 0 ? void 0 : _state52$additionalDe.NumberofDwellingUnits) || "NA"
|
|
50368
51001
|
}), /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
|
|
50369
51002
|
className: "border-none",
|
|
50370
51003
|
label: t("WS_LOCALITY"),
|
|
50371
|
-
text: ((
|
|
50372
|
-
}), (Array.isArray(((
|
|
51004
|
+
text: ((_state53 = state) === null || _state53 === void 0 ? void 0 : (_state53$additionalDe = _state53.additionalDetails) === null || _state53$additionalDe === void 0 ? void 0 : _state53$additionalDe.locality) || "NA"
|
|
51005
|
+
}), (Array.isArray(((_state54 = state) === null || _state54 === void 0 ? void 0 : (_state54$additionalDe = _state54.additionalDetails) === null || _state54$additionalDe === void 0 ? void 0 : _state54$additionalDe.questions) || ((_state55 = state) === null || _state55 === void 0 ? void 0 : (_state55$additionalDe = _state55.additionalDetails) === null || _state55$additionalDe === void 0 ? void 0 : _state55$additionalDe.questionAnswers)) ? ((_state56 = state) === null || _state56 === void 0 ? void 0 : (_state56$additionalDe = _state56.additionalDetails) === null || _state56$additionalDe === void 0 ? void 0 : _state56$additionalDe.questions) || ((_state57 = state) === null || _state57 === void 0 ? void 0 : (_state57$additionalDe = _state57.additionalDetails) === null || _state57$additionalDe === void 0 ? void 0 : _state57$additionalDe.questionAnswers) : []).map((q, idx) => {
|
|
50373
51006
|
var _q$answer, _q$answer2, _q$answer3;
|
|
50374
51007
|
const qText = typeof q === "object" ? (q === null || q === void 0 ? void 0 : q.question) || (q === null || q === void 0 ? void 0 : q.questionText) || (q === null || q === void 0 ? void 0 : q.title) || `Question ${idx + 1}` : `Question ${idx + 1}`;
|
|
50375
51008
|
const aText = typeof q === "object" ? typeof (q === null || q === void 0 ? void 0 : q.answer) === "object" ? (q === null || q === void 0 ? void 0 : (_q$answer = q.answer) === null || _q$answer === void 0 ? void 0 : _q$answer.name) || (q === null || q === void 0 ? void 0 : (_q$answer2 = q.answer) === null || _q$answer2 === void 0 ? void 0 : _q$answer2.value) || (q === null || q === void 0 ? void 0 : (_q$answer3 = q.answer) === null || _q$answer3 === void 0 ? void 0 : _q$answer3.code) : q === null || q === void 0 ? void 0 : q.answer : q;
|
|
@@ -50382,7 +51015,7 @@ const ConnectionDetails$5 = () => {
|
|
|
50382
51015
|
text: `${t(checkForNA(aText))}`
|
|
50383
51016
|
});
|
|
50384
51017
|
}), /*#__PURE__*/React__default.createElement(reactRouterDom.Link, {
|
|
50385
|
-
to: `/digit-ui/citizen/commonpt/view-property?propertyId=${(
|
|
51018
|
+
to: `/digit-ui/citizen/commonpt/view-property?propertyId=${(_state58 = state) === null || _state58 === void 0 ? void 0 : _state58.propertyId}&tenantId=${(_state59 = state) === null || _state59 === void 0 ? void 0 : _state59.tenantId}`
|
|
50386
51019
|
}, /*#__PURE__*/React__default.createElement(digitUiReactComponents.LinkButton, {
|
|
50387
51020
|
style: {
|
|
50388
51021
|
textAlign: "left",
|
|
@@ -50394,10 +51027,10 @@ const ConnectionDetails$5 = () => {
|
|
|
50394
51027
|
styles: {
|
|
50395
51028
|
fontSize: "28px"
|
|
50396
51029
|
}
|
|
50397
|
-
}, t("WS_COMMON_CONNECTION_HOLDER_DETAILS_HEADER")), (
|
|
51030
|
+
}, t("WS_COMMON_CONNECTION_HOLDER_DETAILS_HEADER")), (_state60 = state) !== null && _state60 !== void 0 && _state60.connectionHolders ? /*#__PURE__*/React__default.createElement("div", null, /*#__PURE__*/React__default.createElement(digitUiReactComponents.StatusTable, null, /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
|
|
50398
51031
|
className: "border-none",
|
|
50399
51032
|
label: t("WS_OWN_DETAIL_OWN_NAME_LABEL"),
|
|
50400
|
-
text: (
|
|
51033
|
+
text: (_state61 = state) === null || _state61 === void 0 ? void 0 : (_state61$connectionHo = _state61.connectionHolders) === null || _state61$connectionHo === void 0 ? void 0 : (_state61$connectionHo2 = _state61$connectionHo[0]) === null || _state61$connectionHo2 === void 0 ? void 0 : _state61$connectionHo2.name,
|
|
50401
51034
|
textStyle: {
|
|
50402
51035
|
whiteSpace: "pre"
|
|
50403
51036
|
}
|
|
@@ -50516,15 +51149,15 @@ const ConnectionDetails$5 = () => {
|
|
|
50516
51149
|
isArray: false
|
|
50517
51150
|
}
|
|
50518
51151
|
}
|
|
50519
|
-
}))) : /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardText, null, t("WS_PROPERTY_OWNER_SAME_AS_CONN_HOLDERS")), ((
|
|
50520
|
-
var _doc$documentType,
|
|
51152
|
+
}))) : /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardText, null, t("WS_PROPERTY_OWNER_SAME_AS_CONN_HOLDERS")), ((_state62 = state) === null || _state62 === void 0 ? void 0 : _state62.documents) && ((_state63 = state) === null || _state63 === void 0 ? void 0 : _state63.documents.map((doc, index) => {
|
|
51153
|
+
var _doc$documentType, _state64, _state65;
|
|
50521
51154
|
return /*#__PURE__*/React__default.createElement("div", {
|
|
50522
51155
|
key: `doc-${index}`
|
|
50523
51156
|
}, /*#__PURE__*/React__default.createElement("div", null, /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardSectionHeader, null, t(doc === null || doc === void 0 ? void 0 : (_doc$documentType = doc.documentType) === null || _doc$documentType === void 0 ? void 0 : _doc$documentType.split(".").slice(0, 2).join("_"))), /*#__PURE__*/React__default.createElement(digitUiReactComponents.StatusTable, null, /*#__PURE__*/React__default.createElement(WSDocument, {
|
|
50524
|
-
value: (
|
|
51157
|
+
value: (_state64 = state) === null || _state64 === void 0 ? void 0 : _state64.documents,
|
|
50525
51158
|
Code: doc === null || doc === void 0 ? void 0 : doc.documentType,
|
|
50526
51159
|
index: index
|
|
50527
|
-
}), ((
|
|
51160
|
+
}), ((_state65 = state) === null || _state65 === void 0 ? void 0 : _state65.documents.length) != index + 1 ? /*#__PURE__*/React__default.createElement("hr", {
|
|
50528
51161
|
style: {
|
|
50529
51162
|
color: "#cccccc",
|
|
50530
51163
|
backgroundColor: "#cccccc",
|
|
@@ -50533,7 +51166,7 @@ const ConnectionDetails$5 = () => {
|
|
|
50533
51166
|
marginBottom: "20px"
|
|
50534
51167
|
}
|
|
50535
51168
|
}) : null)));
|
|
50536
|
-
})), ((
|
|
51169
|
+
})), ((_state66 = state) === null || _state66 === void 0 ? void 0 : (_state66$status = _state66.status) === null || _state66$status === void 0 ? void 0 : _state66$status.toLowerCase()) === "inactive" || ((_state67 = state) === null || _state67 === void 0 ? void 0 : (_state67$applicationS = _state67.applicationStatus) === null || _state67$applicationS === void 0 ? void 0 : _state67$applicationS.toLowerCase()) === "inactive" || ((_state68 = state) === null || _state68 === void 0 ? void 0 : _state68.applicationStatus) === "DISCONNECTION_EXECUTED" || isDisconnectionDone ? /*#__PURE__*/React__default.createElement("div", {
|
|
50537
51170
|
style: {
|
|
50538
51171
|
display: "flex",
|
|
50539
51172
|
justifyContent: "flex-end",
|
|
@@ -50570,8 +51203,8 @@ const ConnectionDetails$5 = () => {
|
|
|
50570
51203
|
actionSingleLabel: t("COMMON_MAKE_PAYMENT"),
|
|
50571
51204
|
hideSubmit: true,
|
|
50572
51205
|
actionSingleSubmit: () => {
|
|
50573
|
-
var
|
|
50574
|
-
history.push(`/digit-ui/citizen/payment/collect/${isSW ? "SW" : "WS"}/${encodeURIComponent((
|
|
51206
|
+
var _state69, _state70;
|
|
51207
|
+
history.push(`/digit-ui/citizen/payment/collect/${isSW ? "SW" : "WS"}/${encodeURIComponent((_state69 = state) === null || _state69 === void 0 ? void 0 : _state69.connectionNo)}/${tenantId}?consumerCode=${(_state70 = state) === null || _state70 === void 0 ? void 0 : _state70.connectionNo}&&tenantId=${tenantId}&&workflow=WNS`);
|
|
50575
51208
|
setshowModal(false);
|
|
50576
51209
|
},
|
|
50577
51210
|
popupStyles: mobileView ? {
|
|
@@ -51969,7 +52602,7 @@ const EditApplication = _ref1 => {
|
|
|
51969
52602
|
});
|
|
51970
52603
|
const latestProperty = ptData === null || ptData === void 0 ? void 0 : (_ptData$Properties = ptData.Properties) === null || _ptData$Properties === void 0 ? void 0 : _ptData$Properties[0];
|
|
51971
52604
|
React.useEffect(() => {
|
|
51972
|
-
var _currentApp$additiona, _params$additionalDet, _params$additionalDet2, _currentApp$additiona2, _currentApp$auditDeta, _params$auditDetails, _params$auditDetails2, _currentApp$auditDeta2, _params$cpt3, _prevProp$auditDetail, _latestProperty$audit
|
|
52605
|
+
var _currentApp$additiona, _params$additionalDet, _params$additionalDet2, _currentApp$additiona2, _currentApp$auditDeta, _params$auditDetails, _params$auditDetails2, _currentApp$auditDeta2, _params$cpt3, _prevProp$auditDetail, _latestProperty$audit;
|
|
51973
52606
|
if (window.location.href.includes("/acknowledgement")) {
|
|
51974
52607
|
return;
|
|
51975
52608
|
}
|
|
@@ -51984,7 +52617,7 @@ const EditApplication = _ref1 => {
|
|
|
51984
52617
|
const isAuditChanged = (currentApp === null || currentApp === void 0 ? void 0 : (_currentApp$auditDeta = currentApp.auditDetails) === null || _currentApp$auditDeta === void 0 ? void 0 : _currentApp$auditDeta.lastModifiedTime) && (params === null || params === void 0 ? void 0 : (_params$auditDetails = params.auditDetails) === null || _params$auditDetails === void 0 ? void 0 : _params$auditDetails.lastModifiedTime) && (params === null || params === void 0 ? void 0 : (_params$auditDetails2 = params.auditDetails) === null || _params$auditDetails2 === void 0 ? void 0 : _params$auditDetails2.lastModifiedTime) !== (currentApp === null || currentApp === void 0 ? void 0 : (_currentApp$auditDeta2 = currentApp.auditDetails) === null || _currentApp$auditDeta2 === void 0 ? void 0 : _currentApp$auditDeta2.lastModifiedTime);
|
|
51985
52618
|
const isStatusChanged = (currentApp === null || currentApp === void 0 ? void 0 : currentApp.applicationStatus) && (params === null || params === void 0 ? void 0 : params.applicationStatus) && (params === null || params === void 0 ? void 0 : params.applicationStatus) !== (currentApp === null || currentApp === void 0 ? void 0 : currentApp.applicationStatus);
|
|
51986
52619
|
const prevProp = (params === null || params === void 0 ? void 0 : (_params$cpt3 = params.cpt) === null || _params$cpt3 === void 0 ? void 0 : _params$cpt3.details) || (params === null || params === void 0 ? void 0 : params.property);
|
|
51987
|
-
const isPropertyUpdated = latestProperty && (!prevProp || prevProp.propertyId !== latestProperty.propertyId || ((_prevProp$auditDetail = prevProp.auditDetails) === null || _prevProp$auditDetail === void 0 ? void 0 : _prevProp$auditDetail.lastModifiedTime) !== ((_latestProperty$audit = latestProperty.auditDetails) === null || _latestProperty$audit === void 0 ? void 0 : _latestProperty$audit.lastModifiedTime) || JSON.stringify(prevProp) !== JSON.stringify(latestProperty)
|
|
52620
|
+
const isPropertyUpdated = latestProperty && (!prevProp || prevProp.propertyId !== latestProperty.propertyId || ((_prevProp$auditDetail = prevProp.auditDetails) === null || _prevProp$auditDetail === void 0 ? void 0 : _prevProp$auditDetail.lastModifiedTime) !== ((_latestProperty$audit = latestProperty.auditDetails) === null || _latestProperty$audit === void 0 ? void 0 : _latestProperty$audit.lastModifiedTime) || JSON.stringify(prevProp) !== JSON.stringify(latestProperty) && prevProp.propertyId === latestProperty.propertyId);
|
|
51988
52621
|
if (isAppLoaded && (isNotHydrated || isDifferentApp || isSatisfiedChanged || isAuditChanged || isStatusChanged)) {
|
|
51989
52622
|
if (window.location.href.includes("edit-application")) {
|
|
51990
52623
|
if (waterapplication) {
|
|
@@ -52192,7 +52825,7 @@ const EditApplication = _ref1 => {
|
|
|
52192
52825
|
}
|
|
52193
52826
|
const propToSubmit = latestProperty || (params === null || params === void 0 ? void 0 : (_params$cpt4 = params.cpt) === null || _params$cpt4 === void 0 ? void 0 : _params$cpt4.details) || (params === null || params === void 0 ? void 0 : params.property);
|
|
52194
52827
|
if (propToSubmit) {
|
|
52195
|
-
var _propMapped$waterConn0, _params$
|
|
52828
|
+
var _propMapped$waterConn0, _params$waterConnecti, _params$WaterConnecti4, _params$WaterConnecti5, _params$SewerageConne4, _params$SewerageConne5;
|
|
52196
52829
|
const propMapped = mapPropertyToFormFields(propToSubmit);
|
|
52197
52830
|
params.property = propToSubmit;
|
|
52198
52831
|
params.cpt = {
|
|
@@ -52209,7 +52842,7 @@ const EditApplication = _ref1 => {
|
|
|
52209
52842
|
...(params.waterConnection || {}),
|
|
52210
52843
|
useDetails: {
|
|
52211
52844
|
...(((_propMapped$waterConn0 = propMapped.waterConnection) === null || _propMapped$waterConn0 === void 0 ? void 0 : _propMapped$waterConn0.useDetails) || {}),
|
|
52212
|
-
...(((_params$
|
|
52845
|
+
...(((_params$waterConnecti = params.waterConnection) === null || _params$waterConnecti === void 0 ? void 0 : _params$waterConnecti.useDetails) || {})
|
|
52213
52846
|
}
|
|
52214
52847
|
};
|
|
52215
52848
|
if (params !== null && params !== void 0 && (_params$WaterConnecti4 = params.WaterConnectionResult) !== null && _params$WaterConnecti4 !== void 0 && (_params$WaterConnecti5 = _params$WaterConnecti4.WaterConnection) !== null && _params$WaterConnecti5 !== void 0 && _params$WaterConnecti5[0]) {
|
|
@@ -52804,7 +53437,15 @@ const CheckPage = _ref => {
|
|
|
52804
53437
|
},
|
|
52805
53438
|
onClick: () => openFilePDF(djbEmployee === null || djbEmployee === void 0 ? void 0 : djbEmployee.document)
|
|
52806
53439
|
}, /*#__PURE__*/React__default.createElement(digitUiReactComponents.GenericFileIcon, null), " ", t("CS_COMMON_VIEW"))
|
|
52807
|
-
}))), /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardSubHeader, null, t("
|
|
53440
|
+
}))), /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardSubHeader, null, t("Rain Water Harvesting Certificate")), /*#__PURE__*/React__default.createElement(digitUiReactComponents.StatusTable, {
|
|
53441
|
+
style: {
|
|
53442
|
+
marginTop: "10px",
|
|
53443
|
+
marginBottom: "30px"
|
|
53444
|
+
}
|
|
53445
|
+
}, /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
|
|
53446
|
+
label: t("Rain Water Harvesting Certificate"),
|
|
53447
|
+
text: `${rainWaterHarvesting !== null && rainWaterHarvesting !== void 0 && rainWaterHarvesting.hasCertificate || rainWaterHarvesting !== null && rainWaterHarvesting !== void 0 && rainWaterHarvesting.isRainwaterHarvesting ? t("CORE_COMMON_YES") : t("CORE_COMMON_NO")}`
|
|
53448
|
+
})), /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardSubHeader, null, t("WS_BANK_DETAILS")), /*#__PURE__*/React__default.createElement(digitUiReactComponents.StatusTable, {
|
|
52808
53449
|
style: {
|
|
52809
53450
|
marginTop: "10px",
|
|
52810
53451
|
marginBottom: "30px"
|
|
@@ -52824,14 +53465,6 @@ const CheckPage = _ref => {
|
|
|
52824
53465
|
}), /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
|
|
52825
53466
|
label: t("WS_BANK_ACCOUNT_NO"),
|
|
52826
53467
|
text: `${t(checkForNA((bankDetails === null || bankDetails === void 0 ? void 0 : bankDetails.bankAccountNumber) || (bankDetails === null || bankDetails === void 0 ? void 0 : bankDetails.accountNumber)))}`
|
|
52827
|
-
})), /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardSubHeader, null, t("Rain Water Harvesting Certificate")), /*#__PURE__*/React__default.createElement(digitUiReactComponents.StatusTable, {
|
|
52828
|
-
style: {
|
|
52829
|
-
marginTop: "10px",
|
|
52830
|
-
marginBottom: "30px"
|
|
52831
|
-
}
|
|
52832
|
-
}, /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
|
|
52833
|
-
label: t("Rain Water Harvesting Certificate"),
|
|
52834
|
-
text: `${rainWaterHarvesting !== null && rainWaterHarvesting !== void 0 && rainWaterHarvesting.hasCertificate || rainWaterHarvesting !== null && rainWaterHarvesting !== void 0 && rainWaterHarvesting.isRainwaterHarvesting ? t("CORE_COMMON_YES") : t("CORE_COMMON_NO")}`
|
|
52835
53468
|
})), /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardSubHeader, null, t("WS_PROPERTY_AND_WATER_CONNECTION_USE_DETAILS")), /*#__PURE__*/React__default.createElement(digitUiReactComponents.StatusTable, {
|
|
52836
53469
|
style: {
|
|
52837
53470
|
marginTop: "10px",
|
|
@@ -53623,6 +54256,7 @@ const CheckPage$1 = () => {
|
|
|
53623
54256
|
location.href = jumpTo;
|
|
53624
54257
|
}
|
|
53625
54258
|
const [isEnableLoader, setIsEnableLoader] = React.useState(false);
|
|
54259
|
+
const [error, setError] = React.useState(null);
|
|
53626
54260
|
const {
|
|
53627
54261
|
isLoading: creatingWaterApplicationLoading,
|
|
53628
54262
|
isError: createWaterApplicationError,
|
|
@@ -53652,14 +54286,16 @@ const CheckPage$1 = () => {
|
|
|
53652
54286
|
mutate: sewerageUpdateMutation
|
|
53653
54287
|
} = Digit.Hooks.ws.useWSApplicationActions("SEWERAGE");
|
|
53654
54288
|
const closeToastOfError = () => {
|
|
53655
|
-
|
|
54289
|
+
setError(null);
|
|
53656
54290
|
};
|
|
53657
54291
|
const onSubmit = function (data) {
|
|
53658
54292
|
try {
|
|
53659
|
-
var
|
|
53660
|
-
const
|
|
54293
|
+
var _appData$service, _appData$connectionNo, _appData$applicationN, _value$connectionNo, _value$serviceType, _value$serviceType2, _appData$additionalDe, _appData$additionalDe2, _appData$connectionNo2;
|
|
54294
|
+
const appData = (value === null || value === void 0 ? void 0 : value.applicationData) || value || {};
|
|
54295
|
+
const isWater = (appData === null || appData === void 0 ? void 0 : appData.water) === true || (appData === null || appData === void 0 ? void 0 : (_appData$service = appData.service) === null || _appData$service === void 0 ? void 0 : _appData$service.toLowerCase()) === "water" || (appData === null || appData === void 0 ? void 0 : (_appData$connectionNo = appData.connectionNo) === null || _appData$connectionNo === void 0 ? void 0 : _appData$connectionNo.includes("WS")) || (appData === null || appData === void 0 ? void 0 : (_appData$applicationN = appData.applicationNo) === null || _appData$applicationN === void 0 ? void 0 : _appData$applicationN.includes("WS")) || (value === null || value === void 0 ? void 0 : (_value$connectionNo = value.connectionNo) === null || _value$connectionNo === void 0 ? void 0 : _value$connectionNo.includes("WS")) || (value === null || value === void 0 ? void 0 : (_value$serviceType = value.serviceType) === null || _value$serviceType === void 0 ? void 0 : _value$serviceType.toUpperCase()) === "WATER" || (value === null || value === void 0 ? void 0 : (_value$serviceType2 = value.serviceType) === null || _value$serviceType2 === void 0 ? void 0 : _value$serviceType2.toUpperCase()) === "WS" || (appData === null || appData === void 0 ? void 0 : (_appData$additionalDe = appData.additionalDetails) === null || _appData$additionalDe === void 0 ? void 0 : (_appData$additionalDe2 = _appData$additionalDe.serviceType) === null || _appData$additionalDe2 === void 0 ? void 0 : _appData$additionalDe2.code) === "WATER" || !(appData !== null && appData !== void 0 && (_appData$connectionNo2 = appData.connectionNo) !== null && _appData$connectionNo2 !== void 0 && _appData$connectionNo2.includes("SW"));
|
|
54296
|
+
const serviceType = isWater ? "WATER" : "SEWERAGE";
|
|
53661
54297
|
return Promise.resolve(createPayloadOfWSDisconnection(data, {
|
|
53662
|
-
applicationData:
|
|
54298
|
+
applicationData: appData
|
|
53663
54299
|
}, serviceType)).then(function (payload) {
|
|
53664
54300
|
const _temp4 = function (_payload$WaterConnect) {
|
|
53665
54301
|
if (payload !== null && payload !== void 0 && (_payload$WaterConnect = payload.WaterConnection) !== null && _payload$WaterConnect !== void 0 && _payload$WaterConnect.water) {
|
|
@@ -53842,7 +54478,11 @@ const CheckPage$1 = () => {
|
|
|
53842
54478
|
}, /*#__PURE__*/React__default.createElement(digitUiReactComponents.SubmitBar, {
|
|
53843
54479
|
label: t("CS_COMMON_SUBMIT"),
|
|
53844
54480
|
onSubmit: () => onSubmit(value === null || value === void 0 ? void 0 : value.WSDisconnectionForm)
|
|
53845
|
-
}))
|
|
54481
|
+
})), error && /*#__PURE__*/React__default.createElement(digitUiReactComponents.Toast, {
|
|
54482
|
+
error: (error === null || error === void 0 ? void 0 : error.key) === "error",
|
|
54483
|
+
label: t(error === null || error === void 0 ? void 0 : error.message),
|
|
54484
|
+
onClose: closeToastOfError
|
|
54485
|
+
})))));
|
|
53846
54486
|
};
|
|
53847
54487
|
|
|
53848
54488
|
const CheckPage$2 = () => {
|
|
@@ -53892,8 +54532,10 @@ const CheckPage$2 = () => {
|
|
|
53892
54532
|
};
|
|
53893
54533
|
const onSubmit = function (data) {
|
|
53894
54534
|
try {
|
|
53895
|
-
var
|
|
53896
|
-
const
|
|
54535
|
+
var _appData$service, _appData$connectionNo, _appData$applicationN, _value$connectionNo, _value$serviceType, _value$serviceType2, _appData$additionalDe, _appData$additionalDe2, _appData$connectionNo2;
|
|
54536
|
+
const appData = (value === null || value === void 0 ? void 0 : value.applicationData) || value || {};
|
|
54537
|
+
const isWater = (appData === null || appData === void 0 ? void 0 : appData.water) === true || (appData === null || appData === void 0 ? void 0 : (_appData$service = appData.service) === null || _appData$service === void 0 ? void 0 : _appData$service.toLowerCase()) === "water" || (appData === null || appData === void 0 ? void 0 : (_appData$connectionNo = appData.connectionNo) === null || _appData$connectionNo === void 0 ? void 0 : _appData$connectionNo.includes("WS")) || (appData === null || appData === void 0 ? void 0 : (_appData$applicationN = appData.applicationNo) === null || _appData$applicationN === void 0 ? void 0 : _appData$applicationN.includes("WS")) || (value === null || value === void 0 ? void 0 : (_value$connectionNo = value.connectionNo) === null || _value$connectionNo === void 0 ? void 0 : _value$connectionNo.includes("WS")) || (value === null || value === void 0 ? void 0 : (_value$serviceType = value.serviceType) === null || _value$serviceType === void 0 ? void 0 : _value$serviceType.toUpperCase()) === "WATER" || (value === null || value === void 0 ? void 0 : (_value$serviceType2 = value.serviceType) === null || _value$serviceType2 === void 0 ? void 0 : _value$serviceType2.toUpperCase()) === "WS" || (appData === null || appData === void 0 ? void 0 : (_appData$additionalDe = appData.additionalDetails) === null || _appData$additionalDe === void 0 ? void 0 : (_appData$additionalDe2 = _appData$additionalDe.serviceType) === null || _appData$additionalDe2 === void 0 ? void 0 : _appData$additionalDe2.code) === "WATER" || !(appData !== null && appData !== void 0 && (_appData$connectionNo2 = appData.connectionNo) !== null && _appData$connectionNo2 !== void 0 && _appData$connectionNo2.includes("SW"));
|
|
54538
|
+
const serviceType = isWater ? "WATER" : "SEWERAGE";
|
|
53897
54539
|
return Promise.resolve(createPayloadOfWSDisconnection(data, {
|
|
53898
54540
|
applicationData: value
|
|
53899
54541
|
}, serviceType)).then(function (payload) {
|
|
@@ -54104,7 +54746,7 @@ const CheckPage$2 = () => {
|
|
|
54104
54746
|
};
|
|
54105
54747
|
|
|
54106
54748
|
const CheckPage$3 = () => {
|
|
54107
|
-
var _value$
|
|
54749
|
+
var _value$applicationDat, _value$WSDisconnectio, _value$WSDisconnectio2, _value$WSDisconnectio3, _value$WSDisconnectio4, _value$WSDisconnectio5;
|
|
54108
54750
|
const {
|
|
54109
54751
|
t
|
|
54110
54752
|
} = reactI18next.useTranslation();
|
|
@@ -54136,8 +54778,10 @@ const CheckPage$3 = () => {
|
|
|
54136
54778
|
};
|
|
54137
54779
|
const onSubmit = function (data) {
|
|
54138
54780
|
try {
|
|
54139
|
-
var
|
|
54140
|
-
const
|
|
54781
|
+
var _appData$service, _appData$connectionNo, _appData$applicationN, _value$connectionNo, _value$serviceType, _value$serviceType2, _appData$additionalDe, _appData$additionalDe2, _appData$connectionNo2;
|
|
54782
|
+
const appData = (value === null || value === void 0 ? void 0 : value.applicationData) || value || {};
|
|
54783
|
+
const isWater = (appData === null || appData === void 0 ? void 0 : appData.water) === true || (appData === null || appData === void 0 ? void 0 : (_appData$service = appData.service) === null || _appData$service === void 0 ? void 0 : _appData$service.toLowerCase()) === "water" || (appData === null || appData === void 0 ? void 0 : (_appData$connectionNo = appData.connectionNo) === null || _appData$connectionNo === void 0 ? void 0 : _appData$connectionNo.includes("WS")) || (appData === null || appData === void 0 ? void 0 : (_appData$applicationN = appData.applicationNo) === null || _appData$applicationN === void 0 ? void 0 : _appData$applicationN.includes("WS")) || (value === null || value === void 0 ? void 0 : (_value$connectionNo = value.connectionNo) === null || _value$connectionNo === void 0 ? void 0 : _value$connectionNo.includes("WS")) || (value === null || value === void 0 ? void 0 : (_value$serviceType = value.serviceType) === null || _value$serviceType === void 0 ? void 0 : _value$serviceType.toUpperCase()) === "WATER" || (value === null || value === void 0 ? void 0 : (_value$serviceType2 = value.serviceType) === null || _value$serviceType2 === void 0 ? void 0 : _value$serviceType2.toUpperCase()) === "WS" || (appData === null || appData === void 0 ? void 0 : (_appData$additionalDe = appData.additionalDetails) === null || _appData$additionalDe === void 0 ? void 0 : (_appData$additionalDe2 = _appData$additionalDe.serviceType) === null || _appData$additionalDe2 === void 0 ? void 0 : _appData$additionalDe2.code) === "WATER" || !(appData !== null && appData !== void 0 && (_appData$connectionNo2 = appData.connectionNo) !== null && _appData$connectionNo2 !== void 0 && _appData$connectionNo2.includes("SW"));
|
|
54784
|
+
const serviceType = isWater ? "WATER" : "SEWERAGE";
|
|
54141
54785
|
return Promise.resolve(createPayloadOfWSReSubmitDisconnection(data, value, serviceType)).then(function (payload) {
|
|
54142
54786
|
const _temp4 = function (_payload$WaterConnect) {
|
|
54143
54787
|
if (payload !== null && payload !== void 0 && (_payload$WaterConnect = payload.WaterConnection) !== null && _payload$WaterConnect !== void 0 && _payload$WaterConnect.water) {
|
|
@@ -54261,7 +54905,7 @@ const CheckPage$3 = () => {
|
|
|
54261
54905
|
})), /*#__PURE__*/React__default.createElement(digitUiReactComponents.StatusTable, null, /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
|
|
54262
54906
|
className: "border-none",
|
|
54263
54907
|
label: t("WS_DISCONNECTION_CONSUMER_NUMBER"),
|
|
54264
|
-
text: value.connectionNo || (value === null || value === void 0 ? void 0 : (_value$
|
|
54908
|
+
text: value.connectionNo || (value === null || value === void 0 ? void 0 : (_value$applicationDat = value.applicationData) === null || _value$applicationDat === void 0 ? void 0 : _value$applicationDat.connectionNo)
|
|
54265
54909
|
}), /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
|
|
54266
54910
|
className: "border-none",
|
|
54267
54911
|
label: t("WS_DISCONNECTION_TYPE"),
|
|
@@ -56077,6 +56721,15 @@ const WSPropertyLocationDetails = props => {
|
|
|
56077
56721
|
};
|
|
56078
56722
|
const onSkip = () => onSelect();
|
|
56079
56723
|
const PropertyLocationDetails = Digit.ComponentRegistryService.getComponent("PropertyLocationDetails");
|
|
56724
|
+
const handleCitizenSelect = React__default.useCallback((key, details) => {
|
|
56725
|
+
setData(prev => {
|
|
56726
|
+
if (JSON.stringify(prev) === JSON.stringify(details)) return prev;
|
|
56727
|
+
return details;
|
|
56728
|
+
});
|
|
56729
|
+
if (typeof onSelect === "function") {
|
|
56730
|
+
onSelect(key, details);
|
|
56731
|
+
}
|
|
56732
|
+
}, [onSelect]);
|
|
56080
56733
|
if (userType === "citizen") {
|
|
56081
56734
|
return /*#__PURE__*/React__default.createElement("div", null, /*#__PURE__*/React__default.createElement(Timeline, {
|
|
56082
56735
|
currentStep: 2
|
|
@@ -56092,9 +56745,7 @@ const WSPropertyLocationDetails = props => {
|
|
|
56092
56745
|
marginBottom: "-30px"
|
|
56093
56746
|
}
|
|
56094
56747
|
}, /*#__PURE__*/React__default.createElement(PropertyLocationDetails, _extends({}, props, {
|
|
56095
|
-
onSelect:
|
|
56096
|
-
setData(details);
|
|
56097
|
-
}
|
|
56748
|
+
onSelect: handleCitizenSelect
|
|
56098
56749
|
})))));
|
|
56099
56750
|
}
|
|
56100
56751
|
return /*#__PURE__*/React__default.createElement(PropertyLocationDetails, props);
|
|
@@ -58340,10 +58991,31 @@ const NewApplication = () => {
|
|
|
58340
58991
|
}, /*#__PURE__*/React__default.createElement(reactHookForm.Controller, {
|
|
58341
58992
|
control: control,
|
|
58342
58993
|
name: "rainWaterHarvesting.hasCertificate",
|
|
58343
|
-
render: props => /*#__PURE__*/React__default.createElement(digitUiReactComponents.
|
|
58344
|
-
|
|
58345
|
-
|
|
58346
|
-
|
|
58994
|
+
render: props => /*#__PURE__*/React__default.createElement(digitUiReactComponents.RadioButtons, {
|
|
58995
|
+
className: "form-field",
|
|
58996
|
+
style: {
|
|
58997
|
+
display: "flex",
|
|
58998
|
+
gap: "2rem",
|
|
58999
|
+
alignItems: "center"
|
|
59000
|
+
},
|
|
59001
|
+
name: "rainWaterHarvestingRadio",
|
|
59002
|
+
options: [{
|
|
59003
|
+
i18nKey: "CORE_COMMON_YES",
|
|
59004
|
+
code: true
|
|
59005
|
+
}, {
|
|
59006
|
+
i18nKey: "CORE_COMMON_NO",
|
|
59007
|
+
code: false
|
|
59008
|
+
}],
|
|
59009
|
+
optionsKey: "i18nKey",
|
|
59010
|
+
selectedOption: props.value ? {
|
|
59011
|
+
i18nKey: "CORE_COMMON_YES",
|
|
59012
|
+
code: true
|
|
59013
|
+
} : {
|
|
59014
|
+
i18nKey: "CORE_COMMON_NO",
|
|
59015
|
+
code: false
|
|
59016
|
+
},
|
|
59017
|
+
onSelect: e => props.onChange(e.code),
|
|
59018
|
+
t: t
|
|
58347
59019
|
})
|
|
58348
59020
|
}))), /*#__PURE__*/React__default.createElement(SectionCard, {
|
|
58349
59021
|
description: t("WS_PROPERTY_ADDRESS_DESC"),
|
|
@@ -59364,118 +60036,6 @@ const NewApplication = () => {
|
|
|
59364
60036
|
}));
|
|
59365
60037
|
};
|
|
59366
60038
|
|
|
59367
|
-
const CheckIcon = () => /*#__PURE__*/React__default.createElement("svg", {
|
|
59368
|
-
width: "14",
|
|
59369
|
-
height: "14",
|
|
59370
|
-
viewBox: "0 0 24 24",
|
|
59371
|
-
fill: "none",
|
|
59372
|
-
stroke: "currentColor",
|
|
59373
|
-
strokeWidth: "3",
|
|
59374
|
-
strokeLinecap: "round",
|
|
59375
|
-
strokeLinejoin: "round"
|
|
59376
|
-
}, /*#__PURE__*/React__default.createElement("polyline", {
|
|
59377
|
-
points: "20 6 9 17 4 12"
|
|
59378
|
-
}));
|
|
59379
|
-
const ClockIcon = () => /*#__PURE__*/React__default.createElement("svg", {
|
|
59380
|
-
width: "14",
|
|
59381
|
-
height: "14",
|
|
59382
|
-
viewBox: "0 0 24 24",
|
|
59383
|
-
fill: "none",
|
|
59384
|
-
stroke: "currentColor",
|
|
59385
|
-
strokeWidth: "2",
|
|
59386
|
-
strokeLinecap: "round",
|
|
59387
|
-
strokeLinejoin: "round"
|
|
59388
|
-
}, /*#__PURE__*/React__default.createElement("circle", {
|
|
59389
|
-
cx: "12",
|
|
59390
|
-
cy: "12",
|
|
59391
|
-
r: "10"
|
|
59392
|
-
}), /*#__PURE__*/React__default.createElement("polyline", {
|
|
59393
|
-
className: "clock-hands2",
|
|
59394
|
-
points: "12 6 12 12 16 14"
|
|
59395
|
-
}));
|
|
59396
|
-
const WorkflowTimeline = _ref => {
|
|
59397
|
-
var _workflowDetails$data;
|
|
59398
|
-
let {
|
|
59399
|
-
workflowDetails,
|
|
59400
|
-
hideTimeline,
|
|
59401
|
-
setHideTimeline
|
|
59402
|
-
} = _ref;
|
|
59403
|
-
const {
|
|
59404
|
-
t
|
|
59405
|
-
} = reactI18next.useTranslation();
|
|
59406
|
-
const timeline = workflowDetails === null || workflowDetails === void 0 ? void 0 : (_workflowDetails$data = workflowDetails.data) === null || _workflowDetails$data === void 0 ? void 0 : _workflowDetails$data.processInstances;
|
|
59407
|
-
if (!timeline || timeline.length === 0) {
|
|
59408
|
-
return null;
|
|
59409
|
-
}
|
|
59410
|
-
const getStatusClass = (index, checkpoint) => {
|
|
59411
|
-
var _checkpoint$state, _checkpoint$state2, _checkpoint$state3, _checkpoint$state4;
|
|
59412
|
-
const isTerminal = (checkpoint === null || checkpoint === void 0 ? void 0 : (_checkpoint$state = checkpoint.state) === null || _checkpoint$state === void 0 ? void 0 : _checkpoint$state.state) === "CONNECTION_ACTIVATED" || (checkpoint === null || checkpoint === void 0 ? void 0 : (_checkpoint$state2 = checkpoint.state) === null || _checkpoint$state2 === void 0 ? void 0 : _checkpoint$state2.applicationStatus) === "CONNECTION_ACTIVATED" || (checkpoint === null || checkpoint === void 0 ? void 0 : (_checkpoint$state3 = checkpoint.state) === null || _checkpoint$state3 === void 0 ? void 0 : _checkpoint$state3.status) === "ACTIVE" || (checkpoint === null || checkpoint === void 0 ? void 0 : (_checkpoint$state4 = checkpoint.state) === null || _checkpoint$state4 === void 0 ? void 0 : _checkpoint$state4.isTerminateState);
|
|
59413
|
-
if (index === 0 && !isTerminal) return "current2";
|
|
59414
|
-
return "completed2";
|
|
59415
|
-
};
|
|
59416
|
-
const convertEpochToDateTime = epoch => {
|
|
59417
|
-
if (!epoch) return "N/A";
|
|
59418
|
-
const date = new Date(epoch);
|
|
59419
|
-
const day = String(date.getDate()).padStart(2, "0");
|
|
59420
|
-
const month = String(date.getMonth() + 1).padStart(2, "0");
|
|
59421
|
-
const year = date.getFullYear().toString().slice(-2);
|
|
59422
|
-
const hours = String(date.getHours()).padStart(2, "0");
|
|
59423
|
-
const minutes = String(date.getMinutes()).padStart(2, "0");
|
|
59424
|
-
return `${day}/${month}/${year} ${hours}:${minutes}`;
|
|
59425
|
-
};
|
|
59426
|
-
return /*#__PURE__*/React__default.createElement(digitUiReactComponents.Card, {
|
|
59427
|
-
className: "workflow-timeline-card2 digit-form-composer",
|
|
59428
|
-
style: {
|
|
59429
|
-
background: "#fff",
|
|
59430
|
-
padding: "16px",
|
|
59431
|
-
height: hideTimeline ? "100%" : ""
|
|
59432
|
-
}
|
|
59433
|
-
}, /*#__PURE__*/React__default.createElement("div", {
|
|
59434
|
-
className: `timeline-header-wrapper ${hideTimeline ? "collapsed" : ""}`
|
|
59435
|
-
}, /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardSubHeader, {
|
|
59436
|
-
style: {
|
|
59437
|
-
marginBottom: "0",
|
|
59438
|
-
fontSize: "16px",
|
|
59439
|
-
fontWeight: "700",
|
|
59440
|
-
color: "#374151"
|
|
59441
|
-
},
|
|
59442
|
-
className: hideTimeline ? "hidden-content" : ""
|
|
59443
|
-
}, t("WORKFLOW_TIMELINE"))), /*#__PURE__*/React__default.createElement("div", {
|
|
59444
|
-
className: hideTimeline ? "hidden-content" : "timeline-container2"
|
|
59445
|
-
}, timeline.map((checkpoint, index) => {
|
|
59446
|
-
var _checkpoint$auditDeta, _checkpoint$auditDeta2, _checkpoint$state5, _checkpoint$state6, _checkpoint$state7, _checkpoint$assigner, _checkpoint$assigner2;
|
|
59447
|
-
const statusClass = getStatusClass(index, checkpoint);
|
|
59448
|
-
const showLine = index !== timeline.length - 1 && timeline.length > 1;
|
|
59449
|
-
const epochTime = (checkpoint === null || checkpoint === void 0 ? void 0 : (_checkpoint$auditDeta = checkpoint.auditDetails) === null || _checkpoint$auditDeta === void 0 ? void 0 : _checkpoint$auditDeta.lastModifiedTime) || (checkpoint === null || checkpoint === void 0 ? void 0 : (_checkpoint$auditDeta2 = checkpoint.auditDetails) === null || _checkpoint$auditDeta2 === void 0 ? void 0 : _checkpoint$auditDeta2.createdTime);
|
|
59450
|
-
return /*#__PURE__*/React__default.createElement("div", {
|
|
59451
|
-
key: index,
|
|
59452
|
-
className: `timeline-item2 ${statusClass}`
|
|
59453
|
-
}, /*#__PURE__*/React__default.createElement("div", {
|
|
59454
|
-
className: "timeline-marker2"
|
|
59455
|
-
}, /*#__PURE__*/React__default.createElement("div", {
|
|
59456
|
-
className: "timeline-circle2"
|
|
59457
|
-
}, statusClass === "completed2" ? /*#__PURE__*/React__default.createElement(CheckIcon, null) : /*#__PURE__*/React__default.createElement(ClockIcon, null)), showLine && /*#__PURE__*/React__default.createElement("div", {
|
|
59458
|
-
className: "timeline-line2"
|
|
59459
|
-
})), /*#__PURE__*/React__default.createElement("div", {
|
|
59460
|
-
className: "timeline-content2"
|
|
59461
|
-
}, /*#__PURE__*/React__default.createElement("div", {
|
|
59462
|
-
className: "timeline-header2"
|
|
59463
|
-
}, /*#__PURE__*/React__default.createElement("div", {
|
|
59464
|
-
className: "timeline-title2"
|
|
59465
|
-
}, t(`WF_${checkpoint === null || checkpoint === void 0 ? void 0 : (_checkpoint$state5 = checkpoint.state) === null || _checkpoint$state5 === void 0 ? void 0 : _checkpoint$state5.state}`)), /*#__PURE__*/React__default.createElement("span", {
|
|
59466
|
-
className: "timeline-date2"
|
|
59467
|
-
}, convertEpochToDateTime(epochTime))), /*#__PURE__*/React__default.createElement("div", {
|
|
59468
|
-
className: "timeline-body2"
|
|
59469
|
-
}, /*#__PURE__*/React__default.createElement("div", {
|
|
59470
|
-
className: `timeline-status-tag2 status-${statusClass}`
|
|
59471
|
-
}, t((checkpoint === null || checkpoint === void 0 ? void 0 : (_checkpoint$state6 = checkpoint.state) === null || _checkpoint$state6 === void 0 ? void 0 : _checkpoint$state6.applicationStatus) || (checkpoint === null || checkpoint === void 0 ? void 0 : (_checkpoint$state7 = checkpoint.state) === null || _checkpoint$state7 === void 0 ? void 0 : _checkpoint$state7.state))), (checkpoint === null || checkpoint === void 0 ? void 0 : checkpoint.comment) && /*#__PURE__*/React__default.createElement("div", {
|
|
59472
|
-
className: "timeline-comment2"
|
|
59473
|
-
}, checkpoint.comment)), (checkpoint === null || checkpoint === void 0 ? void 0 : (_checkpoint$assigner = checkpoint.assigner) === null || _checkpoint$assigner === void 0 ? void 0 : _checkpoint$assigner.name) && /*#__PURE__*/React__default.createElement("div", {
|
|
59474
|
-
className: "timeline-footer2"
|
|
59475
|
-
}, /*#__PURE__*/React__default.createElement("span", null, t("ES_COMMON_ASSIGNED_TO"), ": ", /*#__PURE__*/React__default.createElement("strong", null, checkpoint === null || checkpoint === void 0 ? void 0 : (_checkpoint$assigner2 = checkpoint.assigner) === null || _checkpoint$assigner2 === void 0 ? void 0 : _checkpoint$assigner2.name)))));
|
|
59476
|
-
})));
|
|
59477
|
-
};
|
|
59478
|
-
|
|
59479
60039
|
const ApplicationDetails$1 = () => {
|
|
59480
60040
|
var _mdmsCommonmastersDat, _commonPayInfo, _applicationDetails$p4, _applicationDetails$p5, _applicationDetails$p6, _applicationDetails$p7, _applicationDetails$a3, _applicationDetails$a4, _applicationDetails$a5, _newValueFilter$, _applicationDetails$a6, _applicationDetails$a7, _applicationDetails$a8, _applicationDetails$a9, _workflowDetails$data, _workflowDetails$data2, _reciept_data$Payment, _applicationDetails$a0, _applicationDetails$p8, _applicationDetails$p9, _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$data23, _workflowDetails$data24, _workflowDetails$data25, _oldData$WaterConnect, _oldData$WaterConnect2, _oldData$SewerageConn, _oldData$SewerageConn2, _applicationDetails$a23, _applicationDetails$a24, _reciept_data$Payment3, _applicationDetails$p17, _applicationDetails$p18, _applicationDetails$p19, _applicationDetails$p20, _applicationDetails$p21, _applicationDetails$p22;
|
|
59481
60041
|
const getRecieptSearch = function (tenantId, payments, consumerCodes, receiptKey) {
|
|
@@ -67956,7 +68516,18 @@ const CheckPage$4 = _ref2 => {
|
|
|
67956
68516
|
},
|
|
67957
68517
|
onClick: () => openFilePDF(djbEmployee === null || djbEmployee === void 0 ? void 0 : djbEmployee.document)
|
|
67958
68518
|
}, /*#__PURE__*/React__default.createElement(digitUiReactComponents.GenericFileIcon, null), " ", t("CS_COMMON_VIEW"))
|
|
67959
|
-
})))), /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardSubHeader, null, t("
|
|
68519
|
+
})))), /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardSubHeader, null, t("Rain Water Harvesting Certificate")), /*#__PURE__*/React__default.createElement(digitUiReactComponents.StatusTable, {
|
|
68520
|
+
style: {
|
|
68521
|
+
marginTop: "10px",
|
|
68522
|
+
marginBottom: "30px"
|
|
68523
|
+
}
|
|
68524
|
+
}, /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
|
|
68525
|
+
label: t("Rain Water Harvesting Certificate"),
|
|
68526
|
+
text: rainWaterHarvesting !== null && rainWaterHarvesting !== void 0 && rainWaterHarvesting.hasCertificate || rainWaterHarvesting !== null && rainWaterHarvesting !== void 0 && rainWaterHarvesting.isRainwaterHarvesting ? t("CORE_COMMON_YES") : t("CORE_COMMON_NO"),
|
|
68527
|
+
actionButton: /*#__PURE__*/React__default.createElement(ActionButton$1, {
|
|
68528
|
+
onClick: onEdit
|
|
68529
|
+
})
|
|
68530
|
+
})), /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardSubHeader, null, t("WS_BANK_DETAILS")), /*#__PURE__*/React__default.createElement(digitUiReactComponents.StatusTable, {
|
|
67960
68531
|
style: {
|
|
67961
68532
|
marginTop: "10px",
|
|
67962
68533
|
marginBottom: "30px"
|
|
@@ -67976,17 +68547,6 @@ const CheckPage$4 = _ref2 => {
|
|
|
67976
68547
|
}), /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
|
|
67977
68548
|
label: t("WS_BANK_ACCOUNT_NO"),
|
|
67978
68549
|
text: `${t(checkForNA$1((bankDetails === null || bankDetails === void 0 ? void 0 : bankDetails.bankAccountNumber) || (bankDetails === null || bankDetails === void 0 ? void 0 : bankDetails.accountNumber)))}`
|
|
67979
|
-
})), /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardSubHeader, null, t("Rain Water Harvesting Certificate")), /*#__PURE__*/React__default.createElement(digitUiReactComponents.StatusTable, {
|
|
67980
|
-
style: {
|
|
67981
|
-
marginTop: "10px",
|
|
67982
|
-
marginBottom: "30px"
|
|
67983
|
-
}
|
|
67984
|
-
}, /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
|
|
67985
|
-
label: t("Rain Water Harvesting Certificate"),
|
|
67986
|
-
text: rainWaterHarvesting !== null && rainWaterHarvesting !== void 0 && rainWaterHarvesting.hasCertificate || rainWaterHarvesting !== null && rainWaterHarvesting !== void 0 && rainWaterHarvesting.isRainwaterHarvesting ? t("CORE_COMMON_YES") : t("CORE_COMMON_NO"),
|
|
67987
|
-
actionButton: /*#__PURE__*/React__default.createElement(ActionButton$1, {
|
|
67988
|
-
onClick: onEdit
|
|
67989
|
-
})
|
|
67990
68550
|
})), /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardSubHeader, null, t("PT_LOCATION_DETAILS")), /*#__PURE__*/React__default.createElement(digitUiReactComponents.StatusTable, {
|
|
67991
68551
|
style: {
|
|
67992
68552
|
marginTop: "10px",
|
|
@@ -68216,6 +68776,11 @@ const isRwhDoc = doc => {
|
|
|
68216
68776
|
const str = ((typeof doc === "string" ? doc : "") + " " + ((doc === null || doc === void 0 ? void 0 : doc.documentType) || "") + " " + ((doc === null || doc === void 0 ? void 0 : doc.code) || "") + " " + ((doc === null || doc === void 0 ? void 0 : doc.i18nKey) || "") + " " + ((doc === null || doc === void 0 ? void 0 : doc.name) || "") + " " + ((doc === null || doc === void 0 ? void 0 : doc.documentName) || "")).toUpperCase();
|
|
68217
68777
|
return str.includes("RAIN") || str.includes("HARVEST");
|
|
68218
68778
|
};
|
|
68779
|
+
const isStpDoc = doc => {
|
|
68780
|
+
if (!doc) return false;
|
|
68781
|
+
const str = ((typeof doc === "string" ? doc : "") + " " + ((doc === null || doc === void 0 ? void 0 : doc.documentType) || "") + " " + ((doc === null || doc === void 0 ? void 0 : doc.code) || "") + " " + ((doc === null || doc === void 0 ? void 0 : doc.i18nKey) || "") + " " + ((doc === null || doc === void 0 ? void 0 : doc.name) || "") + " " + ((doc === null || doc === void 0 ? void 0 : doc.documentName) || "")).toUpperCase();
|
|
68782
|
+
return str.includes("SEWER") || str.includes("SEWAGE") || str.includes("STP") || str.includes("TREATMENT");
|
|
68783
|
+
};
|
|
68219
68784
|
const OLDApplication = () => {
|
|
68220
68785
|
var _Digit$UserService$ge;
|
|
68221
68786
|
const {
|
|
@@ -68238,10 +68803,10 @@ const OLDApplication = () => {
|
|
|
68238
68803
|
label: "Are you a Divyangjan/Person with Disability?"
|
|
68239
68804
|
}, {
|
|
68240
68805
|
label: "WS_DJB_EMPLOYEE"
|
|
68241
|
-
}, {
|
|
68242
|
-
label: "WS_BANK_DETAILS"
|
|
68243
68806
|
}, {
|
|
68244
68807
|
label: "Rain Water Harvesting Certificate"
|
|
68808
|
+
}, {
|
|
68809
|
+
label: "WS_BANK_DETAILS"
|
|
68245
68810
|
}, {
|
|
68246
68811
|
label: "PT_LOCATION_DETAILS"
|
|
68247
68812
|
}, {
|
|
@@ -68315,7 +68880,7 @@ const OLDApplication = () => {
|
|
|
68315
68880
|
};
|
|
68316
68881
|
const configCopy = cloneDeep_1(foundConfig);
|
|
68317
68882
|
const allCreateSections = (configCopy === null || configCopy === void 0 ? void 0 : (_configCopy$body = configCopy.body) === null || _configCopy$body === void 0 ? void 0 : _configCopy$body.filter(section => section === null || section === void 0 ? void 0 : section.isCreateConnection)) || [];
|
|
68318
|
-
const desiredComponentOrder = ["CPTPropertySearchNSummary", "WSConnectionDetails", "WSConnectionHolderDetails", "WSDivyangjan", "WSDjbEmployee", "
|
|
68883
|
+
const desiredComponentOrder = ["CPTPropertySearchNSummary", "WSConnectionDetails", "WSConnectionHolderDetails", "WSDivyangjan", "WSDjbEmployee", "WSRainWaterHarvesting", "WSBankDetails", "WSPropertyLocationDetails", "PropertyWaterConnection", "WSActivationPlumberDetails", "WSRoadCuttingDetails", "WSDocumentsEmployee"];
|
|
68319
68884
|
const reorderedBody = [];
|
|
68320
68885
|
desiredComponentOrder.forEach(compName => {
|
|
68321
68886
|
const section = allCreateSections.find(s => {
|
|
@@ -68659,7 +69224,7 @@ const OLDApplication = () => {
|
|
|
68659
69224
|
};
|
|
68660
69225
|
const processSubmission = function (data) {
|
|
68661
69226
|
try {
|
|
68662
|
-
var _data$useDetails, _data$ConnectionDetai, _data$ConnectionDetai2, _data$DocumentsRequir, _data$djbEmployee, _data$djbEmployee$doc, _data$djbEmployee2, _data$djbEmployee3, _data$djbEmployee4, _data$DocumentsRequir2, _data$DocumentsRequir3, _data$DocumentsRequir4, _data$documents, _data$documents$docum, _data$documents$docum2, _data$cpt, _Digit$UserService$ge2, _data$ConnectionHolde, _data$ConnectionHolde2, _data$ConnectionHolde3, _data$ConnectionHolde4, _data$ConnectionHolde5, _propertyDetails$Prop9, _propertyDetails$Prop0, _propertyDetails$Prop1, _propertyDetails$Prop10, _data$ConnectionHolde6, _data$ConnectionHolde7, _data$cpt2, _data$cpt2$details, _data$cpt2$details$ow, _data$cpt2$details$ow2;
|
|
69227
|
+
var _data$useDetails, _data$ConnectionDetai, _data$ConnectionDetai2, _data$DocumentsRequir, _data$djbEmployee, _data$djbEmployee$doc, _data$djbEmployee2, _data$djbEmployee3, _data$djbEmployee4, _data$DocumentsRequir2, _data$DocumentsRequir3, _data$DocumentsRequir4, _data$documents, _data$documents$docum, _data$documents$docum2, _data$DocumentsRequir5, _data$documents2, _generalDocWithVal$ad, _data$documents3, _rwhDocFromList$addit, _stpDocFromList$addit, _data$cpt, _Digit$UserService$ge2, _data$ConnectionHolde, _data$ConnectionHolde2, _data$ConnectionHolde3, _data$ConnectionHolde4, _data$ConnectionHolde5, _propertyDetails$Prop9, _propertyDetails$Prop0, _propertyDetails$Prop1, _propertyDetails$Prop10, _data$ConnectionHolde6, _data$ConnectionHolde7, _data$cpt2, _data$cpt2$details, _data$cpt2$details$ow, _data$cpt2$details$ow2;
|
|
68663
69228
|
const basePath = window.location.href.includes("/employee") ? "/digit-ui/employee/ws" : "/digit-ui/citizen/ws";
|
|
68664
69229
|
if (data !== null && data !== void 0 && (_data$useDetails = data.useDetails) !== null && _data$useDetails !== void 0 && _data$useDetails.useDetails) {
|
|
68665
69230
|
data.useDetails = {
|
|
@@ -68700,6 +69265,7 @@ const OLDApplication = () => {
|
|
|
68700
69265
|
};
|
|
68701
69266
|
}
|
|
68702
69267
|
if (data !== null && data !== void 0 && (_data$DocumentsRequir = data.DocumentsRequired) !== null && _data$DocumentsRequir !== void 0 && _data$DocumentsRequir.documents) {
|
|
69268
|
+
var _docWithValidity$addi, _docWithValidity$addi2, _rwhDoc$additionalDet, _stpDoc$additionalDet;
|
|
68703
69269
|
const docs = data.DocumentsRequired.documents;
|
|
68704
69270
|
const identityDoc = docs.find(d => {
|
|
68705
69271
|
var _d$documentType8;
|
|
@@ -68713,11 +69279,25 @@ const OLDApplication = () => {
|
|
|
68713
69279
|
var _d$documentType1;
|
|
68714
69280
|
return d === null || d === void 0 ? void 0 : (_d$documentType1 = d.documentType) === null || _d$documentType1 === void 0 ? void 0 : _d$documentType1.includes("OTHERDOCUMENTS");
|
|
68715
69281
|
});
|
|
69282
|
+
const docWithValidity = docs.find(d => {
|
|
69283
|
+
var _d$additionalDetails, _d$additionalDetails2;
|
|
69284
|
+
return (d === null || d === void 0 ? void 0 : d.validityDate) || (d === null || d === void 0 ? void 0 : d.validityUpTo) || (d === null || d === void 0 ? void 0 : d.date) || (d === null || d === void 0 ? void 0 : (_d$additionalDetails = d.additionalDetails) === null || _d$additionalDetails === void 0 ? void 0 : _d$additionalDetails.validityDate) || (d === null || d === void 0 ? void 0 : (_d$additionalDetails2 = d.additionalDetails) === null || _d$additionalDetails2 === void 0 ? void 0 : _d$additionalDetails2.validityUpTo);
|
|
69285
|
+
});
|
|
69286
|
+
const valDate = (docWithValidity === null || docWithValidity === void 0 ? void 0 : docWithValidity.validityDate) || (docWithValidity === null || docWithValidity === void 0 ? void 0 : docWithValidity.validityUpTo) || (docWithValidity === null || docWithValidity === void 0 ? void 0 : docWithValidity.date) || (docWithValidity === null || docWithValidity === void 0 ? void 0 : (_docWithValidity$addi = docWithValidity.additionalDetails) === null || _docWithValidity$addi === void 0 ? void 0 : _docWithValidity$addi.validityDate) || (docWithValidity === null || docWithValidity === void 0 ? void 0 : (_docWithValidity$addi2 = docWithValidity.additionalDetails) === null || _docWithValidity$addi2 === void 0 ? void 0 : _docWithValidity$addi2.validityUpTo) || "";
|
|
69287
|
+
const rwhDoc = docs.find(d => isRwhDoc(d));
|
|
69288
|
+
const stpDoc = docs.find(d => isStpDoc(d));
|
|
69289
|
+
const rwhValDate = (rwhDoc === null || rwhDoc === void 0 ? void 0 : rwhDoc.validityDate) || (rwhDoc === null || rwhDoc === void 0 ? void 0 : rwhDoc.validityUpTo) || (rwhDoc === null || rwhDoc === void 0 ? void 0 : rwhDoc.date) || (rwhDoc === null || rwhDoc === void 0 ? void 0 : (_rwhDoc$additionalDet = rwhDoc.additionalDetails) === null || _rwhDoc$additionalDet === void 0 ? void 0 : _rwhDoc$additionalDet.validityDate) || "";
|
|
69290
|
+
const stpValDate = (stpDoc === null || stpDoc === void 0 ? void 0 : stpDoc.validityDate) || (stpDoc === null || stpDoc === void 0 ? void 0 : stpDoc.validityUpTo) || (stpDoc === null || stpDoc === void 0 ? void 0 : stpDoc.date) || (stpDoc === null || stpDoc === void 0 ? void 0 : (_stpDoc$additionalDet = stpDoc.additionalDetails) === null || _stpDoc$additionalDet === void 0 ? void 0 : _stpDoc$additionalDet.validityDate) || "";
|
|
68716
69291
|
data.documents = {
|
|
68717
69292
|
documents: docs,
|
|
68718
69293
|
identityProofNumber: (identityDoc === null || identityDoc === void 0 ? void 0 : identityDoc.documentUid) || "",
|
|
68719
69294
|
ownershipDocumentNumber: (ownershipDoc === null || ownershipDoc === void 0 ? void 0 : ownershipDoc.documentUid) || "",
|
|
68720
|
-
otherDocumentNumber: (otherDoc === null || otherDoc === void 0 ? void 0 : otherDoc.documentUid) || ""
|
|
69295
|
+
otherDocumentNumber: (otherDoc === null || otherDoc === void 0 ? void 0 : otherDoc.documentUid) || "",
|
|
69296
|
+
validityDate: valDate || undefined,
|
|
69297
|
+
validityUpTo: valDate || undefined,
|
|
69298
|
+
date: valDate || undefined,
|
|
69299
|
+
rwhValidityDate: rwhValDate || undefined,
|
|
69300
|
+
stpValidityDate: stpValDate || undefined
|
|
68721
69301
|
};
|
|
68722
69302
|
}
|
|
68723
69303
|
const djbDoc = (data === null || data === void 0 ? void 0 : (_data$djbEmployee = data.djbEmployee) === null || _data$djbEmployee === void 0 ? void 0 : (_data$djbEmployee$doc = _data$djbEmployee.document) === null || _data$djbEmployee$doc === void 0 ? void 0 : _data$djbEmployee$doc.fileStoreId) || typeof (data === null || data === void 0 ? void 0 : (_data$djbEmployee2 = data.djbEmployee) === null || _data$djbEmployee2 === void 0 ? void 0 : _data$djbEmployee2.document) === "string" && (data === null || data === void 0 ? void 0 : (_data$djbEmployee3 = data.djbEmployee) === null || _data$djbEmployee3 === void 0 ? void 0 : _data$djbEmployee3.document.trim()) || (data === null || data === void 0 ? void 0 : (_data$djbEmployee4 = data.djbEmployee) === null || _data$djbEmployee4 === void 0 ? void 0 : _data$djbEmployee4.document) || (data === null || data === void 0 ? void 0 : (_data$DocumentsRequir2 = data.DocumentsRequired) === null || _data$DocumentsRequir2 === void 0 ? void 0 : (_data$DocumentsRequir3 = _data$DocumentsRequir2.documents) === null || _data$DocumentsRequir3 === void 0 ? void 0 : (_data$DocumentsRequir4 = _data$DocumentsRequir3.find(d => {
|
|
@@ -68792,14 +69372,52 @@ const OLDApplication = () => {
|
|
|
68792
69372
|
};
|
|
68793
69373
|
}
|
|
68794
69374
|
}
|
|
69375
|
+
const docsList = (data === null || data === void 0 ? void 0 : (_data$DocumentsRequir5 = data.DocumentsRequired) === null || _data$DocumentsRequir5 === void 0 ? void 0 : _data$DocumentsRequir5.documents) || (data === null || data === void 0 ? void 0 : (_data$documents2 = data.documents) === null || _data$documents2 === void 0 ? void 0 : _data$documents2.documents) || (data === null || data === void 0 ? void 0 : data.documents) || [];
|
|
69376
|
+
const rwhDocFromList = Array.isArray(docsList) ? docsList.find(d => isRwhDoc(d)) : null;
|
|
69377
|
+
const stpDocFromList = Array.isArray(docsList) ? docsList.find(d => isStpDoc(d)) : null;
|
|
69378
|
+
const generalDocWithVal = Array.isArray(docsList) ? docsList.find(d => {
|
|
69379
|
+
var _d$additionalDetails3;
|
|
69380
|
+
return (d === null || d === void 0 ? void 0 : d.validityDate) || (d === null || d === void 0 ? void 0 : d.validityUpTo) || (d === null || d === void 0 ? void 0 : d.date) || (d === null || d === void 0 ? void 0 : (_d$additionalDetails3 = d.additionalDetails) === null || _d$additionalDetails3 === void 0 ? void 0 : _d$additionalDetails3.validityDate);
|
|
69381
|
+
}) : null;
|
|
69382
|
+
const extractedValDate = (generalDocWithVal === null || generalDocWithVal === void 0 ? void 0 : generalDocWithVal.validityDate) || (generalDocWithVal === null || generalDocWithVal === void 0 ? void 0 : generalDocWithVal.validityUpTo) || (generalDocWithVal === null || generalDocWithVal === void 0 ? void 0 : generalDocWithVal.date) || (generalDocWithVal === null || generalDocWithVal === void 0 ? void 0 : (_generalDocWithVal$ad = generalDocWithVal.additionalDetails) === null || _generalDocWithVal$ad === void 0 ? void 0 : _generalDocWithVal$ad.validityDate) || (data === null || data === void 0 ? void 0 : (_data$documents3 = data.documents) === null || _data$documents3 === void 0 ? void 0 : _data$documents3.validityDate) || "";
|
|
69383
|
+
const extractedRwhDate = (rwhDocFromList === null || rwhDocFromList === void 0 ? void 0 : rwhDocFromList.validityDate) || (rwhDocFromList === null || rwhDocFromList === void 0 ? void 0 : rwhDocFromList.validityUpTo) || (rwhDocFromList === null || rwhDocFromList === void 0 ? void 0 : rwhDocFromList.date) || (rwhDocFromList === null || rwhDocFromList === void 0 ? void 0 : (_rwhDocFromList$addit = rwhDocFromList.additionalDetails) === null || _rwhDocFromList$addit === void 0 ? void 0 : _rwhDocFromList$addit.validityDate) || extractedValDate;
|
|
69384
|
+
const extractedStpDate = (stpDocFromList === null || stpDocFromList === void 0 ? void 0 : stpDocFromList.validityDate) || (stpDocFromList === null || stpDocFromList === void 0 ? void 0 : stpDocFromList.validityUpTo) || (stpDocFromList === null || stpDocFromList === void 0 ? void 0 : stpDocFromList.date) || (stpDocFromList === null || stpDocFromList === void 0 ? void 0 : (_stpDocFromList$addit = stpDocFromList.additionalDetails) === null || _stpDocFromList$addit === void 0 ? void 0 : _stpDocFromList$addit.validityDate) || extractedValDate;
|
|
68795
69385
|
if (data !== null && data !== void 0 && data.rainWaterHarvesting) {
|
|
68796
69386
|
var _data$rainWaterHarves, _data$rainWaterHarves2, _data$rainWaterHarves3, _data$rainWaterHarves4;
|
|
68797
69387
|
data.additionalDetails = {
|
|
68798
69388
|
...data.additionalDetails,
|
|
68799
69389
|
...data.rainWaterHarvesting,
|
|
68800
69390
|
hasRainWaterHarvestingCertificate: !!(data !== null && data !== void 0 && (_data$rainWaterHarves = data.rainWaterHarvesting) !== null && _data$rainWaterHarves !== void 0 && _data$rainWaterHarves.hasCertificate || data !== null && data !== void 0 && (_data$rainWaterHarves2 = data.rainWaterHarvesting) !== null && _data$rainWaterHarves2 !== void 0 && _data$rainWaterHarves2.isRainwaterHarvesting),
|
|
68801
|
-
isRainwaterHarvesting: !!(data !== null && data !== void 0 && (_data$rainWaterHarves3 = data.rainWaterHarvesting) !== null && _data$rainWaterHarves3 !== void 0 && _data$rainWaterHarves3.hasCertificate || data !== null && data !== void 0 && (_data$rainWaterHarves4 = data.rainWaterHarvesting) !== null && _data$rainWaterHarves4 !== void 0 && _data$rainWaterHarves4.isRainwaterHarvesting)
|
|
69391
|
+
isRainwaterHarvesting: !!(data !== null && data !== void 0 && (_data$rainWaterHarves3 = data.rainWaterHarvesting) !== null && _data$rainWaterHarves3 !== void 0 && _data$rainWaterHarves3.hasCertificate || data !== null && data !== void 0 && (_data$rainWaterHarves4 = data.rainWaterHarvesting) !== null && _data$rainWaterHarves4 !== void 0 && _data$rainWaterHarves4.isRainwaterHarvesting),
|
|
69392
|
+
validityDate: extractedRwhDate || undefined,
|
|
69393
|
+
validityUpTo: extractedRwhDate || undefined,
|
|
69394
|
+
date: extractedRwhDate || undefined,
|
|
69395
|
+
rwhValidityDate: extractedRwhDate || undefined
|
|
68802
69396
|
};
|
|
69397
|
+
if (extractedRwhDate) {
|
|
69398
|
+
data.rainWaterHarvesting.validityDate = extractedRwhDate;
|
|
69399
|
+
data.rainWaterHarvesting.validityUpTo = extractedRwhDate;
|
|
69400
|
+
data.rainWaterHarvesting.date = extractedRwhDate;
|
|
69401
|
+
}
|
|
69402
|
+
}
|
|
69403
|
+
if (data !== null && data !== void 0 && data.sewerTreatmentPlant) {
|
|
69404
|
+
var _data$sewerTreatmentP, _data$sewerTreatmentP2, _data$sewerTreatmentP3, _data$sewerTreatmentP4, _data$sewerTreatmentP5, _data$sewerTreatmentP6, _data$sewerTreatmentP7, _data$sewerTreatmentP8, _data$sewerTreatmentP9;
|
|
69405
|
+
data.additionalDetails = {
|
|
69406
|
+
...data.additionalDetails,
|
|
69407
|
+
...data.sewerTreatmentPlant,
|
|
69408
|
+
hasSewerTreatmentPlant: !!(data !== null && data !== void 0 && (_data$sewerTreatmentP = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP !== void 0 && _data$sewerTreatmentP.hasCertificate || data !== null && data !== void 0 && (_data$sewerTreatmentP2 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP2 !== void 0 && _data$sewerTreatmentP2.hasStp || data !== null && data !== void 0 && (_data$sewerTreatmentP3 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP3 !== void 0 && _data$sewerTreatmentP3.isSewerTreatmentPlant),
|
|
69409
|
+
isSewerTreatmentPlant: !!(data !== null && data !== void 0 && (_data$sewerTreatmentP4 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP4 !== void 0 && _data$sewerTreatmentP4.hasCertificate || data !== null && data !== void 0 && (_data$sewerTreatmentP5 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP5 !== void 0 && _data$sewerTreatmentP5.hasStp || data !== null && data !== void 0 && (_data$sewerTreatmentP6 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP6 !== void 0 && _data$sewerTreatmentP6.isSewerTreatmentPlant),
|
|
69410
|
+
hasStp: !!(data !== null && data !== void 0 && (_data$sewerTreatmentP7 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP7 !== void 0 && _data$sewerTreatmentP7.hasCertificate || data !== null && data !== void 0 && (_data$sewerTreatmentP8 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP8 !== void 0 && _data$sewerTreatmentP8.hasStp || data !== null && data !== void 0 && (_data$sewerTreatmentP9 = data.sewerTreatmentPlant) !== null && _data$sewerTreatmentP9 !== void 0 && _data$sewerTreatmentP9.isSewerTreatmentPlant),
|
|
69411
|
+
validityDate: extractedStpDate || undefined,
|
|
69412
|
+
validityUpTo: extractedStpDate || undefined,
|
|
69413
|
+
date: extractedStpDate || undefined,
|
|
69414
|
+
stpValidityDate: extractedStpDate || undefined
|
|
69415
|
+
};
|
|
69416
|
+
if (extractedStpDate) {
|
|
69417
|
+
data.sewerTreatmentPlant.validityDate = extractedStpDate;
|
|
69418
|
+
data.sewerTreatmentPlant.validityUpTo = extractedStpDate;
|
|
69419
|
+
data.sewerTreatmentPlant.date = extractedStpDate;
|
|
69420
|
+
}
|
|
68803
69421
|
}
|
|
68804
69422
|
if (data !== null && data !== void 0 && data.bankDetails) {
|
|
68805
69423
|
const normalizedBank = getNormalizedBankDetails(data);
|
|
@@ -69749,6 +70367,7 @@ const componentsToRegister = {
|
|
|
69749
70367
|
WSOLDApplication: OLDApplication,
|
|
69750
70368
|
WSDivyangjan: WSDivyangjan,
|
|
69751
70369
|
WSRainWaterHarvesting: WSRainWaterHarvesting,
|
|
70370
|
+
WSSewerTreatmentPlant: WSSewerTreatmentPlant,
|
|
69752
70371
|
WSExecuteDisconnection: WSExecuteDisconnection,
|
|
69753
70372
|
WSFieldInspection: WSFieldInspection
|
|
69754
70373
|
};
|