@djb25/digit-ui-module-ws 1.0.101 → 1.0.102

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 CHANGED
@@ -507,35 +507,31 @@ const getPattern = type => {
507
507
  };
508
508
  const getFiles = function (filesArray, tenant) {
509
509
  try {
510
- return Promise.resolve(Digit.UploadServices.Filefetch(filesArray, tenant)).then(function (response) {
511
- var _response$data, _response$data$fileSt, _response$data$fileSt2, _response$data2, _response$data2$fileS, _response$data2$fileS2;
512
- response !== null && response !== void 0 && (_response$data = response.data) !== null && _response$data !== void 0 && (_response$data$fileSt = _response$data.fileStoreIds) !== null && _response$data$fileSt !== void 0 && (_response$data$fileSt2 = _response$data$fileSt[0]) !== null && _response$data$fileSt2 !== void 0 && _response$data$fileSt2.url ? window.open(response === null || response === void 0 ? void 0 : (_response$data2 = response.data) === null || _response$data2 === void 0 ? void 0 : (_response$data2$fileS = _response$data2.fileStoreIds) === null || _response$data2$fileS === void 0 ? void 0 : (_response$data2$fileS2 = _response$data2$fileS[0]) === null || _response$data2$fileS2 === void 0 ? void 0 : _response$data2$fileS2.url) : null;
513
- const _temp3 = _catch(function () {
514
- return Promise.resolve(Digit.UploadServices.Filefetch(filesArray, tenant)).then(function (response) {
515
- var _response$data3, _response$data3$fileS, _response$data3$fileS2, _response$data4;
516
- if (response !== null && response !== void 0 && (_response$data3 = response.data) !== null && _response$data3 !== void 0 && (_response$data3$fileS = _response$data3.fileStoreIds) !== null && _response$data3$fileS !== void 0 && (_response$data3$fileS2 = _response$data3$fileS[0]) !== null && _response$data3$fileS2 !== void 0 && _response$data3$fileS2.url) {
517
- window.open(response.data.fileStoreIds[0].url);
518
- } else if (response !== null && response !== void 0 && (_response$data4 = response.data) !== null && _response$data4 !== void 0 && _response$data4[filesArray === null || filesArray === void 0 ? void 0 : filesArray[0]]) {
519
- let linkText = response.data[filesArray[0]];
520
- let fileURL = "";
521
- if (linkText && typeof linkText == "string") {
522
- const linkList = linkText.split(",");
523
- linkList.forEach(link => {
524
- if (!link.includes("large") && !link.includes("medium") && !link.includes("small")) {
525
- fileURL = link;
526
- }
527
- });
528
- }
529
- if (fileURL) {
530
- window.open(fileURL);
531
- }
510
+ const _temp3 = _catch(function () {
511
+ return Promise.resolve(Digit.UploadServices.Filefetch(filesArray, tenant)).then(function (response) {
512
+ var _response$data, _response$data$fileSt, _response$data$fileSt2, _response$data2;
513
+ if (response !== null && response !== void 0 && (_response$data = response.data) !== null && _response$data !== void 0 && (_response$data$fileSt = _response$data.fileStoreIds) !== null && _response$data$fileSt !== void 0 && (_response$data$fileSt2 = _response$data$fileSt[0]) !== null && _response$data$fileSt2 !== void 0 && _response$data$fileSt2.url) {
514
+ window.open(response.data.fileStoreIds[0].url);
515
+ } else if (response !== null && response !== void 0 && (_response$data2 = response.data) !== null && _response$data2 !== void 0 && _response$data2[filesArray === null || filesArray === void 0 ? void 0 : filesArray[0]]) {
516
+ let linkText = response.data[filesArray[0]];
517
+ let fileURL = "";
518
+ if (linkText && typeof linkText == "string") {
519
+ const linkList = linkText.split(",");
520
+ linkList.forEach(link => {
521
+ if (!link.includes("large") && !link.includes("medium") && !link.includes("small")) {
522
+ fileURL = link;
523
+ }
524
+ });
532
525
  }
533
- });
534
- }, function (error) {
535
- console.error("Error fetching file URL", error);
526
+ if (fileURL) {
527
+ window.open(fileURL);
528
+ }
529
+ }
536
530
  });
537
- if (_temp3 && _temp3.then) return _temp3.then(function () {});
531
+ }, function (error) {
532
+ console.error("Error fetching file URL", error);
538
533
  });
534
+ return Promise.resolve(_temp3 && _temp3.then ? _temp3.then(function () {}) : void 0);
539
535
  } catch (e) {
540
536
  return Promise.reject(e);
541
537
  }
@@ -735,7 +731,7 @@ const updatePayloadOfWS = function (data, type) {
735
731
  },
736
732
  documents: JSON.parse(sessionStorage.getItem("WS_DOCUMENTS_INOF") && sessionStorage.getItem("WS_DOCUMENTS_INOF") !== "undefined" ? sessionStorage.getItem("WS_DOCUMENTS_INOF") : "null"),
737
733
  property: JSON.parse(sessionStorage.getItem("WS_PROPERTY_INOF") && sessionStorage.getItem("WS_PROPERTY_INOF") !== "undefined" ? sessionStorage.getItem("WS_PROPERTY_INOF") : "null"),
738
- connectionType: type === "WATER" ? (data === null || data === void 0 ? void 0 : data.connectionType) || "Permanent" : "Non Metered",
734
+ connectionType: type === "WATER" ? (data === null || data === void 0 ? void 0 : data.connectionType) === "Permanent" ? "Metered" : (data === null || data === void 0 ? void 0 : data.connectionType) || "Metered" : "Non Metered",
739
735
  additionalDetails: {
740
736
  ...(data === null || data === void 0 ? void 0 : data.additionalDetails),
741
737
  connectionType: (data === null || data === void 0 ? void 0 : (_data$additionalDetai = data.additionalDetails) === null || _data$additionalDetai === void 0 ? void 0 : _data$additionalDetai.connectionType) || "Permanent",
@@ -12910,6 +12906,7 @@ const WSPlumberPreference = _ref => {
12910
12906
  };
12911
12907
 
12912
12908
  const WSActivationDetails = _ref => {
12909
+ var _formData$activationD;
12913
12910
  let {
12914
12911
  t,
12915
12912
  config,
@@ -12917,20 +12914,39 @@ const WSActivationDetails = _ref => {
12917
12914
  formData,
12918
12915
  onSelect
12919
12916
  } = _ref;
12917
+ const initialData = Array.isArray(formData === null || formData === void 0 ? void 0 : formData.activationDetails) ? formData === null || formData === void 0 ? void 0 : (_formData$activationD = formData.activationDetails) === null || _formData$activationD === void 0 ? void 0 : _formData$activationD[0] : (formData === null || formData === void 0 ? void 0 : formData.activationDetails) || {};
12920
12918
  const [activationDetails, setActivationDetails] = React__default.useState({
12921
- meterId: "",
12922
- meterInstallationDate: "",
12923
- meterInitialReading: "",
12924
- connectionExecutionDate: ""
12919
+ meterId: (initialData === null || initialData === void 0 ? void 0 : initialData.meterId) || "",
12920
+ meterInstallationDate: (initialData === null || initialData === void 0 ? void 0 : initialData.meterInstallationDate) || "",
12921
+ meterInitialReading: "0",
12922
+ connectionExecutionDate: (initialData === null || initialData === void 0 ? void 0 : initialData.connectionExecutionDate) || ""
12925
12923
  });
12926
12924
  React__default.useEffect(() => {
12927
- });
12928
- return /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement(digitUiReactComponents.LabelFieldPair, null, /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardLabel, {
12929
- className: "card-label-smaller",
12930
- style: {
12931
- fontWeight: "700"
12925
+ var _formData$activationD2;
12926
+ const actData = Array.isArray(formData === null || formData === void 0 ? void 0 : formData.activationDetails) ? formData === null || formData === void 0 ? void 0 : (_formData$activationD2 = formData.activationDetails) === null || _formData$activationD2 === void 0 ? void 0 : _formData$activationD2[0] : formData === null || formData === void 0 ? void 0 : formData.activationDetails;
12927
+ if (actData) {
12928
+ setActivationDetails(prev => {
12929
+ const nextState = {
12930
+ meterId: actData.meterId !== undefined ? actData.meterId : prev.meterId,
12931
+ meterInstallationDate: actData.meterInstallationDate !== undefined ? actData.meterInstallationDate : prev.meterInstallationDate,
12932
+ meterInitialReading: "0",
12933
+ connectionExecutionDate: actData.connectionExecutionDate !== undefined ? actData.connectionExecutionDate : prev.connectionExecutionDate
12934
+ };
12935
+ if (prev.meterId === nextState.meterId && prev.meterInstallationDate === nextState.meterInstallationDate && prev.meterInitialReading === nextState.meterInitialReading && prev.connectionExecutionDate === nextState.connectionExecutionDate) {
12936
+ return prev;
12937
+ }
12938
+ return nextState;
12939
+ });
12932
12940
  }
12933
- }, `${t(`WS_METER_ID`)}`), /*#__PURE__*/React__default.createElement("div", {
12941
+ }, [formData === null || formData === void 0 ? void 0 : formData.activationDetails]);
12942
+ React__default.useEffect(() => {
12943
+ if (onSelect && config !== null && config !== void 0 && config.key) {
12944
+ onSelect(config.key, [activationDetails]);
12945
+ }
12946
+ }, [activationDetails]);
12947
+ return /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement(digitUiReactComponents.LabelFieldPair, null, /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardLabel, null, `${t(`WS_METER_ID`)}`, /*#__PURE__*/React__default.createElement("span", {
12948
+ className: "check-page-link-button"
12949
+ }, " *")), /*#__PURE__*/React__default.createElement("div", {
12934
12950
  className: "field"
12935
12951
  }, /*#__PURE__*/React__default.createElement(digitUiReactComponents.TextInput, {
12936
12952
  t: t,
@@ -12938,51 +12954,48 @@ const WSActivationDetails = _ref => {
12938
12954
  optionKey: "i18nKey",
12939
12955
  name: "meterId",
12940
12956
  value: activationDetails.meterId,
12957
+ placeholder: `${t(`WS_METER_ID_PLACEHOLDER`)}`,
12941
12958
  onChange: ev => {
12942
12959
  setActivationDetails({
12943
12960
  ...activationDetails,
12944
12961
  meterId: ev.target.value
12945
12962
  });
12946
12963
  }
12947
- }))), /*#__PURE__*/React__default.createElement(digitUiReactComponents.LabelFieldPair, null, /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardLabel, {
12948
- className: "card-label-smaller",
12949
- style: {
12950
- fontWeight: "700"
12951
- }
12952
- }, `${t(`WS_METER_INSTALLATION_DATE`)}`), /*#__PURE__*/React__default.createElement("div", {
12964
+ }))), /*#__PURE__*/React__default.createElement(digitUiReactComponents.LabelFieldPair, null, /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardLabel, null, `${t(`WS_METER_INSTALLATION_DATE`)}`, /*#__PURE__*/React__default.createElement("span", {
12965
+ className: "check-page-link-button"
12966
+ }, " *")), /*#__PURE__*/React__default.createElement("div", {
12953
12967
  className: "field"
12954
12968
  }, /*#__PURE__*/React__default.createElement(digitUiReactComponents.DatePicker, {
12955
12969
  date: activationDetails.meterInstallationDate,
12970
+ placeholder: `${t(`WS_METER_INSTALLATION_DATE_PLACEHOLDER`)}`,
12956
12971
  onChange: date => {
12957
12972
  setActivationDetails({
12958
12973
  ...activationDetails,
12959
12974
  meterInstallationDate: date
12960
12975
  });
12961
12976
  }
12962
- }))), /*#__PURE__*/React__default.createElement(digitUiReactComponents.LabelFieldPair, null, /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardLabel, {
12963
- className: "card-label-smaller",
12964
- style: {
12965
- fontWeight: "700"
12966
- }
12967
- }, `${t(`WS_INIT_METER_READING`)}`), /*#__PURE__*/React__default.createElement("div", {
12977
+ }))), /*#__PURE__*/React__default.createElement(digitUiReactComponents.LabelFieldPair, null, /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardLabel, null, `${t(`WS_INIT_METER_READING`)}`, /*#__PURE__*/React__default.createElement("span", {
12978
+ className: "check-page-link-button"
12979
+ }, " *")), /*#__PURE__*/React__default.createElement("div", {
12968
12980
  className: "field"
12969
12981
  }, /*#__PURE__*/React__default.createElement(digitUiReactComponents.TextInput, {
12970
- value: activationDetails.meterInitialReading,
12982
+ value: activationDetails.meterInitialReading || "0",
12983
+ disabled: true,
12984
+ disable: true,
12985
+ placeholder: `${t(`WS_INIT_METER_READING_PLACEHOLDER`)}`,
12971
12986
  onChange: ev => {
12972
12987
  setActivationDetails({
12973
12988
  ...activationDetails,
12974
- meterInitialReading: ev.target.value
12989
+ meterInitialReading: "0"
12975
12990
  });
12976
12991
  }
12977
- }))), /*#__PURE__*/React__default.createElement(digitUiReactComponents.LabelFieldPair, null, /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardLabel, {
12978
- className: "card-label-smaller",
12979
- style: {
12980
- fontWeight: "700"
12981
- }
12982
- }, `${t(`WS_CONN_EXEC_DATE`)}`), /*#__PURE__*/React__default.createElement("div", {
12992
+ }))), /*#__PURE__*/React__default.createElement(digitUiReactComponents.LabelFieldPair, null, /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardLabel, null, `${t(`WS_CONN_EXEC_DATE`)}`, /*#__PURE__*/React__default.createElement("span", {
12993
+ className: "check-page-link-button"
12994
+ }, " *")), /*#__PURE__*/React__default.createElement("div", {
12983
12995
  className: "field"
12984
12996
  }, /*#__PURE__*/React__default.createElement(digitUiReactComponents.DatePicker, {
12985
12997
  date: activationDetails.connectionExecutionDate,
12998
+ placeholder: `${t(`WS_CONN_EXEC_DATE_PLACEHOLDER`)}`,
12986
12999
  onChange: date => {
12987
13000
  setActivationDetails({
12988
13001
  ...activationDetails,
@@ -13435,7 +13448,7 @@ const ConnectionDetails = _props => {
13435
13448
  placeholder: t("Select Applicant Type")
13436
13449
  });
13437
13450
  }
13438
- })), window.location.href.includes("/citizen") && /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement(digitUiReactComponents.LabelFieldPair, null, /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardLabel, null, t("Address Type"), /*#__PURE__*/React__default.createElement("span", {
13451
+ })), window.location.href.includes("/citizen") && /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement(digitUiReactComponents.LabelFieldPair, null, /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardLabel, null, t("WS_Billing_Address_Type"), /*#__PURE__*/React__default.createElement("span", {
13439
13452
  className: "check-page-link-button"
13440
13453
  }, "*")), /*#__PURE__*/React__default.createElement(reactHookForm.Controller, {
13441
13454
  control: control,
@@ -15860,11 +15873,13 @@ const createConnectionDetails$1 = service => service == "WATER" ? {
15860
15873
  i18nKey: "WS_CONNECTIONTYPE_METERED",
15861
15874
  name: "Metered"
15862
15875
  },
15863
- noOfTaps: "",
15864
- waterSource: "",
15865
- pipeSize: "",
15876
+ noOfTaps: 0,
15877
+ waterSource: "GROUND.WELL",
15878
+ pipeSize: 0,
15866
15879
  waterSubSource: "",
15867
- sourceSubData: ""
15880
+ sourceSubData: "",
15881
+ proposedPipeSize: 0,
15882
+ proposedTaps: 0
15868
15883
  } : {
15869
15884
  noOfWaterClosets: "",
15870
15885
  noOfToilets: ""
@@ -15885,7 +15900,7 @@ const WSActivationConnectionDetails = _ref => {
15885
15900
  const {
15886
15901
  pathname
15887
15902
  } = reactRouterDom.useLocation();
15888
- const filters = getQueryStringParams(location.search);
15903
+ const filters = getQueryStringParams(window.location.search);
15889
15904
  const [connectionDetails, setConnectionDetails] = React.useState(() => {
15890
15905
  var _formData$connectionD, _filters$service, _filters$service2, _filters$service3;
15891
15906
  let details = window.location.href.includes("modify") ? formData !== null && formData !== void 0 && formData.connectionDetails ? [formData === null || formData === void 0 ? void 0 : (_formData$connectionD = formData.connectionDetails) === null || _formData$connectionD === void 0 ? void 0 : _formData$connectionD[0]] : [createConnectionDetails$1(filters === null || filters === void 0 ? void 0 : (_filters$service = filters.service) === null || _filters$service === void 0 ? void 0 : _filters$service.toUpperCase())] : (formData === null || formData === void 0 ? void 0 : formData.connectionDetails) || [createConnectionDetails$1(filters === null || filters === void 0 ? void 0 : (_filters$service2 = filters.service) === null || _filters$service2 === void 0 ? void 0 : _filters$service2.toUpperCase())];
@@ -16370,6 +16385,7 @@ const PlumberDetails = _props => {
16370
16385
  selected: getValues("detailsProvidedBy"),
16371
16386
  disable: false,
16372
16387
  option: options,
16388
+ placeholder: `${t(`WS_ADDN_DETAILS_PLUMBER_PROVIDED_BY_PLACEHOLDER`)}`,
16373
16389
  errorStyle: localFormState.touched.detailsProvidedBy && errors !== null && errors !== void 0 && (_errors$detailsProvid = errors.detailsProvidedBy) !== null && _errors$detailsProvid !== void 0 && _errors$detailsProvid.message ? true : false,
16374
16390
  select: e => {
16375
16391
  if (e.code == "ULB") {
@@ -16427,7 +16443,8 @@ const PlumberDetails = _props => {
16427
16443
  labelStyle: {
16428
16444
  marginTop: "unset"
16429
16445
  },
16430
- onBlur: props.onBlur
16446
+ onBlur: props.onBlur,
16447
+ placeholder: `${t(`WS_PLIMBER_LICENSE_NO_PLACEHOLDER`)}`
16431
16448
  });
16432
16449
  }
16433
16450
  })), localFormState.touched.plumberLicenseNo && errors !== null && errors !== void 0 && (_errors$plumberLicens2 = errors.plumberLicenseNo) !== null && _errors$plumberLicens2 !== void 0 && _errors$plumberLicens2.message ? /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardLabelError, {
@@ -16463,7 +16480,8 @@ const PlumberDetails = _props => {
16463
16480
  labelStyle: {
16464
16481
  marginTop: "unset"
16465
16482
  },
16466
- onBlur: props.onBlur
16483
+ onBlur: props.onBlur,
16484
+ placeholder: `${t(`WS_ADDN_DETAILS_PLUMBER_NAME_PLACEHOLDER`)}`
16467
16485
  });
16468
16486
  }
16469
16487
  })), localFormState.touched.plumberName && errors !== null && errors !== void 0 && (_errors$plumberName2 = errors.plumberName) !== null && _errors$plumberName2 !== void 0 && _errors$plumberName2.message ? /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardLabelError, {
@@ -16519,7 +16537,8 @@ const PlumberDetails = _props => {
16519
16537
  labelStyle: {
16520
16538
  marginTop: "unset"
16521
16539
  },
16522
- onBlur: props.onBlur
16540
+ onBlur: props.onBlur,
16541
+ placeholder: `${t(`WS_PLUMBER_MOBILE_NO_PLACEHOLDER`)}`
16523
16542
  }), /*#__PURE__*/React__default.createElement("div", {
16524
16543
  style: isMobile && isEmployee ? {} : {
16525
16544
  marginRight: "-50px",
@@ -16977,7 +16996,9 @@ const WSActivationSupportingDocuments = _ref => {
16977
16996
  });
16978
16997
  }
16979
16998
  }, [uploadedFile]);
16980
- return /*#__PURE__*/React__default.createElement("div", null, /*#__PURE__*/React__default.createElement(digitUiReactComponents.LabelFieldPair, null, /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardLabel, null, t(`WF_APPROVAL_UPLOAD_HEAD`), ":"), /*#__PURE__*/React__default.createElement("div", {
16999
+ return /*#__PURE__*/React__default.createElement("div", null, /*#__PURE__*/React__default.createElement(digitUiReactComponents.LabelFieldPair, null, /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardLabel, null, t(`WF_APPROVAL_UPLOAD_HEAD`), /*#__PURE__*/React__default.createElement("span", {
17000
+ className: "check-page-link-button"
17001
+ }, " *"), ":"), /*#__PURE__*/React__default.createElement("div", {
16981
17002
  className: "field"
16982
17003
  }, /*#__PURE__*/React__default.createElement(digitUiReactComponents.UploadFile, {
16983
17004
  onUpload: e => {
@@ -16995,7 +17016,8 @@ const WSActivationSupportingDocuments = _ref => {
16995
17016
  },
16996
17017
  buttonType: "button",
16997
17018
  accept: "image/*, .pdf, .png, .jpeg, .jpg",
16998
- iserror: error
17019
+ iserror: error,
17020
+ isMandatory: true
16999
17021
  }))));
17000
17022
  };
17001
17023
 
@@ -18604,7 +18626,7 @@ const removeDuplicateOtherDocuments = function (documentList) {
18604
18626
  });
18605
18627
  };
18606
18628
  const WSDocumentsEmployee = _ref => {
18607
- var _applicationDetailsDa, _applicationDetailsDa2, _wsDocs$wsDocsData3, _wsDocs$wsDocsData3$f, _formData$ConnectionD, _formData$ConnectionD2, _formData$ConnectionD3;
18629
+ var _formData$ConnectionD, _formData$ConnectionD2, _formData$ConnectionD3, _formData$application, _formData$application2, _formData$connectionH, _formData$connectionH2, _formData$connectionH3, _formData$connectionH4, _formData$connectionH5, _applicationDetailsDa, _applicationDetailsDa2, _wsDocs$wsDocsData3, _wsDocs$wsDocsData3$f;
18608
18630
  let {
18609
18631
  t,
18610
18632
  config,
@@ -18616,6 +18638,7 @@ const WSDocumentsEmployee = _ref => {
18616
18638
  formState
18617
18639
  } = _ref;
18618
18640
  const tenantId = Digit.ULBService.getCurrentTenantId();
18641
+ const isTenant = (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$ConnectionD3 = _formData$ConnectionD2.applicantType) === null || _formData$ConnectionD3 === void 0 ? void 0 : _formData$ConnectionD3.code) === "TENANT" || (formData === null || formData === void 0 ? void 0 : (_formData$application = formData.applicationSelection) === null || _formData$application === void 0 ? void 0 : (_formData$application2 = _formData$application.applicantType) === null || _formData$application2 === void 0 ? void 0 : _formData$application2.code) === "TENANT" || (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) === "TENANT" || (formData === null || formData === void 0 ? void 0 : (_formData$connectionH3 = formData.connectionHolders) === null || _formData$connectionH3 === void 0 ? void 0 : (_formData$connectionH4 = _formData$connectionH3[0]) === null || _formData$connectionH4 === void 0 ? void 0 : (_formData$connectionH5 = _formData$connectionH4.applicantType) === null || _formData$connectionH5 === void 0 ? void 0 : _formData$connectionH5.code) === "TENANT";
18619
18642
  const [documents, setDocuments] = React.useState(() => {
18620
18643
  var _formData$documents, _formData$DocumentsRe;
18621
18644
  return removeDuplicateOtherDocuments(userType === "citizen" ? (formData === null || formData === void 0 ? void 0 : (_formData$documents = formData.documents) === null || _formData$documents === void 0 ? void 0 : _formData$documents.documents) || (formData === null || formData === void 0 ? void 0 : formData.documents) || [] : (formData === null || formData === void 0 ? void 0 : (_formData$DocumentsRe = formData.DocumentsRequired) === null || _formData$DocumentsRe === void 0 ? void 0 : _formData$DocumentsRe.documents) || []);
@@ -18701,9 +18724,18 @@ const WSDocumentsEmployee = _ref => {
18701
18724
  const innerContent = /*#__PURE__*/React__default.createElement("div", {
18702
18725
  className: "formcomposer-section-grid ws-doc-upload"
18703
18726
  }, wsDocs === null || wsDocs === void 0 ? void 0 : (_wsDocs$wsDocsData3 = wsDocs[wsDocsData]) === null || _wsDocs$wsDocsData3 === void 0 ? void 0 : (_wsDocs$wsDocsData3$f = _wsDocs$wsDocsData3.filter(doc => doc.code !== "OWNER.APPLICANTPHOTO")) === null || _wsDocs$wsDocsData3$f === void 0 ? void 0 : _wsDocs$wsDocsData3$f.map((document, index) => {
18727
+ let modifiedDocument = {
18728
+ ...document
18729
+ };
18730
+ if (!isTenant && modifiedDocument.dropdownData) {
18731
+ modifiedDocument.dropdownData = modifiedDocument.dropdownData.filter(opt => {
18732
+ const code = opt.code || "";
18733
+ return !(code.includes("NOC_FROM_OWNER") || code === "NOC from Owner");
18734
+ });
18735
+ }
18704
18736
  return /*#__PURE__*/React__default.createElement(SelectDocument, {
18705
18737
  key: index,
18706
- document: document,
18738
+ document: modifiedDocument,
18707
18739
  action: action,
18708
18740
  t: t,
18709
18741
  id: `pt-document-${index}`,
@@ -18719,7 +18751,6 @@ const WSDocumentsEmployee = _ref => {
18719
18751
  isOtherDocument: isOtherDocument(document === null || document === void 0 ? void 0 : document.code)
18720
18752
  });
18721
18753
  }));
18722
- const isTenant = (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$ConnectionD3 = _formData$ConnectionD2.applicantType) === null || _formData$ConnectionD3 === void 0 ? void 0 : _formData$ConnectionD3.code) === "TENANT";
18723
18754
  const nocDownloadSection = isTenant ? /*#__PURE__*/React__default.createElement("div", {
18724
18755
  style: {
18725
18756
  marginBottom: "20px",
@@ -18778,7 +18809,7 @@ const WSDocumentsEmployee = _ref => {
18778
18809
  }));
18779
18810
  };
18780
18811
  function SelectDocument(_ref2) {
18781
- var _formData$application, _formData$application2, _formData$application3, _formData$ConnectionD4, _formData$ConnectionD5, _formData$ConnectionD6, _formData$ConnectionD7, _doc$i18nKey, _selectedDocument$cod2, _selectedDocument$cod3, _selectedDocument$cod4, _selectedDocument$cod5, _selectedDocument$cod6, _selectedDocument$cod7, _selectedDocument$cod8, _selectedDocument$cod9, _selectedDocument$cod0, _selectedDocument$cod1, _selectedDocument$cod10, _selectedDocument$cod11, _selectedDocument$cod12, _selectedDocument$cod13, _selectedDocument$cod14, _selectedDocument$cod15, _doc$i18nKey2;
18812
+ var _formData$application3, _formData$application4, _formData$application5, _formData$ConnectionD4, _formData$ConnectionD5, _formData$ConnectionD6, _formData$ConnectionD7, _doc$i18nKey, _selectedDocument$cod2, _selectedDocument$cod3, _selectedDocument$cod4, _selectedDocument$cod5, _selectedDocument$cod6, _selectedDocument$cod7, _selectedDocument$cod8, _selectedDocument$cod9, _selectedDocument$cod0, _selectedDocument$cod1, _selectedDocument$cod10, _selectedDocument$cod11, _selectedDocument$cod12, _selectedDocument$cod13, _selectedDocument$cod14, _selectedDocument$cod15, _doc$i18nKey2;
18782
18813
  let {
18783
18814
  t,
18784
18815
  document: doc,
@@ -18797,9 +18828,10 @@ function SelectDocument(_ref2) {
18797
18828
  isOtherDocument: isOther = false
18798
18829
  } = _ref2;
18799
18830
  const fileRef = React.useRef();
18831
+ const pendingId = React.useRef(Date.now());
18800
18832
  const otherUploadedDocuments = isOther ? (documents === null || documents === void 0 ? void 0 : documents.filter(item => {
18801
18833
  var _item$documentType;
18802
- return item === null || item === void 0 ? void 0 : (_item$documentType = item.documentType) === null || _item$documentType === void 0 ? void 0 : _item$documentType.includes(doc === null || doc === void 0 ? void 0 : doc.code);
18834
+ return (item === null || item === void 0 ? void 0 : (_item$documentType = item.documentType) === null || _item$documentType === void 0 ? void 0 : _item$documentType.includes(doc === null || doc === void 0 ? void 0 : doc.code)) && (item === null || item === void 0 ? void 0 : item.tempId) !== pendingId.current;
18803
18835
  })) || [] : [];
18804
18836
  const filteredDocument = isOther ? null : documents === null || documents === void 0 ? void 0 : documents.filter(item => {
18805
18837
  var _item$documentType2;
@@ -18930,13 +18962,13 @@ function SelectDocument(_ref2) {
18930
18962
  dropdownData
18931
18963
  } = doc;
18932
18964
  var dropDownData = dropdownData;
18933
- const applicantTypeVal = (formData === null || formData === void 0 ? void 0 : (_formData$application = formData.applicationSelection) === null || _formData$application === void 0 ? void 0 : _formData$application.applicantType) || (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) || (formData === null || formData === void 0 ? void 0 : (_formData$ConnectionD4 = formData.ConnectionDetails) === null || _formData$ConnectionD4 === void 0 ? void 0 : _formData$ConnectionD4.applicantType) || (formData === null || formData === void 0 ? void 0 : (_formData$ConnectionD5 = formData.ConnectionDetails) === null || _formData$ConnectionD5 === void 0 ? void 0 : (_formData$ConnectionD6 = _formData$ConnectionD5[0]) === null || _formData$ConnectionD6 === void 0 ? void 0 : _formData$ConnectionD6.applicantType);
18965
+ const applicantTypeVal = (formData === null || formData === void 0 ? void 0 : (_formData$application3 = formData.applicationSelection) === null || _formData$application3 === void 0 ? void 0 : _formData$application3.applicantType) || (formData === null || formData === void 0 ? void 0 : (_formData$application4 = formData.applicationSelection) === null || _formData$application4 === void 0 ? void 0 : (_formData$application5 = _formData$application4[0]) === null || _formData$application5 === void 0 ? void 0 : _formData$application5.applicantType) || (formData === null || formData === void 0 ? void 0 : (_formData$ConnectionD4 = formData.ConnectionDetails) === null || _formData$ConnectionD4 === void 0 ? void 0 : _formData$ConnectionD4.applicantType) || (formData === null || formData === void 0 ? void 0 : (_formData$ConnectionD5 = formData.ConnectionDetails) === null || _formData$ConnectionD5 === void 0 ? void 0 : (_formData$ConnectionD6 = _formData$ConnectionD5[0]) === null || _formData$ConnectionD6 === void 0 ? void 0 : _formData$ConnectionD6.applicantType);
18934
18966
  const applicantTypeCode = typeof applicantTypeVal === "object" ? applicantTypeVal === null || applicantTypeVal === void 0 ? void 0 : applicantTypeVal.code : applicantTypeVal;
18935
- if (isOther && applicantTypeCode === "TENANT") {
18967
+ if (isOther && applicantTypeCode !== "TENANT") {
18936
18968
  var _dropDownData;
18937
18969
  dropDownData = (_dropDownData = dropDownData) === null || _dropDownData === void 0 ? void 0 : _dropDownData.filter(d => {
18938
18970
  var _d$code;
18939
- return d.code === "OWNER.OTHERDOCUMENTS.NOC_FROM_OWNER" || ((_d$code = d.code) === null || _d$code === void 0 ? void 0 : _d$code.includes("NOC_FROM_OWNER"));
18971
+ return d.code !== "OWNER.OTHERDOCUMENTS.NOC_FROM_OWNER" && !((_d$code = d.code) !== null && _d$code !== void 0 && _d$code.includes("NOC_FROM_OWNER"));
18940
18972
  });
18941
18973
  }
18942
18974
  const [isHidden, setHidden] = React.useState(false);
@@ -18968,13 +19000,19 @@ function SelectDocument(_ref2) {
18968
19000
  }
18969
19001
  };
18970
19002
  React.useEffect(() => {
18971
- if (selectedDocument !== null && selectedDocument !== void 0 && selectedDocument.code && !isOther) {
19003
+ if (selectedDocument !== null && selectedDocument !== void 0 && selectedDocument.code) {
18972
19004
  setDocuments(prev => {
18973
- const filteredDocumentsByDocumentType = prev === null || prev === void 0 ? void 0 : prev.filter(item => (item === null || item === void 0 ? void 0 : item.documentType) !== (selectedDocument === null || selectedDocument === void 0 ? void 0 : selectedDocument.code));
19005
+ var _filteredDocumentsByD;
19006
+ let filteredDocumentsByDocumentType = prev || [];
19007
+ if (!isOther) {
19008
+ filteredDocumentsByDocumentType = filteredDocumentsByDocumentType.filter(item => (item === null || item === void 0 ? void 0 : item.documentType) !== (selectedDocument === null || selectedDocument === void 0 ? void 0 : selectedDocument.code));
19009
+ } else {
19010
+ filteredDocumentsByDocumentType = filteredDocumentsByDocumentType.filter(item => (item === null || item === void 0 ? void 0 : item.tempId) !== pendingId.current);
19011
+ }
18974
19012
  if ((uploadedFile === null || uploadedFile === void 0 ? void 0 : uploadedFile.length) === 0 || uploadedFile === null) {
18975
- return isOther ? prev : filteredDocumentsByDocumentType;
19013
+ return filteredDocumentsByDocumentType;
18976
19014
  }
18977
- const filteredDocumentsByFileStoreId = filteredDocumentsByDocumentType === null || filteredDocumentsByDocumentType === void 0 ? void 0 : filteredDocumentsByDocumentType.filter(item => (item === null || item === void 0 ? void 0 : item.fileStoreId) !== uploadedFile);
19015
+ const filteredDocumentsByFileStoreId = (_filteredDocumentsByD = filteredDocumentsByDocumentType) === null || _filteredDocumentsByD === void 0 ? void 0 : _filteredDocumentsByD.filter(item => (item === null || item === void 0 ? void 0 : item.fileStoreId) !== uploadedFile);
18978
19016
  const data = [...filteredDocumentsByFileStoreId, {
18979
19017
  documentType: selectedDocument === null || selectedDocument === void 0 ? void 0 : selectedDocument.code,
18980
19018
  fileStoreId: uploadedFile,
@@ -18984,7 +19022,8 @@ function SelectDocument(_ref2) {
18984
19022
  documentNumber: documentUid,
18985
19023
  i18nKey: selectedDocument === null || selectedDocument === void 0 ? void 0 : selectedDocument.code,
18986
19024
  id: selectedDocument === null || selectedDocument === void 0 ? void 0 : selectedDocument.id,
18987
- status: "ACTIVE"
19025
+ status: "ACTIVE",
19026
+ tempId: isOther ? pendingId.current : undefined
18988
19027
  }];
18989
19028
  sessionStorage.setItem("DISCONNECTION_EDIT_DOCS", JSON.stringify(data));
18990
19029
  return data;
@@ -19305,21 +19344,7 @@ function SelectDocument(_ref2) {
19305
19344
  setError(docNumberError);
19306
19345
  return;
19307
19346
  }
19308
- setDocuments(prev => {
19309
- const data = [...(prev || []), {
19310
- documentType: selectedDocument === null || selectedDocument === void 0 ? void 0 : selectedDocument.code,
19311
- fileStoreId: uploadedFile,
19312
- fileName: (file === null || file === void 0 ? void 0 : file.name) || (filteredDocument === null || filteredDocument === void 0 ? void 0 : filteredDocument.fileName) || "",
19313
- documentName: (selectedDocument === null || selectedDocument === void 0 ? void 0 : selectedDocument.i18nKey) || (selectedDocument === null || selectedDocument === void 0 ? void 0 : selectedDocument.code) || "",
19314
- documentUid: documentUid,
19315
- documentNumber: documentUid,
19316
- i18nKey: selectedDocument === null || selectedDocument === void 0 ? void 0 : selectedDocument.code,
19317
- id: selectedDocument === null || selectedDocument === void 0 ? void 0 : selectedDocument.id,
19318
- status: "ACTIVE"
19319
- }];
19320
- sessionStorage.setItem("DISCONNECTION_EDIT_DOCS", JSON.stringify(data));
19321
- return data;
19322
- });
19347
+ pendingId.current = Date.now();
19323
19348
  setUploadedFile(null);
19324
19349
  setFile(null);
19325
19350
  setSelectedDocument(doc !== null && doc !== void 0 && doc.hasDropdown ? {} : doc);
@@ -25491,7 +25516,7 @@ const DECIMAL_PATTERN$1 = /^\d+(\.\d{1,2})?$/;
25491
25516
  const normalizeCode = value => String(value || "").replace(/[._\s-]/g, "").toUpperCase();
25492
25517
  const getCode = value => typeof value === "object" ? (value === null || value === void 0 ? void 0 : value.code) || (value === null || value === void 0 ? void 0 : value.value) : value;
25493
25518
  const PropertyWaterConnection = _ref => {
25494
- var _formData$cpt3, _errors$useDetails, _errors$useDetails2, _errors$useDetails3, _errors$useDetails4, _errors$useDetails5, _errors$useDetails6, _errors$useDetails7, _errors$useDetails8, _errors$useDetails9, _errors$useDetails0, _errors$useDetails1, _errors$useDetails10, _errors$useDetails11, _errors$useDetails12;
25519
+ var _formData$cpt3, _errors$useDetails, _errors$useDetails2, _errors$useDetails3, _errors$useDetails4, _errors$useDetails5, _errors$useDetails6, _errors$useDetails7, _errors$useDetails8, _errors$useDetails9, _errors$useDetails0, _errors$useDetails1, _errors$useDetails10, _errors$useDetails11;
25495
25520
  let {
25496
25521
  t,
25497
25522
  config,
@@ -25533,7 +25558,7 @@ const PropertyWaterConnection = _ref => {
25533
25558
  const tenantId = Digit.ULBService.getCurrentTenantId();
25534
25559
  const {
25535
25560
  data: ptServicesMastersData
25536
- } = Digit.Hooks.pt.usePropertyMDMS(tenantId, "PropertyTax", ["PropertyCategory", "PropertyType", "NoOfFloors", "PropertyNewUsageType", "PropertyToUsageMapping"]);
25561
+ } = Digit.Hooks.pt.usePropertyMDMS(tenantId, "PropertyTax", ["PropertyCategory", "PropertyType", "NoOfFloors", "PropertyNewUsageType", "PropertyToUsageMapping", "PropertyType2"]);
25537
25562
  const {
25538
25563
  data: wsServicesMastersData
25539
25564
  } = Digit.Hooks.ws.useMDMS(tenantId, "ws-services-masters", ["WsCategoryType"]);
@@ -25542,8 +25567,20 @@ const PropertyWaterConnection = _ref => {
25542
25567
  React.useEffect(() => {
25543
25568
  var _wsServicesMastersDat;
25544
25569
  const categories = (wsServicesMastersData === null || wsServicesMastersData === void 0 ? void 0 : (_wsServicesMastersDat = wsServicesMastersData["ws-services-masters"]) === null || _wsServicesMastersDat === void 0 ? void 0 : _wsServicesMastersDat.WsCategoryType) || [];
25545
- categories.forEach(data => data.i18nKey = data.i18nKey || `WS_CATEGORY_${data.code}`);
25546
- setCategoryTypeList(categories);
25570
+ if (categories.length > 0) {
25571
+ categories.forEach(data => data.i18nKey = data.i18nKey || `WS_CATEGORY_${data.code}`);
25572
+ setCategoryTypeList(categories);
25573
+ } else {
25574
+ setCategoryTypeList([{
25575
+ code: "DOMESTIC",
25576
+ name: "Domestic",
25577
+ i18nKey: "WS_CATEGORY_DOMESTIC"
25578
+ }, {
25579
+ code: "NON_DOMESTIC",
25580
+ name: "Non-Domestic",
25581
+ i18nKey: "WS_CATEGORY_NON_DOMESTIC"
25582
+ }]);
25583
+ }
25547
25584
  }, [wsServicesMastersData]);
25548
25585
  const isPropertyFound = window.location.href.includes("ws/old-application") || window.location.href.includes("/edit-application");
25549
25586
  React.useEffect(() => {
@@ -25563,7 +25600,6 @@ const PropertyWaterConnection = _ref => {
25563
25600
  const isSchoolCollegeProperty = (watchPropertyType === null || watchPropertyType === void 0 ? void 0 : watchPropertyType.code) === "School" || (watchPropertyType === null || watchPropertyType === void 0 ? void 0 : watchPropertyType.code) === "College";
25564
25601
  const dwellingPropertyTypes = ["Apartment", "DDAFlats", "GovtFlats", "Bungalows", "FlatOrApartment", "GroupHousingSociety", "JJSLUMS", "IndividualHouse"];
25565
25602
  const isDwellingUnit = dwellingPropertyTypes.includes(watchPropertyType === null || watchPropertyType === void 0 ? void 0 : watchPropertyType.code);
25566
- const isServentHouse = dwellingPropertyTypes.includes(watchPropertyType === null || watchPropertyType === void 0 ? void 0 : watchPropertyType.code);
25567
25603
  const yearOptions = React.useMemo(() => {
25568
25604
  const currentYear = new Date().getFullYear();
25569
25605
  const years = [];
@@ -25577,76 +25613,68 @@ const PropertyWaterConnection = _ref => {
25577
25613
  }, []);
25578
25614
  const categoryOptions = React.useMemo(() => {
25579
25615
  var _ptServicesMastersDat, _ptServicesMastersDat2;
25580
- if (!(watchCategoryType !== null && watchCategoryType !== void 0 && watchCategoryType.code)) return [];
25581
25616
  let options = (ptServicesMastersData === null || ptServicesMastersData === void 0 ? void 0 : (_ptServicesMastersDat = ptServicesMastersData.PropertyTax) === null || _ptServicesMastersDat === void 0 ? void 0 : (_ptServicesMastersDat2 = _ptServicesMastersDat.PropertyCategory) === null || _ptServicesMastersDat2 === void 0 ? void 0 : _ptServicesMastersDat2.filter(item => item.active)) || [];
25582
- options = options.filter(item => normalizeCode(item.type) === normalizeCode(watchCategoryType.code));
25583
25617
  return options.map(item => ({
25584
25618
  code: item.code,
25585
25619
  name: item.name
25586
25620
  }));
25587
- }, [ptServicesMastersData, watchCategoryType]);
25588
- React.useEffect(() => {
25589
- var _ptServicesMastersDat3;
25590
- if (watchCategoryType && watchPropertyCategory && ptServicesMastersData !== null && ptServicesMastersData !== void 0 && (_ptServicesMastersDat3 = ptServicesMastersData.PropertyTax) !== null && _ptServicesMastersDat3 !== void 0 && _ptServicesMastersDat3.PropertyCategory) {
25591
- const isCategoryValid = categoryOptions.some(opt => opt.code === watchPropertyCategory.code);
25592
- if (!isCategoryValid) {
25593
- setValue("useDetails.propertyCategory", null);
25594
- }
25595
- }
25596
- }, [watchCategoryType, categoryOptions, setValue, watchPropertyCategory, ptServicesMastersData]);
25621
+ }, [ptServicesMastersData]);
25597
25622
  const propertyTypeOptions = React.useMemo(() => {
25598
- var _ptServicesMastersDat4, _ptServicesMastersDat5, _ptServicesMastersDat6, _watchPropertyCategor;
25599
- if (!(watchPropertyCategory !== null && watchPropertyCategory !== void 0 && watchPropertyCategory.code)) return [];
25600
- let options = (ptServicesMastersData === null || ptServicesMastersData === void 0 ? void 0 : (_ptServicesMastersDat4 = ptServicesMastersData.PropertyTax) === null || _ptServicesMastersDat4 === void 0 ? void 0 : (_ptServicesMastersDat5 = _ptServicesMastersDat4.PropertyType) === null || _ptServicesMastersDat5 === void 0 ? void 0 : _ptServicesMastersDat5.filter(item => item.active)) || [];
25601
- let mapping = (ptServicesMastersData === null || ptServicesMastersData === void 0 ? void 0 : (_ptServicesMastersDat6 = ptServicesMastersData.PropertyTax) === null || _ptServicesMastersDat6 === void 0 ? void 0 : _ptServicesMastersDat6.PropertyToUsageMapping) || [];
25602
- if (mapping.length > 0) {
25603
- options = options.filter(item => mapping.some(m => m.propertyTypeCode === item.code));
25604
- }
25605
- if ((watchPropertyCategory === null || watchPropertyCategory === void 0 ? void 0 : (_watchPropertyCategor = watchPropertyCategory.code) === null || _watchPropertyCategor === void 0 ? void 0 : _watchPropertyCategor.toUpperCase()) !== "MIXED") {
25606
- options = options.filter(item => normalizeCode(item.type) === normalizeCode(watchPropertyCategory.code));
25607
- }
25608
- return options.map(item => ({
25623
+ var _ptServicesMastersDat3, _ptServicesMastersDat4;
25624
+ const list = (ptServicesMastersData === null || ptServicesMastersData === void 0 ? void 0 : (_ptServicesMastersDat3 = ptServicesMastersData.PropertyTax) === null || _ptServicesMastersDat3 === void 0 ? void 0 : _ptServicesMastersDat3.PropertyType2) || (ptServicesMastersData === null || ptServicesMastersData === void 0 ? void 0 : (_ptServicesMastersDat4 = ptServicesMastersData.PropertyTax) === null || _ptServicesMastersDat4 === void 0 ? void 0 : _ptServicesMastersDat4.PropertyType) || [];
25625
+ return list.filter(item => item.active).map(item => ({
25626
+ ...item,
25609
25627
  code: item.code,
25610
25628
  name: item.name
25611
25629
  }));
25612
- }, [ptServicesMastersData, watchPropertyCategory]);
25613
- React.useEffect(() => {
25614
- var _ptServicesMastersDat7;
25615
- if (watchPropertyCategory && watchPropertyType && ptServicesMastersData !== null && ptServicesMastersData !== void 0 && (_ptServicesMastersDat7 = ptServicesMastersData.PropertyTax) !== null && _ptServicesMastersDat7 !== void 0 && _ptServicesMastersDat7.PropertyType) {
25616
- const isTypeValid = propertyTypeOptions.some(opt => opt.code === watchPropertyType.code);
25617
- if (!isTypeValid) {
25618
- setValue("useDetails.propertyType", null);
25619
- }
25620
- }
25621
- }, [watchPropertyCategory, propertyTypeOptions, setValue, watchPropertyType, ptServicesMastersData]);
25630
+ }, [ptServicesMastersData]);
25622
25631
  const usageTypeOptions = React.useMemo(() => {
25623
- var _ptServicesMastersDat8, _ptServicesMastersDat9, _ptServicesMastersDat0;
25624
- if (!(watchPropertyType !== null && watchPropertyType !== void 0 && watchPropertyType.code)) return [];
25625
- let options = (ptServicesMastersData === null || ptServicesMastersData === void 0 ? void 0 : (_ptServicesMastersDat8 = ptServicesMastersData.PropertyTax) === null || _ptServicesMastersDat8 === void 0 ? void 0 : (_ptServicesMastersDat9 = _ptServicesMastersDat8.PropertyNewUsageType) === null || _ptServicesMastersDat9 === void 0 ? void 0 : _ptServicesMastersDat9.filter(item => item.active)) || [];
25626
- let mapping = (ptServicesMastersData === null || ptServicesMastersData === void 0 ? void 0 : (_ptServicesMastersDat0 = ptServicesMastersData.PropertyTax) === null || _ptServicesMastersDat0 === void 0 ? void 0 : _ptServicesMastersDat0.PropertyToUsageMapping) || [];
25627
- const selectedMapping = mapping.find(m => m.propertyTypeCode === watchPropertyType.code);
25628
- if (selectedMapping && selectedMapping.allowedUsages) {
25629
- options = options.filter(item => selectedMapping.allowedUsages.includes(item.code));
25630
- } else {
25631
- options = [];
25632
- }
25633
- return options.map(item => ({
25634
- code: item.code,
25635
- name: item.name
25632
+ var _ptServicesMastersDat5;
25633
+ const list = (ptServicesMastersData === null || ptServicesMastersData === void 0 ? void 0 : (_ptServicesMastersDat5 = ptServicesMastersData.PropertyTax) === null || _ptServicesMastersDat5 === void 0 ? void 0 : _ptServicesMastersDat5.PropertyType2) || [];
25634
+ const uniqueTypes = [...new Set(list.map(item => item.waterConnectionUsageType).filter(Boolean))];
25635
+ const typesToMap = uniqueTypes.length > 0 ? uniqueTypes : ["Normal", "Bulk"];
25636
+ return typesToMap.map(type => ({
25637
+ code: type,
25638
+ name: type,
25639
+ value: type
25636
25640
  }));
25637
- }, [ptServicesMastersData, watchPropertyCategory, watchPropertyType]);
25641
+ }, [ptServicesMastersData]);
25642
+ const prevPropertyTypeCode = React__default.useRef(null);
25638
25643
  React.useEffect(() => {
25639
- var _ptServicesMastersDat1;
25640
- if (watchPropertyType && watchWaterConnectionUsageType && ptServicesMastersData !== null && ptServicesMastersData !== void 0 && (_ptServicesMastersDat1 = ptServicesMastersData.PropertyTax) !== null && _ptServicesMastersDat1 !== void 0 && _ptServicesMastersDat1.PropertyNewUsageType) {
25641
- const isUsageTypeValid = usageTypeOptions.some(opt => opt.code === watchWaterConnectionUsageType.code);
25642
- if (!isUsageTypeValid) {
25643
- setValue("useDetails.WaterConnectionUsageType", null);
25644
+ var _ptServicesMastersDat6;
25645
+ if (!(watchPropertyType !== null && watchPropertyType !== void 0 && watchPropertyType.code)) {
25646
+ prevPropertyTypeCode.current = null;
25647
+ return;
25648
+ }
25649
+ const isNewType = prevPropertyTypeCode.current !== watchPropertyType.code;
25650
+ prevPropertyTypeCode.current = watchPropertyType.code;
25651
+ const propertyType2List = (ptServicesMastersData === null || ptServicesMastersData === void 0 ? void 0 : (_ptServicesMastersDat6 = ptServicesMastersData.PropertyTax) === null || _ptServicesMastersDat6 === void 0 ? void 0 : _ptServicesMastersDat6.PropertyType2) || [];
25652
+ const matched = propertyType2List.find(item => normalizeCode(item.code) === normalizeCode(watchPropertyType.code));
25653
+ if (matched && isNewType) {
25654
+ if (matched.categoryType && matched.categoryType.length > 0 && categoryTypeList.length > 0) {
25655
+ const catTarget = matched.categoryType[0];
25656
+ const foundCat = categoryTypeList.find(c => normalizeCode(c.code) === normalizeCode(catTarget) || normalizeCode(c.name) === normalizeCode(catTarget));
25657
+ if (foundCat) {
25658
+ setValue("useDetails.categoryType", foundCat);
25659
+ }
25660
+ }
25661
+ if (matched.propertyCategory && categoryOptions.length > 0) {
25662
+ const foundPropCat = categoryOptions.find(c => normalizeCode(c.code) === normalizeCode(matched.propertyCategory) || normalizeCode(c.name) === normalizeCode(matched.propertyCategory));
25663
+ if (foundPropCat) {
25664
+ setValue("useDetails.propertyCategory", foundPropCat);
25665
+ }
25666
+ }
25667
+ if (matched.waterConnectionUsageType && matched.waterConnectionUsageType.length > 0) {
25668
+ const foundUsage = usageTypeOptions.find(u => normalizeCode(u.code) === normalizeCode(matched.waterConnectionUsageType) || normalizeCode(u.name) === normalizeCode(matched.waterConnectionUsageType));
25669
+ if (foundUsage) {
25670
+ setValue("useDetails.WaterConnectionUsageType", foundUsage);
25671
+ }
25644
25672
  }
25645
25673
  }
25646
- }, [watchPropertyType, usageTypeOptions, setValue, watchWaterConnectionUsageType, ptServicesMastersData]);
25674
+ }, [watchPropertyType === null || watchPropertyType === void 0 ? void 0 : watchPropertyType.code, ptServicesMastersData, categoryTypeList, categoryOptions, usageTypeOptions, setValue]);
25647
25675
  const floorOptions = React.useMemo(() => {
25648
- var _ptServicesMastersDat10, _ptServicesMastersDat11;
25649
- return ptServicesMastersData === null || ptServicesMastersData === void 0 ? void 0 : (_ptServicesMastersDat10 = ptServicesMastersData.PropertyTax) === null || _ptServicesMastersDat10 === void 0 ? void 0 : (_ptServicesMastersDat11 = _ptServicesMastersDat10.NoOfFloors) === null || _ptServicesMastersDat11 === void 0 ? void 0 : _ptServicesMastersDat11.filter(item => item.active).map(item => ({
25676
+ var _ptServicesMastersDat7, _ptServicesMastersDat8;
25677
+ return ptServicesMastersData === null || ptServicesMastersData === void 0 ? void 0 : (_ptServicesMastersDat7 = ptServicesMastersData.PropertyTax) === null || _ptServicesMastersDat7 === void 0 ? void 0 : (_ptServicesMastersDat8 = _ptServicesMastersDat7.NoOfFloors) === null || _ptServicesMastersDat8 === void 0 ? void 0 : _ptServicesMastersDat8.filter(item => item.active).map(item => ({
25650
25678
  code: item.code,
25651
25679
  name: item.name
25652
25680
  }));
@@ -25663,27 +25691,25 @@ const PropertyWaterConnection = _ref => {
25663
25691
  if (propertyDetailsInitialized.current || !(formData !== null && formData !== void 0 && (_formData$cpt = formData.cpt) !== null && _formData$cpt !== void 0 && _formData$cpt.details)) return;
25664
25692
  if (!categoryTypeList.length || !ptServicesMastersData) return;
25665
25693
  if (formData !== null && formData !== void 0 && (_formData$cpt2 = formData.cpt) !== null && _formData$cpt2 !== void 0 && _formData$cpt2.details) {
25666
- var _ptServicesMastersDat12, _ptServicesMastersDat13, _ptServicesMastersDat14, _ptServicesMastersDat15, _ptServicesMastersDat16, _ptServicesMastersDat17, _details$landArea, _details$superBuiltUp, _details$heightOfTheB, _details$farArea, _details$servantQuart, _details$numberOfBeds, _details$numberOfStud;
25694
+ var _ptServicesMastersDat9, _ptServicesMastersDat0, _ref2, _ptServicesMastersDat1, _ptServicesMastersDat10, _details$landArea, _details$superBuiltUp, _details$heightOfTheB, _details$farArea, _details$servantQuart, _details$numberOfBeds, _details$numberOfStud;
25667
25695
  const details = formData.cpt.details;
25668
25696
  const additionalDetails = (details === null || details === void 0 ? void 0 : details.additionalDetails) || {};
25669
25697
  const usageCategory = getCode(additionalDetails.propertyCategory || additionalDetails.usageCategory || details.usageCategory);
25670
25698
  const catType = getCode(additionalDetails.categoryType) || (String(usageCategory).includes("RESIDENTIAL") ? "DOMESTIC" : "NON_DOMESTIC");
25671
25699
  setValue("useDetails.categoryType", (categoryTypeList === null || categoryTypeList === void 0 ? void 0 : categoryTypeList.find(o => normalizeCode(o.code) === normalizeCode(catType))) || null);
25672
- const propCategoryMatch = ptServicesMastersData === null || ptServicesMastersData === void 0 ? void 0 : (_ptServicesMastersDat12 = ptServicesMastersData.PropertyTax) === null || _ptServicesMastersDat12 === void 0 ? void 0 : (_ptServicesMastersDat13 = _ptServicesMastersDat12.PropertyCategory) === null || _ptServicesMastersDat13 === void 0 ? void 0 : _ptServicesMastersDat13.find(o => normalizeCode(o.code) === normalizeCode(usageCategory));
25700
+ const propCategoryMatch = ptServicesMastersData === null || ptServicesMastersData === void 0 ? void 0 : (_ptServicesMastersDat9 = ptServicesMastersData.PropertyTax) === null || _ptServicesMastersDat9 === void 0 ? void 0 : (_ptServicesMastersDat0 = _ptServicesMastersDat9.PropertyCategory) === null || _ptServicesMastersDat0 === void 0 ? void 0 : _ptServicesMastersDat0.find(o => normalizeCode(o.code) === normalizeCode(usageCategory));
25673
25701
  setValue("useDetails.propertyCategory", propCategoryMatch ? {
25674
25702
  code: propCategoryMatch.code,
25675
25703
  name: propCategoryMatch.name
25676
25704
  } : null);
25677
- const propTypeMatch = ptServicesMastersData === null || ptServicesMastersData === void 0 ? void 0 : (_ptServicesMastersDat14 = ptServicesMastersData.PropertyTax) === null || _ptServicesMastersDat14 === void 0 ? void 0 : (_ptServicesMastersDat15 = _ptServicesMastersDat14.PropertyType) === null || _ptServicesMastersDat15 === void 0 ? void 0 : _ptServicesMastersDat15.find(o => normalizeCode(o.code) === normalizeCode(getCode(additionalDetails.propertyType || details.propertyType)));
25705
+ const propTypeMatch = (_ref2 = (ptServicesMastersData === null || ptServicesMastersData === void 0 ? void 0 : (_ptServicesMastersDat1 = ptServicesMastersData.PropertyTax) === null || _ptServicesMastersDat1 === void 0 ? void 0 : _ptServicesMastersDat1.PropertyType2) || (ptServicesMastersData === null || ptServicesMastersData === void 0 ? void 0 : (_ptServicesMastersDat10 = ptServicesMastersData.PropertyTax) === null || _ptServicesMastersDat10 === void 0 ? void 0 : _ptServicesMastersDat10.PropertyType)) === null || _ref2 === void 0 ? void 0 : _ref2.find(o => normalizeCode(o.code) === normalizeCode(getCode(additionalDetails.propertyType || details.propertyType)));
25678
25706
  setValue("useDetails.propertyType", propTypeMatch ? {
25679
25707
  code: propTypeMatch.code,
25680
25708
  name: propTypeMatch.name
25681
25709
  } : null);
25682
- const usageTypeMatch = ptServicesMastersData === null || ptServicesMastersData === void 0 ? void 0 : (_ptServicesMastersDat16 = ptServicesMastersData.PropertyTax) === null || _ptServicesMastersDat16 === void 0 ? void 0 : (_ptServicesMastersDat17 = _ptServicesMastersDat16.PropertyNewUsageType) === null || _ptServicesMastersDat17 === void 0 ? void 0 : _ptServicesMastersDat17.find(o => normalizeCode(o.code) === normalizeCode(getCode(additionalDetails.waterConnectionUsageType || additionalDetails.WaterConnectionUsageType)));
25683
- setValue("useDetails.WaterConnectionUsageType", usageTypeMatch ? {
25684
- code: usageTypeMatch.code,
25685
- name: usageTypeMatch.name
25686
- } : null);
25710
+ const usageVal = getCode(additionalDetails.waterConnectionUsageType || additionalDetails.WaterConnectionUsageType);
25711
+ const usageTypeMatch = usageTypeOptions.find(o => normalizeCode(o.code) === normalizeCode(usageVal) || normalizeCode(o.name) === normalizeCode(usageVal));
25712
+ setValue("useDetails.WaterConnectionUsageType", usageTypeMatch || null);
25687
25713
  setValue("useDetails.noOfFloors", (floorOptions === null || floorOptions === void 0 ? void 0 : floorOptions.find(o => {
25688
25714
  var _details$noOfFloors;
25689
25715
  const val1 = getCode(additionalDetails.numberOfFloors);
@@ -25747,73 +25773,73 @@ const PropertyWaterConnection = _ref => {
25747
25773
  style: props.style
25748
25774
  }, /*#__PURE__*/React__default.createElement("div", {
25749
25775
  className: "formcomposer-section-grid"
25750
- }, /*#__PURE__*/React__default.createElement(digitUiReactComponents.LabelFieldPair, null, /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardLabel, null, `${t("WS_CATEGORY_TYPE")}`, " ", /*#__PURE__*/React__default.createElement("span", {
25776
+ }, /*#__PURE__*/React__default.createElement(digitUiReactComponents.LabelFieldPair, null, /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardLabel, null, `${t("WS_PROPERTY_TYPE")}`, " ", /*#__PURE__*/React__default.createElement("span", {
25751
25777
  className: "check-page-link-button"
25752
25778
  }, "*")), /*#__PURE__*/React__default.createElement("div", {
25753
25779
  className: "form-field"
25754
25780
  }, /*#__PURE__*/React__default.createElement(reactHookForm.Controller, {
25755
25781
  control: control,
25756
- name: "useDetails.categoryType",
25782
+ name: "useDetails.propertyType",
25757
25783
  rules: {
25758
25784
  required: t("REQUIRED_FIELD")
25759
25785
  },
25760
25786
  render: props => /*#__PURE__*/React__default.createElement(digitUiReactComponents.Dropdown, {
25761
- option: categoryTypeList,
25762
- optionKey: "i18nKey",
25787
+ option: propertyTypeOptions,
25788
+ optionKey: "name",
25763
25789
  selected: props.value,
25764
25790
  select: props.onChange,
25765
25791
  t: t,
25766
25792
  onBlur: props.onBlur,
25767
25793
  disable: isPropertyFound,
25768
- placeholder: t("WS_CATEGORY_TYPE")
25794
+ placeholder: t("WS_PROPERTY_TYPE")
25769
25795
  })
25770
- }))), (errors === null || errors === void 0 ? void 0 : (_errors$useDetails = errors.useDetails) === null || _errors$useDetails === void 0 ? void 0 : _errors$useDetails.categoryType) && /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardLabelError, {
25796
+ }))), (errors === null || errors === void 0 ? void 0 : (_errors$useDetails = errors.useDetails) === null || _errors$useDetails === void 0 ? void 0 : _errors$useDetails.propertyType) && /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardLabelError, {
25771
25797
  style: errorStyle
25772
- }, errors.useDetails.categoryType.message), /*#__PURE__*/React__default.createElement(digitUiReactComponents.LabelFieldPair, null, /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardLabel, null, `${t("WS_PROPERTY_CATEGORY")}`, " ", /*#__PURE__*/React__default.createElement("span", {
25798
+ }, errors.useDetails.propertyType.message), /*#__PURE__*/React__default.createElement(digitUiReactComponents.LabelFieldPair, null, /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardLabel, null, `${t("WS_CATEGORY_TYPE")}`, " ", /*#__PURE__*/React__default.createElement("span", {
25773
25799
  className: "check-page-link-button"
25774
25800
  }, "*")), /*#__PURE__*/React__default.createElement("div", {
25775
25801
  className: "form-field"
25776
25802
  }, /*#__PURE__*/React__default.createElement(reactHookForm.Controller, {
25777
25803
  control: control,
25778
- name: "useDetails.propertyCategory",
25804
+ name: "useDetails.categoryType",
25779
25805
  rules: {
25780
25806
  required: t("REQUIRED_FIELD")
25781
25807
  },
25782
25808
  render: props => /*#__PURE__*/React__default.createElement(digitUiReactComponents.Dropdown, {
25783
- option: categoryOptions,
25784
- optionKey: "name",
25809
+ option: categoryTypeList,
25810
+ optionKey: "i18nKey",
25785
25811
  selected: props.value,
25786
25812
  select: props.onChange,
25787
25813
  t: t,
25788
25814
  onBlur: props.onBlur,
25789
25815
  disable: isPropertyFound,
25790
- placeholder: t("WS_PROPERTY_CATEGORY")
25816
+ placeholder: t("WS_CATEGORY_TYPE")
25791
25817
  })
25792
- }))), (errors === null || errors === void 0 ? void 0 : (_errors$useDetails2 = errors.useDetails) === null || _errors$useDetails2 === void 0 ? void 0 : _errors$useDetails2.propertyCategory) && /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardLabelError, {
25818
+ }))), (errors === null || errors === void 0 ? void 0 : (_errors$useDetails2 = errors.useDetails) === null || _errors$useDetails2 === void 0 ? void 0 : _errors$useDetails2.categoryType) && /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardLabelError, {
25793
25819
  style: errorStyle
25794
- }, errors.useDetails.propertyCategory.message), /*#__PURE__*/React__default.createElement(digitUiReactComponents.LabelFieldPair, null, /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardLabel, null, `${t("WS_PROPERTY_TYPE")}`, " ", /*#__PURE__*/React__default.createElement("span", {
25820
+ }, errors.useDetails.categoryType.message), /*#__PURE__*/React__default.createElement(digitUiReactComponents.LabelFieldPair, null, /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardLabel, null, `${t("WS_PROPERTY_CATEGORY")}`, " ", /*#__PURE__*/React__default.createElement("span", {
25795
25821
  className: "check-page-link-button"
25796
25822
  }, "*")), /*#__PURE__*/React__default.createElement("div", {
25797
25823
  className: "form-field"
25798
25824
  }, /*#__PURE__*/React__default.createElement(reactHookForm.Controller, {
25799
25825
  control: control,
25800
- name: "useDetails.propertyType",
25826
+ name: "useDetails.propertyCategory",
25801
25827
  rules: {
25802
25828
  required: t("REQUIRED_FIELD")
25803
25829
  },
25804
25830
  render: props => /*#__PURE__*/React__default.createElement(digitUiReactComponents.Dropdown, {
25805
- option: propertyTypeOptions,
25831
+ option: categoryOptions,
25806
25832
  optionKey: "name",
25807
25833
  selected: props.value,
25808
25834
  select: props.onChange,
25809
25835
  t: t,
25810
25836
  onBlur: props.onBlur,
25811
25837
  disable: isPropertyFound,
25812
- placeholder: t("WS_PROPERTY_TYPE")
25838
+ placeholder: t("WS_PROPERTY_CATEGORY")
25813
25839
  })
25814
- }))), (errors === null || errors === void 0 ? void 0 : (_errors$useDetails3 = errors.useDetails) === null || _errors$useDetails3 === void 0 ? void 0 : _errors$useDetails3.propertyType) && /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardLabelError, {
25840
+ }))), (errors === null || errors === void 0 ? void 0 : (_errors$useDetails3 = errors.useDetails) === null || _errors$useDetails3 === void 0 ? void 0 : _errors$useDetails3.propertyCategory) && /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardLabelError, {
25815
25841
  style: errorStyle
25816
- }, errors.useDetails.propertyType.message), /*#__PURE__*/React__default.createElement(digitUiReactComponents.LabelFieldPair, null, /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardLabel, null, `${t("WS_WATER_CONNECTION_USAGE_TYPE")}`, " ", /*#__PURE__*/React__default.createElement("span", {
25842
+ }, errors.useDetails.propertyCategory.message), /*#__PURE__*/React__default.createElement(digitUiReactComponents.LabelFieldPair, null, /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardLabel, null, `${t("WS_WATER_CONNECTION_USAGE_TYPE")}`, " ", /*#__PURE__*/React__default.createElement("span", {
25817
25843
  className: "check-page-link-button"
25818
25844
  }, "*")), /*#__PURE__*/React__default.createElement("div", {
25819
25845
  className: "form-field"
@@ -25936,7 +25962,9 @@ const PropertyWaterConnection = _ref => {
25936
25962
  })
25937
25963
  }))), (errors === null || errors === void 0 ? void 0 : (_errors$useDetails9 = errors.useDetails) === null || _errors$useDetails9 === void 0 ? void 0 : _errors$useDetails9.SelectYearofConstruction) && /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardLabelError, {
25938
25964
  style: errorStyle
25939
- }, errors.useDetails.SelectYearofConstruction.message), isDwellingUnit ? /*#__PURE__*/React__default.createElement(digitUiReactComponents.LabelFieldPair, null, /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardLabel, null, `${t("WS_NUMBER_OF_DWELLING_UNITS")}`), /*#__PURE__*/React__default.createElement("div", {
25965
+ }, errors.useDetails.SelectYearofConstruction.message), isDwellingUnit ? /*#__PURE__*/React__default.createElement(digitUiReactComponents.LabelFieldPair, null, /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardLabel, null, `${t("WS_NUMBER_OF_DWELLING_UNITS")}`, /*#__PURE__*/React__default.createElement("span", {
25966
+ className: "check-page-link-button"
25967
+ }, " *")), /*#__PURE__*/React__default.createElement("div", {
25940
25968
  className: "form-field"
25941
25969
  }, /*#__PURE__*/React__default.createElement(digitUiReactComponents.TextInput, {
25942
25970
  t: t,
@@ -25944,10 +25972,14 @@ const PropertyWaterConnection = _ref => {
25944
25972
  pattern: {
25945
25973
  value: NUMBER_PATTERN$1,
25946
25974
  message: t("ERR_INVALID_NUMBER")
25947
- }
25975
+ },
25976
+ required: t("REQUIRED_FIELD")
25948
25977
  }),
25949
25978
  name: "useDetails.NumberofDwellingUnits",
25950
25979
  disabled: isPropertyFound,
25980
+ rules: {
25981
+ required: t("REQUIRED_FIELD")
25982
+ },
25951
25983
  placeholder: t("WS_NUMBER_OF_DWELLING_UNITS")
25952
25984
  }))) : null, isDwellingUnit && (errors === null || errors === void 0 ? void 0 : (_errors$useDetails0 = errors.useDetails) === null || _errors$useDetails0 === void 0 ? void 0 : _errors$useDetails0.NumberofDwellingUnits) && /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardLabelError, {
25953
25985
  style: errorStyle
@@ -26002,22 +26034,7 @@ const PropertyWaterConnection = _ref => {
26002
26034
  placeholder: t("WS_NUMBER_OF_STUDENTS")
26003
26035
  }))) : null, isSchoolCollegeProperty && (errors === null || errors === void 0 ? void 0 : (_errors$useDetails11 = errors.useDetails) === null || _errors$useDetails11 === void 0 ? void 0 : _errors$useDetails11.numberOfStudents) && /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardLabelError, {
26004
26036
  style: errorStyle
26005
- }, errors.useDetails.numberOfStudents.message), isServentHouse ? /*#__PURE__*/React__default.createElement(digitUiReactComponents.LabelFieldPair, null, /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardLabel, null, `${t("WS_SERVENT_HOUSE")}`), /*#__PURE__*/React__default.createElement("div", {
26006
- className: "form-field"
26007
- }, /*#__PURE__*/React__default.createElement(digitUiReactComponents.TextInput, {
26008
- t: t,
26009
- inputRef: register({
26010
- pattern: {
26011
- value: NUMBER_PATTERN$1,
26012
- message: t("ERR_INVALID_NUMBER")
26013
- }
26014
- }),
26015
- name: "useDetails.servantQuarterArea",
26016
- disabled: isPropertyFound,
26017
- placeholder: t("WS_SERVENT_HOUSE")
26018
- }))) : null, isServentHouse && (errors === null || errors === void 0 ? void 0 : (_errors$useDetails12 = errors.useDetails) === null || _errors$useDetails12 === void 0 ? void 0 : _errors$useDetails12.servantQuarterArea) && /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardLabelError, {
26019
- style: errorStyle
26020
- }, errors.useDetails.servantQuarterArea.message)));
26037
+ }, errors.useDetails.numberOfStudents.message)));
26021
26038
  };
26022
26039
 
26023
26040
  const WSPropertyWaterConnection = props => {
@@ -32981,7 +32998,7 @@ const Rebate_menu = [{
32981
32998
  value: "Others"
32982
32999
  }];
32983
33000
  const WSFeeEstimation = _ref => {
32984
- var _wsAdditionalDetails$, _wsAdditionalDetails$2, _wsAdditionalDetails$3, _billDetails$billDeta, _billDetails$billDeta2, _fields$adhocPenaltyR, _fields$adhocRebateRe;
33001
+ var _wsAdditionalDetails$, _wsAdditionalDetails$2, _wsAdditionalDetails$3, _wsAdditionalDetails$4, _workflowDetails$data, _workflowDetails$data2, _workflowDetails$data3, _workflowDetails$data4, _workflowDetails$data5, _workflowDetails$data6, _workflowDetails$data7, _workflowDetails$data8, _workflowDetails$data9, _wsAdditionalDetails$5, _wsAdditionalDetails$6, _wsAdditionalDetails$7, _billDetails$billDeta, _billDetails$billDeta2, _fields$adhocPenaltyR, _fields$adhocRebateRe;
32985
33002
  let {
32986
33003
  wsAdditionalDetails,
32987
33004
  workflowDetails,
@@ -32992,13 +33009,21 @@ const WSFeeEstimation = _ref => {
32992
33009
  } = reactI18next.useTranslation();
32993
33010
  const [sessionFormData, setSessionFormData, clearSessionFormData] = Digit.Hooks.useSessionStorage("ADHOC_ADD_REBATE_DATA", {});
32994
33011
  const [sessionBillFormData, setSessionBillFormData, clearBillSessionFormData] = Digit.Hooks.useSessionStorage("ADHOC_BILL_ADD_REBATE_DATA", {});
32995
- const isPaid = wsAdditionalDetails !== null && wsAdditionalDetails !== void 0 && (_wsAdditionalDetails$ = wsAdditionalDetails.additionalDetails) !== null && _wsAdditionalDetails$ !== void 0 && _wsAdditionalDetails$.isPaid ? true : false;
33012
+ const appStatus = (wsAdditionalDetails === null || wsAdditionalDetails === void 0 ? void 0 : (_wsAdditionalDetails$ = wsAdditionalDetails.additionalDetails) === null || _wsAdditionalDetails$ === void 0 ? void 0 : (_wsAdditionalDetails$2 = _wsAdditionalDetails$.appDetails) === null || _wsAdditionalDetails$2 === void 0 ? void 0 : _wsAdditionalDetails$2.applicationStatus) || (wsAdditionalDetails === null || wsAdditionalDetails === void 0 ? void 0 : (_wsAdditionalDetails$3 = wsAdditionalDetails.additionalDetails) === null || _wsAdditionalDetails$3 === void 0 ? void 0 : (_wsAdditionalDetails$4 = _wsAdditionalDetails$3.data) === null || _wsAdditionalDetails$4 === void 0 ? void 0 : _wsAdditionalDetails$4.applicationStatus) || (workflowDetails === null || workflowDetails === void 0 ? void 0 : (_workflowDetails$data = workflowDetails.data) === null || _workflowDetails$data === void 0 ? void 0 : (_workflowDetails$data2 = _workflowDetails$data.processInstances) === null || _workflowDetails$data2 === void 0 ? void 0 : (_workflowDetails$data3 = _workflowDetails$data2[0]) === null || _workflowDetails$data3 === void 0 ? void 0 : (_workflowDetails$data4 = _workflowDetails$data3.state) === null || _workflowDetails$data4 === void 0 ? void 0 : _workflowDetails$data4.applicationStatus) || (workflowDetails === null || workflowDetails === void 0 ? void 0 : (_workflowDetails$data5 = workflowDetails.data) === null || _workflowDetails$data5 === void 0 ? void 0 : (_workflowDetails$data6 = _workflowDetails$data5.processInstances) === null || _workflowDetails$data6 === void 0 ? void 0 : (_workflowDetails$data7 = _workflowDetails$data6[0]) === null || _workflowDetails$data7 === void 0 ? void 0 : (_workflowDetails$data8 = _workflowDetails$data7.state) === null || _workflowDetails$data8 === void 0 ? void 0 : _workflowDetails$data8.state);
33013
+ const timeline = (workflowDetails === null || workflowDetails === void 0 ? void 0 : (_workflowDetails$data9 = workflowDetails.data) === null || _workflowDetails$data9 === void 0 ? void 0 : _workflowDetails$data9.processInstances) || (workflowDetails === null || workflowDetails === void 0 ? void 0 : workflowDetails.ProcessInstances);
33014
+ const hasPaymentInTimeline = Array.isArray(timeline) && timeline.some(step => {
33015
+ var _step$state, _step$state2;
33016
+ return (step === null || step === void 0 ? void 0 : step.action) === "PAY" || (step === null || step === void 0 ? void 0 : (_step$state = step.state) === null || _step$state === void 0 ? void 0 : _step$state.state) === "PENDING_FOR_PAYMENT" || (step === null || step === void 0 ? void 0 : (_step$state2 = step.state) === null || _step$state2 === void 0 ? void 0 : _step$state2.applicationStatus) === "PENDING_FOR_PAYMENT";
33017
+ });
33018
+ const isPostPaymentState = hasPaymentInTimeline && appStatus !== "PENDING_FOR_PAYMENT" && appStatus !== "INITIATED" && appStatus !== "PENDING_FOR_DOCUMENT_VERIFICATION" && appStatus !== "PENDING_FOR_CITIZEN_ACTION" && appStatus !== "PENDING_FOR_FIELD_INSPECTION";
33019
+ const isWorkflowPaid = appStatus && appStatus !== "INITIATED" && appStatus !== "PENDING_FOR_DOCUMENT_VERIFICATION" && appStatus !== "PENDING_FOR_CITIZEN_ACTION" && appStatus !== "PENDING_FOR_FIELD_INSPECTION" && appStatus !== "PENDING_FOR_PAYMENT" && appStatus !== "PENDING_FOR_FINAL_PAYMENT" && appStatus !== "PENDING_FOR_ADDITIONAL_PAYMENT" && appStatus !== "PENDING_APPROVAL_FOR_MUTATION";
33020
+ const isPaid = wsAdditionalDetails !== null && wsAdditionalDetails !== void 0 && (_wsAdditionalDetails$5 = wsAdditionalDetails.additionalDetails) !== null && _wsAdditionalDetails$5 !== void 0 && _wsAdditionalDetails$5.isPaid || isWorkflowPaid || isPostPaymentState ? true : false;
32996
33021
  const [popup, showPopUp] = React.useState(false);
32997
33022
  const [fields, setFields] = React.useState(sessionFormData ? sessionFormData : {});
32998
33023
  const [showToast, setShowToast] = React.useState(null);
32999
33024
  const [billDetails, setBillDetails] = React.useState(wsAdditionalDetails.additionalDetails.data ? wsAdditionalDetails.additionalDetails.data : {});
33000
33025
  const [values, setValues] = React.useState(wsAdditionalDetails.additionalDetails.values ? wsAdditionalDetails.additionalDetails.values : []);
33001
- const isDisconnectionExecuted = (wsAdditionalDetails === null || wsAdditionalDetails === void 0 ? void 0 : (_wsAdditionalDetails$2 = wsAdditionalDetails.additionalDetails) === null || _wsAdditionalDetails$2 === void 0 ? void 0 : (_wsAdditionalDetails$3 = _wsAdditionalDetails$2.appDetails) === null || _wsAdditionalDetails$3 === void 0 ? void 0 : _wsAdditionalDetails$3.applicationStatus) === "DISCONNECTION_EXECUTED";
33026
+ const isDisconnectionExecuted = (wsAdditionalDetails === null || wsAdditionalDetails === void 0 ? void 0 : (_wsAdditionalDetails$6 = wsAdditionalDetails.additionalDetails) === null || _wsAdditionalDetails$6 === void 0 ? void 0 : (_wsAdditionalDetails$7 = _wsAdditionalDetails$6.appDetails) === null || _wsAdditionalDetails$7 === void 0 ? void 0 : _wsAdditionalDetails$7.applicationStatus) === "DISCONNECTION_EXECUTED";
33002
33027
  const billRows = (billDetails === null || billDetails === void 0 ? void 0 : (_billDetails$billDeta = billDetails.billDetails) === null || _billDetails$billDeta === void 0 ? void 0 : (_billDetails$billDeta2 = _billDetails$billDeta[0]) === null || _billDetails$billDeta2 === void 0 ? void 0 : _billDetails$billDeta2.billAccountDetails) || (billDetails === null || billDetails === void 0 ? void 0 : billDetails.taxHeadEstimates) || [];
33003
33028
  const disconnectionFee = billRows.find(row => (row === null || row === void 0 ? void 0 : row.taxHeadCode) === "WS_DISCONNECTION_FEE" || (row === null || row === void 0 ? void 0 : row.taxHeadCode) === "SW_DISCONNECTION_FEE");
33004
33029
  const displayedValues = onlyDisconnectionFee || isDisconnectionExecuted ? values.filter(value => (value === null || value === void 0 ? void 0 : value.title) === "WS_DISCONNECTION_FEE" || (value === null || value === void 0 ? void 0 : value.title) === "SW_DISCONNECTION_FEE") : values;
@@ -33010,9 +33035,9 @@ const WSFeeEstimation = _ref => {
33010
33035
  data: mdmsRes
33011
33036
  } = Digit.Hooks.ws.useMDMS(stateCode, "BillingService", ["TaxHeadMaster"]);
33012
33037
  React.useEffect(() => {
33013
- var _wsAdditionalDetails$4, _wsAdditionalDetails$5, _sessionFormData$bill;
33038
+ var _wsAdditionalDetails$8, _wsAdditionalDetails$9, _sessionFormData$bill;
33014
33039
  const data = {
33015
- ...(wsAdditionalDetails === null || wsAdditionalDetails === void 0 ? void 0 : (_wsAdditionalDetails$4 = wsAdditionalDetails.additionalDetails) === null || _wsAdditionalDetails$4 === void 0 ? void 0 : (_wsAdditionalDetails$5 = _wsAdditionalDetails$4.appDetails) === null || _wsAdditionalDetails$5 === void 0 ? void 0 : _wsAdditionalDetails$5.additionalDetails)
33040
+ ...(wsAdditionalDetails === null || wsAdditionalDetails === void 0 ? void 0 : (_wsAdditionalDetails$8 = wsAdditionalDetails.additionalDetails) === null || _wsAdditionalDetails$8 === void 0 ? void 0 : (_wsAdditionalDetails$9 = _wsAdditionalDetails$8.appDetails) === null || _wsAdditionalDetails$9 === void 0 ? void 0 : _wsAdditionalDetails$9.additionalDetails)
33016
33041
  };
33017
33042
  if ((sessionFormData === null || sessionFormData === void 0 ? void 0 : (_sessionFormData$bill = sessionFormData.billDetails) === null || _sessionFormData$bill === void 0 ? void 0 : _sessionFormData$bill.length) > 0) {
33018
33043
  var _sessionFormData$bill2, _sessionFormData$bill3, _sessionFormData$bill4, _sessionFormData$bill5, _sessionFormData$bill6, _sessionFormData$bill7, _sessionFormData$bill8, _sessionFormData$bill9, _sessionFormData$bill0, _sessionFormData$bill1, _sessionFormData$bill10;
@@ -33066,8 +33091,8 @@ const WSFeeEstimation = _ref => {
33066
33091
  const adhocAmount = fields !== null && fields !== void 0 && fields.adhocPenalty ? Number(fields === null || fields === void 0 ? void 0 : fields.adhocPenalty) : 0;
33067
33092
  const rebateAmount = fields !== null && fields !== void 0 && fields.adhocRebate ? Number(fields === null || fields === void 0 ? void 0 : fields.adhocRebate) : 0;
33068
33093
  if (adhocAmount || rebateAmount) {
33069
- var _wsAdditionalDetails$6, _wsAdditionalDetails$7;
33070
- const totalAmount = wsAdditionalDetails === null || wsAdditionalDetails === void 0 ? void 0 : (_wsAdditionalDetails$6 = wsAdditionalDetails.additionalDetails) === null || _wsAdditionalDetails$6 === void 0 ? void 0 : (_wsAdditionalDetails$7 = _wsAdditionalDetails$6.data) === null || _wsAdditionalDetails$7 === void 0 ? void 0 : _wsAdditionalDetails$7.totalAmount;
33094
+ var _wsAdditionalDetails$0, _wsAdditionalDetails$1;
33095
+ const totalAmount = wsAdditionalDetails === null || wsAdditionalDetails === void 0 ? void 0 : (_wsAdditionalDetails$0 = wsAdditionalDetails.additionalDetails) === null || _wsAdditionalDetails$0 === void 0 ? void 0 : (_wsAdditionalDetails$1 = _wsAdditionalDetails$0.data) === null || _wsAdditionalDetails$1 === void 0 ? void 0 : _wsAdditionalDetails$1.totalAmount;
33071
33096
  if (rebateAmount > totalAmount) {
33072
33097
  setShowToast({
33073
33098
  isError: false,
@@ -33076,16 +33101,16 @@ const WSFeeEstimation = _ref => {
33076
33101
  message: t("ERR_WS_REBATE_GREATER_THAN_AMOUNT")
33077
33102
  });
33078
33103
  } else {
33079
- var _wsAdditionalDetails$10, _wsAdditionalDetails$11, _wsAdditionalDetails$12, _wsAdditionalDetails$13, _wsAdditionalDetails$14, _wsAdditionalDetails$15, _wsAdditionalDetails$16, _wsAdditionalDetails$17, _wsAdditionalDetails$18, _wsAdditionalDetails$19;
33080
- const applicationNo = wsAdditionalDetails === null || wsAdditionalDetails === void 0 ? void 0 : (_wsAdditionalDetails$10 = wsAdditionalDetails.additionalDetails) === null || _wsAdditionalDetails$10 === void 0 ? void 0 : (_wsAdditionalDetails$11 = _wsAdditionalDetails$10.appDetails) === null || _wsAdditionalDetails$11 === void 0 ? void 0 : _wsAdditionalDetails$11.applicationNo;
33081
- const tenantId = wsAdditionalDetails === null || wsAdditionalDetails === void 0 ? void 0 : (_wsAdditionalDetails$12 = wsAdditionalDetails.additionalDetails) === null || _wsAdditionalDetails$12 === void 0 ? void 0 : (_wsAdditionalDetails$13 = _wsAdditionalDetails$12.appDetails) === null || _wsAdditionalDetails$13 === void 0 ? void 0 : _wsAdditionalDetails$13.tenantId;
33104
+ var _wsAdditionalDetails$14, _wsAdditionalDetails$15, _wsAdditionalDetails$16, _wsAdditionalDetails$17, _wsAdditionalDetails$18, _wsAdditionalDetails$19, _wsAdditionalDetails$20, _wsAdditionalDetails$21, _wsAdditionalDetails$22, _wsAdditionalDetails$23;
33105
+ const applicationNo = wsAdditionalDetails === null || wsAdditionalDetails === void 0 ? void 0 : (_wsAdditionalDetails$14 = wsAdditionalDetails.additionalDetails) === null || _wsAdditionalDetails$14 === void 0 ? void 0 : (_wsAdditionalDetails$15 = _wsAdditionalDetails$14.appDetails) === null || _wsAdditionalDetails$15 === void 0 ? void 0 : _wsAdditionalDetails$15.applicationNo;
33106
+ const tenantId = wsAdditionalDetails === null || wsAdditionalDetails === void 0 ? void 0 : (_wsAdditionalDetails$16 = wsAdditionalDetails.additionalDetails) === null || _wsAdditionalDetails$16 === void 0 ? void 0 : (_wsAdditionalDetails$17 = _wsAdditionalDetails$16.appDetails) === null || _wsAdditionalDetails$17 === void 0 ? void 0 : _wsAdditionalDetails$17.tenantId;
33082
33107
  const appAdditionalDetails = {
33083
- ...(wsAdditionalDetails === null || wsAdditionalDetails === void 0 ? void 0 : (_wsAdditionalDetails$14 = wsAdditionalDetails.additionalDetails) === null || _wsAdditionalDetails$14 === void 0 ? void 0 : (_wsAdditionalDetails$15 = _wsAdditionalDetails$14.appDetails) === null || _wsAdditionalDetails$15 === void 0 ? void 0 : _wsAdditionalDetails$15.additionalDetails),
33108
+ ...(wsAdditionalDetails === null || wsAdditionalDetails === void 0 ? void 0 : (_wsAdditionalDetails$18 = wsAdditionalDetails.additionalDetails) === null || _wsAdditionalDetails$18 === void 0 ? void 0 : (_wsAdditionalDetails$19 = _wsAdditionalDetails$18.appDetails) === null || _wsAdditionalDetails$19 === void 0 ? void 0 : _wsAdditionalDetails$19.additionalDetails),
33084
33109
  ...fields
33085
33110
  };
33086
33111
  wsAdditionalDetails.additionalDetails.appDetails.additionalDetails = appAdditionalDetails;
33087
33112
  const data = {
33088
- CalculationCriteria: (wsAdditionalDetails === null || wsAdditionalDetails === void 0 ? void 0 : (_wsAdditionalDetails$16 = wsAdditionalDetails.additionalDetails) === null || _wsAdditionalDetails$16 === void 0 ? void 0 : (_wsAdditionalDetails$17 = _wsAdditionalDetails$16.appDetails) === null || _wsAdditionalDetails$17 === void 0 ? void 0 : _wsAdditionalDetails$17.service) == "WATER" ? [{
33113
+ CalculationCriteria: (wsAdditionalDetails === null || wsAdditionalDetails === void 0 ? void 0 : (_wsAdditionalDetails$20 = wsAdditionalDetails.additionalDetails) === null || _wsAdditionalDetails$20 === void 0 ? void 0 : (_wsAdditionalDetails$21 = _wsAdditionalDetails$20.appDetails) === null || _wsAdditionalDetails$21 === void 0 ? void 0 : _wsAdditionalDetails$21.service) == "WATER" ? [{
33089
33114
  applicationNo: applicationNo,
33090
33115
  tenantId: tenantId,
33091
33116
  waterConnection: wsAdditionalDetails.additionalDetails.appDetails
@@ -33096,14 +33121,14 @@ const WSFeeEstimation = _ref => {
33096
33121
  }],
33097
33122
  isconnectionCalculation: false
33098
33123
  };
33099
- let businessService = (wsAdditionalDetails === null || wsAdditionalDetails === void 0 ? void 0 : (_wsAdditionalDetails$18 = wsAdditionalDetails.additionalDetails) === null || _wsAdditionalDetails$18 === void 0 ? void 0 : (_wsAdditionalDetails$19 = _wsAdditionalDetails$18.appDetails) === null || _wsAdditionalDetails$19 === void 0 ? void 0 : _wsAdditionalDetails$19.service) == "WATER" ? "WS" : "SW";
33124
+ let businessService = (wsAdditionalDetails === null || wsAdditionalDetails === void 0 ? void 0 : (_wsAdditionalDetails$22 = wsAdditionalDetails.additionalDetails) === null || _wsAdditionalDetails$22 === void 0 ? void 0 : (_wsAdditionalDetails$23 = _wsAdditionalDetails$22.appDetails) === null || _wsAdditionalDetails$23 === void 0 ? void 0 : _wsAdditionalDetails$23.service) == "WATER" ? "WS" : "SW";
33100
33125
  Digit.WSService.wsCalculationEstimate(data, businessService).then((result, err) => {
33101
33126
  var _result$Calculation, _result$Calculation$, _result$Calculation$$, _result$Calculation3, _result$Calculation3$, _result$Calculation4, _result$Calculation4$, _result$Calculation5, _result$Calculation5$, _result$Calculation6, _result$Calculation6$, _result$Calculation7, _result$Calculation7$, _result$Calculation8;
33102
33127
  if ((result === null || result === void 0 ? void 0 : (_result$Calculation = result.Calculation) === null || _result$Calculation === void 0 ? void 0 : (_result$Calculation$ = _result$Calculation[0]) === null || _result$Calculation$ === void 0 ? void 0 : (_result$Calculation$$ = _result$Calculation$.taxHeadEstimates) === null || _result$Calculation$$ === void 0 ? void 0 : _result$Calculation$$.length) > 0) {
33103
33128
  var _result$Calculation2, _result$Calculation2$, _result$Calculation2$2;
33104
33129
  result === null || result === void 0 ? void 0 : (_result$Calculation2 = result.Calculation) === null || _result$Calculation2 === void 0 ? void 0 : (_result$Calculation2$ = _result$Calculation2[0]) === null || _result$Calculation2$ === void 0 ? void 0 : (_result$Calculation2$2 = _result$Calculation2$.taxHeadEstimates) === null || _result$Calculation2$2 === void 0 ? void 0 : _result$Calculation2$2.forEach(data => data.amount = data.estimateAmount);
33105
33130
  }
33106
- result.Calculation[0].billSlabData = _.groupBy(result === null || result === void 0 ? void 0 : (_result$Calculation3 = result.Calculation) === null || _result$Calculation3 === void 0 ? void 0 : (_result$Calculation3$ = _result$Calculation3[0]) === null || _result$Calculation3$ === void 0 ? void 0 : _result$Calculation3$.taxHeadEstimates, "category");
33131
+ result.Calculation[0].billSlabData = lodash.groupBy(result === null || result === void 0 ? void 0 : (_result$Calculation3 = result.Calculation) === null || _result$Calculation3 === void 0 ? void 0 : (_result$Calculation3$ = _result$Calculation3[0]) === null || _result$Calculation3$ === void 0 ? void 0 : _result$Calculation3$.taxHeadEstimates, "category");
33107
33132
  const taxHeadEstimates = (result === null || result === void 0 ? void 0 : (_result$Calculation4 = result.Calculation) === null || _result$Calculation4 === void 0 ? void 0 : (_result$Calculation4$ = _result$Calculation4[0]) === null || _result$Calculation4$ === void 0 ? void 0 : _result$Calculation4$.taxHeadEstimates) || [];
33108
33133
  const values = taxHeadEstimates.length > 0 ? taxHeadEstimates.map(data => ({
33109
33134
  title: data === null || data === void 0 ? void 0 : data.taxHeadCode,
@@ -33201,7 +33226,7 @@ const WSFeeEstimation = _ref => {
33201
33226
  key: `CS_INBOX_STATUS_FILTER`,
33202
33227
  label: `${t(`CS_INBOX_STATUS_FILTER`)}`,
33203
33228
  text: displayedIsPaid ? t("WS_COMMON_PAID_LABEL") : t("WS_COMMON_NOT_PAID"),
33204
- textStyle: !isPaid ? {
33229
+ textStyle: !displayedIsPaid ? {
33205
33230
  color: "#D83A2F"
33206
33231
  } : {
33207
33232
  color: "#2E9E8F"
@@ -33806,7 +33831,7 @@ const checkForNA$1 = value => {
33806
33831
  return value ? value : "CS_NA";
33807
33832
  };
33808
33833
  const WSApplicationDetails = () => {
33809
- var _user$info, _user$info$userName, _user$info2, _user$info3, _Digit$SessionStorage, _user$info4, _data$WaterConnection, _data$WaterConnection2, _data$SewerageConnect, _data$SewerageConnect2, _data$WaterConnection3, _data$WaterConnection4, _data$WaterConnection5, _data$SewerageConnect3, _data$SewerageConnect4, _data$SewerageConnect5, _data$WaterConnection6, _data$WaterConnection7, _data$SewerageConnect6, _data$SewerageConnect7, _data$WaterConnection8, _data$WaterConnection9, _data$SewerageConnect8, _data$SewerageConnect9, _data$WaterConnection0, _data$WaterConnection1, _data$SewerageConnect0, _data$SewerageConnect1, _data$WaterConnection10, _data$SewerageConnect10, _PTData$Properties, _PTData$Properties$, _PTData$Properties2, _PTData$Properties2$, _data$WaterConnection11, _data$WaterConnection12, _data$WaterConnection13, _data$WaterConnection14, _data$SewerageConnect11, _data$SewerageConnect12, _data$SewerageConnect13, _data$SewerageConnect14, _data$WaterConnection15, _data$WaterConnection16, _data$SewerageConnect15, _data$SewerageConnect16, _appDetailsData$appli, _data$WaterConnection35, _data$WaterConnection36, _data$WaterConnection37, _data$SewerageConnect31, _data$SewerageConnect32, _data$SewerageConnect33, _data$WaterConnection38, _data$WaterConnection39, _data$SewerageConnect34, _data$SewerageConnect35, _data$WaterConnection40, _data$WaterConnection41, _data$WaterConnection42, _data$SewerageConnect36, _data$SewerageConnect37, _data$SewerageConnect38, _data$WaterConnection43, _data$WaterConnection44, _data$WaterConnection45, _data$SewerageConnect39, _data$SewerageConnect40, _data$SewerageConnect41, _data$WaterConnection46, _data$WaterConnection47, _data$SewerageConnect42, _data$WaterConnection48, _data$WaterConnection49, _data$SewerageConnect43, _data$SewerageConnect44, _data$WaterConnection50, _data$WaterConnection51, _data$SewerageConnect45, _data$SewerageConnect46, _data$WaterConnection52, _data$WaterConnection53, _data$WaterConnection54, _data$SewerageConnect47, _data$SewerageConnect48, _data$SewerageConnect49, _data$WaterConnection55, _data$WaterConnection56, _data$SewerageConnect50, _data$SewerageConnect51, _data$WaterConnection57, _data$WaterConnection58, _data$SewerageConnect52, _data$SewerageConnect53, _data$WaterConnection59, _data$WaterConnection60, _data$WaterConnection61, _data$SewerageConnect54, _data$SewerageConnect55, _data$SewerageConnect56, _data$WaterConnection62, _data$WaterConnection63, _data$SewerageConnect57, _data$SewerageConnect58, _data$WaterConnection64, _data$WaterConnection65, _data$WaterConnection66, _data$SewerageConnect59, _data$SewerageConnect60, _data$SewerageConnect61, _data$WaterConnection67, _data$WaterConnection68, _data$SewerageConnect62, _data$SewerageConnect63, _data$WaterConnection69, _data$WaterConnection70, _data$WaterConnection71, _data$SewerageConnect64, _data$SewerageConnect65, _data$SewerageConnect66, _data$WaterConnection72, _data$WaterConnection73, _data$WaterConnection74, _data$WaterConnection75, _data$SewerageConnect67, _data$SewerageConnect68, _data$SewerageConnect69, _data$SewerageConnect70, _connectionDetails$se, _connectionDetails$se2, _connectionDetails$ap, _connectionDetails$ap2, _connectionDetails$do, _connectionDetails$de, _connectionDetails$de2, _data$WaterConnection76, _data$WaterConnection77, _data$WaterConnection78, _data$SewerageConnect71, _data$SewerageConnect72, _data$SewerageConnect73, _data$WaterConnection79, _data$WaterConnection80, _data$WaterConnection81, _data$WaterConnection82, _data$SewerageConnect74, _data$SewerageConnect75, _data$SewerageConnect76, _data$SewerageConnect77, _data$WaterConnection83, _data$WaterConnection84, _data$WaterConnection85, _data$WaterConnection86, _data$SewerageConnect78, _data$SewerageConnect79, _data$SewerageConnect80, _data$SewerageConnect81, _data$WaterConnection87, _data$WaterConnection88, _data$WaterConnection89, _data$WaterConnection90, _data$SewerageConnect82, _data$SewerageConnect83, _data$SewerageConnect84, _data$SewerageConnect85, _data$WaterConnection91, _data$WaterConnection92, _data$WaterConnection93, _data$WaterConnection94, _data$SewerageConnect86, _data$SewerageConnect87, _data$SewerageConnect88, _data$SewerageConnect89, _data$WaterConnection95, _data$WaterConnection96, _data$WaterConnection97, _data$WaterConnection98, _data$SewerageConnect90, _data$SewerageConnect91, _data$SewerageConnect92, _data$SewerageConnect93, _data$WaterConnection99, _data$WaterConnection100, _data$WaterConnection101, _data$WaterConnection102, _data$SewerageConnect94, _data$SewerageConnect95, _data$SewerageConnect96, _data$SewerageConnect97, _data$WaterConnection103, _data$WaterConnection104, _data$WaterConnection105, _data$WaterConnection106, _data$SewerageConnect98, _data$SewerageConnect99, _data$SewerageConnect100, _data$SewerageConnect101, _data$WaterConnection107, _data$WaterConnection108, _data$WaterConnection109, _data$WaterConnection110, _data$SewerageConnect102, _data$SewerageConnect103, _data$SewerageConnect104, _data$SewerageConnect105, _data$WaterConnection111, _data$WaterConnection112, _data$WaterConnection113, _data$WaterConnection114, _data$SewerageConnect106, _data$SewerageConnect107, _data$SewerageConnect108, _data$SewerageConnect109, _data$WaterConnection115, _data$WaterConnection116, _data$SewerageConnect110, _data$SewerageConnect111, _PTData$Properties5, _PTData$Properties5$, _PTData$Properties5$$, _PTData$Properties5$$2, _PTData$Properties6, _PTData$Properties6$, _PTData$Properties7, _PTData$Properties7$, _PTData$Properties7$$, _PTData$Properties7$$2, _PTData$Properties8, _PTData$Properties8$, _data$WaterConnection117, _data$WaterConnection118, _data$SewerageConnect112, _data$SewerageConnect113, _data$WaterConnection119, _data$WaterConnection120, _data$SewerageConnect114, _data$SewerageConnect115, _propertyAddress$city, _propertyAddress$city2, _propertyAddress$city3, _propertyAddress$city4, _propertyAddress$loca, _propertyAddress$loca2, _propertyAddress$subL, _propertyAddress$subL2, _propertyAddress$asse, _propertyAddress$asse2, _propertyAddress$bloc, _propertyAddress$bloc2, _propertyAddress$ward, _propertyAddress$ward2, _propertyAddress$zone, _propertyAddress$zone2, _propertyAddress$zone3, _propertyAddress$zone4, _useDetails$categoryT, _useDetails$categoryT2, _useDetails$propertyC, _useDetails$propertyC2, _propertyAdditionalDe, _propertyAdditionalDe2, _PTData$Properties9, _PTData$Properties9$, _useDetails$propertyT, _useDetails$propertyT2, _propertyAdditionalDe3, _propertyAdditionalDe4, _PTData$Properties0, _PTData$Properties0$, _useDetails$WaterConn, _useDetails$WaterConn2, _useDetails$waterConn, _useDetails$waterConn2, _propertyAdditionalDe5, _propertyAdditionalDe6, _useDetails$noOfFloor, _useDetails$noOfFloor2, _PTData$Properties1, _PTData$Properties1$, _useDetails$SelectYea, _useDetails$SelectYea2, _useDetails$SelectYea3, _useDetails$construct, _useDetails$construct2, _applicationData$dueV, _data$WaterConnection121, _data$WaterConnection122, _data$WaterConnection123, _data$WaterConnection124, _data$SewerageConnect116, _data$SewerageConnect117, _data$SewerageConnect118, _data$SewerageConnect119, _data$WaterConnection127, _data$WaterConnection128, _data$WaterConnection129, _data$WaterConnection130, _data$WaterConnection131, _data$WaterConnection132, _data$SewerageConnect122, _data$SewerageConnect123, _data$SewerageConnect124, _data$SewerageConnect125, _data$SewerageConnect126, _data$SewerageConnect127, _data$WaterConnection138, _data$WaterConnection139, _data$WaterConnection140, _data$WaterConnection141, _data$WaterConnection142, _data$SewerageConnect133, _data$SewerageConnect134, _data$SewerageConnect135, _data$SewerageConnect136, _data$SewerageConnect137, _data$WaterConnection143, _data$WaterConnection144, _data$SewerageConnect138, _data$SewerageConnect139, _data$WaterConnection145, _data$WaterConnection146, _data$SewerageConnect140, _data$SewerageConnect141, _data$WaterConnection147, _data$WaterConnection148, _data$SewerageConnect142, _data$SewerageConnect143, _data$WaterConnection149, _data$WaterConnection150, _data$WaterConnection151, _data$SewerageConnect144, _data$SewerageConnect145, _data$WaterConnection152, _data$WaterConnection153, _data$SewerageConnect146, _data$SewerageConnect147, _data$WaterConnection154, _data$WaterConnection155, _data$WaterConnection156, _data$WaterConnection157, _data$WaterConnection158, _data$SewerageConnect148, _data$SewerageConnect149, _data$SewerageConnect150, _data$SewerageConnect151, _data$SewerageConnect152, _data$WaterConnection159, _data$WaterConnection160, _data$SewerageConnect153, _data$SewerageConnect154, _data$SewerageConnect155, _data$SewerageConnect156, _data$SewerageConnect157, _data$SewerageConnect158, _data$SewerageConnect159, _data$SewerageConnect160, _data$SewerageConnect161, _data$SewerageConnect162, _data$SewerageConnect163, _data$WaterConnection161, _data$WaterConnection162, _data$WaterConnection163, _data$WaterConnection164, _data$WaterConnection165, _data$WaterConnection166, _data$WaterConnection167, _data$WaterConnection168, _data$WaterConnection169, _data$WaterConnection170, _data$WaterConnection171, _data$WaterConnection172, _data$WaterConnection173, _data$SewerageConnect164, _data$SewerageConnect165, _data$SewerageConnect166, _data$SewerageConnect167, _data$WaterConnection174, _data$SewerageConnect168, _data$WaterConnection175, _data$WaterConnection176, _data$WaterConnection177, _data$SewerageConnect169, _data$SewerageConnect170, _data$WaterConnection178, _data$WaterConnection179, _data$SewerageConnect171, _data$SewerageConnect172, _data$WaterConnection180, _data$WaterConnection181, _data$SewerageConnect173;
33834
+ var _user$info, _user$info$userName, _user$info2, _user$info3, _Digit$SessionStorage, _user$info4, _data$WaterConnection, _data$WaterConnection2, _data$SewerageConnect, _data$SewerageConnect2, _data$WaterConnection3, _data$WaterConnection4, _data$WaterConnection5, _data$SewerageConnect3, _data$SewerageConnect4, _data$SewerageConnect5, _data$WaterConnection6, _data$WaterConnection7, _data$SewerageConnect6, _data$SewerageConnect7, _data$WaterConnection8, _data$WaterConnection9, _data$SewerageConnect8, _data$SewerageConnect9, _data$WaterConnection0, _data$WaterConnection1, _data$SewerageConnect0, _data$SewerageConnect1, _data$WaterConnection10, _data$SewerageConnect10, _PTData$Properties, _PTData$Properties$, _PTData$Properties2, _PTData$Properties2$, _data$WaterConnection11, _data$WaterConnection12, _data$WaterConnection13, _data$WaterConnection14, _data$SewerageConnect11, _data$SewerageConnect12, _data$SewerageConnect13, _data$SewerageConnect14, _data$WaterConnection15, _data$WaterConnection16, _data$SewerageConnect15, _data$SewerageConnect16, _appDetailsData$appli, _data$WaterConnection35, _data$WaterConnection36, _data$WaterConnection37, _data$SewerageConnect31, _data$SewerageConnect32, _data$SewerageConnect33, _data$WaterConnection38, _data$WaterConnection39, _data$SewerageConnect34, _data$SewerageConnect35, _data$WaterConnection40, _data$WaterConnection41, _data$WaterConnection42, _data$SewerageConnect36, _data$SewerageConnect37, _data$SewerageConnect38, _data$WaterConnection43, _data$WaterConnection44, _data$WaterConnection45, _data$SewerageConnect39, _data$SewerageConnect40, _data$SewerageConnect41, _data$WaterConnection46, _data$WaterConnection47, _data$SewerageConnect42, _data$WaterConnection48, _data$WaterConnection49, _data$SewerageConnect43, _data$SewerageConnect44, _data$WaterConnection50, _data$WaterConnection51, _data$SewerageConnect45, _data$SewerageConnect46, _data$WaterConnection52, _data$WaterConnection53, _data$WaterConnection54, _data$SewerageConnect47, _data$SewerageConnect48, _data$SewerageConnect49, _data$WaterConnection55, _data$WaterConnection56, _data$SewerageConnect50, _data$SewerageConnect51, _data$WaterConnection57, _data$WaterConnection58, _data$SewerageConnect52, _data$SewerageConnect53, _data$WaterConnection59, _data$WaterConnection60, _data$WaterConnection61, _data$SewerageConnect54, _data$SewerageConnect55, _data$SewerageConnect56, _data$WaterConnection62, _data$WaterConnection63, _data$SewerageConnect57, _data$SewerageConnect58, _data$WaterConnection64, _data$WaterConnection65, _data$WaterConnection66, _data$SewerageConnect59, _data$SewerageConnect60, _data$SewerageConnect61, _data$WaterConnection67, _data$WaterConnection68, _data$SewerageConnect62, _data$SewerageConnect63, _data$WaterConnection69, _data$WaterConnection70, _data$WaterConnection71, _data$SewerageConnect64, _data$SewerageConnect65, _data$SewerageConnect66, _data$WaterConnection72, _data$WaterConnection73, _data$WaterConnection74, _data$WaterConnection75, _data$SewerageConnect67, _data$SewerageConnect68, _data$SewerageConnect69, _data$SewerageConnect70, _connectionDetails$se, _connectionDetails$se2, _connectionDetails$ap, _connectionDetails$ap2, _connectionDetails$do, _connectionDetails$de, _connectionDetails$de2, _data$WaterConnection76, _data$WaterConnection77, _data$WaterConnection78, _data$SewerageConnect71, _data$SewerageConnect72, _data$SewerageConnect73, _data$WaterConnection79, _data$WaterConnection80, _data$WaterConnection81, _data$WaterConnection82, _data$SewerageConnect74, _data$SewerageConnect75, _data$SewerageConnect76, _data$SewerageConnect77, _data$WaterConnection83, _data$WaterConnection84, _data$WaterConnection85, _data$WaterConnection86, _data$SewerageConnect78, _data$SewerageConnect79, _data$SewerageConnect80, _data$SewerageConnect81, _data$WaterConnection87, _data$WaterConnection88, _data$WaterConnection89, _data$WaterConnection90, _data$SewerageConnect82, _data$SewerageConnect83, _data$SewerageConnect84, _data$SewerageConnect85, _data$WaterConnection91, _data$WaterConnection92, _data$WaterConnection93, _data$WaterConnection94, _data$SewerageConnect86, _data$SewerageConnect87, _data$SewerageConnect88, _data$SewerageConnect89, _data$WaterConnection95, _data$WaterConnection96, _data$WaterConnection97, _data$WaterConnection98, _data$SewerageConnect90, _data$SewerageConnect91, _data$SewerageConnect92, _data$SewerageConnect93, _data$WaterConnection99, _data$WaterConnection100, _data$WaterConnection101, _data$WaterConnection102, _data$SewerageConnect94, _data$SewerageConnect95, _data$SewerageConnect96, _data$SewerageConnect97, _data$WaterConnection103, _data$WaterConnection104, _data$WaterConnection105, _data$WaterConnection106, _data$SewerageConnect98, _data$SewerageConnect99, _data$SewerageConnect100, _data$SewerageConnect101, _data$WaterConnection107, _data$WaterConnection108, _data$WaterConnection109, _data$WaterConnection110, _data$SewerageConnect102, _data$SewerageConnect103, _data$SewerageConnect104, _data$SewerageConnect105, _data$WaterConnection111, _data$WaterConnection112, _data$WaterConnection113, _data$WaterConnection114, _data$SewerageConnect106, _data$SewerageConnect107, _data$SewerageConnect108, _data$SewerageConnect109, _data$WaterConnection115, _data$WaterConnection116, _data$SewerageConnect110, _data$SewerageConnect111, _PTData$Properties5, _PTData$Properties5$, _PTData$Properties5$$, _PTData$Properties5$$2, _PTData$Properties6, _PTData$Properties6$, _PTData$Properties7, _PTData$Properties7$, _PTData$Properties7$$, _PTData$Properties7$$2, _PTData$Properties8, _PTData$Properties8$, _data$WaterConnection117, _data$WaterConnection118, _data$SewerageConnect112, _data$SewerageConnect113, _data$WaterConnection119, _data$WaterConnection120, _data$SewerageConnect114, _data$SewerageConnect115, _propertyAddress$city, _propertyAddress$city2, _propertyAddress$city3, _propertyAddress$city4, _propertyAddress$loca, _propertyAddress$loca2, _propertyAddress$subL, _propertyAddress$subL2, _propertyAddress$asse, _propertyAddress$asse2, _propertyAddress$bloc, _propertyAddress$bloc2, _propertyAddress$ward, _propertyAddress$ward2, _propertyAddress$zone, _propertyAddress$zone2, _propertyAddress$zone3, _propertyAddress$zone4, _useDetails$categoryT, _useDetails$categoryT2, _useDetails$propertyC, _useDetails$propertyC2, _propertyAdditionalDe, _propertyAdditionalDe2, _PTData$Properties9, _PTData$Properties9$, _useDetails$propertyT, _useDetails$propertyT2, _propertyAdditionalDe3, _propertyAdditionalDe4, _PTData$Properties0, _PTData$Properties0$, _useDetails$WaterConn, _useDetails$WaterConn2, _useDetails$waterConn, _useDetails$waterConn2, _propertyAdditionalDe5, _propertyAdditionalDe6, _useDetails$noOfFloor, _useDetails$noOfFloor2, _PTData$Properties1, _PTData$Properties1$, _useDetails$SelectYea, _useDetails$SelectYea2, _useDetails$SelectYea3, _useDetails$construct, _useDetails$construct2, _useDetails$propertyT3, _applicationData$dueV, _data$WaterConnection121, _data$WaterConnection122, _data$WaterConnection123, _data$WaterConnection124, _data$SewerageConnect116, _data$SewerageConnect117, _data$SewerageConnect118, _data$SewerageConnect119, _data$WaterConnection127, _data$WaterConnection128, _data$WaterConnection129, _data$WaterConnection130, _data$WaterConnection131, _data$WaterConnection132, _data$SewerageConnect122, _data$SewerageConnect123, _data$SewerageConnect124, _data$SewerageConnect125, _data$SewerageConnect126, _data$SewerageConnect127, _data$WaterConnection138, _data$WaterConnection139, _data$WaterConnection140, _data$WaterConnection141, _data$WaterConnection142, _data$SewerageConnect133, _data$SewerageConnect134, _data$SewerageConnect135, _data$SewerageConnect136, _data$SewerageConnect137, _data$WaterConnection143, _data$WaterConnection144, _data$SewerageConnect138, _data$SewerageConnect139, _data$WaterConnection145, _data$WaterConnection146, _data$SewerageConnect140, _data$SewerageConnect141, _data$WaterConnection147, _data$WaterConnection148, _data$SewerageConnect142, _data$SewerageConnect143, _data$WaterConnection149, _data$WaterConnection150, _data$WaterConnection151, _data$SewerageConnect144, _data$SewerageConnect145, _data$WaterConnection152, _data$WaterConnection153, _data$SewerageConnect146, _data$SewerageConnect147, _data$WaterConnection154, _data$WaterConnection155, _data$WaterConnection156, _data$WaterConnection157, _data$WaterConnection158, _data$SewerageConnect148, _data$SewerageConnect149, _data$SewerageConnect150, _data$SewerageConnect151, _data$SewerageConnect152, _data$WaterConnection159, _data$WaterConnection160, _data$SewerageConnect153, _data$SewerageConnect154, _data$SewerageConnect155, _data$SewerageConnect156, _data$SewerageConnect157, _data$SewerageConnect158, _data$SewerageConnect159, _data$SewerageConnect160, _data$SewerageConnect161, _data$SewerageConnect162, _data$SewerageConnect163, _data$WaterConnection161, _data$WaterConnection162, _data$WaterConnection163, _data$WaterConnection164, _data$WaterConnection165, _data$WaterConnection166, _data$WaterConnection167, _data$WaterConnection168, _data$WaterConnection169, _data$WaterConnection170, _data$WaterConnection171, _data$WaterConnection172, _data$WaterConnection173, _data$SewerageConnect164, _data$SewerageConnect165, _data$SewerageConnect166, _data$SewerageConnect167, _data$WaterConnection174, _data$SewerageConnect168, _data$WaterConnection175, _data$WaterConnection176, _data$WaterConnection177, _data$SewerageConnect169, _data$SewerageConnect170, _data$WaterConnection178, _data$WaterConnection179, _data$SewerageConnect171, _data$SewerageConnect172, _data$WaterConnection180, _data$WaterConnection181, _data$SewerageConnect173;
33810
33835
  const getDisconnectionNoticeSearch = function () {
33811
33836
  try {
33812
33837
  var _data$WaterConnection183, _data$WaterConnection184, _data$SewerageConnect175, _data$SewerageConnect176;
@@ -34399,6 +34424,9 @@ const WSApplicationDetails = () => {
34399
34424
  }), /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
34400
34425
  label: t("SubLocality"),
34401
34426
  text: `${t(checkForNA$1((propertyAddress === null || propertyAddress === void 0 ? void 0 : (_propertyAddress$subL = propertyAddress.subLocality) === null || _propertyAddress$subL === void 0 ? void 0 : _propertyAddress$subL.name) || (propertyAddress === null || propertyAddress === void 0 ? void 0 : (_propertyAddress$subL2 = propertyAddress.subLocality) === null || _propertyAddress$subL2 === void 0 ? void 0 : _propertyAddress$subL2.code) || (propertyAddress === null || propertyAddress === void 0 ? void 0 : propertyAddress.subLocality)))}`
34427
+ }), /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
34428
+ label: t("COMMON_COLONY_MCD_CATEGORY"),
34429
+ text: `${t(checkForNA$1(propertyAddress === null || propertyAddress === void 0 ? void 0 : propertyAddress.colonyMcdCategory))}`
34402
34430
  }), /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
34403
34431
  label: t("STREET_NAME"),
34404
34432
  text: `${t(checkForNA$1((propertyAddress === null || propertyAddress === void 0 ? void 0 : propertyAddress.streetName) || (propertyAddress === null || propertyAddress === void 0 ? void 0 : propertyAddress.street)))}`
@@ -34468,13 +34496,16 @@ const WSApplicationDetails = () => {
34468
34496
  }), /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
34469
34497
  label: t("WS_BUILT_UP_AREA"),
34470
34498
  text: `${t(checkForNA$1(useDetails === null || useDetails === void 0 ? void 0 : useDetails.builtUpArea))}`
34499
+ }), /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
34500
+ label: t("WS_HEIGHT_OF_THE_BUILDING"),
34501
+ text: `${t(checkForNA$1(useDetails === null || useDetails === void 0 ? void 0 : useDetails.heightOfTheBuilding))}`
34471
34502
  }), /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
34472
34503
  label: t("WS_SELECT_YEAR_OF_CONSTRUCTION"),
34473
34504
  text: `${t(checkForNA$1((useDetails === null || useDetails === void 0 ? void 0 : (_useDetails$SelectYea = useDetails.SelectYearofConstruction) === null || _useDetails$SelectYea === void 0 ? void 0 : _useDetails$SelectYea.i18nKey) || (useDetails === null || useDetails === void 0 ? void 0 : (_useDetails$SelectYea2 = useDetails.SelectYearofConstruction) === null || _useDetails$SelectYea2 === void 0 ? void 0 : _useDetails$SelectYea2.value) || (useDetails === null || useDetails === void 0 ? void 0 : (_useDetails$SelectYea3 = useDetails.SelectYearofConstruction) === null || _useDetails$SelectYea3 === void 0 ? void 0 : _useDetails$SelectYea3.code) || (useDetails === null || useDetails === void 0 ? void 0 : useDetails.SelectYearofConstruction) || (useDetails === null || useDetails === void 0 ? void 0 : (_useDetails$construct = useDetails.constructionYear) === null || _useDetails$construct === void 0 ? void 0 : _useDetails$construct.i18nKey) || (useDetails === null || useDetails === void 0 ? void 0 : (_useDetails$construct2 = useDetails.constructionYear) === null || _useDetails$construct2 === void 0 ? void 0 : _useDetails$construct2.code) || (useDetails === null || useDetails === void 0 ? void 0 : useDetails.constructionYear)))}`
34474
- }), /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
34505
+ }), ["Apartment", "DDAFlats", "GovtFlats", "Bungalows", "FlatOrApartment", "GroupHousingSociety", "JJSLUMS", "IndividualHouse", "BuiltUp.GroupHousingSociety", "BuiltUp.JJSLUMS", "BuiltUp.IndividualHouse"].includes((useDetails === null || useDetails === void 0 ? void 0 : (_useDetails$propertyT3 = useDetails.propertyType) === null || _useDetails$propertyT3 === void 0 ? void 0 : _useDetails$propertyT3.code) || (useDetails === null || useDetails === void 0 ? void 0 : useDetails.propertyType)) ? /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
34475
34506
  label: t("WS_NUMBER_OF_DWELLING_UNITS"),
34476
34507
  text: `${t(checkForNA$1((useDetails === null || useDetails === void 0 ? void 0 : useDetails.NumberofDwellingUnits) || (useDetails === null || useDetails === void 0 ? void 0 : useDetails.noOfDwellingUnits)))}`
34477
- })), /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardHeader, {
34508
+ }) : null), /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardHeader, {
34478
34509
  styles: {
34479
34510
  fontSize: "28px"
34480
34511
  }
@@ -34489,9 +34520,6 @@ const WSApplicationDetails = () => {
34489
34520
  }), (djbEmployee === null || djbEmployee === void 0 ? void 0 : djbEmployee.isDjbEmployee) && /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
34490
34521
  label: t("WS_EMPLOYEE_ID"),
34491
34522
  text: `${t(checkForNA$1(djbEmployee === null || djbEmployee === void 0 ? void 0 : djbEmployee.employeeId))}`
34492
- }), /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
34493
- label: t("WS_DATE_OF_RETIREMENT"),
34494
- text: `${t(checkForNA$1(djbEmployee === null || djbEmployee === void 0 ? void 0 : djbEmployee.dor))}`
34495
34523
  }), /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
34496
34524
  label: t("WS_EMPLOYEE_DESIGNATION"),
34497
34525
  text: `${t(checkForNA$1(djbEmployee === null || djbEmployee === void 0 ? void 0 : djbEmployee.designation))}`
@@ -37341,7 +37369,7 @@ const ReSubmitDisconnectionApplication = () => {
37341
37369
  };
37342
37370
 
37343
37371
  const CheckPage = _ref => {
37344
- var _value$ConnectionDeta, _value$waterConnectio, _cpt$details12, _cpt$details13, _cpt$details14, _reversedOwners$, _cpt$details15, _cpt$details16, _cpt$details17, _connectionDetails$se, _connectionDetails$se2, _connectionDetails$co, _connectionDetails$co2, _connectionDetails$wa, _connectionDetails$wa2, _connectionDetails$ap, _connectionDetails$ap2, _connectionDetails$do, _connectionDetails$do2, _connectionDetails$do3, _connectionDetails$de, _connectionDetails$de2, _ConnectionHolderDeta, _ConnectionHolderDeta2, _ConnectionHolderDeta3, _ConnectionHolderDeta4, _ConnectionHolderDeta5, _ConnectionHolderDeta6, _ConnectionHolderDeta7, _ConnectionHolderDeta8, _ConnectionHolderDeta9, _ConnectionHolderDeta0, _propertyAddress$zro, _propertyAddress$addi, _propertyAddress$addr, _propertyAddress$addr2, _propertyAddress$city, _propertyAddress$city2, _propertyAddress$loca, _propertyAddress$loca2, _propertyAddress$subL, _propertyAddress$subL2, _propertyAddress$asse, _propertyAddress$asse2, _propertyAddress$bloc, _propertyAddress$bloc2, _propertyAddress$ward, _propertyAddress$ward2, _propertyAddress$zone, _propertyAddress$zone2, _propertyAddress$zone3, _propertyAddress$zone4, _useDetails$categoryT, _useDetails$categoryT2, _useDetails$propertyC, _useDetails$propertyC2, _useDetails$propertyT, _useDetails$propertyT2, _useDetails$WaterConn, _useDetails$WaterConn2, _useDetails$waterConn, _useDetails$waterConn2, _useDetails$noOfFloor, _useDetails$noOfFloor2, _useDetails$SelectYea, _useDetails$SelectYea2, _useDetails$SelectYea3, _useDetails$construct, _useDetails$construct2;
37372
+ var _value$ConnectionDeta, _value$waterConnectio, _cpt$details12, _cpt$details13, _cpt$details14, _reversedOwners$, _cpt$details15, _cpt$details16, _cpt$details17, _connectionDetails$se, _connectionDetails$se2, _connectionDetails$co, _connectionDetails$co2, _connectionDetails$wa, _connectionDetails$wa2, _connectionDetails$ap, _connectionDetails$ap2, _connectionDetails$do, _connectionDetails$do2, _connectionDetails$do3, _connectionDetails$de, _connectionDetails$de2, _ConnectionHolderDeta, _ConnectionHolderDeta2, _ConnectionHolderDeta3, _ConnectionHolderDeta4, _ConnectionHolderDeta5, _ConnectionHolderDeta6, _ConnectionHolderDeta7, _ConnectionHolderDeta8, _ConnectionHolderDeta9, _ConnectionHolderDeta0, _propertyAddress$zro, _propertyAddress$addi, _propertyAddress$addr, _propertyAddress$addr2, _propertyAddress$city, _propertyAddress$city2, _propertyAddress$loca, _propertyAddress$loca2, _propertyAddress$subL, _propertyAddress$subL2, _propertyAddress$asse, _propertyAddress$asse2, _propertyAddress$bloc, _propertyAddress$bloc2, _propertyAddress$ward, _propertyAddress$ward2, _propertyAddress$zone, _propertyAddress$zone2, _propertyAddress$zone3, _propertyAddress$zone4, _useDetails$categoryT, _useDetails$categoryT2, _useDetails$propertyC, _useDetails$propertyC2, _useDetails$propertyT, _useDetails$propertyT2, _useDetails$WaterConn, _useDetails$WaterConn2, _useDetails$waterConn, _useDetails$waterConn2, _useDetails$noOfFloor, _useDetails$noOfFloor2, _useDetails$SelectYea, _useDetails$SelectYea2, _useDetails$SelectYea3, _useDetails$construct, _useDetails$construct2, _useDetails$propertyT3;
37345
37373
  let {
37346
37374
  onSubmit,
37347
37375
  value
@@ -37645,10 +37673,10 @@ const CheckPage = _ref => {
37645
37673
  }), /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
37646
37674
  label: t("WS_SELECT_YEAR_OF_CONSTRUCTION"),
37647
37675
  text: `${t(checkForNA((useDetails === null || useDetails === void 0 ? void 0 : (_useDetails$SelectYea = useDetails.SelectYearofConstruction) === null || _useDetails$SelectYea === void 0 ? void 0 : _useDetails$SelectYea.i18nKey) || (useDetails === null || useDetails === void 0 ? void 0 : (_useDetails$SelectYea2 = useDetails.SelectYearofConstruction) === null || _useDetails$SelectYea2 === void 0 ? void 0 : _useDetails$SelectYea2.value) || (useDetails === null || useDetails === void 0 ? void 0 : (_useDetails$SelectYea3 = useDetails.SelectYearofConstruction) === null || _useDetails$SelectYea3 === void 0 ? void 0 : _useDetails$SelectYea3.code) || (useDetails === null || useDetails === void 0 ? void 0 : useDetails.SelectYearofConstruction) || (useDetails === null || useDetails === void 0 ? void 0 : (_useDetails$construct = useDetails.constructionYear) === null || _useDetails$construct === void 0 ? void 0 : _useDetails$construct.i18nKey) || (useDetails === null || useDetails === void 0 ? void 0 : (_useDetails$construct2 = useDetails.constructionYear) === null || _useDetails$construct2 === void 0 ? void 0 : _useDetails$construct2.code) || (useDetails === null || useDetails === void 0 ? void 0 : useDetails.constructionYear)))}`
37648
- }), /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
37676
+ }), ["Apartment", "DDAFlats", "GovtFlats", "Bungalows", "FlatOrApartment", "GroupHousingSociety", "JJSLUMS", "IndividualHouse", "BuiltUp.GroupHousingSociety", "BuiltUp.JJSLUMS", "BuiltUp.IndividualHouse"].includes((useDetails === null || useDetails === void 0 ? void 0 : (_useDetails$propertyT3 = useDetails.propertyType) === null || _useDetails$propertyT3 === void 0 ? void 0 : _useDetails$propertyT3.code) || (useDetails === null || useDetails === void 0 ? void 0 : useDetails.propertyType)) ? /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
37649
37677
  label: t("WS_NUMBER_OF_DWELLING_UNITS"),
37650
37678
  text: `${t(checkForNA((useDetails === null || useDetails === void 0 ? void 0 : useDetails.NumberofDwellingUnits) || (useDetails === null || useDetails === void 0 ? void 0 : useDetails.noOfDwellingUnits)))}`
37651
- })), /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardSubHeader, null, t("WS_DJB_EMPLOYEE")), /*#__PURE__*/React__default.createElement(digitUiReactComponents.StatusTable, {
37679
+ }) : null), /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardSubHeader, null, t("WS_DJB_EMPLOYEE")), /*#__PURE__*/React__default.createElement(digitUiReactComponents.StatusTable, {
37652
37680
  style: {
37653
37681
  marginTop: "10px",
37654
37682
  marginBottom: "30px"
@@ -37662,9 +37690,6 @@ const CheckPage = _ref => {
37662
37690
  }), (djbEmployee === null || djbEmployee === void 0 ? void 0 : djbEmployee.isDjbEmployee) && /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
37663
37691
  label: t("WS_EMPLOYEE_ID"),
37664
37692
  text: `${t(checkForNA(djbEmployee === null || djbEmployee === void 0 ? void 0 : djbEmployee.employeeId))}`
37665
- }), /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
37666
- label: t("WS_DATE_OF_RETIREMENT"),
37667
- text: `${t(checkForNA(djbEmployee === null || djbEmployee === void 0 ? void 0 : djbEmployee.dor))}`
37668
37693
  }), /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
37669
37694
  label: t("WS_EMPLOYEE_DESIGNATION"),
37670
37695
  text: `${t(checkForNA(djbEmployee === null || djbEmployee === void 0 ? void 0 : djbEmployee.designation))}`
@@ -40157,92 +40182,12 @@ const WSInfoPage = () => {
40157
40182
  }
40158
40183
  }
40159
40184
  `), /*#__PURE__*/React__default.createElement("div", {
40160
- className: "ws-info-header-card"
40161
- }, /*#__PURE__*/React__default.createElement("div", {
40162
40185
  className: "ws-header-badge-row"
40163
40186
  }, /*#__PURE__*/React__default.createElement("span", {
40164
40187
  className: "ws-service-tag"
40165
- }, t("Water & Sewerage Services")), /*#__PURE__*/React__default.createElement("span", {
40188
+ }, t("Apply For New Connection")), /*#__PURE__*/React__default.createElement("span", {
40166
40189
  className: "ws-portal-tag"
40167
- }, isEmployee ? t("Employee Portal") : t("Citizen Services"))), /*#__PURE__*/React__default.createElement("h1", {
40168
- className: "ws-page-title"
40169
- }, t("Apply For New Connection")), /*#__PURE__*/React__default.createElement("p", {
40170
- className: "ws-page-subtitle"
40171
- }, t("Submit an application for a new domestic, commercial, or industrial water/sewerage connection with Delhi Jal Board.")), /*#__PURE__*/React__default.createElement("div", {
40172
- className: "ws-guidance-box"
40173
- }, /*#__PURE__*/React__default.createElement("div", {
40174
- className: "ws-guidance-icon-wrap"
40175
- }, /*#__PURE__*/React__default.createElement("svg", {
40176
- width: "24",
40177
- height: "24",
40178
- viewBox: "0 0 24 24",
40179
- fill: "none",
40180
- stroke: "#1a67a3",
40181
- strokeWidth: "2",
40182
- strokeLinecap: "round",
40183
- strokeLinejoin: "round"
40184
- }, /*#__PURE__*/React__default.createElement("circle", {
40185
- cx: "12",
40186
- cy: "12",
40187
- r: "10"
40188
- }), /*#__PURE__*/React__default.createElement("line", {
40189
- x1: "12",
40190
- y1: "16",
40191
- x2: "12",
40192
- y2: "12"
40193
- }), /*#__PURE__*/React__default.createElement("line", {
40194
- x1: "12",
40195
- y1: "8",
40196
- x2: "12.01",
40197
- y2: "8"
40198
- }))), /*#__PURE__*/React__default.createElement("div", {
40199
- className: "ws-guidance-text-wrap"
40200
- }, /*#__PURE__*/React__default.createElement("div", {
40201
- className: "ws-guidance-title"
40202
- }, t("Before You Begin: What You Need To Know")), /*#__PURE__*/React__default.createElement("div", {
40203
- className: "ws-guidance-desc"
40204
- }, t("Applying for a new connection takes about 10–20 minutes. Water and sewerage connections are linked to a registered Property ID. Please verify your property below, review the required information checklist, and ensure you have all supporting documents ready before starting.")), /*#__PURE__*/React__default.createElement("div", {
40205
- className: "ws-guidance-chips"
40206
- }, /*#__PURE__*/React__default.createElement("div", {
40207
- className: "ws-chip"
40208
- }, /*#__PURE__*/React__default.createElement("svg", {
40209
- width: "14",
40210
- height: "14",
40211
- viewBox: "0 0 24 24",
40212
- fill: "none",
40213
- stroke: "currentColor",
40214
- strokeWidth: "2"
40215
- }, /*#__PURE__*/React__default.createElement("circle", {
40216
- cx: "12",
40217
- cy: "12",
40218
- r: "10"
40219
- }), /*#__PURE__*/React__default.createElement("polyline", {
40220
- points: "12 6 12 12 16 14"
40221
- })), /*#__PURE__*/React__default.createElement("span", null, t("Estimated time: 10-20 minutes"))), /*#__PURE__*/React__default.createElement("div", {
40222
- className: "ws-chip"
40223
- }, /*#__PURE__*/React__default.createElement("svg", {
40224
- width: "14",
40225
- height: "14",
40226
- viewBox: "0 0 24 24",
40227
- fill: "none",
40228
- stroke: "currentColor",
40229
- strokeWidth: "2"
40230
- }, /*#__PURE__*/React__default.createElement("path", {
40231
- d: "M3 9l9-7 9 7v11a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z"
40232
- })), /*#__PURE__*/React__default.createElement("span", null, t("Requires Registered Property ID"))), /*#__PURE__*/React__default.createElement("div", {
40233
- className: "ws-chip"
40234
- }, /*#__PURE__*/React__default.createElement("svg", {
40235
- width: "14",
40236
- height: "14",
40237
- viewBox: "0 0 24 24",
40238
- fill: "none",
40239
- stroke: "currentColor",
40240
- strokeWidth: "2"
40241
- }, /*#__PURE__*/React__default.createElement("path", {
40242
- d: "M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8z"
40243
- }), /*#__PURE__*/React__default.createElement("polyline", {
40244
- points: "14 2 14 8 20 8"
40245
- })), /*#__PURE__*/React__default.createElement("span", null, t("Keep Scanned Documents Ready (≤ 5MB)"))))))), /*#__PURE__*/React__default.createElement("div", {
40190
+ }, isEmployee ? t("Employee Portal") : t("Citizen Services"))), /*#__PURE__*/React__default.createElement("div", {
40246
40191
  className: "ws-card"
40247
40192
  }, /*#__PURE__*/React__default.createElement("div", {
40248
40193
  className: "ws-step-header"
@@ -40587,8 +40532,6 @@ const WSInfoPage = () => {
40587
40532
  className: "ws-tag-item"
40588
40533
  }, t("Employee ID")), /*#__PURE__*/React__default.createElement("span", {
40589
40534
  className: "ws-tag-item"
40590
- }, t("Date of Retirement")), /*#__PURE__*/React__default.createElement("span", {
40591
- className: "ws-tag-item"
40592
40535
  }, t("Employee Designation")))))), /*#__PURE__*/React__default.createElement("div", {
40593
40536
  className: "ws-checklist-column"
40594
40537
  }, /*#__PURE__*/React__default.createElement("div", {
@@ -42427,7 +42370,7 @@ const FileUploadField = _ref6 => {
42427
42370
  })))));
42428
42371
  };
42429
42372
  const NewApplication = () => {
42430
- var _Digit$SessionStorage, _getFieldError, _getFieldError2, _getFieldError3, _getFieldError4, _getFieldError5, _getFieldError6, _getFieldError7, _getFieldError8, _getFieldError9, _getFieldError0, _getFieldError1, _getFieldError10, _getFieldError11, _watch, _watch3, _watch4, _watch6, _watch8, _watch0, _formValues$applicati, _formValues$applicati2, _formValues$applicati3, _formValues$applicati4, _formValues$applicati5, _formValues$applicati6, _formValues$applicati7, _formValues$applicati8, _formValues$applicati9, _formValues$applicati0, _formValues$applicati1, _formValues$applicati10, _formValues$applicati11, _formValues$applicati12, _formValues$applicati13, _formValues$applicati14, _formValues$applicati15, _formValues$applicati16, _formValues$applicati17, _formValues$applicati18, _formValues$applicati19, _formValues$applicati20, _formValues$applicati21, _formValues$applicati22, _formValues$applicati23, _formValues$applicant, _formValues$applicant2, _formValues$applicant3, _formValues$applicant4, _formValues$applicant5, _formValues$applicant6, _formValues$applicant7, _formValues$useDetail, _formValues$applicant8, _formValues$contact, _formValues$contact2, _formValues$contact3, _formValues$documents, _formValues$djbEmploy, _formValues$djbEmploy2, _formValues$djbEmploy3, _formValues$djbEmploy4, _formValues$djbEmploy5, _formValues$disabilit, _formValues$governmen, _formValues$governmen2, _formValues$governmen3, _formValues$governmen4, _formValues$propertyA, _formValues$propertyA2, _formValues$propertyA3, _formValues$propertyA4, _formValues$propertyA5, _formValues$propertyA6, _formValues$propertyA7, _formValues$propertyA8, _formValues$propertyA9, _formValues$propertyA0, _formValues$propertyA1, _formValues$useDetail2, _formValues$useDetail3, _formValues$useDetail4, _formValues$useDetail5, _formValues$useDetail6, _formValues$useDetail7, _formValues$useDetail8, _formValues$useDetail9, _formValues$useDetail0, _formValues$useDetail1, _formValues$useDetail10, _formValues$useDetail11, _formValues$documents2, _formValues$documents3, _formValues$documents4, _formValues$documents5, _formValues$documents6, _formValues$documents7, _formValues$documents8, _formValues$documents9, _formValues$documents0, _formValues$documents1, _formValues$declarati, _formValues$declarati2, _formValues$declarati3, _formValues$declarati4, _formValues$declarati5;
42373
+ var _Digit$SessionStorage, _getFieldError, _getFieldError2, _getFieldError3, _getFieldError4, _getFieldError5, _getFieldError6, _getFieldError7, _getFieldError8, _getFieldError9, _getFieldError0, _getFieldError1, _getFieldError10, _getFieldError11, _watch, _watch3, _watch4, _watch6, _watch8, _watch0, _formValues$applicati, _formValues$applicati2, _formValues$applicati3, _formValues$applicati4, _formValues$applicati5, _formValues$applicati6, _formValues$applicati7, _formValues$applicati8, _formValues$applicati9, _formValues$applicati0, _formValues$applicati1, _formValues$applicati10, _formValues$applicati11, _formValues$applicati12, _formValues$applicati13, _formValues$applicati14, _formValues$applicati15, _formValues$applicati16, _formValues$applicati17, _formValues$applicati18, _formValues$applicati19, _formValues$applicati20, _formValues$applicati21, _formValues$applicati22, _formValues$applicati23, _formValues$applicant, _formValues$applicant2, _formValues$applicant3, _formValues$applicant4, _formValues$applicant5, _formValues$applicant6, _formValues$applicant7, _formValues$useDetail, _formValues$applicant8, _formValues$contact, _formValues$contact2, _formValues$contact3, _formValues$documents, _formValues$djbEmploy, _formValues$djbEmploy2, _formValues$djbEmploy3, _formValues$djbEmploy4, _formValues$disabilit, _formValues$governmen, _formValues$governmen2, _formValues$governmen3, _formValues$governmen4, _formValues$propertyA, _formValues$propertyA2, _formValues$propertyA3, _formValues$propertyA4, _formValues$propertyA5, _formValues$propertyA6, _formValues$propertyA7, _formValues$propertyA8, _formValues$propertyA9, _formValues$propertyA0, _formValues$propertyA1, _formValues$useDetail2, _formValues$useDetail3, _formValues$useDetail4, _formValues$useDetail5, _formValues$useDetail6, _formValues$useDetail7, _formValues$useDetail8, _formValues$useDetail9, _formValues$useDetail0, _formValues$useDetail1, _formValues$useDetail10, _formValues$useDetail11, _formValues$useDetail12, _formValues$useDetail13, _formValues$documents2, _formValues$documents3, _formValues$documents4, _formValues$documents5, _formValues$documents6, _formValues$documents7, _formValues$documents8, _formValues$documents9, _formValues$documents0, _formValues$documents1, _formValues$declarati, _formValues$declarati2, _formValues$declarati3, _formValues$declarati4, _formValues$declarati5;
42431
42374
  const {
42432
42375
  t
42433
42376
  } = reactI18next.useTranslation();
@@ -42586,6 +42529,8 @@ const NewApplication = () => {
42586
42529
  const isDjbEmployee = watch("djbEmployee.isDjbEmployee");
42587
42530
  const isGovernmentEmployee = watch("governmentEmployee.isGovernmentEmployee");
42588
42531
  const selectedPropertyType = watch("useDetails.propertyType");
42532
+ const dwellingPropertyTypes = ["Apartment", "DDAFlats", "GovtFlats", "Bungalows", "FlatOrApartment", "GroupHousingSociety", "JJSLUMS", "IndividualHouse", "BuiltUp.GroupHousingSociety", "BuiltUp.JJSLUMS", "BuiltUp.IndividualHouse"];
42533
+ const isDwellingUnit = dwellingPropertyTypes.includes(selectedPropertyType === null || selectedPropertyType === void 0 ? void 0 : selectedPropertyType.code);
42589
42534
  const selectedLocality = watch("propertyAddress.locality");
42590
42535
  const selectedSubLocality = watch("propertyAddress.subLocality");
42591
42536
  const pCode = watch("propertyAddress.pinCode");
@@ -43853,20 +43798,6 @@ const NewApplication = () => {
43853
43798
  required: isDjbEmployee ? "Employee ID is required." : false
43854
43799
  }),
43855
43800
  name: "djbEmployee.employeeId"
43856
- })), /*#__PURE__*/React__default.createElement(FieldBlock, {
43857
- error: getFieldError("djbEmployee.retirementDate"),
43858
- label: t("WS_DATE_OF_RETIREMENT"),
43859
- required: isDjbEmployee
43860
- }, /*#__PURE__*/React__default.createElement(reactHookForm.Controller, {
43861
- control: control,
43862
- name: "djbEmployee.retirementDate",
43863
- rules: {
43864
- required: isDjbEmployee ? "Date of Retirement is required." : false
43865
- },
43866
- render: props => /*#__PURE__*/React__default.createElement(digitUiReactComponents.DatePicker, {
43867
- date: props.value,
43868
- onChange: props.onChange
43869
- })
43870
43801
  })), /*#__PURE__*/React__default.createElement(FieldBlock, {
43871
43802
  error: getFieldError("djbEmployee.officeNameAndAddress"),
43872
43803
  isFullWidth: true,
@@ -44199,7 +44130,7 @@ const NewApplication = () => {
44199
44130
  select: props.onChange,
44200
44131
  t: t
44201
44132
  })
44202
- })), /*#__PURE__*/React__default.createElement(FieldBlock, {
44133
+ })), isDwellingUnit ? /*#__PURE__*/React__default.createElement(FieldBlock, {
44203
44134
  error: getFieldError("useDetails.NumberofDwellingUnits"),
44204
44135
  label: t("WS_NUMBER_OF_DWELLING_UNITS"),
44205
44136
  required: true
@@ -44210,10 +44141,10 @@ const NewApplication = () => {
44210
44141
  value: DECIMAL_PATTERN$2,
44211
44142
  message: "Enter a valid numeric value."
44212
44143
  },
44213
- required: "Built Up Area is required."
44144
+ required: "Number of Dwelling Units is required."
44214
44145
  }),
44215
44146
  name: "useDetails.NumberofDwellingUnits"
44216
- })), /*#__PURE__*/React__default.createElement(FieldBlock, {
44147
+ })) : null, /*#__PURE__*/React__default.createElement(FieldBlock, {
44217
44148
  error: getFieldError("useDetails.NumberofRooms"),
44218
44149
  label: t("WS_NUMBER_OF_ROOMS"),
44219
44150
  required: true
@@ -44406,7 +44337,7 @@ const NewApplication = () => {
44406
44337
  control: control,
44407
44338
  name: "documents.otherDocument",
44408
44339
  render: props => /*#__PURE__*/React__default.createElement(digitUiReactComponents.Dropdown, {
44409
- option: OTHER_DOCUMENTS_OPTIONS,
44340
+ option: (selectedApplicantType === null || selectedApplicantType === void 0 ? void 0 : selectedApplicantType.code) === "TENANT" ? OTHER_DOCUMENTS_OPTIONS : OTHER_DOCUMENTS_OPTIONS.filter(opt => opt.code !== "NOC_FROM_OWNER"),
44410
44341
  optionKey: "name",
44411
44342
  selected: props.value,
44412
44343
  select: props.onChange,
@@ -44625,13 +44556,10 @@ const NewApplication = () => {
44625
44556
  }), formValues !== null && formValues !== void 0 && (_formValues$djbEmploy2 = formValues.djbEmployee) !== null && _formValues$djbEmploy2 !== void 0 && _formValues$djbEmploy2.isDjbEmployee ? /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement(PreviewItem, {
44626
44557
  label: "Employee ID",
44627
44558
  value: formValues === null || formValues === void 0 ? void 0 : (_formValues$djbEmploy3 = formValues.djbEmployee) === null || _formValues$djbEmploy3 === void 0 ? void 0 : _formValues$djbEmploy3.employeeId
44628
- }), /*#__PURE__*/React__default.createElement(PreviewItem, {
44629
- label: "Date of Retirement",
44630
- value: formValues === null || formValues === void 0 ? void 0 : (_formValues$djbEmploy4 = formValues.djbEmployee) === null || _formValues$djbEmploy4 === void 0 ? void 0 : _formValues$djbEmploy4.retirementDate
44631
44559
  }), /*#__PURE__*/React__default.createElement(PreviewItem, {
44632
44560
  isFullWidth: true,
44633
44561
  label: "Office Name & Address",
44634
- value: formValues === null || formValues === void 0 ? void 0 : (_formValues$djbEmploy5 = formValues.djbEmployee) === null || _formValues$djbEmploy5 === void 0 ? void 0 : _formValues$djbEmploy5.officeNameAndAddress
44562
+ value: formValues === null || formValues === void 0 ? void 0 : (_formValues$djbEmploy4 = formValues.djbEmployee) === null || _formValues$djbEmploy4 === void 0 ? void 0 : _formValues$djbEmploy4.officeNameAndAddress
44635
44563
  })) : null), /*#__PURE__*/React__default.createElement(SectionCard, {
44636
44564
  description: "Divyangjan/Person with Disability declaration.",
44637
44565
  isOpen: collapsedSections.disability,
@@ -44718,18 +44646,18 @@ const NewApplication = () => {
44718
44646
  }), /*#__PURE__*/React__default.createElement(PreviewItem, {
44719
44647
  label: "Number of Floors",
44720
44648
  value: formValues === null || formValues === void 0 ? void 0 : (_formValues$useDetail5 = formValues.useDetails) === null || _formValues$useDetail5 === void 0 ? void 0 : _formValues$useDetail5.noOfFloors
44721
- }), /*#__PURE__*/React__default.createElement(PreviewItem, {
44649
+ }), dwellingPropertyTypes.includes(formValues === null || formValues === void 0 ? void 0 : (_formValues$useDetail6 = formValues.useDetails) === null || _formValues$useDetail6 === void 0 ? void 0 : (_formValues$useDetail7 = _formValues$useDetail6.propertyType) === null || _formValues$useDetail7 === void 0 ? void 0 : _formValues$useDetail7.code) ? /*#__PURE__*/React__default.createElement(PreviewItem, {
44722
44650
  label: "Number of Dwelling Units",
44723
- value: formValues === null || formValues === void 0 ? void 0 : (_formValues$useDetail6 = formValues.useDetails) === null || _formValues$useDetail6 === void 0 ? void 0 : _formValues$useDetail6.NumberofDwellingUnits
44724
- }), (formValues === null || formValues === void 0 ? void 0 : (_formValues$useDetail7 = formValues.useDetails) === null || _formValues$useDetail7 === void 0 ? void 0 : (_formValues$useDetail8 = _formValues$useDetail7.propertyType) === null || _formValues$useDetail8 === void 0 ? void 0 : _formValues$useDetail8.code) === "HOSPITAL" || (formValues === null || formValues === void 0 ? void 0 : (_formValues$useDetail9 = formValues.useDetails) === null || _formValues$useDetail9 === void 0 ? void 0 : (_formValues$useDetail0 = _formValues$useDetail9.propertyType) === null || _formValues$useDetail0 === void 0 ? void 0 : _formValues$useDetail0.code) === "HOSPITAL_NURSING_HOME" ? /*#__PURE__*/React__default.createElement(PreviewItem, {
44651
+ value: formValues === null || formValues === void 0 ? void 0 : (_formValues$useDetail8 = formValues.useDetails) === null || _formValues$useDetail8 === void 0 ? void 0 : _formValues$useDetail8.NumberofDwellingUnits
44652
+ }) : null, (formValues === null || formValues === void 0 ? void 0 : (_formValues$useDetail9 = formValues.useDetails) === null || _formValues$useDetail9 === void 0 ? void 0 : (_formValues$useDetail0 = _formValues$useDetail9.propertyType) === null || _formValues$useDetail0 === void 0 ? void 0 : _formValues$useDetail0.code) === "HOSPITAL" || (formValues === null || formValues === void 0 ? void 0 : (_formValues$useDetail1 = formValues.useDetails) === null || _formValues$useDetail1 === void 0 ? void 0 : (_formValues$useDetail10 = _formValues$useDetail1.propertyType) === null || _formValues$useDetail10 === void 0 ? void 0 : _formValues$useDetail10.code) === "HOSPITAL_NURSING_HOME" ? /*#__PURE__*/React__default.createElement(PreviewItem, {
44725
44653
  label: "No. of Beds",
44726
- value: formValues === null || formValues === void 0 ? void 0 : (_formValues$useDetail1 = formValues.useDetails) === null || _formValues$useDetail1 === void 0 ? void 0 : _formValues$useDetail1.hospitalBeds
44654
+ value: formValues === null || formValues === void 0 ? void 0 : (_formValues$useDetail11 = formValues.useDetails) === null || _formValues$useDetail11 === void 0 ? void 0 : _formValues$useDetail11.hospitalBeds
44727
44655
  }) : null, /*#__PURE__*/React__default.createElement(PreviewItem, {
44728
44656
  label: "Year of Construction",
44729
- value: formValues === null || formValues === void 0 ? void 0 : (_formValues$useDetail10 = formValues.useDetails) === null || _formValues$useDetail10 === void 0 ? void 0 : _formValues$useDetail10.SelectYearofConstruction
44657
+ value: formValues === null || formValues === void 0 ? void 0 : (_formValues$useDetail12 = formValues.useDetails) === null || _formValues$useDetail12 === void 0 ? void 0 : _formValues$useDetail12.SelectYearofConstruction
44730
44658
  }), /*#__PURE__*/React__default.createElement(PreviewItem, {
44731
44659
  label: "Water Connection Usage Type",
44732
- value: formValues === null || formValues === void 0 ? void 0 : (_formValues$useDetail11 = formValues.useDetails) === null || _formValues$useDetail11 === void 0 ? void 0 : _formValues$useDetail11.WaterConnectionUsageType
44660
+ value: formValues === null || formValues === void 0 ? void 0 : (_formValues$useDetail13 = formValues.useDetails) === null || _formValues$useDetail13 === void 0 ? void 0 : _formValues$useDetail13.WaterConnectionUsageType
44733
44661
  })), /*#__PURE__*/React__default.createElement(SectionCard, {
44734
44662
  description: "Uploaded supporting documents.",
44735
44663
  isOpen: collapsedSections.documents,
@@ -52497,7 +52425,7 @@ const ApplicationDetails = props => {
52497
52425
  };
52498
52426
 
52499
52427
  const ApplicationDetails$1 = () => {
52500
- 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, _applicationDetails$p8, _applicationDetails$p9, _workflowDetails$data4, _workflowDetails$data5, _workflowDetails$data6, _workflowDetails$data7, _workflowDetails$data8, _workflowDetails$data9, _workflowDetails$data0, _workflowDetails$data1, _workflowDetails$data10, _workflowDetails$data11, _workflowDetails$data12, _workflowDetails$data13, _workflowDetails$data14, _workflowDetails$data21, _workflowDetails$data22, _workflowDetails$data23, _oldData$WaterConnect, _oldData$WaterConnect2, _oldData$SewerageConn, _oldData$SewerageConn2, _applicationDetails$a22, _applicationDetails$a23, _reciept_data$Payment2, _applicationDetails$p17, _applicationDetails$p18, _applicationDetails$p19, _applicationDetails$p20, _applicationDetails$p21, _applicationDetails$p22;
52428
+ 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, _reciept_data$Payment, _applicationDetails$a0, _applicationDetails$p8, _applicationDetails$p9, _workflowDetails$data4, _workflowDetails$data5, _workflowDetails$data6, _workflowDetails$data7, _workflowDetails$data8, _workflowDetails$data9, _workflowDetails$data0, _workflowDetails$data1, _workflowDetails$data10, _workflowDetails$data11, _workflowDetails$data12, _workflowDetails$data13, _workflowDetails$data14, _workflowDetails$data21, _workflowDetails$data22, _workflowDetails$data23, _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;
52501
52429
  const getRecieptSearch = function (tenantId, payments, consumerCodes, receiptKey) {
52502
52430
  try {
52503
52431
  let response = null;
@@ -52541,7 +52469,7 @@ const ApplicationDetails$1 = () => {
52541
52469
  const [showToast, setShowToast] = React.useState(null);
52542
52470
  const [showWaringToast, setShowWaringToast] = React.useState(null);
52543
52471
  const [showOptions, setShowOptions] = React.useState(false);
52544
- let filters = getQueryStringParams(location.search);
52472
+ let filters = getQueryStringParams(window.location.search);
52545
52473
  const applicationNumber = filters === null || filters === void 0 ? void 0 : filters.applicationNumber;
52546
52474
  const serviceType = filters === null || filters === void 0 ? void 0 : filters.service;
52547
52475
  const menuRef = React.useRef();
@@ -52658,6 +52586,11 @@ const ApplicationDetails$1 = () => {
52658
52586
  };
52659
52587
  let dowloadOptions = [],
52660
52588
  appStatus = (applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$a9 = applicationDetails.applicationData) === null || _applicationDetails$a9 === void 0 ? void 0 : _applicationDetails$a9.applicationStatus) || "";
52589
+ const isFeePaid = (reciept_data === null || reciept_data === void 0 ? void 0 : (_reciept_data$Payment = reciept_data.Payments) === null || _reciept_data$Payment === void 0 ? void 0 : _reciept_data$Payment.length) > 0 || appStatus && appStatus !== "INITIATED" && appStatus !== "PENDING_FOR_DOCUMENT_VERIFICATION" && appStatus !== "PENDING_FOR_CITIZEN_ACTION" && appStatus !== "PENDING_FOR_FIELD_INSPECTION" && appStatus !== "PENDING_FOR_PAYMENT" && appStatus !== "PENDING_FOR_FINAL_PAYMENT" && appStatus !== "PENDING_FOR_ADDITIONAL_PAYMENT" && appStatus !== "PENDING_APPROVAL_FOR_MUTATION";
52590
+ const feeEstimationSection = applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$a0 = applicationDetails.applicationDetails) === null || _applicationDetails$a0 === void 0 ? void 0 : _applicationDetails$a0.find(section => (section === null || section === void 0 ? void 0 : section.title) === "WS_TASK_DETAILS_FEE_ESTIMATE");
52591
+ if (feeEstimationSection !== null && feeEstimationSection !== void 0 && feeEstimationSection.additionalDetails && isFeePaid) {
52592
+ feeEstimationSection.additionalDetails.isPaid = true;
52593
+ }
52661
52594
  if (workflowDetails !== null && workflowDetails !== void 0 && workflowDetails.data && (applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$p8 = applicationDetails.processInstancesDetails) === null || _applicationDetails$p8 === void 0 ? void 0 : (_applicationDetails$p9 = _applicationDetails$p8[0]) === null || _applicationDetails$p9 === void 0 ? void 0 : _applicationDetails$p9.businessService) === "NewWS1" && appStatus === "PENDING_FOR_BILLING_CLERK_REVIEW") {
52662
52595
  var _applicationDetails$p0, _applicationDetails$p1, _workflowDetails$data, _workflowDetails$data2, _workflowDetails$data3;
52663
52596
  const plotArea = Number((applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$p0 = applicationDetails.propertyDetails) === null || _applicationDetails$p0 === void 0 ? void 0 : (_applicationDetails$p1 = _applicationDetails$p0.additionalDetails) === null || _applicationDetails$p1 === void 0 ? void 0 : _applicationDetails$p1.plotArea) ?? 0);
@@ -52693,8 +52626,8 @@ const ApplicationDetails$1 = () => {
52693
52626
  };
52694
52627
  }
52695
52628
  if ((action === null || action === void 0 ? void 0 : action.action) === "RESUBMIT_APPLICATION") {
52696
- var _applicationDetails$a0, _applicationDetails$a1, _applicationDetails$p10, _applicationDetails$p11, _servicesMasterData$w, _userConfig$, _userConfig$2;
52697
- const isMutation = applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$a0 = applicationDetails.applicationData) === null || _applicationDetails$a0 === void 0 ? void 0 : (_applicationDetails$a1 = _applicationDetails$a0.applicationType) === null || _applicationDetails$a1 === void 0 ? void 0 : _applicationDetails$a1.includes("MUTATION");
52629
+ var _applicationDetails$a1, _applicationDetails$a10, _applicationDetails$p10, _applicationDetails$p11, _servicesMasterData$w, _userConfig$, _userConfig$2;
52630
+ const isMutation = applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$a1 = applicationDetails.applicationData) === null || _applicationDetails$a1 === void 0 ? void 0 : (_applicationDetails$a10 = _applicationDetails$a1.applicationType) === null || _applicationDetails$a10 === void 0 ? void 0 : _applicationDetails$a10.includes("MUTATION");
52698
52631
  let pathName = isMutation ? `/digit-ui/employee/ws/mutation-application?applicationNumber=${applicationNumber}&tenantId=${tenantId}&service=${serviceType}&propertyId=${applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$p10 = applicationDetails.propertyDetails) === null || _applicationDetails$p10 === void 0 ? void 0 : _applicationDetails$p10.propertyId}` : `/digit-ui/employee/ws/edit-application?applicationNumber=${applicationNumber}&service=${serviceType}&propertyId=${applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$p11 = applicationDetails.propertyDetails) === null || _applicationDetails$p11 === void 0 ? void 0 : _applicationDetails$p11.propertyId}`;
52699
52632
  const userConfig = (servicesMasterData === null || servicesMasterData === void 0 ? void 0 : (_servicesMasterData$w = servicesMasterData["ws-services-masters"]) === null || _servicesMasterData$w === void 0 ? void 0 : _servicesMasterData$w.WSEditApplicationByConfigUser) || [];
52700
52633
  const editApplicationUserRole = (userConfig === null || userConfig === void 0 ? void 0 : (_userConfig$ = userConfig[0]) === null || _userConfig$ === void 0 ? void 0 : _userConfig$.roles) || [];
@@ -52728,8 +52661,8 @@ const ApplicationDetails$1 = () => {
52728
52661
  });
52729
52662
  workflowDetails === null || workflowDetails === void 0 ? void 0 : (_workflowDetails$data7 = workflowDetails.data) === null || _workflowDetails$data7 === void 0 ? void 0 : (_workflowDetails$data8 = _workflowDetails$data7.actionState) === null || _workflowDetails$data8 === void 0 ? void 0 : (_workflowDetails$data9 = _workflowDetails$data8.nextActions) === null || _workflowDetails$data9 === void 0 ? void 0 : _workflowDetails$data9.forEach(action => {
52730
52663
  if ((action === null || action === void 0 ? void 0 : action.action) === "EDIT") {
52731
- var _applicationDetails$a10, _applicationDetails$a11, _applicationDetails$p14, _applicationDetails$p15, _servicesMasterData$w2, _userConfig$3, _userConfig$4;
52732
- const isMutation = applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$a10 = applicationDetails.applicationData) === null || _applicationDetails$a10 === void 0 ? void 0 : (_applicationDetails$a11 = _applicationDetails$a10.applicationType) === null || _applicationDetails$a11 === void 0 ? void 0 : _applicationDetails$a11.includes("MUTATION");
52664
+ var _applicationDetails$a11, _applicationDetails$a12, _applicationDetails$p14, _applicationDetails$p15, _servicesMasterData$w2, _userConfig$3, _userConfig$4;
52665
+ const isMutation = applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$a11 = applicationDetails.applicationData) === null || _applicationDetails$a11 === void 0 ? void 0 : (_applicationDetails$a12 = _applicationDetails$a11.applicationType) === null || _applicationDetails$a12 === void 0 ? void 0 : _applicationDetails$a12.includes("MUTATION");
52733
52666
  let pathName = isMutation ? `/digit-ui/employee/ws/mutation-application?applicationNumber=${applicationNumber}&tenantId=${tenantId}&service=${serviceType}&propertyId=${applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$p14 = applicationDetails.propertyDetails) === null || _applicationDetails$p14 === void 0 ? void 0 : _applicationDetails$p14.propertyId}` : `/digit-ui/employee/ws/edit-application?applicationNumber=${applicationNumber}&service=${serviceType}&propertyId=${applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$p15 = applicationDetails.propertyDetails) === null || _applicationDetails$p15 === void 0 ? void 0 : _applicationDetails$p15.propertyId}`;
52734
52667
  const userConfig = (servicesMasterData === null || servicesMasterData === void 0 ? void 0 : (_servicesMasterData$w2 = servicesMasterData["ws-services-masters"]) === null || _servicesMasterData$w2 === void 0 ? void 0 : _servicesMasterData$w2.WSEditApplicationByConfigUser) || [];
52735
52668
  const editApplicationUserRole = (userConfig === null || userConfig === void 0 ? void 0 : (_userConfig$3 = userConfig[0]) === null || _userConfig$3 === void 0 ? void 0 : _userConfig$3.roles) || [];
@@ -52810,10 +52743,10 @@ const ApplicationDetails$1 = () => {
52810
52743
  const oldApplication = serviceType === "WATER" ? oldData === null || oldData === void 0 ? void 0 : (_oldData$WaterConnect = oldData.WaterConnection) === null || _oldData$WaterConnect === void 0 ? void 0 : _oldData$WaterConnect[(oldData === null || oldData === void 0 ? void 0 : (_oldData$WaterConnect2 = oldData.WaterConnection) === null || _oldData$WaterConnect2 === void 0 ? void 0 : _oldData$WaterConnect2.length) - 1] : oldData === null || oldData === void 0 ? void 0 : (_oldData$SewerageConn = oldData.SewerageConnections) === null || _oldData$SewerageConn === void 0 ? void 0 : _oldData$SewerageConn[(oldData === null || oldData === void 0 ? void 0 : (_oldData$SewerageConn2 = oldData.SewerageConnections) === null || _oldData$SewerageConn2 === void 0 ? void 0 : _oldData$SewerageConn2.length) - 1];
52811
52744
  const handleDownloadPdf = function () {
52812
52745
  try {
52813
- var _applicationDetails$a12, _applicationDetails$a13, _applicationDetails$a14;
52814
- const tenantInfo = applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$a12 = applicationDetails.applicationData) === null || _applicationDetails$a12 === void 0 ? void 0 : _applicationDetails$a12.tenantId;
52746
+ var _applicationDetails$a13, _applicationDetails$a14, _applicationDetails$a15;
52747
+ const tenantInfo = applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$a13 = applicationDetails.applicationData) === null || _applicationDetails$a13 === void 0 ? void 0 : _applicationDetails$a13.tenantId;
52815
52748
  let result = applicationDetails === null || applicationDetails === void 0 ? void 0 : applicationDetails.applicationData;
52816
- if (applicationDetails !== null && applicationDetails !== void 0 && (_applicationDetails$a13 = applicationDetails.applicationData) !== null && _applicationDetails$a13 !== void 0 && (_applicationDetails$a14 = _applicationDetails$a13.applicationType) !== null && _applicationDetails$a14 !== void 0 && _applicationDetails$a14.includes("MODIFY_")) {
52749
+ if (applicationDetails !== null && applicationDetails !== void 0 && (_applicationDetails$a14 = applicationDetails.applicationData) !== null && _applicationDetails$a14 !== void 0 && (_applicationDetails$a15 = _applicationDetails$a14.applicationType) !== null && _applicationDetails$a15 !== void 0 && _applicationDetails$a15.includes("MODIFY_")) {
52817
52750
  const PDFdata = getWSAcknowledgementData$1({
52818
52751
  ...result
52819
52752
  }, {
@@ -52835,10 +52768,10 @@ const ApplicationDetails$1 = () => {
52835
52768
  };
52836
52769
  const handleEstimateDownload = function () {
52837
52770
  try {
52838
- const _temp2 = function (_applicationDetails$a15, _applicationDetails$a16) {
52839
- if (applicationDetails !== null && applicationDetails !== void 0 && (_applicationDetails$a15 = applicationDetails.applicationData) !== null && _applicationDetails$a15 !== void 0 && (_applicationDetails$a16 = _applicationDetails$a15.additionalDetails) !== null && _applicationDetails$a16 !== void 0 && _applicationDetails$a16.estimationFileStoreId) {
52840
- var _applicationDetails$a17, _applicationDetails$a18;
52841
- getFiles([applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$a17 = applicationDetails.applicationData) === null || _applicationDetails$a17 === void 0 ? void 0 : (_applicationDetails$a18 = _applicationDetails$a17.additionalDetails) === null || _applicationDetails$a18 === void 0 ? void 0 : _applicationDetails$a18.estimationFileStoreId], applicationDetails === null || applicationDetails === void 0 ? void 0 : applicationDetails.tenantId);
52771
+ const _temp2 = function (_applicationDetails$a16, _applicationDetails$a17) {
52772
+ if (applicationDetails !== null && applicationDetails !== void 0 && (_applicationDetails$a16 = applicationDetails.applicationData) !== null && _applicationDetails$a16 !== void 0 && (_applicationDetails$a17 = _applicationDetails$a16.additionalDetails) !== null && _applicationDetails$a17 !== void 0 && _applicationDetails$a17.estimationFileStoreId) {
52773
+ var _applicationDetails$a18, _applicationDetails$a19;
52774
+ getFiles([applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$a18 = applicationDetails.applicationData) === null || _applicationDetails$a18 === void 0 ? void 0 : (_applicationDetails$a19 = _applicationDetails$a18.additionalDetails) === null || _applicationDetails$a19 === void 0 ? void 0 : _applicationDetails$a19.estimationFileStoreId], applicationDetails === null || applicationDetails === void 0 ? void 0 : applicationDetails.tenantId);
52842
52775
  } else {
52843
52776
  const warningCount = sessionStorage.getItem("WARINIG_COUNT") || "0";
52844
52777
  const warningCountDetails = JSON.parse(warningCount);
@@ -52898,8 +52831,8 @@ const ApplicationDetails$1 = () => {
52898
52831
  order: 2,
52899
52832
  label: t("WS_SANCTION_LETTER"),
52900
52833
  onClick: () => {
52901
- var _applicationDetails$a19, _applicationDetails$a20;
52902
- return getFiles([applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$a19 = applicationDetails.applicationData) === null || _applicationDetails$a19 === void 0 ? void 0 : (_applicationDetails$a20 = _applicationDetails$a19.additionalDetails) === null || _applicationDetails$a20 === void 0 ? void 0 : _applicationDetails$a20.sanctionFileStoreId], applicationDetails === null || applicationDetails === void 0 ? void 0 : applicationDetails.tenantId);
52834
+ var _applicationDetails$a20, _applicationDetails$a21;
52835
+ return getFiles([applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$a20 = applicationDetails.applicationData) === null || _applicationDetails$a20 === void 0 ? void 0 : (_applicationDetails$a21 = _applicationDetails$a20.additionalDetails) === null || _applicationDetails$a21 === void 0 ? void 0 : _applicationDetails$a21.sanctionFileStoreId], applicationDetails === null || applicationDetails === void 0 ? void 0 : applicationDetails.tenantId);
52903
52836
  }
52904
52837
  };
52905
52838
  const applicationDownloadObject = {
@@ -52911,8 +52844,8 @@ const ApplicationDetails$1 = () => {
52911
52844
  order: 4,
52912
52845
  label: t("DOWNLOAD_RECEIPT_HEADER"),
52913
52846
  onClick: () => {
52914
- var _reciept_data$Payment, _applicationDetails$a21;
52915
- return getRecieptSearch(Digit.ULBService.getStateId(), reciept_data === null || reciept_data === void 0 ? void 0 : (_reciept_data$Payment = reciept_data.Payments) === null || _reciept_data$Payment === void 0 ? void 0 : _reciept_data$Payment[0], applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$a21 = applicationDetails.applicationData) === null || _applicationDetails$a21 === void 0 ? void 0 : _applicationDetails$a21.applicationNo, receiptKey);
52847
+ var _reciept_data$Payment2, _applicationDetails$a22;
52848
+ return getRecieptSearch(Digit.ULBService.getStateId(), reciept_data === null || reciept_data === void 0 ? void 0 : (_reciept_data$Payment2 = reciept_data.Payments) === null || _reciept_data$Payment2 === void 0 ? void 0 : _reciept_data$Payment2[0], applicationDetails === null || applicationDetails === void 0 ? void 0 : (_applicationDetails$a22 = applicationDetails.applicationData) === null || _applicationDetails$a22 === void 0 ? void 0 : _applicationDetails$a22.applicationNo, receiptKey);
52916
52849
  }
52917
52850
  };
52918
52851
  switch (appStatus) {
@@ -52927,7 +52860,7 @@ const ApplicationDetails$1 = () => {
52927
52860
  break;
52928
52861
  case "PENDING_FOR_CONNECTION_ACTIVATION":
52929
52862
  case "CONNECTION_ACTIVATED":
52930
- if (applicationDetails !== null && applicationDetails !== void 0 && (_applicationDetails$a22 = applicationDetails.applicationData) !== null && _applicationDetails$a22 !== void 0 && (_applicationDetails$a23 = _applicationDetails$a22.applicationType) !== null && _applicationDetails$a23 !== void 0 && _applicationDetails$a23.includes("NEW_") && (reciept_data === null || reciept_data === void 0 ? void 0 : (_reciept_data$Payment2 = reciept_data.Payments) === null || _reciept_data$Payment2 === void 0 ? void 0 : _reciept_data$Payment2.length) > 0) dowloadOptions = [sanctionDownloadObject, wsEstimateDownloadObject, applicationDownloadObject, appFeeDownloadReceipt];else dowloadOptions = [sanctionDownloadObject, wsEstimateDownloadObject, applicationDownloadObject];
52863
+ if (applicationDetails !== null && applicationDetails !== void 0 && (_applicationDetails$a23 = applicationDetails.applicationData) !== null && _applicationDetails$a23 !== void 0 && (_applicationDetails$a24 = _applicationDetails$a23.applicationType) !== null && _applicationDetails$a24 !== void 0 && _applicationDetails$a24.includes("NEW_") && (reciept_data === null || reciept_data === void 0 ? void 0 : (_reciept_data$Payment3 = reciept_data.Payments) === null || _reciept_data$Payment3 === void 0 ? void 0 : _reciept_data$Payment3.length) > 0) dowloadOptions = [sanctionDownloadObject, wsEstimateDownloadObject, applicationDownloadObject, appFeeDownloadReceipt];else dowloadOptions = [sanctionDownloadObject, wsEstimateDownloadObject, applicationDownloadObject];
52931
52864
  break;
52932
52865
  case "REJECTED":
52933
52866
  dowloadOptions = [applicationDownloadObject];
@@ -53335,15 +53268,53 @@ const GetConnectionDetails = () => {
53335
53268
  }));
53336
53269
  };
53337
53270
 
53271
+ const newConfig$2 = [{
53272
+ hideInCitizen: true,
53273
+ body: [{
53274
+ body: [{
53275
+ type: "component",
53276
+ key: "connectionDetails",
53277
+ component: "WSActivationConnectionDetails",
53278
+ withoutLabel: true
53279
+ }]
53280
+ }, {
53281
+ body: [{
53282
+ type: "component",
53283
+ key: "plumberDetails",
53284
+ component: "WSActivationPlumberDetails",
53285
+ withoutLabel: true
53286
+ }]
53287
+ }, {
53288
+ body: [{
53289
+ type: "component",
53290
+ key: "activationDetails",
53291
+ component: "WSActivationDetails",
53292
+ withoutLabel: true
53293
+ }]
53294
+ }, {
53295
+ body: [{
53296
+ type: "component",
53297
+ key: "comments",
53298
+ component: "WSActivationCommentsDetails",
53299
+ withoutLabel: true
53300
+ }]
53301
+ }, {
53302
+ body: [{
53303
+ type: "component",
53304
+ key: "supportingDocuments",
53305
+ component: "WSActivationSupportingDocuments",
53306
+ withoutLabel: true
53307
+ }]
53308
+ }]
53309
+ }];
53310
+
53338
53311
  const ActivateConnection = () => {
53339
- var _Digit$SessionStorage, _state, _details, _details2, _state2, _state2$data, _state3, _state3$data, _state4, _state4$data, _state5, _state5$data, _state6, _state6$data, _state6$data$connecti, _state7, _state7$data, _state8, _state8$data, _state9, _state9$data, _state9$data$waterSou, _state9$data$waterSou2, _state0, _state0$data, _state1, _state1$data, _state10, _state10$data, _state11, _state11$data, _state12, _state12$data, _state13, _state13$data, _state14, _state14$data, _state15, _state15$data, _state16, _state16$data, _state16$data$plumber, _state16$data$plumber2, _state17, _state17$data, _state17$data$plumber, _state17$data$plumber2, _state18, _state18$data, _state18$data$plumber, _state18$data$plumber2, _state19, _state19$data, _state19$data$additio, _state20, _state20$data, _state20$data$additio, _state20$data$additio2, _state21, _state21$data, _state21$data$additio, _state22, _state22$data, _state23, _state23$data, _state23$data$connect, _state24, _state24$data, _state25, _state25$data, _state26, _state26$data, _state27, _state27$data, _state28, _state28$data, _state28$data$additio, _state29, _state29$data, _state30, _state30$data, _state31, _state31$data, _state32, _state32$data;
53312
+ var _Digit$SessionStorage, _state, _details, _details2, _state2, _state2$data, _state3, _state3$data, _state4, _state4$data, _state5, _state5$data, _ref, _ref$split$, _state6, _state6$data, _state7, _state7$data, _state8, _state8$data, _state9, _state9$data, _state0, _state0$data, _state1, _state1$data, _state10, _state10$data, _state11, _state11$data, _state12, _state12$data, _state13, _state13$data, _state14, _state14$data, _state15, _state15$data, _state15$data$plumber, _state15$data$plumber2, _state16, _state16$data, _state16$data$plumber, _state16$data$plumber2, _state17, _state17$data, _state17$data$plumber, _state17$data$plumber2, _state18, _state18$data, _state18$data$additio, _state19, _state19$data, _state19$data$additio, _state19$data$additio2, _state20, _state20$data, _state20$data$additio, _state21, _state21$data, _state22, _state22$data, _state23, _state23$data, _state23$data$connect, _state24, _state24$data, _state24$data$connect, _state25, _state25$data, _state25$data$additio, _state25$data$additio2, _state26, _state26$data, _state26$data$additio, _state26$data$additio2, _state27, _state27$data, _state28, _state28$data, _state29, _state29$data, _state30, _state30$data, _state31, _state31$data, _state31$data$additio, _state32, _state32$data, _state33, _state33$data, _state34, _state34$data, _state35, _state35$data;
53340
53313
  const {
53341
53314
  t
53342
53315
  } = reactI18next.useTranslation();
53343
- let {
53344
- state
53345
- } = reactRouterDom.useLocation();
53346
- state = state ? typeof state === "string" ? JSON.parse(state) : state : {};
53316
+ const location = reactRouterDom.useLocation();
53317
+ let state = location !== null && location !== void 0 && location.state ? typeof location.state === "string" ? JSON.parse(location.state) : location.state : {};
53347
53318
  const history = reactRouterDom.useHistory();
53348
53319
  let filters = getQueryStringParams(location.search);
53349
53320
  const [canSubmit, setSubmitValve] = React.useState(false);
@@ -53355,8 +53326,7 @@ const ActivateConnection = () => {
53355
53326
  body: []
53356
53327
  });
53357
53328
  const stateId = Digit.ULBService.getStateId();
53358
- let tenantId = Digit.ULBService.getCurrentTenantId();
53359
- tenantId ? tenantId : (_Digit$SessionStorage = Digit.SessionStorage.get("CITIZEN.COMMON.HOME.CITY")) === null || _Digit$SessionStorage === void 0 ? void 0 : _Digit$SessionStorage.code;
53329
+ let tenantId = Digit.ULBService.getCurrentTenantId() || ((_Digit$SessionStorage = Digit.SessionStorage.get("CITIZEN.COMMON.HOME.CITY")) === null || _Digit$SessionStorage === void 0 ? void 0 : _Digit$SessionStorage.code);
53360
53330
  let {
53361
53331
  data: newConfig,
53362
53332
  isLoading
@@ -53387,47 +53357,51 @@ const ActivateConnection = () => {
53387
53357
  const waterSourceSubDataWithUS = waterSourceSubDataWithClone ? stringReplaceAll(waterSourceSubDataWithClone === null || waterSourceSubDataWithClone === void 0 ? void 0 : waterSourceSubDataWithClone.toUpperCase(), " ", "_") : "";
53388
53358
  const waterSourceSubDataWithCma = waterSourceSubDataWithUS ? stringReplaceAll(waterSourceSubDataWithUS === null || waterSourceSubDataWithUS === void 0 ? void 0 : waterSourceSubDataWithUS.toUpperCase(), ".", "_") : "";
53389
53359
  const connectionDetails = (filters === null || filters === void 0 ? void 0 : filters.service) === "WATER" ? {
53390
- connectionType: (_state4 = state) !== null && _state4 !== void 0 && (_state4$data = _state4.data) !== null && _state4$data !== void 0 && _state4$data.connectionType ? {
53391
- code: (_state5 = state) === null || _state5 === void 0 ? void 0 : (_state5$data = _state5.data) === null || _state5$data === void 0 ? void 0 : _state5$data.connectionType,
53392
- i18nKey: `WS_CONNECTIONTYPE_${stringReplaceAll((_state6 = state) === null || _state6 === void 0 ? void 0 : (_state6$data = _state6.data) === null || _state6$data === void 0 ? void 0 : (_state6$data$connecti = _state6$data.connectionType) === null || _state6$data$connecti === void 0 ? void 0 : _state6$data$connecti.toUpperCase(), " ", "_")}`
53360
+ connectionType: {
53361
+ code: "Metered",
53362
+ i18nKey: "WS_CONNECTIONTYPE_METERED",
53363
+ name: "Metered"
53364
+ },
53365
+ waterSource: (_state4 = state) !== null && _state4 !== void 0 && (_state4$data = _state4.data) !== null && _state4$data !== void 0 && _state4$data.waterSource || "GROUND.WELL" ? {
53366
+ code: ((_state5 = state) === null || _state5 === void 0 ? void 0 : (_state5$data = _state5.data) === null || _state5$data === void 0 ? void 0 : _state5$data.waterSource) || "GROUND.WELL",
53367
+ i18nKey: `WS_SERVICES_MASTERS_WATERSOURCE_${stringReplaceAll((_ref = ((_state6 = state) === null || _state6 === void 0 ? void 0 : (_state6$data = _state6.data) === null || _state6$data === void 0 ? void 0 : _state6$data.waterSource) || "GROUND.WELL") === null || _ref === void 0 ? void 0 : (_ref$split$ = _ref.split(".")[0]) === null || _ref$split$ === void 0 ? void 0 : _ref$split$.toUpperCase(), " ", "_")}`
53393
53368
  } : "",
53394
- waterSource: (_state7 = state) !== null && _state7 !== void 0 && (_state7$data = _state7.data) !== null && _state7$data !== void 0 && _state7$data.waterSource ? {
53395
- code: (_state8 = state) === null || _state8 === void 0 ? void 0 : (_state8$data = _state8.data) === null || _state8$data === void 0 ? void 0 : _state8$data.waterSource,
53396
- i18nKey: `WS_SERVICES_MASTERS_WATERSOURCE_${stringReplaceAll((_state9 = state) === null || _state9 === void 0 ? void 0 : (_state9$data = _state9.data) === null || _state9$data === void 0 ? void 0 : (_state9$data$waterSou = _state9$data.waterSource) === null || _state9$data$waterSou === void 0 ? void 0 : (_state9$data$waterSou2 = _state9$data$waterSou.split(".")[0]) === null || _state9$data$waterSou2 === void 0 ? void 0 : _state9$data$waterSou2.toUpperCase(), " ", "_")}`
53369
+ sourceSubData: (_state7 = state) !== null && _state7 !== void 0 && (_state7$data = _state7.data) !== null && _state7$data !== void 0 && _state7$data.waterSource || "GROUND.WELL" ? {
53370
+ code: ((_state8 = state) === null || _state8 === void 0 ? void 0 : (_state8$data = _state8.data) === null || _state8$data === void 0 ? void 0 : _state8$data.waterSource) || "GROUND.WELL",
53371
+ i18nKey: `WS_SERVICES_MASTERS_WATERSOURCE_${waterSourceSubDataWithCma || "GROUND_WELL"}`
53397
53372
  } : "",
53398
- sourceSubData: (_state0 = state) !== null && _state0 !== void 0 && (_state0$data = _state0.data) !== null && _state0$data !== void 0 && _state0$data.waterSource ? {
53399
- code: (_state1 = state) === null || _state1 === void 0 ? void 0 : (_state1$data = _state1.data) === null || _state1$data === void 0 ? void 0 : _state1$data.waterSource,
53400
- i18nKey: `WS_SERVICES_MASTERS_WATERSOURCE_${waterSourceSubDataWithCma}`
53401
- } : "",
53402
- pipeSize: (_state10 = state) !== null && _state10 !== void 0 && (_state10$data = _state10.data) !== null && _state10$data !== void 0 && _state10$data.pipeSize ? {
53403
- code: (_state11 = state) === null || _state11 === void 0 ? void 0 : (_state11$data = _state11.data) === null || _state11$data === void 0 ? void 0 : _state11$data.pipeSize,
53404
- i18nKey: (_state12 = state) === null || _state12 === void 0 ? void 0 : (_state12$data = _state12.data) === null || _state12$data === void 0 ? void 0 : _state12$data.pipeSize
53405
- } : "",
53406
- noOfTaps: ((_state13 = state) === null || _state13 === void 0 ? void 0 : (_state13$data = _state13.data) === null || _state13$data === void 0 ? void 0 : _state13$data.noOfTaps) || "",
53373
+ pipeSize: (_state9 = state) !== null && _state9 !== void 0 && (_state9$data = _state9.data) !== null && _state9$data !== void 0 && _state9$data.pipeSize ? {
53374
+ code: (_state0 = state) === null || _state0 === void 0 ? void 0 : (_state0$data = _state0.data) === null || _state0$data === void 0 ? void 0 : _state0$data.pipeSize,
53375
+ i18nKey: (_state1 = state) === null || _state1 === void 0 ? void 0 : (_state1$data = _state1.data) === null || _state1$data === void 0 ? void 0 : _state1$data.pipeSize
53376
+ } : 0,
53377
+ noOfTaps: ((_state10 = state) === null || _state10 === void 0 ? void 0 : (_state10$data = _state10.data) === null || _state10$data === void 0 ? void 0 : _state10$data.noOfTaps) !== undefined && ((_state11 = state) === null || _state11 === void 0 ? void 0 : (_state11$data = _state11.data) === null || _state11$data === void 0 ? void 0 : _state11$data.noOfTaps) !== "" ? (_state12 = state) === null || _state12 === void 0 ? void 0 : (_state12$data = _state12.data) === null || _state12$data === void 0 ? void 0 : _state12$data.noOfTaps : 0,
53378
+ proposedPipeSize: 0,
53379
+ proposedTaps: 0,
53407
53380
  formDetails: details
53408
53381
  } : {
53409
- noOfWaterClosets: ((_state14 = state) === null || _state14 === void 0 ? void 0 : (_state14$data = _state14.data) === null || _state14$data === void 0 ? void 0 : _state14$data.noOfWaterClosets) || "",
53410
- noOfToilets: ((_state15 = state) === null || _state15 === void 0 ? void 0 : (_state15$data = _state15.data) === null || _state15$data === void 0 ? void 0 : _state15$data.noOfToilets) || "",
53382
+ noOfWaterClosets: ((_state13 = state) === null || _state13 === void 0 ? void 0 : (_state13$data = _state13.data) === null || _state13$data === void 0 ? void 0 : _state13$data.noOfWaterClosets) || "",
53383
+ noOfToilets: ((_state14 = state) === null || _state14 === void 0 ? void 0 : (_state14$data = _state14.data) === null || _state14$data === void 0 ? void 0 : _state14$data.noOfToilets) || "",
53411
53384
  formDetails: details
53412
53385
  };
53413
53386
  const plumberDetails = [{
53414
- plumberName: ((_state16 = state) === null || _state16 === void 0 ? void 0 : (_state16$data = _state16.data) === null || _state16$data === void 0 ? void 0 : (_state16$data$plumber = _state16$data.plumberInfo) === null || _state16$data$plumber === void 0 ? void 0 : (_state16$data$plumber2 = _state16$data$plumber[0]) === null || _state16$data$plumber2 === void 0 ? void 0 : _state16$data$plumber2.name) || "",
53415
- plumberMobileNo: ((_state17 = state) === null || _state17 === void 0 ? void 0 : (_state17$data = _state17.data) === null || _state17$data === void 0 ? void 0 : (_state17$data$plumber = _state17$data.plumberInfo) === null || _state17$data$plumber === void 0 ? void 0 : (_state17$data$plumber2 = _state17$data$plumber[0]) === null || _state17$data$plumber2 === void 0 ? void 0 : _state17$data$plumber2.mobileNumber) || "",
53416
- plumberLicenseNo: ((_state18 = state) === null || _state18 === void 0 ? void 0 : (_state18$data = _state18.data) === null || _state18$data === void 0 ? void 0 : (_state18$data$plumber = _state18$data.plumberInfo) === null || _state18$data$plumber === void 0 ? void 0 : (_state18$data$plumber2 = _state18$data$plumber[0]) === null || _state18$data$plumber2 === void 0 ? void 0 : _state18$data$plumber2.licenseNo) || "",
53417
- detailsProvidedBy: (_state19 = state) !== null && _state19 !== void 0 && (_state19$data = _state19.data) !== null && _state19$data !== void 0 && (_state19$data$additio = _state19$data.additionalDetails) !== null && _state19$data$additio !== void 0 && _state19$data$additio.detailsProvidedBy ? {
53418
- i18nKey: `WS_PLUMBER_${(_state20 = state) === null || _state20 === void 0 ? void 0 : (_state20$data = _state20.data) === null || _state20$data === void 0 ? void 0 : (_state20$data$additio = _state20$data.additionalDetails) === null || _state20$data$additio === void 0 ? void 0 : (_state20$data$additio2 = _state20$data$additio.detailsProvidedBy) === null || _state20$data$additio2 === void 0 ? void 0 : _state20$data$additio2.toUpperCase()}`,
53419
- code: (_state21 = state) === null || _state21 === void 0 ? void 0 : (_state21$data = _state21.data) === null || _state21$data === void 0 ? void 0 : (_state21$data$additio = _state21$data.additionalDetails) === null || _state21$data$additio === void 0 ? void 0 : _state21$data$additio.detailsProvidedBy
53387
+ plumberName: ((_state15 = state) === null || _state15 === void 0 ? void 0 : (_state15$data = _state15.data) === null || _state15$data === void 0 ? void 0 : (_state15$data$plumber = _state15$data.plumberInfo) === null || _state15$data$plumber === void 0 ? void 0 : (_state15$data$plumber2 = _state15$data$plumber[0]) === null || _state15$data$plumber2 === void 0 ? void 0 : _state15$data$plumber2.name) || "",
53388
+ plumberMobileNo: ((_state16 = state) === null || _state16 === void 0 ? void 0 : (_state16$data = _state16.data) === null || _state16$data === void 0 ? void 0 : (_state16$data$plumber = _state16$data.plumberInfo) === null || _state16$data$plumber === void 0 ? void 0 : (_state16$data$plumber2 = _state16$data$plumber[0]) === null || _state16$data$plumber2 === void 0 ? void 0 : _state16$data$plumber2.mobileNumber) || "",
53389
+ plumberLicenseNo: ((_state17 = state) === null || _state17 === void 0 ? void 0 : (_state17$data = _state17.data) === null || _state17$data === void 0 ? void 0 : (_state17$data$plumber = _state17$data.plumberInfo) === null || _state17$data$plumber === void 0 ? void 0 : (_state17$data$plumber2 = _state17$data$plumber[0]) === null || _state17$data$plumber2 === void 0 ? void 0 : _state17$data$plumber2.licenseNo) || "",
53390
+ detailsProvidedBy: (_state18 = state) !== null && _state18 !== void 0 && (_state18$data = _state18.data) !== null && _state18$data !== void 0 && (_state18$data$additio = _state18$data.additionalDetails) !== null && _state18$data$additio !== void 0 && _state18$data$additio.detailsProvidedBy ? {
53391
+ i18nKey: `WS_PLUMBER_${(_state19 = state) === null || _state19 === void 0 ? void 0 : (_state19$data = _state19.data) === null || _state19$data === void 0 ? void 0 : (_state19$data$additio = _state19$data.additionalDetails) === null || _state19$data$additio === void 0 ? void 0 : (_state19$data$additio2 = _state19$data$additio.detailsProvidedBy) === null || _state19$data$additio2 === void 0 ? void 0 : _state19$data$additio2.toUpperCase()}`,
53392
+ code: (_state20 = state) === null || _state20 === void 0 ? void 0 : (_state20$data = _state20.data) === null || _state20$data === void 0 ? void 0 : (_state20$data$additio = _state20$data.additionalDetails) === null || _state20$data$additio === void 0 ? void 0 : _state20$data$additio.detailsProvidedBy
53420
53393
  } : "",
53421
- applicationNo: (_state22 = state) === null || _state22 === void 0 ? void 0 : (_state22$data = _state22.data) === null || _state22$data === void 0 ? void 0 : _state22$data.applicationNo,
53394
+ applicationNo: (_state21 = state) === null || _state21 === void 0 ? void 0 : (_state21$data = _state21.data) === null || _state21$data === void 0 ? void 0 : _state21$data.applicationNo,
53422
53395
  key: Date.now()
53423
53396
  }];
53424
- const activationDetails = ((_state23 = state) === null || _state23 === void 0 ? void 0 : (_state23$data = _state23.data) === null || _state23$data === void 0 ? void 0 : (_state23$data$connect = _state23$data.connectionType) === null || _state23$data$connect === void 0 ? void 0 : _state23$data$connect.toUpperCase()) === "METERED" && ((_state24 = state) === null || _state24 === void 0 ? void 0 : (_state24$data = _state24.data) === null || _state24$data === void 0 ? void 0 : _state24$data.applicationType) !== "WATER_RECONNECTION" ? [{
53425
- meterId: ((_state25 = state) === null || _state25 === void 0 ? void 0 : (_state25$data = _state25.data) === null || _state25$data === void 0 ? void 0 : _state25$data.meterId) || "",
53426
- meterInstallationDate: (_state26 = state) !== null && _state26 !== void 0 && (_state26$data = _state26.data) !== null && _state26$data !== void 0 && _state26$data.meterInstallationDate ? convertEpochToDates((_state27 = state) === null || _state27 === void 0 ? void 0 : (_state27$data = _state27.data) === null || _state27$data === void 0 ? void 0 : _state27$data.meterInstallationDate) : null,
53427
- meterInitialReading: ((_state28 = state) === null || _state28 === void 0 ? void 0 : (_state28$data = _state28.data) === null || _state28$data === void 0 ? void 0 : (_state28$data$additio = _state28$data.additionalDetails) === null || _state28$data$additio === void 0 ? void 0 : _state28$data$additio.initialMeterReading) || "",
53428
- connectionExecutionDate: (_state29 = state) !== null && _state29 !== void 0 && (_state29$data = _state29.data) !== null && _state29$data !== void 0 && _state29$data.connectionExecutionDate ? convertEpochToDates((_state30 = state) === null || _state30 === void 0 ? void 0 : (_state30$data = _state30.data) === null || _state30$data === void 0 ? void 0 : _state30$data.connectionExecutionDate) : null
53397
+ const isMeteredConn = !((_state22 = state) !== null && _state22 !== void 0 && (_state22$data = _state22.data) !== null && _state22$data !== void 0 && _state22$data.connectionType) || ((_state23 = state) === null || _state23 === void 0 ? void 0 : (_state23$data = _state23.data) === null || _state23$data === void 0 ? void 0 : (_state23$data$connect = _state23$data.connectionType) === null || _state23$data$connect === void 0 ? void 0 : _state23$data$connect.toUpperCase()) === "METERED" || ((_state24 = state) === null || _state24 === void 0 ? void 0 : (_state24$data = _state24.data) === null || _state24$data === void 0 ? void 0 : (_state24$data$connect = _state24$data.connectionType) === null || _state24$data$connect === void 0 ? void 0 : _state24$data$connect.toUpperCase()) === "PERMANENT" || ((_state25 = state) === null || _state25 === void 0 ? void 0 : (_state25$data = _state25.data) === null || _state25$data === void 0 ? void 0 : (_state25$data$additio = _state25$data.additionalDetails) === null || _state25$data$additio === void 0 ? void 0 : (_state25$data$additio2 = _state25$data$additio.connectionType) === null || _state25$data$additio2 === void 0 ? void 0 : _state25$data$additio2.toUpperCase()) === "METERED" || ((_state26 = state) === null || _state26 === void 0 ? void 0 : (_state26$data = _state26.data) === null || _state26$data === void 0 ? void 0 : (_state26$data$additio = _state26$data.additionalDetails) === null || _state26$data$additio === void 0 ? void 0 : (_state26$data$additio2 = _state26$data$additio.connectionType) === null || _state26$data$additio2 === void 0 ? void 0 : _state26$data$additio2.toUpperCase()) === "PERMANENT";
53398
+ const activationDetails = isMeteredConn && ((_state27 = state) === null || _state27 === void 0 ? void 0 : (_state27$data = _state27.data) === null || _state27$data === void 0 ? void 0 : _state27$data.applicationType) !== "WATER_RECONNECTION" ? [{
53399
+ meterId: ((_state28 = state) === null || _state28 === void 0 ? void 0 : (_state28$data = _state28.data) === null || _state28$data === void 0 ? void 0 : _state28$data.meterId) || "",
53400
+ meterInstallationDate: (_state29 = state) !== null && _state29 !== void 0 && (_state29$data = _state29.data) !== null && _state29$data !== void 0 && _state29$data.meterInstallationDate ? convertEpochToDates((_state30 = state) === null || _state30 === void 0 ? void 0 : (_state30$data = _state30.data) === null || _state30$data === void 0 ? void 0 : _state30$data.meterInstallationDate) : null,
53401
+ meterInitialReading: ((_state31 = state) === null || _state31 === void 0 ? void 0 : (_state31$data = _state31.data) === null || _state31$data === void 0 ? void 0 : (_state31$data$additio = _state31$data.additionalDetails) === null || _state31$data$additio === void 0 ? void 0 : _state31$data$additio.initialMeterReading) || "",
53402
+ connectionExecutionDate: (_state32 = state) !== null && _state32 !== void 0 && (_state32$data = _state32.data) !== null && _state32$data !== void 0 && _state32$data.connectionExecutionDate ? convertEpochToDates((_state33 = state) === null || _state33 === void 0 ? void 0 : (_state33$data = _state33.data) === null || _state33$data === void 0 ? void 0 : _state33$data.connectionExecutionDate) : null
53429
53403
  }] : [{
53430
- connectionExecutionDate: (_state31 = state) !== null && _state31 !== void 0 && (_state31$data = _state31.data) !== null && _state31$data !== void 0 && _state31$data.connectionExecutionDate ? convertEpochToDates((_state32 = state) === null || _state32 === void 0 ? void 0 : (_state32$data = _state32.data) === null || _state32$data === void 0 ? void 0 : _state32$data.connectionExecutionDate) : null
53404
+ connectionExecutionDate: (_state34 = state) !== null && _state34 !== void 0 && (_state34$data = _state34.data) !== null && _state34$data !== void 0 && _state34$data.connectionExecutionDate ? convertEpochToDates((_state35 = state) === null || _state35 === void 0 ? void 0 : (_state35$data = _state35.data) === null || _state35$data === void 0 ? void 0 : _state35$data.connectionExecutionDate) : null
53431
53405
  }];
53432
53406
  const defaultValues = {
53433
53407
  formDetails: details,
@@ -53441,13 +53415,25 @@ const ActivateConnection = () => {
53441
53415
  }
53442
53416
  }, []);
53443
53417
  React.useEffect(() => {
53444
- if (!isLoading && newConfig && Array.isArray(newConfig)) {
53445
- const configObj = newConfig.find(conf => conf.hideInCitizen);
53418
+ const configsToUse = !isLoading && newConfig && Array.isArray(newConfig) && newConfig.length > 0 ? newConfig : newConfig$2;
53419
+ if (configsToUse && Array.isArray(configsToUse)) {
53420
+ var _Digit$UserService$ge, _Digit$UserService$ge2;
53421
+ const isCitizen = ((_Digit$UserService$ge = Digit.UserService.getUser()) === null || _Digit$UserService$ge === void 0 ? void 0 : (_Digit$UserService$ge2 = _Digit$UserService$ge.info) === null || _Digit$UserService$ge2 === void 0 ? void 0 : _Digit$UserService$ge2.type) === "CITIZEN" || window.location.href.includes("/citizen");
53422
+ const configObj = configsToUse.find(conf => conf.hideInCitizen) || configsToUse[0];
53446
53423
  if (configObj && configObj.body) {
53447
53424
  let flattenedBody = [];
53448
53425
  configObj.body.forEach(section => {
53449
53426
  if (section.body && Array.isArray(section.body)) {
53450
- flattenedBody = [...flattenedBody, ...section.body];
53427
+ const mappedSectionBody = section.body.map(item => {
53428
+ if (item.key === "activationDetails" && (isCitizen || item.component === "WSActivationPageDetails")) {
53429
+ return {
53430
+ ...item,
53431
+ component: "WSActivationDetails"
53432
+ };
53433
+ }
53434
+ return item;
53435
+ });
53436
+ flattenedBody = [...flattenedBody, ...mappedSectionBody];
53451
53437
  }
53452
53438
  });
53453
53439
  setConfig([{
@@ -53456,12 +53442,12 @@ const ActivateConnection = () => {
53456
53442
  }]);
53457
53443
  }
53458
53444
  }
53459
- }, [newConfig]);
53445
+ }, [newConfig, isLoading]);
53460
53446
  React.useEffect(() => {
53461
53447
  const timer = setTimeout(() => {
53462
53448
  if (isAppDetailsPage) {
53463
- var _Digit$UserService$ge, _Digit$UserService$ge2;
53464
- const isCitizen = ((_Digit$UserService$ge = Digit.UserService.getUser()) === null || _Digit$UserService$ge === void 0 ? void 0 : (_Digit$UserService$ge2 = _Digit$UserService$ge.info) === null || _Digit$UserService$ge2 === void 0 ? void 0 : _Digit$UserService$ge2.type) === "CITIZEN";
53449
+ var _Digit$UserService$ge3, _Digit$UserService$ge4;
53450
+ const isCitizen = ((_Digit$UserService$ge3 = Digit.UserService.getUser()) === null || _Digit$UserService$ge3 === void 0 ? void 0 : (_Digit$UserService$ge4 = _Digit$UserService$ge3.info) === null || _Digit$UserService$ge4 === void 0 ? void 0 : _Digit$UserService$ge4.type) === "CITIZEN";
53465
53451
  if (isCitizen) {
53466
53452
  window.location.href = `${window.location.origin}/digit-ui/citizen/ws/connection/application/${filters === null || filters === void 0 ? void 0 : filters.applicationNumber}`;
53467
53453
  } else {
@@ -53506,9 +53492,8 @@ const ActivateConnection = () => {
53506
53492
  setShowToast(false);
53507
53493
  }, 3000);
53508
53494
  } else {
53509
- var _Object$keys, _details3, _formDetails$connecti, _formDetails$connecti2, _formDetails$connecti3, _formDetails$connecti4, _formDetails$connecti5, _formDetails$connecti6, _formDetails$connecti7, _formDetails$connecti8, _formDetails$connecti9, _formDetails$connecti0, _formDetails$connecti1, _formDetails$connecti10, _formDetails$connecti11, _formDetails$connecti12, _formDetails$connecti13, _formDetails$connecti14, _formDetails$connecti15, _formDetails$connecti16, _formDetails$connecti17, _formDetails$connecti18, _formDetails$connecti19, _formDetails$connecti20, _formDetails$connecti21, _formDetails$connecti22, _formDetails$connecti23, _formDetails$connecti24, _formDetails$connecti25, _formDetails$connecti26, _formDetails$connecti27, _formDetails$connecti28, _formDetails$plumberD, _formDetails$plumberD2, _formDetails$plumberD3, _formData$plumberInfo, _formDetails$plumberD7, _formDetails$plumberD8, _formDetails$plumberD9, _formDetails$plumberD0, _formDetails$plumberD1, _formDetails$plumberD10, _formDetails$plumberD11, _formDetails$plumberD12, _formDetails$plumberD13, _formDetails$plumberD14, _formDetails$plumberD15, _formDetails$plumberD16, _formDetails$activati9, _formDetails$activati0, _formDetails$activati1, _formDetails$activati10;
53495
+ var _Object$keys, _details3, _formDetails$connecti, _formDetails$connecti2, _formDetails$connecti3, _formDetails$connecti4, _formDetails$connecti5, _formDetails$connecti6, _formDetails$connecti7, _formDetails$connecti8, _formDetails$connecti9, _formDetails$connecti0, _formDetails$connecti1, _formDetails$connecti10, _formDetails$connecti11, _formDetails$connecti12, _formDetails$connecti13, _formDetails$connecti14, _formDetails$connecti15, _formDetails$connecti16, _formDetails$connecti17, _formDetails$connecti18, _formDetails$connecti19, _formDetails$connecti20, _formDetails$connecti21, _formDetails$connecti22, _formDetails$connecti23, _formDetails$connecti24, _formDetails$connecti25, _formDetails$connecti26, _formDetails$connecti27, _formDetails$connecti28, _formDetails$plumberD, _formDetails$plumberD2, _formDetails$plumberD3, _formData$plumberInfo, _formDetails$plumberD7, _formDetails$plumberD8, _formDetails$plumberD9, _formDetails$plumberD0, _formDetails$plumberD1, _formDetails$plumberD10, _formDetails$plumberD11, _formDetails$plumberD12, _formDetails$plumberD13, _formDetails$plumberD14, _formDetails$plumberD15, _formDetails$plumberD16, _formDetails$activati;
53510
53496
  function _temp4() {
53511
- var _formDetails$activati, _formDetails$activati2, _formDetails$activati3, _formDetails$activati4;
53512
53497
  function _temp2() {
53513
53498
  var _formDetails$comments, _data$supportingDocum, _data$supportingDocum2, _data$supportingDocum3, _data$supportingDocum4, _formDetails$comments2, _data$supportingDocum5, _data$supportingDocum6, _data$supportingDocum7, _data$supportingDocum8;
53514
53499
  formData.comment = (formDetails === null || formDetails === void 0 ? void 0 : (_formDetails$comments = formDetails.comments) === null || _formDetails$comments === void 0 ? void 0 : _formDetails$comments.comments) || "";
@@ -53516,7 +53501,8 @@ const ActivateConnection = () => {
53516
53501
  formData.wfDocuments = data !== null && data !== void 0 && (_data$supportingDocum = data.supportingDocuments) !== null && _data$supportingDocum !== void 0 && (_data$supportingDocum2 = _data$supportingDocum[0]) !== null && _data$supportingDocum2 !== void 0 && _data$supportingDocum2.fileStoreId ? [{
53517
53502
  documentType: "Document - 1",
53518
53503
  fileStoreId: data === null || data === void 0 ? void 0 : (_data$supportingDocum3 = data.supportingDocuments) === null || _data$supportingDocum3 === void 0 ? void 0 : (_data$supportingDocum4 = _data$supportingDocum3[0]) === null || _data$supportingDocum4 === void 0 ? void 0 : _data$supportingDocum4.fileStoreId
53519
- }] : [], formData.processInstance = {
53504
+ }] : [];
53505
+ formData.processInstance = {
53520
53506
  action: filters === null || filters === void 0 ? void 0 : filters.action,
53521
53507
  comment: (formDetails === null || formDetails === void 0 ? void 0 : (_formDetails$comments2 = formDetails.comments) === null || _formDetails$comments2 === void 0 ? void 0 : _formDetails$comments2.comments) || "",
53522
53508
  documents: data !== null && data !== void 0 && (_data$supportingDocum5 = data.supportingDocuments) !== null && _data$supportingDocum5 !== void 0 && (_data$supportingDocum6 = _data$supportingDocum5[0]) !== null && _data$supportingDocum6 !== void 0 && _data$supportingDocum6.fileStoreId ? [{
@@ -53524,7 +53510,18 @@ const ActivateConnection = () => {
53524
53510
  fileStoreId: data === null || data === void 0 ? void 0 : (_data$supportingDocum7 = data.supportingDocuments) === null || _data$supportingDocum7 === void 0 ? void 0 : (_data$supportingDocum8 = _data$supportingDocum7[0]) === null || _data$supportingDocum8 === void 0 ? void 0 : _data$supportingDocum8.fileStoreId
53525
53511
  }] : []
53526
53512
  };
53527
- const reqDetails = (filters === null || filters === void 0 ? void 0 : filters.service) == "WATER" ? (formData === null || formData === void 0 ? void 0 : formData.applicationType) === "WATER_RECONNECTION" ? {
53513
+ const isWater = filters !== null && filters !== void 0 && filters.service ? filters.service.toUpperCase() === "WATER" : (formData === null || formData === void 0 ? void 0 : formData.serviceType) === "WATER" || !(formData !== null && formData !== void 0 && formData.serviceType);
53514
+ if (isWater) {
53515
+ formData.waterSource = "GROUND.WELL";
53516
+ formData.proposedPipeSize = 0;
53517
+ formData.proposedTaps = 0;
53518
+ formData.pipeSize = 0;
53519
+ formData.noOfTaps = 0;
53520
+ formData.connectionType = "Metered";
53521
+ if (!formData.additionalDetails) formData.additionalDetails = {};
53522
+ formData.additionalDetails.connectionType = "Permanent";
53523
+ }
53524
+ const reqDetails = isWater ? (formData === null || formData === void 0 ? void 0 : formData.applicationType) === "WATER_RECONNECTION" ? {
53528
53525
  WaterConnection: formData,
53529
53526
  reconnectRequest: true,
53530
53527
  disconnectRequest: false
@@ -53541,6 +53538,20 @@ const ActivateConnection = () => {
53541
53538
  reconnectRequest: false,
53542
53539
  disconnectRequest: false
53543
53540
  };
53541
+ if (reqDetails !== null && reqDetails !== void 0 && reqDetails.WaterConnection) {
53542
+ reqDetails.WaterConnection.waterSource = "GROUND.WELL";
53543
+ reqDetails.WaterConnection.proposedPipeSize = 0;
53544
+ reqDetails.WaterConnection.proposedTaps = 0;
53545
+ reqDetails.WaterConnection.pipeSize = 0;
53546
+ reqDetails.WaterConnection.noOfTaps = 0;
53547
+ reqDetails.WaterConnection.connectionType = "Metered";
53548
+ if (!reqDetails.WaterConnection.additionalDetails) reqDetails.WaterConnection.additionalDetails = {};
53549
+ reqDetails.WaterConnection.additionalDetails.connectionType = "Permanent";
53550
+ }
53551
+ if (reqDetails !== null && reqDetails !== void 0 && reqDetails.SewerageConnection) {
53552
+ if (!reqDetails.SewerageConnection.additionalDetails) reqDetails.SewerageConnection.additionalDetails = {};
53553
+ reqDetails.SewerageConnection.additionalDetails.connectionType = "Permanent";
53554
+ }
53544
53555
  if (mutate) {
53545
53556
  mutate(reqDetails, {
53546
53557
  onError: (error, variables) => {
@@ -53560,9 +53571,10 @@ const ActivateConnection = () => {
53560
53571
  });
53561
53572
  }
53562
53573
  }
53563
- if (formDetails !== null && formDetails !== void 0 && (_formDetails$activati = formDetails.activationDetails) !== null && _formDetails$activati !== void 0 && (_formDetails$activati2 = _formDetails$activati[0]) !== null && _formDetails$activati2 !== void 0 && _formDetails$activati2.meterInitialReading) formData.additionalDetails.initialMeterReading = formDetails === null || formDetails === void 0 ? void 0 : (_formDetails$activati3 = formDetails.activationDetails) === null || _formDetails$activati3 === void 0 ? void 0 : (_formDetails$activati4 = _formDetails$activati3[0]) === null || _formDetails$activati4 === void 0 ? void 0 : _formDetails$activati4.meterInitialReading;
53564
- const _temp = function (_formDetails$activati5, _formDetails$activati6, _formDetails$activati7, _formDetails$activati8) {
53565
- if (formDetails !== null && formDetails !== void 0 && (_formDetails$activati5 = formDetails.activationDetails) !== null && _formDetails$activati5 !== void 0 && (_formDetails$activati6 = _formDetails$activati5[0]) !== null && _formDetails$activati6 !== void 0 && _formDetails$activati6.connectionExecutionDate) return Promise.resolve(getConvertedDate(formDetails === null || formDetails === void 0 ? void 0 : (_formDetails$activati7 = formDetails.activationDetails) === null || _formDetails$activati7 === void 0 ? void 0 : (_formDetails$activati8 = _formDetails$activati7[0]) === null || _formDetails$activati8 === void 0 ? void 0 : _formDetails$activati8.connectionExecutionDate)).then(function (_getConvertedDate2) {
53574
+ if (!formData.additionalDetails) formData.additionalDetails = {};
53575
+ formData.additionalDetails.initialMeterReading = (actObj === null || actObj === void 0 ? void 0 : actObj.meterInitialReading) !== undefined && (actObj === null || actObj === void 0 ? void 0 : actObj.meterInitialReading) !== "" ? actObj.meterInitialReading : "0";
53576
+ const _temp = function () {
53577
+ if (actObj !== null && actObj !== void 0 && actObj.connectionExecutionDate) return Promise.resolve(getConvertedDate(actObj === null || actObj === void 0 ? void 0 : actObj.connectionExecutionDate)).then(function (_getConvertedDate2) {
53566
53578
  formData.connectionExecutionDate = _getConvertedDate2;
53567
53579
  });
53568
53580
  }();
@@ -53589,9 +53601,10 @@ const ActivateConnection = () => {
53589
53601
  if (formDetails !== null && formDetails !== void 0 && (_formDetails$plumberD7 = formDetails.plumberDetails) !== null && _formDetails$plumberD7 !== void 0 && (_formDetails$plumberD8 = _formDetails$plumberD7[0]) !== null && _formDetails$plumberD8 !== void 0 && _formDetails$plumberD8.plumberName) formData.plumberInfo[0].name = formDetails === null || formDetails === void 0 ? void 0 : (_formDetails$plumberD9 = formDetails.plumberDetails) === null || _formDetails$plumberD9 === void 0 ? void 0 : (_formDetails$plumberD0 = _formDetails$plumberD9[0]) === null || _formDetails$plumberD0 === void 0 ? void 0 : _formDetails$plumberD0.plumberName;
53590
53602
  if (formDetails !== null && formDetails !== void 0 && (_formDetails$plumberD1 = formDetails.plumberDetails) !== null && _formDetails$plumberD1 !== void 0 && (_formDetails$plumberD10 = _formDetails$plumberD1[0]) !== null && _formDetails$plumberD10 !== void 0 && _formDetails$plumberD10.plumberLicenseNo) formData.plumberInfo[0].licenseNo = formDetails === null || formDetails === void 0 ? void 0 : (_formDetails$plumberD11 = formDetails.plumberDetails) === null || _formDetails$plumberD11 === void 0 ? void 0 : (_formDetails$plumberD12 = _formDetails$plumberD11[0]) === null || _formDetails$plumberD12 === void 0 ? void 0 : _formDetails$plumberD12.plumberLicenseNo;
53591
53603
  if (formDetails !== null && formDetails !== void 0 && (_formDetails$plumberD13 = formDetails.plumberDetails) !== null && _formDetails$plumberD13 !== void 0 && (_formDetails$plumberD14 = _formDetails$plumberD13[0]) !== null && _formDetails$plumberD14 !== void 0 && _formDetails$plumberD14.plumberMobileNo) formData.plumberInfo[0].mobileNumber = formDetails === null || formDetails === void 0 ? void 0 : (_formDetails$plumberD15 = formDetails.plumberDetails) === null || _formDetails$plumberD15 === void 0 ? void 0 : (_formDetails$plumberD16 = _formDetails$plumberD15[0]) === null || _formDetails$plumberD16 === void 0 ? void 0 : _formDetails$plumberD16.plumberMobileNo;
53592
- if (formDetails !== null && formDetails !== void 0 && (_formDetails$activati9 = formDetails.activationDetails) !== null && _formDetails$activati9 !== void 0 && (_formDetails$activati0 = _formDetails$activati9[0]) !== null && _formDetails$activati0 !== void 0 && _formDetails$activati0.meterId) formData.meterId = formDetails === null || formDetails === void 0 ? void 0 : (_formDetails$activati1 = formDetails.activationDetails) === null || _formDetails$activati1 === void 0 ? void 0 : (_formDetails$activati10 = _formDetails$activati1[0]) === null || _formDetails$activati10 === void 0 ? void 0 : _formDetails$activati10.meterId;
53593
- const _temp3 = function (_formDetails$activati11, _formDetails$activati12, _formDetails$activati13, _formDetails$activati14) {
53594
- if (formDetails !== null && formDetails !== void 0 && (_formDetails$activati11 = formDetails.activationDetails) !== null && _formDetails$activati11 !== void 0 && (_formDetails$activati12 = _formDetails$activati11[0]) !== null && _formDetails$activati12 !== void 0 && _formDetails$activati12.meterInstallationDate) return Promise.resolve(getConvertedDate(formDetails === null || formDetails === void 0 ? void 0 : (_formDetails$activati13 = formDetails.activationDetails) === null || _formDetails$activati13 === void 0 ? void 0 : (_formDetails$activati14 = _formDetails$activati13[0]) === null || _formDetails$activati14 === void 0 ? void 0 : _formDetails$activati14.meterInstallationDate)).then(function (_getConvertedDate) {
53604
+ const actObj = Array.isArray(formDetails === null || formDetails === void 0 ? void 0 : formDetails.activationDetails) ? formDetails === null || formDetails === void 0 ? void 0 : (_formDetails$activati = formDetails.activationDetails) === null || _formDetails$activati === void 0 ? void 0 : _formDetails$activati[0] : formDetails === null || formDetails === void 0 ? void 0 : formDetails.activationDetails;
53605
+ if (actObj !== null && actObj !== void 0 && actObj.meterId) formData.meterId = actObj === null || actObj === void 0 ? void 0 : actObj.meterId;
53606
+ const _temp3 = function () {
53607
+ if (actObj !== null && actObj !== void 0 && actObj.meterInstallationDate) return Promise.resolve(getConvertedDate(actObj === null || actObj === void 0 ? void 0 : actObj.meterInstallationDate)).then(function (_getConvertedDate) {
53595
53608
  formData.meterInstallationDate = _getConvertedDate;
53596
53609
  });
53597
53610
  }();
@@ -53625,7 +53638,6 @@ const ActivateConnection = () => {
53625
53638
  body: config.body
53626
53639
  };
53627
53640
  }),
53628
- userType: "employee",
53629
53641
  defaultValues: defaultValues,
53630
53642
  onSubmit: onSubmit,
53631
53643
  label: t("WF_EMPLOYEE_NEWSW1_ACTIVATE_CONNECTION"),
@@ -60571,7 +60583,7 @@ const openFilePDF = fileId => {
60571
60583
  }).catch(error => console.error("Error fetching file:", error));
60572
60584
  };
60573
60585
  const CheckPage$4 = _ref2 => {
60574
- var _Digit$UserService$ge, _data$cpt, _data$ConnectionDetai, _data$connectionDetai, _data$ConnectionHolde, _data$connectionHolde, _data$useDetails, _data$DocumentsRequir, _data$documents, _data$djbEmployee, _data$disability, _connectionDetails, _connectionDetails$se, _connectionDetails2, _connectionDetails2$s, _connectionDetails3, _connectionDetails4, _connectionDetails4$a, _connectionDetails5, _connectionDetails5$a, _connectionDetails6, _holderDetails, _holderDetails2, _holderDetails3, _holderDetails4, _holderDetails4$gende, _holderDetails5, _holderDetails5$gende, _holderDetails6, _holderDetails7, _holderDetails8, _holderDetails9, _propertyAddress, _propertyAddress$zro, _propertyAddress2, _propertyAddress3, _propertyAddress4, _propertyAddress4$add, _propertyAddress5, _propertyAddress5$add, _propertyAddress6, _propertyAddress6$add, _propertyAddress7, _propertyAddress8, _propertyAddress8$cit, _propertyAddress9, _propertyAddress9$cit, _propertyAddress0, _propertyAddress1, _propertyAddress10, _propertyAddress11, _propertyAddress11$lo, _propertyAddress12, _propertyAddress12$lo, _propertyAddress13, _propertyAddress14, _propertyAddress14$su, _propertyAddress15, _propertyAddress15$su, _propertyAddress16, _propertyAddress17, _propertyAddress18, _propertyAddress19, _propertyAddress20, _propertyAddress21, _propertyAddress22, _propertyAddress23, _propertyAddress24, _propertyAddress25, _propertyAddress26, _propertyAddress26$as, _propertyAddress27, _propertyAddress27$as, _propertyAddress28, _propertyAddress29, _propertyAddress29$bl, _propertyAddress30, _propertyAddress30$bl, _propertyAddress31, _propertyAddress32, _propertyAddress32$wa, _propertyAddress33, _propertyAddress33$wa, _propertyAddress34, _propertyAddress35, _propertyAddress35$zo, _propertyAddress36, _propertyAddress36$zo, _propertyAddress37, _propertyAddress38, _propertyAddress39, _propertyAddress40, _propertyAddress41, _useDetails$categoryT, _useDetails$categoryT2, _useDetails$propertyC, _useDetails$propertyC2, _useDetails$propertyT, _useDetails$propertyT2, _useDetails$WaterConn, _useDetails$WaterConn2, _useDetails$waterConn, _useDetails$waterConn2, _useDetails$noOfFloor, _useDetails$noOfFloor2, _useDetails$SelectYea, _useDetails$SelectYea2, _useDetails$SelectYea3, _useDetails$construct, _useDetails$construct2;
60586
+ var _Digit$UserService$ge, _data$cpt, _data$ConnectionDetai, _data$connectionDetai, _data$ConnectionHolde, _data$connectionHolde, _data$useDetails, _data$DocumentsRequir, _data$documents, _data$djbEmployee, _data$disability, _connectionDetails, _connectionDetails$se, _connectionDetails2, _connectionDetails2$s, _connectionDetails3, _connectionDetails4, _connectionDetails4$a, _connectionDetails5, _connectionDetails5$a, _connectionDetails6, _holderDetails, _holderDetails2, _holderDetails3, _holderDetails4, _holderDetails4$gende, _holderDetails5, _holderDetails5$gende, _holderDetails6, _holderDetails7, _holderDetails8, _holderDetails9, _propertyAddress, _propertyAddress$zro, _propertyAddress2, _propertyAddress3, _propertyAddress4, _propertyAddress4$add, _propertyAddress5, _propertyAddress5$add, _propertyAddress6, _propertyAddress6$add, _propertyAddress7, _propertyAddress8, _propertyAddress8$cit, _propertyAddress9, _propertyAddress9$cit, _propertyAddress0, _propertyAddress1, _propertyAddress10, _propertyAddress11, _propertyAddress11$lo, _propertyAddress12, _propertyAddress12$lo, _propertyAddress13, _propertyAddress14, _propertyAddress14$su, _propertyAddress15, _propertyAddress15$su, _propertyAddress16, _propertyAddress17, _propertyAddress18, _propertyAddress19, _propertyAddress20, _propertyAddress21, _propertyAddress22, _propertyAddress23, _propertyAddress24, _propertyAddress25, _propertyAddress26, _propertyAddress26$as, _propertyAddress27, _propertyAddress27$as, _propertyAddress28, _propertyAddress29, _propertyAddress29$bl, _propertyAddress30, _propertyAddress30$bl, _propertyAddress31, _propertyAddress32, _propertyAddress32$wa, _propertyAddress33, _propertyAddress33$wa, _propertyAddress34, _propertyAddress35, _propertyAddress35$zo, _propertyAddress36, _propertyAddress36$zo, _propertyAddress37, _propertyAddress38, _propertyAddress39, _propertyAddress40, _propertyAddress41, _useDetails$categoryT, _useDetails$categoryT2, _useDetails$propertyC, _useDetails$propertyC2, _useDetails$propertyT, _useDetails$propertyT2, _useDetails$WaterConn, _useDetails$WaterConn2, _useDetails$waterConn, _useDetails$waterConn2, _useDetails$noOfFloor, _useDetails$noOfFloor2, _useDetails$SelectYea, _useDetails$SelectYea2, _useDetails$SelectYea3, _useDetails$construct, _useDetails$construct2, _useDetails$propertyT3;
60575
60587
  let {
60576
60588
  data,
60577
60589
  onSubmit,
@@ -60760,10 +60772,10 @@ const CheckPage$4 = _ref2 => {
60760
60772
  }), /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
60761
60773
  label: t("WS_SELECT_YEAR_OF_CONSTRUCTION"),
60762
60774
  text: `${t(checkForNA((useDetails === null || useDetails === void 0 ? void 0 : (_useDetails$SelectYea = useDetails.SelectYearofConstruction) === null || _useDetails$SelectYea === void 0 ? void 0 : _useDetails$SelectYea.i18nKey) || (useDetails === null || useDetails === void 0 ? void 0 : (_useDetails$SelectYea2 = useDetails.SelectYearofConstruction) === null || _useDetails$SelectYea2 === void 0 ? void 0 : _useDetails$SelectYea2.value) || (useDetails === null || useDetails === void 0 ? void 0 : (_useDetails$SelectYea3 = useDetails.SelectYearofConstruction) === null || _useDetails$SelectYea3 === void 0 ? void 0 : _useDetails$SelectYea3.code) || (useDetails === null || useDetails === void 0 ? void 0 : useDetails.SelectYearofConstruction) || (useDetails === null || useDetails === void 0 ? void 0 : (_useDetails$construct = useDetails.constructionYear) === null || _useDetails$construct === void 0 ? void 0 : _useDetails$construct.i18nKey) || (useDetails === null || useDetails === void 0 ? void 0 : (_useDetails$construct2 = useDetails.constructionYear) === null || _useDetails$construct2 === void 0 ? void 0 : _useDetails$construct2.code) || (useDetails === null || useDetails === void 0 ? void 0 : useDetails.constructionYear)))}`
60763
- }), /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
60775
+ }), ["Apartment", "DDAFlats", "GovtFlats", "Bungalows", "FlatOrApartment", "GroupHousingSociety", "JJSLUMS", "IndividualHouse", "BuiltUp.GroupHousingSociety", "BuiltUp.JJSLUMS", "BuiltUp.IndividualHouse"].includes((useDetails === null || useDetails === void 0 ? void 0 : (_useDetails$propertyT3 = useDetails.propertyType) === null || _useDetails$propertyT3 === void 0 ? void 0 : _useDetails$propertyT3.code) || (useDetails === null || useDetails === void 0 ? void 0 : useDetails.propertyType)) ? /*#__PURE__*/React__default.createElement(digitUiReactComponents.Row, {
60764
60776
  label: t("WS_NUMBER_OF_DWELLING_UNITS"),
60765
60777
  text: `${t(checkForNA((useDetails === null || useDetails === void 0 ? void 0 : useDetails.NumberofDwellingUnits) || (useDetails === null || useDetails === void 0 ? void 0 : useDetails.noOfDwellingUnits)))}`
60766
- })), /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardSubHeader, null, t("WS_DJB_EMPLOYEE")), /*#__PURE__*/React__default.createElement(digitUiReactComponents.StatusTable, {
60778
+ }) : null), /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement(digitUiReactComponents.CardSubHeader, null, t("WS_DJB_EMPLOYEE")), /*#__PURE__*/React__default.createElement(digitUiReactComponents.StatusTable, {
60767
60779
  style: {
60768
60780
  marginTop: "10px",
60769
60781
  marginBottom: "30px"