@egovernments/digit-ui-libraries 1.5.0-beta.2 → 1.5.0-beta.28

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.
@@ -970,6 +970,8 @@ var LocalizationService = {
970
970
  locale: locale,
971
971
  tenantId: tenantId
972
972
  });
973
+ localStorage.setItem("Employee.locale", locale);
974
+ localStorage.setItem("Citizen.locale", locale);
973
975
  Digit.SessionStorage.set("locale", locale);
974
976
  i18next.changeLanguage(locale);
975
977
  },
@@ -34138,12 +34140,13 @@ var Download = {
34138
34140
  });
34139
34141
  },
34140
34142
  Excel: function Excel(data, filename) {
34143
+ var file = filename.substring(0, 30);
34141
34144
  var wb = XLSX.utils.book_new();
34142
34145
  var ws = null;
34143
34146
  ws = XLSX.utils.json_to_sheet(data);
34144
- wb.SheetNames.push(filename);
34145
- wb.Sheets[filename] = ws;
34146
- XLSX.writeFile(wb, filename + ".xlsx");
34147
+ wb.SheetNames.push(file);
34148
+ wb.Sheets[file] = ws;
34149
+ XLSX.writeFile(wb, file + ".xlsx");
34147
34150
  },
34148
34151
  PDF: function PDF(node, fileName, share, resolve) {
34149
34152
  if (resolve === void 0) {
@@ -34151,6 +34154,10 @@ var Download = {
34151
34154
  }
34152
34155
 
34153
34156
  var saveAs = function saveAs(uri, filename) {
34157
+ if (window.mSewaApp && window.mSewaApp.isMsewaApp()) {
34158
+ window.mSewaApp.downloadBase64File(uri, filename);
34159
+ }
34160
+
34154
34161
  var link = document.createElement("a");
34155
34162
 
34156
34163
  if (typeof link.download === "string") {
@@ -34207,6 +34214,10 @@ var Download = {
34207
34214
  }
34208
34215
 
34209
34216
  var saveAs = function saveAs(uri, filename) {
34217
+ if (window.mSewaApp && window.mSewaApp.isMsewaApp()) {
34218
+ window.mSewaApp.downloadBase64File(uri, filename);
34219
+ }
34220
+
34210
34221
  var link = document.createElement("a");
34211
34222
 
34212
34223
  if (typeof link.download === "string") {
@@ -35890,23 +35901,50 @@ function cloneDeep(value) {
35890
35901
 
35891
35902
  var cloneDeep_1 = cloneDeep;
35892
35903
 
35893
- var getThumbnails = function getThumbnails(ids, tenantId) {
35904
+ var getThumbnails = function getThumbnails(ids, tenantId, documents) {
35905
+ if (documents === void 0) {
35906
+ documents = [];
35907
+ }
35908
+
35894
35909
  try {
35895
35910
  tenantId = window.location.href.includes("/obps/") ? Digit.ULBService.getStateId() : tenantId;
35896
- return Promise.resolve(Digit.UploadServices.Filefetch(ids, tenantId)).then(function (res) {
35897
- if (res.data.fileStoreIds && res.data.fileStoreIds.length !== 0) {
35898
- return {
35899
- thumbs: res.data.fileStoreIds.map(function (o) {
35900
- return o.url.split(",")[3] || o.url.split(",")[0];
35901
- }),
35902
- images: res.data.fileStoreIds.map(function (o) {
35903
- return Digit.Utils.getFileUrl(o.url);
35904
- })
35905
- };
35911
+
35912
+ if (window.location.href.includes("/obps/")) {
35913
+ var _documents;
35914
+
35915
+ if (((_documents = documents) === null || _documents === void 0 ? void 0 : _documents.length) > 0) {
35916
+ var _documents2;
35917
+
35918
+ var workflowsDocs = [];
35919
+ (_documents2 = documents) === null || _documents2 === void 0 ? void 0 : _documents2.map(function (doc) {
35920
+ if (doc !== null && doc !== void 0 && doc.url) {
35921
+ var thumbs = doc.url.split(",")[3] || doc.url.split(",")[0];
35922
+ workflowsDocs.push({
35923
+ thumbs: [thumbs],
35924
+ images: [Digit.Utils.getFileUrl(doc.url)]
35925
+ });
35926
+ }
35927
+ });
35928
+ return Promise.resolve(workflowsDocs === null || workflowsDocs === void 0 ? void 0 : workflowsDocs[0]);
35906
35929
  } else {
35907
- return null;
35930
+ return Promise.resolve(null);
35908
35931
  }
35909
- });
35932
+ } else {
35933
+ return Promise.resolve(Digit.UploadServices.Filefetch(ids, tenantId)).then(function (res) {
35934
+ if (res.data.fileStoreIds && res.data.fileStoreIds.length !== 0) {
35935
+ return {
35936
+ thumbs: res.data.fileStoreIds.map(function (o) {
35937
+ return o.url.split(",")[3] || o.url.split(",")[0];
35938
+ }),
35939
+ images: res.data.fileStoreIds.map(function (o) {
35940
+ return Digit.Utils.getFileUrl(o.url);
35941
+ })
35942
+ };
35943
+ } else {
35944
+ return null;
35945
+ }
35946
+ });
35947
+ }
35910
35948
  } catch (e) {
35911
35949
  return Promise.reject(e);
35912
35950
  }
@@ -35914,45 +35952,86 @@ var getThumbnails = function getThumbnails(ids, tenantId) {
35914
35952
 
35915
35953
  var makeCommentsSubsidariesOfPreviousActions = function makeCommentsSubsidariesOfPreviousActions(wf) {
35916
35954
  try {
35917
- var _temp5 = function _temp5() {
35918
- var response = TimelineMap.get("tlActions");
35919
- return response;
35920
- };
35955
+ var _wf$;
35921
35956
 
35922
- var TimelineMap = new Map();
35957
+ var _temp9 = function _temp9() {
35958
+ function _temp6() {
35959
+ var response = TimelineMap.get("tlActions");
35960
+ return response;
35961
+ }
35923
35962
 
35924
- var _temp6 = _forOf(wf, function (eventHappened) {
35925
- function _temp2() {
35926
- if (eventHappened.action === "COMMENT") {
35927
- var commentAccumulator = TimelineMap.get("tlCommentStack") || [];
35928
- TimelineMap.set("tlCommentStack", [].concat(commentAccumulator, [eventHappened]));
35929
- } else {
35930
- var eventAccumulator = TimelineMap.get("tlActions") || [];
35963
+ var _temp5 = _forOf(wf, function (eventHappened) {
35964
+ function _temp4() {
35965
+ if (eventHappened.action === "COMMENT") {
35966
+ var commentAccumulator = TimelineMap.get("tlCommentStack") || [];
35967
+ TimelineMap.set("tlCommentStack", [].concat(commentAccumulator, [eventHappened]));
35968
+ } else {
35969
+ var eventAccumulator = TimelineMap.get("tlActions") || [];
35931
35970
 
35932
- var _commentAccumulator = TimelineMap.get("tlCommentStack") || [];
35971
+ var _commentAccumulator = TimelineMap.get("tlCommentStack") || [];
35933
35972
 
35934
- eventHappened.wfComments = [].concat(_commentAccumulator, eventHappened.comment ? [eventHappened] : []);
35935
- TimelineMap.set("tlActions", [].concat(eventAccumulator, [eventHappened]));
35936
- TimelineMap.delete("tlCommentStack");
35973
+ eventHappened.wfComments = [].concat(_commentAccumulator, eventHappened.comment ? [eventHappened] : []);
35974
+ TimelineMap.set("tlActions", [].concat(eventAccumulator, [eventHappened]));
35975
+ TimelineMap.delete("tlCommentStack");
35976
+ }
35937
35977
  }
35938
- }
35939
35978
 
35940
- var _temp = function () {
35941
- if (eventHappened !== null && eventHappened !== void 0 && eventHappened.documents) {
35942
- var _eventHappened$docume;
35979
+ var _temp3 = function () {
35980
+ if (eventHappened !== null && eventHappened !== void 0 && eventHappened.documents) {
35981
+ var _eventHappened$docume;
35982
+
35983
+ return Promise.resolve(getThumbnails(eventHappened === null || eventHappened === void 0 ? void 0 : (_eventHappened$docume = eventHappened.documents) === null || _eventHappened$docume === void 0 ? void 0 : _eventHappened$docume.map(function (e) {
35984
+ return e === null || e === void 0 ? void 0 : e.fileStoreId;
35985
+ }), eventHappened === null || eventHappened === void 0 ? void 0 : eventHappened.tenantId, eventHappened === null || eventHappened === void 0 ? void 0 : eventHappened.documents)).then(function (_getThumbnails) {
35986
+ eventHappened.thumbnailsToShow = _getThumbnails;
35987
+ });
35988
+ }
35989
+ }();
35990
+
35991
+ return _temp3 && _temp3.then ? _temp3.then(_temp4) : _temp4(_temp3);
35992
+ });
35993
+
35994
+ return _temp5 && _temp5.then ? _temp5.then(_temp6) : _temp6(_temp5);
35995
+ };
35943
35996
 
35944
- return Promise.resolve(getThumbnails(eventHappened === null || eventHappened === void 0 ? void 0 : (_eventHappened$docume = eventHappened.documents) === null || _eventHappened$docume === void 0 ? void 0 : _eventHappened$docume.map(function (e) {
35945
- return e === null || e === void 0 ? void 0 : e.fileStoreId;
35946
- }), eventHappened === null || eventHappened === void 0 ? void 0 : eventHappened.tenantId)).then(function (_getThumbnails) {
35947
- eventHappened.thumbnailsToShow = _getThumbnails;
35997
+ var TimelineMap = new Map();
35998
+ var tenantId = window.location.href.includes("/obps/") ? Digit.ULBService.getStateId() : wf === null || wf === void 0 ? void 0 : (_wf$ = wf[0]) === null || _wf$ === void 0 ? void 0 : _wf$.tenantId;
35999
+ var fileStoreIdsList = [];
36000
+ var res = {};
36001
+
36002
+ var _temp10 = function () {
36003
+ if (window.location.href.includes("/obps/")) {
36004
+ var _temp11 = function _temp11() {
36005
+ wf === null || wf === void 0 ? void 0 : wf.forEach(function (wfData) {
36006
+ var _wfData$documents;
36007
+
36008
+ wfData === null || wfData === void 0 ? void 0 : (_wfData$documents = wfData.documents) === null || _wfData$documents === void 0 ? void 0 : _wfData$documents.forEach(function (wfDoc) {
36009
+ if (wfDoc !== null && wfDoc !== void 0 && wfDoc.fileStoreId) wfDoc.url = res.data[wfDoc === null || wfDoc === void 0 ? void 0 : wfDoc.fileStoreId];
36010
+ });
35948
36011
  });
35949
- }
35950
- }();
36012
+ };
35951
36013
 
35952
- return _temp && _temp.then ? _temp.then(_temp2) : _temp2(_temp);
35953
- });
36014
+ wf === null || wf === void 0 ? void 0 : wf.map(function (wfData) {
36015
+ var _wfData$documents2;
35954
36016
 
35955
- return Promise.resolve(_temp6 && _temp6.then ? _temp6.then(_temp5) : _temp5(_temp6));
36017
+ wfData === null || wfData === void 0 ? void 0 : (_wfData$documents2 = wfData.documents) === null || _wfData$documents2 === void 0 ? void 0 : _wfData$documents2.map(function (wfDoc) {
36018
+ if (wfDoc !== null && wfDoc !== void 0 && wfDoc.fileStoreId) fileStoreIdsList.push(wfDoc === null || wfDoc === void 0 ? void 0 : wfDoc.fileStoreId);
36019
+ });
36020
+ });
36021
+
36022
+ var _temp12 = function () {
36023
+ if ((fileStoreIdsList === null || fileStoreIdsList === void 0 ? void 0 : fileStoreIdsList.length) > 0) {
36024
+ return Promise.resolve(Digit.UploadServices.Filefetch(fileStoreIdsList, tenantId)).then(function (_Digit$UploadServices) {
36025
+ res = _Digit$UploadServices;
36026
+ });
36027
+ }
36028
+ }();
36029
+
36030
+ return _temp12 && _temp12.then ? _temp12.then(_temp11) : _temp11(_temp12);
36031
+ }
36032
+ }();
36033
+
36034
+ return Promise.resolve(_temp10 && _temp10.then ? _temp10.then(_temp9) : _temp9(_temp10));
35956
36035
  } catch (e) {
35957
36036
  return Promise.reject(e);
35958
36037
  }
@@ -36012,13 +36091,13 @@ var WorkflowService = {
36012
36091
 
36013
36092
  var _exit = false;
36014
36093
 
36015
- function _temp14(_result2) {
36094
+ function _temp20(_result2) {
36016
36095
  return _exit ? _result2 : {};
36017
36096
  }
36018
36097
 
36019
36098
  var businessServiceResponse = _Digit$WorkflowServic === null || _Digit$WorkflowServic === void 0 ? void 0 : (_Digit$WorkflowServic2 = _Digit$WorkflowServic.BusinessServices[0]) === null || _Digit$WorkflowServic2 === void 0 ? void 0 : _Digit$WorkflowServic2.states;
36020
36099
 
36021
- var _temp13 = function () {
36100
+ var _temp19 = function () {
36022
36101
  if (workflow && workflow.ProcessInstances) {
36023
36102
  var _processInstances$, _businessServiceRespo;
36024
36103
 
@@ -36099,7 +36178,7 @@ var WorkflowService = {
36099
36178
  return function () {
36100
36179
  if (processInstances.length > 0) {
36101
36180
  return Promise.resolve(makeCommentsSubsidariesOfPreviousActions(processInstances)).then(function (TLEnrichedWithWorflowData) {
36102
- function _temp12() {
36181
+ function _temp18() {
36103
36182
  var _workflow$ProcessInst, _workflow$ProcessInst2;
36104
36183
 
36105
36184
  var nextActions = actionRolePair;
@@ -36167,17 +36246,17 @@ var WorkflowService = {
36167
36246
  return checkPoint;
36168
36247
  });
36169
36248
 
36170
- var _temp11 = function () {
36249
+ var _temp17 = function () {
36171
36250
  if (getTripData) {
36172
- var _temp15 = _catch(function () {
36251
+ var _temp21 = _catch(function () {
36173
36252
  var filters = {
36174
36253
  businessService: 'FSM_VEHICLE_TRIP',
36175
36254
  refernceNos: id
36176
36255
  };
36177
36256
  return Promise.resolve(Digit.FSMService.vehicleSearch(tenantId, filters)).then(function (tripSearchResp) {
36178
- var _temp9 = function () {
36257
+ var _temp15 = function () {
36179
36258
  if (tripSearchResp && tripSearchResp.vehicleTrip && tripSearchResp.vehicleTrip.length) {
36180
- var _temp16 = function _temp16() {
36259
+ var _temp22 = function _temp22() {
36181
36260
  var tripTimeline = [];
36182
36261
  var disposalInProgressPosition = timeline.findIndex(function (data) {
36183
36262
  return data.status === "DISPOSAL_IN_PROGRESS";
@@ -36216,7 +36295,7 @@ var WorkflowService = {
36216
36295
  var _waitingForDisposedAction = [];
36217
36296
  var _disposedAction = [];
36218
36297
 
36219
- var _temp17 = _forOf(tripSearchResp.vehicleTrip, function (data) {
36298
+ var _temp23 = _forOf(tripSearchResp.vehicleTrip, function (data) {
36220
36299
  return Promise.resolve(Digit.WorkflowService.getByBusinessId(tenantId, data.applicationNo)).then(function (resp) {
36221
36300
  var _resp$ProcessInstance;
36222
36301
 
@@ -36286,19 +36365,19 @@ var WorkflowService = {
36286
36365
  });
36287
36366
  });
36288
36367
 
36289
- return _temp17 && _temp17.then ? _temp17.then(_temp16) : _temp16(_temp17);
36368
+ return _temp23 && _temp23.then ? _temp23.then(_temp22) : _temp22(_temp23);
36290
36369
  }
36291
36370
  }();
36292
36371
 
36293
- if (_temp9 && _temp9.then) return _temp9.then(function () {});
36372
+ if (_temp15 && _temp15.then) return _temp15.then(function () {});
36294
36373
  });
36295
36374
  }, function () {});
36296
36375
 
36297
- if (_temp15 && _temp15.then) return _temp15.then(function () {});
36376
+ if (_temp21 && _temp21.then) return _temp21.then(function () {});
36298
36377
  }
36299
36378
  }();
36300
36379
 
36301
- return _temp11 && _temp11.then ? _temp11.then(_temp12) : _temp12(_temp11);
36380
+ return _temp17 && _temp17.then ? _temp17.then(_temp18) : _temp18(_temp17);
36302
36381
  });
36303
36382
  }
36304
36383
  }();
@@ -36307,7 +36386,7 @@ var WorkflowService = {
36307
36386
  }
36308
36387
  }();
36309
36388
 
36310
- return _temp13 && _temp13.then ? _temp13.then(_temp14) : _temp14(_temp13);
36389
+ return _temp19 && _temp19.then ? _temp19.then(_temp20) : _temp20(_temp19);
36311
36390
  });
36312
36391
  });
36313
36392
  } catch (e) {
@@ -37119,14 +37198,18 @@ var UrlShortener = function UrlShortener(fileStoreId) {
37119
37198
  });
37120
37199
  };
37121
37200
 
37201
+ var isMobileOrTablet = function isMobileOrTablet() {
37202
+ return /(android|iphone|ipad|mobile)/i.test(navigator.userAgent);
37203
+ };
37204
+
37122
37205
  var ShareFiles = {
37123
37206
  targetLink: function targetLink(target, shortUrl) {
37124
37207
  switch (target) {
37125
37208
  case "mail":
37126
- return window.open("mailto:?body=" + shortUrl, "_blank");
37209
+ return window.open("mailto:?body=" + encodeURIComponent(shortUrl), "_blank");
37127
37210
 
37128
37211
  case "whatsapp":
37129
- return window.open("https://web.whatsapp.com/send?text=" + shortUrl, "_blank");
37212
+ return window.open('https://' + (isMobileOrTablet() ? 'api' : 'web') + '.whatsapp.com/send?text=' + encodeURIComponent(shortUrl), "_blank");
37130
37213
 
37131
37214
  default:
37132
37215
  return window.open(shortUrl, "_blank");
@@ -37150,7 +37233,7 @@ var ShareFiles = {
37150
37233
  files: [pdfData],
37151
37234
  title: filename
37152
37235
  }) : Promise.resolve(ShareFiles.getShortener(tenantId, pdfData)).then(function (shortUrl) {
37153
- ShareFiles.targetLink(target, shortUrl);
37236
+ return ShareFiles.targetLink(target, shortUrl);
37154
37237
  });
37155
37238
  });
37156
37239
  } catch (e) {
@@ -37166,7 +37249,7 @@ var ShareFiles = {
37166
37249
  files: [imageData],
37167
37250
  title: filename
37168
37251
  }) : Promise.resolve(ShareFiles.getShortener(tenantId, imageData)).then(function (shortUrl) {
37169
- ShareFiles.targetLink(target, shortUrl);
37252
+ return ShareFiles.targetLink(target, shortUrl);
37170
37253
  });
37171
37254
  });
37172
37255
  } catch (e) {
@@ -37182,7 +37265,7 @@ var ShareFiles = {
37182
37265
  files: [imageData],
37183
37266
  title: filename
37184
37267
  }) : Promise.resolve(ShareFiles.getShortener(tenantId, imageData)).then(function (shortUrl) {
37185
- ShareFiles.targetLink(target, shortUrl);
37268
+ return ShareFiles.targetLink(target, shortUrl);
37186
37269
  });
37187
37270
  });
37188
37271
  } catch (e) {
@@ -37198,7 +37281,7 @@ var ShareFiles = {
37198
37281
  files: [imageData],
37199
37282
  title: filename
37200
37283
  }) : Promise.resolve(ShareFiles.getShortener(tenantId, imageData)).then(function (shortUrl) {
37201
- ShareFiles.targetLink(target, shortUrl);
37284
+ return ShareFiles.targetLink(target, shortUrl);
37202
37285
  });
37203
37286
  });
37204
37287
  } catch (e) {
@@ -37556,6 +37639,1066 @@ var useQueryParams = function useQueryParams() {
37556
37639
  return params;
37557
37640
  };
37558
37641
 
37642
+ var b$1 = "function" === typeof Symbol && Symbol.for,
37643
+ c = b$1 ? Symbol.for("react.element") : 60103,
37644
+ d = b$1 ? Symbol.for("react.portal") : 60106,
37645
+ e = b$1 ? Symbol.for("react.fragment") : 60107,
37646
+ f = b$1 ? Symbol.for("react.strict_mode") : 60108,
37647
+ g = b$1 ? Symbol.for("react.profiler") : 60114,
37648
+ h = b$1 ? Symbol.for("react.provider") : 60109,
37649
+ k$1 = b$1 ? Symbol.for("react.context") : 60110,
37650
+ l = b$1 ? Symbol.for("react.async_mode") : 60111,
37651
+ m = b$1 ? Symbol.for("react.concurrent_mode") : 60111,
37652
+ n = b$1 ? Symbol.for("react.forward_ref") : 60112,
37653
+ p = b$1 ? Symbol.for("react.suspense") : 60113,
37654
+ q = b$1 ? Symbol.for("react.suspense_list") : 60120,
37655
+ r = b$1 ? Symbol.for("react.memo") : 60115,
37656
+ t = b$1 ? Symbol.for("react.lazy") : 60116,
37657
+ v = b$1 ? Symbol.for("react.block") : 60121,
37658
+ w = b$1 ? Symbol.for("react.fundamental") : 60117,
37659
+ x = b$1 ? Symbol.for("react.responder") : 60118,
37660
+ y$1 = b$1 ? Symbol.for("react.scope") : 60119;
37661
+
37662
+ function z(a) {
37663
+ if ("object" === typeof a && null !== a) {
37664
+ var u = a.$$typeof;
37665
+
37666
+ switch (u) {
37667
+ case c:
37668
+ switch (a = a.type, a) {
37669
+ case l:
37670
+ case m:
37671
+ case e:
37672
+ case g:
37673
+ case f:
37674
+ case p:
37675
+ return a;
37676
+
37677
+ default:
37678
+ switch (a = a && a.$$typeof, a) {
37679
+ case k$1:
37680
+ case n:
37681
+ case t:
37682
+ case r:
37683
+ case h:
37684
+ return a;
37685
+
37686
+ default:
37687
+ return u;
37688
+ }
37689
+
37690
+ }
37691
+
37692
+ case d:
37693
+ return u;
37694
+ }
37695
+ }
37696
+ }
37697
+
37698
+ function A(a) {
37699
+ return z(a) === m;
37700
+ }
37701
+
37702
+ var AsyncMode = l;
37703
+ var ConcurrentMode = m;
37704
+ var ContextConsumer = k$1;
37705
+ var ContextProvider = h;
37706
+ var Element = c;
37707
+ var ForwardRef = n;
37708
+ var Fragment = e;
37709
+ var Lazy = t;
37710
+ var Memo = r;
37711
+ var Portal = d;
37712
+ var Profiler = g;
37713
+ var StrictMode = f;
37714
+ var Suspense = p;
37715
+
37716
+ var isAsyncMode = function isAsyncMode(a) {
37717
+ return A(a) || z(a) === l;
37718
+ };
37719
+
37720
+ var isConcurrentMode = A;
37721
+
37722
+ var isContextConsumer = function isContextConsumer(a) {
37723
+ return z(a) === k$1;
37724
+ };
37725
+
37726
+ var isContextProvider = function isContextProvider(a) {
37727
+ return z(a) === h;
37728
+ };
37729
+
37730
+ var isElement = function isElement(a) {
37731
+ return "object" === typeof a && null !== a && a.$$typeof === c;
37732
+ };
37733
+
37734
+ var isForwardRef = function isForwardRef(a) {
37735
+ return z(a) === n;
37736
+ };
37737
+
37738
+ var isFragment = function isFragment(a) {
37739
+ return z(a) === e;
37740
+ };
37741
+
37742
+ var isLazy = function isLazy(a) {
37743
+ return z(a) === t;
37744
+ };
37745
+
37746
+ var isMemo = function isMemo(a) {
37747
+ return z(a) === r;
37748
+ };
37749
+
37750
+ var isPortal = function isPortal(a) {
37751
+ return z(a) === d;
37752
+ };
37753
+
37754
+ var isProfiler = function isProfiler(a) {
37755
+ return z(a) === g;
37756
+ };
37757
+
37758
+ var isStrictMode = function isStrictMode(a) {
37759
+ return z(a) === f;
37760
+ };
37761
+
37762
+ var isSuspense = function isSuspense(a) {
37763
+ return z(a) === p;
37764
+ };
37765
+
37766
+ var isValidElementType = function isValidElementType(a) {
37767
+ return "string" === typeof a || "function" === typeof a || a === e || a === m || a === g || a === f || a === p || a === q || "object" === typeof a && null !== a && (a.$$typeof === t || a.$$typeof === r || a.$$typeof === h || a.$$typeof === k$1 || a.$$typeof === n || a.$$typeof === w || a.$$typeof === x || a.$$typeof === y$1 || a.$$typeof === v);
37768
+ };
37769
+
37770
+ var typeOf = z;
37771
+ var reactIs_production_min = {
37772
+ AsyncMode: AsyncMode,
37773
+ ConcurrentMode: ConcurrentMode,
37774
+ ContextConsumer: ContextConsumer,
37775
+ ContextProvider: ContextProvider,
37776
+ Element: Element,
37777
+ ForwardRef: ForwardRef,
37778
+ Fragment: Fragment,
37779
+ Lazy: Lazy,
37780
+ Memo: Memo,
37781
+ Portal: Portal,
37782
+ Profiler: Profiler,
37783
+ StrictMode: StrictMode,
37784
+ Suspense: Suspense,
37785
+ isAsyncMode: isAsyncMode,
37786
+ isConcurrentMode: isConcurrentMode,
37787
+ isContextConsumer: isContextConsumer,
37788
+ isContextProvider: isContextProvider,
37789
+ isElement: isElement,
37790
+ isForwardRef: isForwardRef,
37791
+ isFragment: isFragment,
37792
+ isLazy: isLazy,
37793
+ isMemo: isMemo,
37794
+ isPortal: isPortal,
37795
+ isProfiler: isProfiler,
37796
+ isStrictMode: isStrictMode,
37797
+ isSuspense: isSuspense,
37798
+ isValidElementType: isValidElementType,
37799
+ typeOf: typeOf
37800
+ };
37801
+
37802
+ var reactIs_development = createCommonjsModule(function (module, exports) {
37803
+
37804
+ if (process.env.NODE_ENV !== "production") {
37805
+ (function () {
37806
+
37807
+ var hasSymbol = typeof Symbol === 'function' && Symbol.for;
37808
+ var REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;
37809
+ var REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;
37810
+ var REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;
37811
+ var REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;
37812
+ var REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;
37813
+ var REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;
37814
+ var REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace;
37815
+ var REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;
37816
+ var REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;
37817
+ var REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;
37818
+ var REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;
37819
+ var REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;
37820
+ var REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;
37821
+ var REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;
37822
+ var REACT_BLOCK_TYPE = hasSymbol ? Symbol.for('react.block') : 0xead9;
37823
+ var REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;
37824
+ var REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;
37825
+ var REACT_SCOPE_TYPE = hasSymbol ? Symbol.for('react.scope') : 0xead7;
37826
+
37827
+ function isValidElementType(type) {
37828
+ return typeof type === 'string' || typeof type === 'function' || type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);
37829
+ }
37830
+
37831
+ function typeOf(object) {
37832
+ if (typeof object === 'object' && object !== null) {
37833
+ var $$typeof = object.$$typeof;
37834
+
37835
+ switch ($$typeof) {
37836
+ case REACT_ELEMENT_TYPE:
37837
+ var type = object.type;
37838
+
37839
+ switch (type) {
37840
+ case REACT_ASYNC_MODE_TYPE:
37841
+ case REACT_CONCURRENT_MODE_TYPE:
37842
+ case REACT_FRAGMENT_TYPE:
37843
+ case REACT_PROFILER_TYPE:
37844
+ case REACT_STRICT_MODE_TYPE:
37845
+ case REACT_SUSPENSE_TYPE:
37846
+ return type;
37847
+
37848
+ default:
37849
+ var $$typeofType = type && type.$$typeof;
37850
+
37851
+ switch ($$typeofType) {
37852
+ case REACT_CONTEXT_TYPE:
37853
+ case REACT_FORWARD_REF_TYPE:
37854
+ case REACT_LAZY_TYPE:
37855
+ case REACT_MEMO_TYPE:
37856
+ case REACT_PROVIDER_TYPE:
37857
+ return $$typeofType;
37858
+
37859
+ default:
37860
+ return $$typeof;
37861
+ }
37862
+
37863
+ }
37864
+
37865
+ case REACT_PORTAL_TYPE:
37866
+ return $$typeof;
37867
+ }
37868
+ }
37869
+
37870
+ return undefined;
37871
+ }
37872
+
37873
+ var AsyncMode = REACT_ASYNC_MODE_TYPE;
37874
+ var ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;
37875
+ var ContextConsumer = REACT_CONTEXT_TYPE;
37876
+ var ContextProvider = REACT_PROVIDER_TYPE;
37877
+ var Element = REACT_ELEMENT_TYPE;
37878
+ var ForwardRef = REACT_FORWARD_REF_TYPE;
37879
+ var Fragment = REACT_FRAGMENT_TYPE;
37880
+ var Lazy = REACT_LAZY_TYPE;
37881
+ var Memo = REACT_MEMO_TYPE;
37882
+ var Portal = REACT_PORTAL_TYPE;
37883
+ var Profiler = REACT_PROFILER_TYPE;
37884
+ var StrictMode = REACT_STRICT_MODE_TYPE;
37885
+ var Suspense = REACT_SUSPENSE_TYPE;
37886
+ var hasWarnedAboutDeprecatedIsAsyncMode = false;
37887
+
37888
+ function isAsyncMode(object) {
37889
+ {
37890
+ if (!hasWarnedAboutDeprecatedIsAsyncMode) {
37891
+ hasWarnedAboutDeprecatedIsAsyncMode = true;
37892
+ console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');
37893
+ }
37894
+ }
37895
+ return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;
37896
+ }
37897
+
37898
+ function isConcurrentMode(object) {
37899
+ return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;
37900
+ }
37901
+
37902
+ function isContextConsumer(object) {
37903
+ return typeOf(object) === REACT_CONTEXT_TYPE;
37904
+ }
37905
+
37906
+ function isContextProvider(object) {
37907
+ return typeOf(object) === REACT_PROVIDER_TYPE;
37908
+ }
37909
+
37910
+ function isElement(object) {
37911
+ return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;
37912
+ }
37913
+
37914
+ function isForwardRef(object) {
37915
+ return typeOf(object) === REACT_FORWARD_REF_TYPE;
37916
+ }
37917
+
37918
+ function isFragment(object) {
37919
+ return typeOf(object) === REACT_FRAGMENT_TYPE;
37920
+ }
37921
+
37922
+ function isLazy(object) {
37923
+ return typeOf(object) === REACT_LAZY_TYPE;
37924
+ }
37925
+
37926
+ function isMemo(object) {
37927
+ return typeOf(object) === REACT_MEMO_TYPE;
37928
+ }
37929
+
37930
+ function isPortal(object) {
37931
+ return typeOf(object) === REACT_PORTAL_TYPE;
37932
+ }
37933
+
37934
+ function isProfiler(object) {
37935
+ return typeOf(object) === REACT_PROFILER_TYPE;
37936
+ }
37937
+
37938
+ function isStrictMode(object) {
37939
+ return typeOf(object) === REACT_STRICT_MODE_TYPE;
37940
+ }
37941
+
37942
+ function isSuspense(object) {
37943
+ return typeOf(object) === REACT_SUSPENSE_TYPE;
37944
+ }
37945
+
37946
+ exports.AsyncMode = AsyncMode;
37947
+ exports.ConcurrentMode = ConcurrentMode;
37948
+ exports.ContextConsumer = ContextConsumer;
37949
+ exports.ContextProvider = ContextProvider;
37950
+ exports.Element = Element;
37951
+ exports.ForwardRef = ForwardRef;
37952
+ exports.Fragment = Fragment;
37953
+ exports.Lazy = Lazy;
37954
+ exports.Memo = Memo;
37955
+ exports.Portal = Portal;
37956
+ exports.Profiler = Profiler;
37957
+ exports.StrictMode = StrictMode;
37958
+ exports.Suspense = Suspense;
37959
+ exports.isAsyncMode = isAsyncMode;
37960
+ exports.isConcurrentMode = isConcurrentMode;
37961
+ exports.isContextConsumer = isContextConsumer;
37962
+ exports.isContextProvider = isContextProvider;
37963
+ exports.isElement = isElement;
37964
+ exports.isForwardRef = isForwardRef;
37965
+ exports.isFragment = isFragment;
37966
+ exports.isLazy = isLazy;
37967
+ exports.isMemo = isMemo;
37968
+ exports.isPortal = isPortal;
37969
+ exports.isProfiler = isProfiler;
37970
+ exports.isStrictMode = isStrictMode;
37971
+ exports.isSuspense = isSuspense;
37972
+ exports.isValidElementType = isValidElementType;
37973
+ exports.typeOf = typeOf;
37974
+ })();
37975
+ }
37976
+ });
37977
+
37978
+ var reactIs = createCommonjsModule(function (module) {
37979
+
37980
+ if (process.env.NODE_ENV === 'production') {
37981
+ module.exports = reactIs_production_min;
37982
+ } else {
37983
+ module.exports = reactIs_development;
37984
+ }
37985
+ });
37986
+
37987
+ var ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';
37988
+ var ReactPropTypesSecret_1 = ReactPropTypesSecret;
37989
+
37990
+ var has = Function.call.bind(Object.prototype.hasOwnProperty);
37991
+
37992
+ var printWarning = function printWarning() {};
37993
+
37994
+ if (process.env.NODE_ENV !== 'production') {
37995
+ var ReactPropTypesSecret$1 = ReactPropTypesSecret_1;
37996
+ var loggedTypeFailures = {};
37997
+ var has$1 = has;
37998
+
37999
+ printWarning = function printWarning(text) {
38000
+ var message = 'Warning: ' + text;
38001
+
38002
+ if (typeof console !== 'undefined') {
38003
+ console.error(message);
38004
+ }
38005
+
38006
+ try {
38007
+ throw new Error(message);
38008
+ } catch (x) {}
38009
+ };
38010
+ }
38011
+
38012
+ function checkPropTypes(typeSpecs, values, location, componentName, getStack) {
38013
+ if (process.env.NODE_ENV !== 'production') {
38014
+ for (var typeSpecName in typeSpecs) {
38015
+ if (has$1(typeSpecs, typeSpecName)) {
38016
+ var error;
38017
+
38018
+ try {
38019
+ if (typeof typeSpecs[typeSpecName] !== 'function') {
38020
+ var err = Error((componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' + 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' + 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.');
38021
+ err.name = 'Invariant Violation';
38022
+ throw err;
38023
+ }
38024
+
38025
+ error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret$1);
38026
+ } catch (ex) {
38027
+ error = ex;
38028
+ }
38029
+
38030
+ if (error && !(error instanceof Error)) {
38031
+ printWarning((componentName || 'React class') + ': type specification of ' + location + ' `' + typeSpecName + '` is invalid; the type checker ' + 'function must return `null` or an `Error` but returned a ' + typeof error + '. ' + 'You may have forgotten to pass an argument to the type checker ' + 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' + 'shape all require an argument).');
38032
+ }
38033
+
38034
+ if (error instanceof Error && !(error.message in loggedTypeFailures)) {
38035
+ loggedTypeFailures[error.message] = true;
38036
+ var stack = getStack ? getStack() : '';
38037
+ printWarning('Failed ' + location + ' type: ' + error.message + (stack != null ? stack : ''));
38038
+ }
38039
+ }
38040
+ }
38041
+ }
38042
+ }
38043
+
38044
+ checkPropTypes.resetWarningCache = function () {
38045
+ if (process.env.NODE_ENV !== 'production') {
38046
+ loggedTypeFailures = {};
38047
+ }
38048
+ };
38049
+
38050
+ var checkPropTypes_1 = checkPropTypes;
38051
+
38052
+ var printWarning$1 = function printWarning() {};
38053
+
38054
+ if (process.env.NODE_ENV !== 'production') {
38055
+ printWarning$1 = function printWarning(text) {
38056
+ var message = 'Warning: ' + text;
38057
+
38058
+ if (typeof console !== 'undefined') {
38059
+ console.error(message);
38060
+ }
38061
+
38062
+ try {
38063
+ throw new Error(message);
38064
+ } catch (x) {}
38065
+ };
38066
+ }
38067
+
38068
+ function emptyFunctionThatReturnsNull() {
38069
+ return null;
38070
+ }
38071
+
38072
+ var factoryWithTypeCheckers = function factoryWithTypeCheckers(isValidElement, throwOnDirectAccess) {
38073
+ var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;
38074
+ var FAUX_ITERATOR_SYMBOL = '@@iterator';
38075
+
38076
+ function getIteratorFn(maybeIterable) {
38077
+ var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);
38078
+
38079
+ if (typeof iteratorFn === 'function') {
38080
+ return iteratorFn;
38081
+ }
38082
+ }
38083
+
38084
+ var ANONYMOUS = '<<anonymous>>';
38085
+ var ReactPropTypes = {
38086
+ array: createPrimitiveTypeChecker('array'),
38087
+ bigint: createPrimitiveTypeChecker('bigint'),
38088
+ bool: createPrimitiveTypeChecker('boolean'),
38089
+ func: createPrimitiveTypeChecker('function'),
38090
+ number: createPrimitiveTypeChecker('number'),
38091
+ object: createPrimitiveTypeChecker('object'),
38092
+ string: createPrimitiveTypeChecker('string'),
38093
+ symbol: createPrimitiveTypeChecker('symbol'),
38094
+ any: createAnyTypeChecker(),
38095
+ arrayOf: createArrayOfTypeChecker,
38096
+ element: createElementTypeChecker(),
38097
+ elementType: createElementTypeTypeChecker(),
38098
+ instanceOf: createInstanceTypeChecker,
38099
+ node: createNodeChecker(),
38100
+ objectOf: createObjectOfTypeChecker,
38101
+ oneOf: createEnumTypeChecker,
38102
+ oneOfType: createUnionTypeChecker,
38103
+ shape: createShapeTypeChecker,
38104
+ exact: createStrictShapeTypeChecker
38105
+ };
38106
+
38107
+ function is(x, y) {
38108
+ if (x === y) {
38109
+ return x !== 0 || 1 / x === 1 / y;
38110
+ } else {
38111
+ return x !== x && y !== y;
38112
+ }
38113
+ }
38114
+
38115
+ function PropTypeError(message, data) {
38116
+ this.message = message;
38117
+ this.data = data && typeof data === 'object' ? data : {};
38118
+ this.stack = '';
38119
+ }
38120
+
38121
+ PropTypeError.prototype = Error.prototype;
38122
+
38123
+ function createChainableTypeChecker(validate) {
38124
+ if (process.env.NODE_ENV !== 'production') {
38125
+ var manualPropTypeCallCache = {};
38126
+ var manualPropTypeWarningCount = 0;
38127
+ }
38128
+
38129
+ function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {
38130
+ componentName = componentName || ANONYMOUS;
38131
+ propFullName = propFullName || propName;
38132
+
38133
+ if (secret !== ReactPropTypesSecret_1) {
38134
+ if (throwOnDirectAccess) {
38135
+ var err = new Error('Calling PropTypes validators directly is not supported by the `prop-types` package. ' + 'Use `PropTypes.checkPropTypes()` to call them. ' + 'Read more at http://fb.me/use-check-prop-types');
38136
+ err.name = 'Invariant Violation';
38137
+ throw err;
38138
+ } else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {
38139
+ var cacheKey = componentName + ':' + propName;
38140
+
38141
+ if (!manualPropTypeCallCache[cacheKey] && manualPropTypeWarningCount < 3) {
38142
+ printWarning$1('You are manually calling a React.PropTypes validation ' + 'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' + 'and will throw in the standalone `prop-types` package. ' + 'You may be seeing this warning due to a third-party PropTypes ' + 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.');
38143
+ manualPropTypeCallCache[cacheKey] = true;
38144
+ manualPropTypeWarningCount++;
38145
+ }
38146
+ }
38147
+ }
38148
+
38149
+ if (props[propName] == null) {
38150
+ if (isRequired) {
38151
+ if (props[propName] === null) {
38152
+ return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));
38153
+ }
38154
+
38155
+ return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));
38156
+ }
38157
+
38158
+ return null;
38159
+ } else {
38160
+ return validate(props, propName, componentName, location, propFullName);
38161
+ }
38162
+ }
38163
+
38164
+ var chainedCheckType = checkType.bind(null, false);
38165
+ chainedCheckType.isRequired = checkType.bind(null, true);
38166
+ return chainedCheckType;
38167
+ }
38168
+
38169
+ function createPrimitiveTypeChecker(expectedType) {
38170
+ function validate(props, propName, componentName, location, propFullName, secret) {
38171
+ var propValue = props[propName];
38172
+ var propType = getPropType(propValue);
38173
+
38174
+ if (propType !== expectedType) {
38175
+ var preciseType = getPreciseType(propValue);
38176
+ return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'), {
38177
+ expectedType: expectedType
38178
+ });
38179
+ }
38180
+
38181
+ return null;
38182
+ }
38183
+
38184
+ return createChainableTypeChecker(validate);
38185
+ }
38186
+
38187
+ function createAnyTypeChecker() {
38188
+ return createChainableTypeChecker(emptyFunctionThatReturnsNull);
38189
+ }
38190
+
38191
+ function createArrayOfTypeChecker(typeChecker) {
38192
+ function validate(props, propName, componentName, location, propFullName) {
38193
+ if (typeof typeChecker !== 'function') {
38194
+ return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');
38195
+ }
38196
+
38197
+ var propValue = props[propName];
38198
+
38199
+ if (!Array.isArray(propValue)) {
38200
+ var propType = getPropType(propValue);
38201
+ return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));
38202
+ }
38203
+
38204
+ for (var i = 0; i < propValue.length; i++) {
38205
+ var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret_1);
38206
+
38207
+ if (error instanceof Error) {
38208
+ return error;
38209
+ }
38210
+ }
38211
+
38212
+ return null;
38213
+ }
38214
+
38215
+ return createChainableTypeChecker(validate);
38216
+ }
38217
+
38218
+ function createElementTypeChecker() {
38219
+ function validate(props, propName, componentName, location, propFullName) {
38220
+ var propValue = props[propName];
38221
+
38222
+ if (!isValidElement(propValue)) {
38223
+ var propType = getPropType(propValue);
38224
+ return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));
38225
+ }
38226
+
38227
+ return null;
38228
+ }
38229
+
38230
+ return createChainableTypeChecker(validate);
38231
+ }
38232
+
38233
+ function createElementTypeTypeChecker() {
38234
+ function validate(props, propName, componentName, location, propFullName) {
38235
+ var propValue = props[propName];
38236
+
38237
+ if (!reactIs.isValidElementType(propValue)) {
38238
+ var propType = getPropType(propValue);
38239
+ return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));
38240
+ }
38241
+
38242
+ return null;
38243
+ }
38244
+
38245
+ return createChainableTypeChecker(validate);
38246
+ }
38247
+
38248
+ function createInstanceTypeChecker(expectedClass) {
38249
+ function validate(props, propName, componentName, location, propFullName) {
38250
+ if (!(props[propName] instanceof expectedClass)) {
38251
+ var expectedClassName = expectedClass.name || ANONYMOUS;
38252
+ var actualClassName = getClassName(props[propName]);
38253
+ return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));
38254
+ }
38255
+
38256
+ return null;
38257
+ }
38258
+
38259
+ return createChainableTypeChecker(validate);
38260
+ }
38261
+
38262
+ function createEnumTypeChecker(expectedValues) {
38263
+ if (!Array.isArray(expectedValues)) {
38264
+ if (process.env.NODE_ENV !== 'production') {
38265
+ if (arguments.length > 1) {
38266
+ printWarning$1('Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' + 'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).');
38267
+ } else {
38268
+ printWarning$1('Invalid argument supplied to oneOf, expected an array.');
38269
+ }
38270
+ }
38271
+
38272
+ return emptyFunctionThatReturnsNull;
38273
+ }
38274
+
38275
+ function validate(props, propName, componentName, location, propFullName) {
38276
+ var propValue = props[propName];
38277
+
38278
+ for (var i = 0; i < expectedValues.length; i++) {
38279
+ if (is(propValue, expectedValues[i])) {
38280
+ return null;
38281
+ }
38282
+ }
38283
+
38284
+ var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {
38285
+ var type = getPreciseType(value);
38286
+
38287
+ if (type === 'symbol') {
38288
+ return String(value);
38289
+ }
38290
+
38291
+ return value;
38292
+ });
38293
+ return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));
38294
+ }
38295
+
38296
+ return createChainableTypeChecker(validate);
38297
+ }
38298
+
38299
+ function createObjectOfTypeChecker(typeChecker) {
38300
+ function validate(props, propName, componentName, location, propFullName) {
38301
+ if (typeof typeChecker !== 'function') {
38302
+ return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');
38303
+ }
38304
+
38305
+ var propValue = props[propName];
38306
+ var propType = getPropType(propValue);
38307
+
38308
+ if (propType !== 'object') {
38309
+ return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));
38310
+ }
38311
+
38312
+ for (var key in propValue) {
38313
+ if (has(propValue, key)) {
38314
+ var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret_1);
38315
+
38316
+ if (error instanceof Error) {
38317
+ return error;
38318
+ }
38319
+ }
38320
+ }
38321
+
38322
+ return null;
38323
+ }
38324
+
38325
+ return createChainableTypeChecker(validate);
38326
+ }
38327
+
38328
+ function createUnionTypeChecker(arrayOfTypeCheckers) {
38329
+ if (!Array.isArray(arrayOfTypeCheckers)) {
38330
+ process.env.NODE_ENV !== 'production' ? printWarning$1('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;
38331
+ return emptyFunctionThatReturnsNull;
38332
+ }
38333
+
38334
+ for (var i = 0; i < arrayOfTypeCheckers.length; i++) {
38335
+ var checker = arrayOfTypeCheckers[i];
38336
+
38337
+ if (typeof checker !== 'function') {
38338
+ printWarning$1('Invalid argument supplied to oneOfType. Expected an array of check functions, but ' + 'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.');
38339
+ return emptyFunctionThatReturnsNull;
38340
+ }
38341
+ }
38342
+
38343
+ function validate(props, propName, componentName, location, propFullName) {
38344
+ var expectedTypes = [];
38345
+
38346
+ for (var i = 0; i < arrayOfTypeCheckers.length; i++) {
38347
+ var checker = arrayOfTypeCheckers[i];
38348
+ var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret_1);
38349
+
38350
+ if (checkerResult == null) {
38351
+ return null;
38352
+ }
38353
+
38354
+ if (checkerResult.data && has(checkerResult.data, 'expectedType')) {
38355
+ expectedTypes.push(checkerResult.data.expectedType);
38356
+ }
38357
+ }
38358
+
38359
+ var expectedTypesMessage = expectedTypes.length > 0 ? ', expected one of type [' + expectedTypes.join(', ') + ']' : '';
38360
+ return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`' + expectedTypesMessage + '.'));
38361
+ }
38362
+
38363
+ return createChainableTypeChecker(validate);
38364
+ }
38365
+
38366
+ function createNodeChecker() {
38367
+ function validate(props, propName, componentName, location, propFullName) {
38368
+ if (!isNode(props[propName])) {
38369
+ return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));
38370
+ }
38371
+
38372
+ return null;
38373
+ }
38374
+
38375
+ return createChainableTypeChecker(validate);
38376
+ }
38377
+
38378
+ function invalidValidatorError(componentName, location, propFullName, key, type) {
38379
+ return new PropTypeError((componentName || 'React class') + ': ' + location + ' type `' + propFullName + '.' + key + '` is invalid; ' + 'it must be a function, usually from the `prop-types` package, but received `' + type + '`.');
38380
+ }
38381
+
38382
+ function createShapeTypeChecker(shapeTypes) {
38383
+ function validate(props, propName, componentName, location, propFullName) {
38384
+ var propValue = props[propName];
38385
+ var propType = getPropType(propValue);
38386
+
38387
+ if (propType !== 'object') {
38388
+ return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));
38389
+ }
38390
+
38391
+ for (var key in shapeTypes) {
38392
+ var checker = shapeTypes[key];
38393
+
38394
+ if (typeof checker !== 'function') {
38395
+ return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));
38396
+ }
38397
+
38398
+ var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret_1);
38399
+
38400
+ if (error) {
38401
+ return error;
38402
+ }
38403
+ }
38404
+
38405
+ return null;
38406
+ }
38407
+
38408
+ return createChainableTypeChecker(validate);
38409
+ }
38410
+
38411
+ function createStrictShapeTypeChecker(shapeTypes) {
38412
+ function validate(props, propName, componentName, location, propFullName) {
38413
+ var propValue = props[propName];
38414
+ var propType = getPropType(propValue);
38415
+
38416
+ if (propType !== 'object') {
38417
+ return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));
38418
+ }
38419
+
38420
+ var allKeys = objectAssign({}, props[propName], shapeTypes);
38421
+
38422
+ for (var key in allKeys) {
38423
+ var checker = shapeTypes[key];
38424
+
38425
+ if (has(shapeTypes, key) && typeof checker !== 'function') {
38426
+ return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));
38427
+ }
38428
+
38429
+ if (!checker) {
38430
+ return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' + '\nBad object: ' + JSON.stringify(props[propName], null, ' ') + '\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' '));
38431
+ }
38432
+
38433
+ var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret_1);
38434
+
38435
+ if (error) {
38436
+ return error;
38437
+ }
38438
+ }
38439
+
38440
+ return null;
38441
+ }
38442
+
38443
+ return createChainableTypeChecker(validate);
38444
+ }
38445
+
38446
+ function isNode(propValue) {
38447
+ switch (typeof propValue) {
38448
+ case 'number':
38449
+ case 'string':
38450
+ case 'undefined':
38451
+ return true;
38452
+
38453
+ case 'boolean':
38454
+ return !propValue;
38455
+
38456
+ case 'object':
38457
+ if (Array.isArray(propValue)) {
38458
+ return propValue.every(isNode);
38459
+ }
38460
+
38461
+ if (propValue === null || isValidElement(propValue)) {
38462
+ return true;
38463
+ }
38464
+
38465
+ var iteratorFn = getIteratorFn(propValue);
38466
+
38467
+ if (iteratorFn) {
38468
+ var iterator = iteratorFn.call(propValue);
38469
+ var step;
38470
+
38471
+ if (iteratorFn !== propValue.entries) {
38472
+ while (!(step = iterator.next()).done) {
38473
+ if (!isNode(step.value)) {
38474
+ return false;
38475
+ }
38476
+ }
38477
+ } else {
38478
+ while (!(step = iterator.next()).done) {
38479
+ var entry = step.value;
38480
+
38481
+ if (entry) {
38482
+ if (!isNode(entry[1])) {
38483
+ return false;
38484
+ }
38485
+ }
38486
+ }
38487
+ }
38488
+ } else {
38489
+ return false;
38490
+ }
38491
+
38492
+ return true;
38493
+
38494
+ default:
38495
+ return false;
38496
+ }
38497
+ }
38498
+
38499
+ function isSymbol(propType, propValue) {
38500
+ if (propType === 'symbol') {
38501
+ return true;
38502
+ }
38503
+
38504
+ if (!propValue) {
38505
+ return false;
38506
+ }
38507
+
38508
+ if (propValue['@@toStringTag'] === 'Symbol') {
38509
+ return true;
38510
+ }
38511
+
38512
+ if (typeof Symbol === 'function' && propValue instanceof Symbol) {
38513
+ return true;
38514
+ }
38515
+
38516
+ return false;
38517
+ }
38518
+
38519
+ function getPropType(propValue) {
38520
+ var propType = typeof propValue;
38521
+
38522
+ if (Array.isArray(propValue)) {
38523
+ return 'array';
38524
+ }
38525
+
38526
+ if (propValue instanceof RegExp) {
38527
+ return 'object';
38528
+ }
38529
+
38530
+ if (isSymbol(propType, propValue)) {
38531
+ return 'symbol';
38532
+ }
38533
+
38534
+ return propType;
38535
+ }
38536
+
38537
+ function getPreciseType(propValue) {
38538
+ if (typeof propValue === 'undefined' || propValue === null) {
38539
+ return '' + propValue;
38540
+ }
38541
+
38542
+ var propType = getPropType(propValue);
38543
+
38544
+ if (propType === 'object') {
38545
+ if (propValue instanceof Date) {
38546
+ return 'date';
38547
+ } else if (propValue instanceof RegExp) {
38548
+ return 'regexp';
38549
+ }
38550
+ }
38551
+
38552
+ return propType;
38553
+ }
38554
+
38555
+ function getPostfixForTypeWarning(value) {
38556
+ var type = getPreciseType(value);
38557
+
38558
+ switch (type) {
38559
+ case 'array':
38560
+ case 'object':
38561
+ return 'an ' + type;
38562
+
38563
+ case 'boolean':
38564
+ case 'date':
38565
+ case 'regexp':
38566
+ return 'a ' + type;
38567
+
38568
+ default:
38569
+ return type;
38570
+ }
38571
+ }
38572
+
38573
+ function getClassName(propValue) {
38574
+ if (!propValue.constructor || !propValue.constructor.name) {
38575
+ return ANONYMOUS;
38576
+ }
38577
+
38578
+ return propValue.constructor.name;
38579
+ }
38580
+
38581
+ ReactPropTypes.checkPropTypes = checkPropTypes_1;
38582
+ ReactPropTypes.resetWarningCache = checkPropTypes_1.resetWarningCache;
38583
+ ReactPropTypes.PropTypes = ReactPropTypes;
38584
+ return ReactPropTypes;
38585
+ };
38586
+
38587
+ function emptyFunction() {}
38588
+
38589
+ function emptyFunctionWithReset() {}
38590
+
38591
+ emptyFunctionWithReset.resetWarningCache = emptyFunction;
38592
+
38593
+ var factoryWithThrowingShims = function factoryWithThrowingShims() {
38594
+ function shim(props, propName, componentName, location, propFullName, secret) {
38595
+ if (secret === ReactPropTypesSecret_1) {
38596
+ return;
38597
+ }
38598
+
38599
+ var err = new Error('Calling PropTypes validators directly is not supported by the `prop-types` package. ' + 'Use PropTypes.checkPropTypes() to call them. ' + 'Read more at http://fb.me/use-check-prop-types');
38600
+ err.name = 'Invariant Violation';
38601
+ throw err;
38602
+ }
38603
+ shim.isRequired = shim;
38604
+
38605
+ function getShim() {
38606
+ return shim;
38607
+ }
38608
+ var ReactPropTypes = {
38609
+ array: shim,
38610
+ bigint: shim,
38611
+ bool: shim,
38612
+ func: shim,
38613
+ number: shim,
38614
+ object: shim,
38615
+ string: shim,
38616
+ symbol: shim,
38617
+ any: shim,
38618
+ arrayOf: getShim,
38619
+ element: shim,
38620
+ elementType: shim,
38621
+ instanceOf: getShim,
38622
+ node: shim,
38623
+ objectOf: getShim,
38624
+ oneOf: getShim,
38625
+ oneOfType: getShim,
38626
+ shape: getShim,
38627
+ exact: getShim,
38628
+ checkPropTypes: emptyFunctionWithReset,
38629
+ resetWarningCache: emptyFunction
38630
+ };
38631
+ ReactPropTypes.PropTypes = ReactPropTypes;
38632
+ return ReactPropTypes;
38633
+ };
38634
+
38635
+ var propTypes = createCommonjsModule(function (module) {
38636
+ if (process.env.NODE_ENV !== 'production') {
38637
+ var ReactIs = reactIs;
38638
+ var throwOnDirectAccess = true;
38639
+ module.exports = factoryWithTypeCheckers(ReactIs.isElement, throwOnDirectAccess);
38640
+ } else {
38641
+ module.exports = factoryWithThrowingShims();
38642
+ }
38643
+ });
38644
+
38645
+ var useDocumentSearch = function useDocumentSearch(documents, config) {
38646
+ var _documents;
38647
+
38648
+ if (documents === void 0) {
38649
+ documents = [];
38650
+ }
38651
+
38652
+ if (config === void 0) {
38653
+ config = {};
38654
+ }
38655
+
38656
+ var client = useQueryClient();
38657
+ var tenant = Digit.ULBService.getStateId();
38658
+ var filesArray = (_documents = documents) === null || _documents === void 0 ? void 0 : _documents.map(function (value) {
38659
+ return value === null || value === void 0 ? void 0 : value.fileStoreId;
38660
+ });
38661
+
38662
+ var _useQuery = useQuery([filesArray.join('')], function () {
38663
+ return Digit.UploadServices.Filefetch(filesArray, tenant);
38664
+ }, _extends({
38665
+ enabled: filesArray && filesArray.length > 0,
38666
+ select: function select(data) {
38667
+ return documents.map(function (document) {
38668
+ var _data$data, _data$data2, _data$data3;
38669
+
38670
+ return _extends({}, document, {
38671
+ fileURL: (data === null || data === void 0 ? void 0 : (_data$data = data.data) === null || _data$data === void 0 ? void 0 : _data$data[document === null || document === void 0 ? void 0 : document.fileStoreId]) && Digit.Utils.getFileUrl(data.data[document === null || document === void 0 ? void 0 : document.fileStoreId]),
38672
+ url: (data === null || data === void 0 ? void 0 : (_data$data2 = data.data) === null || _data$data2 === void 0 ? void 0 : _data$data2[document === null || document === void 0 ? void 0 : document.fileStoreId]) && Digit.Utils.getFileUrl(data.data[document === null || document === void 0 ? void 0 : document.fileStoreId]),
38673
+ fileResponse: (data === null || data === void 0 ? void 0 : (_data$data3 = data.data) === null || _data$data3 === void 0 ? void 0 : _data$data3[document === null || document === void 0 ? void 0 : document.fileStoreId]) || ""
38674
+ });
38675
+ });
38676
+ }
38677
+ }, config)),
38678
+ isLoading = _useQuery.isLoading,
38679
+ error = _useQuery.error,
38680
+ data = _useQuery.data;
38681
+
38682
+ return {
38683
+ isLoading: isLoading,
38684
+ error: error,
38685
+ data: {
38686
+ pdfFiles: data
38687
+ },
38688
+ revalidate: function revalidate() {
38689
+ return client.invalidateQueries([filesArray.join('')]);
38690
+ }
38691
+ };
38692
+ };
38693
+ useDocumentSearch.propTypes = {
38694
+ documents: propTypes.array,
38695
+ config: propTypes.object
38696
+ };
38697
+ useDocumentSearch.defaultProps = {
38698
+ documents: [],
38699
+ config: {}
38700
+ };
38701
+
37559
38702
  var useOnClickOutside = function useOnClickOutside(ref, handler, isActive, eventParam) {
37560
38703
  if (eventParam === void 0) {
37561
38704
  eventParam = false;
@@ -41332,7 +42475,7 @@ var PTSearch = {
41332
42475
  value: owner === null || owner === void 0 ? void 0 : owner.emailId
41333
42476
  }, {
41334
42477
  title: "PT_OWNERSHIP_INFO_CORR_ADDR",
41335
- value: owner === null || owner === void 0 ? void 0 : owner.correspondenceAddress
42478
+ value: owner === null || owner === void 0 ? void 0 : owner.permanentAddress
41336
42479
  }]
41337
42480
  };
41338
42481
  })
@@ -42249,7 +43392,7 @@ var useTradeLicenseMDMS = function useTradeLicenseMDMS(tenantId, moduleCode, typ
42249
43392
  };
42250
43393
 
42251
43394
  var useTLDocumentSearch = function useTLDocumentSearch(data1, config) {
42252
- var _data, _data$value, _data$value$owners, _data$value$owners$do, _data2, _data2$value, _data2$value$owners, _data2$value$owners$d, _data3, _data3$value, _data3$value$owners, _data3$value$owners$d;
43395
+ var _data, _data$value, _data$value$tradeLice, _data2, _data2$value, _data3, _data3$value, _data3$value$workflow, _data4, _data4$value, _data4$value$owners, _data4$value$owners$d, _data5, _data5$value, _data5$value$owners, _data5$value$owners$d, _data6, _data6$value, _data6$value$owners, _data6$value$owners$d;
42253
43396
 
42254
43397
  if (data1 === void 0) {
42255
43398
  data1 = {};
@@ -42258,10 +43401,15 @@ var useTLDocumentSearch = function useTLDocumentSearch(data1, config) {
42258
43401
  var client = useQueryClient();
42259
43402
  var tenantId = Digit.ULBService.getCurrentTenantId();
42260
43403
  var tenant = Digit.ULBService.getStateId();
42261
- var filesArray = [];
42262
- if ((_data = data1) !== null && _data !== void 0 && (_data$value = _data.value) !== null && _data$value !== void 0 && (_data$value$owners = _data$value.owners) !== null && _data$value$owners !== void 0 && (_data$value$owners$do = _data$value$owners.documents["OwnerPhotoProof"]) !== null && _data$value$owners$do !== void 0 && _data$value$owners$do.fileStoreId) filesArray.push(data1.value.owners.documents["OwnerPhotoProof"].fileStoreId);
42263
- if ((_data2 = data1) !== null && _data2 !== void 0 && (_data2$value = _data2.value) !== null && _data2$value !== void 0 && (_data2$value$owners = _data2$value.owners) !== null && _data2$value$owners !== void 0 && (_data2$value$owners$d = _data2$value$owners.documents["ProofOfIdentity"]) !== null && _data2$value$owners$d !== void 0 && _data2$value$owners$d.fileStoreId) filesArray.push(data1.value.owners.documents["ProofOfIdentity"].fileStoreId);
42264
- if ((_data3 = data1) !== null && _data3 !== void 0 && (_data3$value = _data3.value) !== null && _data3$value !== void 0 && (_data3$value$owners = _data3$value.owners) !== null && _data3$value$owners !== void 0 && (_data3$value$owners$d = _data3$value$owners.documents["ProofOfOwnership"]) !== null && _data3$value$owners$d !== void 0 && _data3$value$owners$d.fileStoreId) filesArray.push(data1.value.owners.documents["ProofOfOwnership"].fileStoreId);
43404
+ var filesArray = window.location.href.includes("/tl/tradelicence/application/") ? (_data = data1) === null || _data === void 0 ? void 0 : (_data$value = _data.value) === null || _data$value === void 0 ? void 0 : (_data$value$tradeLice = _data$value.tradeLicenseDetail) === null || _data$value$tradeLice === void 0 ? void 0 : _data$value$tradeLice.applicationDocuments.map(function (ob) {
43405
+ return ob === null || ob === void 0 ? void 0 : ob.fileStoreId;
43406
+ }) : [];
43407
+ if ((_data2 = data1) !== null && _data2 !== void 0 && (_data2$value = _data2.value) !== null && _data2$value !== void 0 && _data2$value.workflowDocs) filesArray = (_data3 = data1) === null || _data3 === void 0 ? void 0 : (_data3$value = _data3.value) === null || _data3$value === void 0 ? void 0 : (_data3$value$workflow = _data3$value.workflowDocs) === null || _data3$value$workflow === void 0 ? void 0 : _data3$value$workflow.map(function (ob) {
43408
+ return ob === null || ob === void 0 ? void 0 : ob.fileStoreId;
43409
+ });
43410
+ if ((_data4 = data1) !== null && _data4 !== void 0 && (_data4$value = _data4.value) !== null && _data4$value !== void 0 && (_data4$value$owners = _data4$value.owners) !== null && _data4$value$owners !== void 0 && (_data4$value$owners$d = _data4$value$owners.documents["OwnerPhotoProof"]) !== null && _data4$value$owners$d !== void 0 && _data4$value$owners$d.fileStoreId) filesArray.push(data1.value.owners.documents["OwnerPhotoProof"].fileStoreId);
43411
+ if ((_data5 = data1) !== null && _data5 !== void 0 && (_data5$value = _data5.value) !== null && _data5$value !== void 0 && (_data5$value$owners = _data5$value.owners) !== null && _data5$value$owners !== void 0 && (_data5$value$owners$d = _data5$value$owners.documents["ProofOfIdentity"]) !== null && _data5$value$owners$d !== void 0 && _data5$value$owners$d.fileStoreId) filesArray.push(data1.value.owners.documents["ProofOfIdentity"].fileStoreId);
43412
+ if ((_data6 = data1) !== null && _data6 !== void 0 && (_data6$value = _data6.value) !== null && _data6$value !== void 0 && (_data6$value$owners = _data6$value.owners) !== null && _data6$value$owners !== void 0 && (_data6$value$owners$d = _data6$value$owners.documents["ProofOfOwnership"]) !== null && _data6$value$owners$d !== void 0 && _data6$value$owners$d.fileStoreId) filesArray.push(data1.value.owners.documents["ProofOfOwnership"].fileStoreId);
42265
43413
 
42266
43414
  var _useQuery = useQuery(["tlDocuments-" + 1, filesArray], function () {
42267
43415
  return Digit.UploadServices.Filefetch(filesArray, tenant);
@@ -42482,6 +43630,10 @@ var convertEpochToDate = function convertEpochToDate(dateEpoch) {
42482
43630
  }
42483
43631
  };
42484
43632
 
43633
+ var getAddress = function getAddress(address, t) {
43634
+ return (address !== null && address !== void 0 && address.doorNo ? (address === null || address === void 0 ? void 0 : address.doorNo) + ", " : "") + " " + (address !== null && address !== void 0 && address.street ? (address === null || address === void 0 ? void 0 : address.street) + ", " : "") + (address !== null && address !== void 0 && address.landmark ? (address === null || address === void 0 ? void 0 : address.landmark) + ", " : "") + t(Digit.Utils.pt.getMohallaLocale(address === null || address === void 0 ? void 0 : address.locality.code, address === null || address === void 0 ? void 0 : address.tenantId)) + ", " + t(Digit.Utils.pt.getCityLocale(address === null || address === void 0 ? void 0 : address.tenantId)) + (address !== null && address !== void 0 && address.pincode && t(address === null || address === void 0 ? void 0 : address.pincode) ? ", " + address.pincode : " ");
43635
+ };
43636
+
42485
43637
  var TLSearch = {
42486
43638
  all: function (tenantId, filters) {
42487
43639
  if (filters === void 0) {
@@ -42539,68 +43691,14 @@ var TLSearch = {
42539
43691
 
42540
43692
  function _temp3(propertyDetails) {
42541
43693
  function _temp2() {
42542
- var _propertyDetails$Prop, _response$tradeLicens2, _response$tradeLicens3, _response$tradeLicens4, _response$tradeLicens5, _response$tradeLicens6, _response$tradeLicens7, _response$tradeLicens8, _response$tradeLicens9, _response$tradeLicens10, _response$tradeLicens11, _response$tradeLicens12, _response$tradeLicens13, _response$tradeLicens14, _propertyDetails$Prop39, _propertyDetails$Prop40, _propertyDetails$Prop41, _propertyDetails$Prop42, _propertyDetails$Prop43, _propertyDetails$Prop44, _propertyDetails$Prop45, _propertyDetails$Prop46, _propertyDetails$Prop47, _response$tradeLicens15, _response$tradeLicens16, _response$tradeLicens17, _response$tradeLicens18, _response$tradeLicens19, _response$tradeLicens20, _response$tradeLicens21, _response$tradeLicens22, _response$tradeLicens23, _response$tradeLicens24, _response$tradeLicens25, _response$tradeLicens26, _response$tradeLicens27, _response$tradeLicens28, _response$tradeLicens29, _response$tradeLicens30, _response$tradeLicens31, _response$tradeLicens32, _response$tradeLicens47, _response$tradeLicens48, _response$tradeLicens49, _response$tradeLicens50, _response$tradeLicens53, _response$tradeLicens54, _response$tradeLicens57, _response$tradeLicens58, _propertyDetails$Prop48, _propertyDetails$Prop49, _response$tradeLicens59;
43694
+ var _response$tradeLicens2, _response$tradeLicens3, _response$tradeLicens4, _response$tradeLicens5, _response$tradeLicens6, _response$tradeLicens7, _response$tradeLicens8, _response$tradeLicens9, _response$tradeLicens10, _response$tradeLicens11, _response$tradeLicens12, _response$tradeLicens13, _response$tradeLicens14, _propertyDetails$Prop2, _propertyDetails$Prop3, _propertyDetails$Prop4, _propertyDetails$Prop5, _propertyDetails$Prop6, _propertyDetails$Prop7, _propertyDetails$Prop8, _propertyDetails$Prop9, _propertyDetails$Prop10, _response$tradeLicens15, _response$tradeLicens16, _response$tradeLicens17, _response$tradeLicens18, _response$tradeLicens19, _response$tradeLicens20, _response$tradeLicens21, _response$tradeLicens22, _response$tradeLicens23, _response$tradeLicens24, _response$tradeLicens25, _response$tradeLicens26, _response$tradeLicens27, _response$tradeLicens28, _response$tradeLicens29, _response$tradeLicens30, _response$tradeLicens31, _response$tradeLicens32, _response$tradeLicens47, _response$tradeLicens48, _response$tradeLicens49, _response$tradeLicens50, _response$tradeLicens53, _response$tradeLicens54, _response$tradeLicens57, _response$tradeLicens58, _propertyDetails$Prop11, _propertyDetails$Prop12, _response$tradeLicens59;
42543
43695
 
42544
43696
  var propertyAddress = "";
42545
43697
 
42546
- if (propertyDetails && propertyDetails !== null && propertyDetails !== void 0 && (_propertyDetails$Prop = propertyDetails.Properties) !== null && _propertyDetails$Prop !== void 0 && _propertyDetails$Prop.length) {
42547
- var _propertyDetails$Prop2, _propertyDetails$Prop3, _propertyDetails$Prop8, _propertyDetails$Prop9, _propertyDetails$Prop14, _propertyDetails$Prop15, _propertyDetails$Prop21, _propertyDetails$Prop22, _propertyDetails$Prop23, _propertyDetails$Prop29, _propertyDetails$Prop30, _propertyDetails$Prop35, _propertyDetails$Prop36;
42548
-
42549
- if (propertyDetails !== null && propertyDetails !== void 0 && (_propertyDetails$Prop2 = propertyDetails.Properties[0]) !== null && _propertyDetails$Prop2 !== void 0 && (_propertyDetails$Prop3 = _propertyDetails$Prop2.address) !== null && _propertyDetails$Prop3 !== void 0 && _propertyDetails$Prop3.doorNo) {
42550
- var _propertyDetails$Prop4, _propertyDetails$Prop5, _propertyDetails$Prop6, _propertyDetails$Prop7;
42551
-
42552
- propertyAddress += propertyDetails === null || propertyDetails === void 0 ? void 0 : (_propertyDetails$Prop4 = propertyDetails.Properties[0]) === null || _propertyDetails$Prop4 === void 0 ? void 0 : (_propertyDetails$Prop5 = _propertyDetails$Prop4.address) === null || _propertyDetails$Prop5 === void 0 ? void 0 : _propertyDetails$Prop5.doorNo;
42553
-
42554
- if (propertyDetails !== null && propertyDetails !== void 0 && (_propertyDetails$Prop6 = propertyDetails.Properties[0]) !== null && _propertyDetails$Prop6 !== void 0 && (_propertyDetails$Prop7 = _propertyDetails$Prop6.address) !== null && _propertyDetails$Prop7 !== void 0 && _propertyDetails$Prop7.street) {
42555
- propertyAddress += ", ";
42556
- }
42557
- }
42558
-
42559
- if (propertyDetails !== null && propertyDetails !== void 0 && (_propertyDetails$Prop8 = propertyDetails.Properties[0]) !== null && _propertyDetails$Prop8 !== void 0 && (_propertyDetails$Prop9 = _propertyDetails$Prop8.address) !== null && _propertyDetails$Prop9 !== void 0 && _propertyDetails$Prop9.street) {
42560
- var _propertyDetails$Prop10, _propertyDetails$Prop11, _propertyDetails$Prop12, _propertyDetails$Prop13;
42561
-
42562
- propertyAddress += propertyDetails === null || propertyDetails === void 0 ? void 0 : (_propertyDetails$Prop10 = propertyDetails.Properties[0]) === null || _propertyDetails$Prop10 === void 0 ? void 0 : (_propertyDetails$Prop11 = _propertyDetails$Prop10.address) === null || _propertyDetails$Prop11 === void 0 ? void 0 : _propertyDetails$Prop11.street;
42563
-
42564
- if (propertyDetails !== null && propertyDetails !== void 0 && (_propertyDetails$Prop12 = propertyDetails.Properties[0]) !== null && _propertyDetails$Prop12 !== void 0 && (_propertyDetails$Prop13 = _propertyDetails$Prop12.address) !== null && _propertyDetails$Prop13 !== void 0 && _propertyDetails$Prop13.landmark) {
42565
- propertyAddress += ", ";
42566
- }
42567
- }
42568
-
42569
- if (propertyDetails !== null && propertyDetails !== void 0 && (_propertyDetails$Prop14 = propertyDetails.Properties[0]) !== null && _propertyDetails$Prop14 !== void 0 && (_propertyDetails$Prop15 = _propertyDetails$Prop14.address) !== null && _propertyDetails$Prop15 !== void 0 && _propertyDetails$Prop15.landmark) {
42570
- var _propertyDetails$Prop16, _propertyDetails$Prop17, _propertyDetails$Prop18, _propertyDetails$Prop19, _propertyDetails$Prop20;
42571
-
42572
- propertyAddress += propertyDetails === null || propertyDetails === void 0 ? void 0 : (_propertyDetails$Prop16 = propertyDetails.Properties[0]) === null || _propertyDetails$Prop16 === void 0 ? void 0 : (_propertyDetails$Prop17 = _propertyDetails$Prop16.address) === null || _propertyDetails$Prop17 === void 0 ? void 0 : _propertyDetails$Prop17.landmark;
43698
+ if (propertyDetails && propertyDetails !== null && propertyDetails !== void 0 && propertyDetails.Properties.length) {
43699
+ var _propertyDetails$Prop;
42573
43700
 
42574
- if (propertyDetails !== null && propertyDetails !== void 0 && (_propertyDetails$Prop18 = propertyDetails.Properties[0]) !== null && _propertyDetails$Prop18 !== void 0 && (_propertyDetails$Prop19 = _propertyDetails$Prop18.address) !== null && _propertyDetails$Prop19 !== void 0 && (_propertyDetails$Prop20 = _propertyDetails$Prop19.locality) !== null && _propertyDetails$Prop20 !== void 0 && _propertyDetails$Prop20.name) {
42575
- propertyAddress += ", ";
42576
- }
42577
- }
42578
-
42579
- if (propertyDetails !== null && propertyDetails !== void 0 && (_propertyDetails$Prop21 = propertyDetails.Properties[0]) !== null && _propertyDetails$Prop21 !== void 0 && (_propertyDetails$Prop22 = _propertyDetails$Prop21.address) !== null && _propertyDetails$Prop22 !== void 0 && (_propertyDetails$Prop23 = _propertyDetails$Prop22.locality) !== null && _propertyDetails$Prop23 !== void 0 && _propertyDetails$Prop23.name) {
42580
- var _propertyDetails$Prop24, _propertyDetails$Prop25, _propertyDetails$Prop26, _propertyDetails$Prop27, _propertyDetails$Prop28;
42581
-
42582
- propertyAddress += propertyDetails === null || propertyDetails === void 0 ? void 0 : (_propertyDetails$Prop24 = propertyDetails.Properties[0]) === null || _propertyDetails$Prop24 === void 0 ? void 0 : (_propertyDetails$Prop25 = _propertyDetails$Prop24.address) === null || _propertyDetails$Prop25 === void 0 ? void 0 : (_propertyDetails$Prop26 = _propertyDetails$Prop25.locality) === null || _propertyDetails$Prop26 === void 0 ? void 0 : _propertyDetails$Prop26.name;
42583
-
42584
- if (propertyDetails !== null && propertyDetails !== void 0 && (_propertyDetails$Prop27 = propertyDetails.Properties[0]) !== null && _propertyDetails$Prop27 !== void 0 && (_propertyDetails$Prop28 = _propertyDetails$Prop27.address) !== null && _propertyDetails$Prop28 !== void 0 && _propertyDetails$Prop28.city) {
42585
- propertyAddress += ", ";
42586
- }
42587
- }
42588
-
42589
- if (propertyDetails !== null && propertyDetails !== void 0 && (_propertyDetails$Prop29 = propertyDetails.Properties[0]) !== null && _propertyDetails$Prop29 !== void 0 && (_propertyDetails$Prop30 = _propertyDetails$Prop29.address) !== null && _propertyDetails$Prop30 !== void 0 && _propertyDetails$Prop30.city) {
42590
- var _propertyDetails$Prop31, _propertyDetails$Prop32, _propertyDetails$Prop33, _propertyDetails$Prop34;
42591
-
42592
- propertyAddress += propertyDetails === null || propertyDetails === void 0 ? void 0 : (_propertyDetails$Prop31 = propertyDetails.Properties[0]) === null || _propertyDetails$Prop31 === void 0 ? void 0 : (_propertyDetails$Prop32 = _propertyDetails$Prop31.address) === null || _propertyDetails$Prop32 === void 0 ? void 0 : _propertyDetails$Prop32.city;
42593
-
42594
- if (propertyDetails !== null && propertyDetails !== void 0 && (_propertyDetails$Prop33 = propertyDetails.Properties[0]) !== null && _propertyDetails$Prop33 !== void 0 && (_propertyDetails$Prop34 = _propertyDetails$Prop33.address) !== null && _propertyDetails$Prop34 !== void 0 && _propertyDetails$Prop34.pincode) {
42595
- propertyAddress += ", ";
42596
- }
42597
- }
42598
-
42599
- if (propertyDetails !== null && propertyDetails !== void 0 && (_propertyDetails$Prop35 = propertyDetails.Properties[0]) !== null && _propertyDetails$Prop35 !== void 0 && (_propertyDetails$Prop36 = _propertyDetails$Prop35.address) !== null && _propertyDetails$Prop36 !== void 0 && _propertyDetails$Prop36.pincode) {
42600
- var _propertyDetails$Prop37, _propertyDetails$Prop38;
42601
-
42602
- propertyAddress += propertyDetails === null || propertyDetails === void 0 ? void 0 : (_propertyDetails$Prop37 = propertyDetails.Properties[0]) === null || _propertyDetails$Prop37 === void 0 ? void 0 : (_propertyDetails$Prop38 = _propertyDetails$Prop37.address) === null || _propertyDetails$Prop38 === void 0 ? void 0 : _propertyDetails$Prop38.pincode;
42603
- }
43701
+ propertyAddress = getAddress(propertyDetails === null || propertyDetails === void 0 ? void 0 : (_propertyDetails$Prop = propertyDetails.Properties[0]) === null || _propertyDetails$Prop === void 0 ? void 0 : _propertyDetails$Prop.address, t);
42604
43702
  }
42605
43703
 
42606
43704
  var employeeResponse = [];
@@ -42621,7 +43719,7 @@ var TLSearch = {
42621
43719
  value: response !== null && response !== void 0 && (_response$tradeLicens2 = response.tradeLicenseDetail) !== null && _response$tradeLicens2 !== void 0 && _response$tradeLicens2.structureType ? "COMMON_MASTERS_STRUCTURETYPE_" + (response === null || response === void 0 ? void 0 : (_response$tradeLicens3 = response.tradeLicenseDetail) === null || _response$tradeLicens3 === void 0 ? void 0 : (_response$tradeLicens4 = _response$tradeLicens3.structureType) === null || _response$tradeLicens4 === void 0 ? void 0 : _response$tradeLicens4.split(".")[0]) : "NA"
42622
43720
  }, {
42623
43721
  title: "TL_NEW_TRADE_DETAILS_STRUCT_SUB_TYPE_LABEL",
42624
- value: response !== null && response !== void 0 && (_response$tradeLicens5 = response.tradeLicenseDetail) !== null && _response$tradeLicens5 !== void 0 && _response$tradeLicens5.structureType ? "COMMON_MASTERS_STRUCTURETYPE_" + stringReplaceAll$2(response === null || response === void 0 ? void 0 : (_response$tradeLicens6 = response.tradeLicenseDetail) === null || _response$tradeLicens6 === void 0 ? void 0 : _response$tradeLicens6.structureType, ".", "_") : "NA"
43722
+ value: response !== null && response !== void 0 && (_response$tradeLicens5 = response.tradeLicenseDetail) !== null && _response$tradeLicens5 !== void 0 && _response$tradeLicens5.structureType ? "TL_" + (response === null || response === void 0 ? void 0 : (_response$tradeLicens6 = response.tradeLicenseDetail) === null || _response$tradeLicens6 === void 0 ? void 0 : _response$tradeLicens6.tradeType) : "NA"
42625
43723
  }, {
42626
43724
  title: "TL_NEW_TRADE_DETAILS_TRADE_COMM_DATE_LABEL",
42627
43725
  value: response !== null && response !== void 0 && response.commencementDate ? convertEpochToDate(response === null || response === void 0 ? void 0 : response.commencementDate) : "NA"
@@ -42700,16 +43798,16 @@ var TLSearch = {
42700
43798
  title: "PT_DETAILS",
42701
43799
  values: [{
42702
43800
  title: "TL_PROPERTY_ID",
42703
- value: (propertyDetails === null || propertyDetails === void 0 ? void 0 : (_propertyDetails$Prop39 = propertyDetails.Properties) === null || _propertyDetails$Prop39 === void 0 ? void 0 : (_propertyDetails$Prop40 = _propertyDetails$Prop39[0]) === null || _propertyDetails$Prop40 === void 0 ? void 0 : _propertyDetails$Prop40.propertyId) || "NA"
43801
+ value: (propertyDetails === null || propertyDetails === void 0 ? void 0 : (_propertyDetails$Prop2 = propertyDetails.Properties) === null || _propertyDetails$Prop2 === void 0 ? void 0 : (_propertyDetails$Prop3 = _propertyDetails$Prop2[0]) === null || _propertyDetails$Prop3 === void 0 ? void 0 : _propertyDetails$Prop3.propertyId) || "NA"
42704
43802
  }, {
42705
43803
  title: "PT_OWNER_NAME",
42706
- value: (propertyDetails === null || propertyDetails === void 0 ? void 0 : (_propertyDetails$Prop41 = propertyDetails.Properties) === null || _propertyDetails$Prop41 === void 0 ? void 0 : (_propertyDetails$Prop42 = _propertyDetails$Prop41[0]) === null || _propertyDetails$Prop42 === void 0 ? void 0 : (_propertyDetails$Prop43 = _propertyDetails$Prop42.owners[0]) === null || _propertyDetails$Prop43 === void 0 ? void 0 : _propertyDetails$Prop43.name) || "NA"
43804
+ value: (propertyDetails === null || propertyDetails === void 0 ? void 0 : (_propertyDetails$Prop4 = propertyDetails.Properties) === null || _propertyDetails$Prop4 === void 0 ? void 0 : (_propertyDetails$Prop5 = _propertyDetails$Prop4[0]) === null || _propertyDetails$Prop5 === void 0 ? void 0 : (_propertyDetails$Prop6 = _propertyDetails$Prop5.owners[0]) === null || _propertyDetails$Prop6 === void 0 ? void 0 : _propertyDetails$Prop6.name) || "NA"
42707
43805
  }, {
42708
43806
  title: "PROPERTY_ADDRESS",
42709
43807
  value: propertyAddress || "NA"
42710
43808
  }, {
42711
43809
  title: "TL_VIEW_PROPERTY_DETAIL",
42712
- to: "/digit-ui/employee/commonpt/view-property?propertyId=" + (propertyDetails === null || propertyDetails === void 0 ? void 0 : (_propertyDetails$Prop44 = propertyDetails.Properties) === null || _propertyDetails$Prop44 === void 0 ? void 0 : (_propertyDetails$Prop45 = _propertyDetails$Prop44[0]) === null || _propertyDetails$Prop45 === void 0 ? void 0 : _propertyDetails$Prop45.propertyId) + "&tenantId=" + (propertyDetails === null || propertyDetails === void 0 ? void 0 : (_propertyDetails$Prop46 = propertyDetails.Properties) === null || _propertyDetails$Prop46 === void 0 ? void 0 : (_propertyDetails$Prop47 = _propertyDetails$Prop46[0]) === null || _propertyDetails$Prop47 === void 0 ? void 0 : _propertyDetails$Prop47.tenantId),
43810
+ to: "/digit-ui/employee/commonpt/view-property?propertyId=" + (propertyDetails === null || propertyDetails === void 0 ? void 0 : (_propertyDetails$Prop7 = propertyDetails.Properties) === null || _propertyDetails$Prop7 === void 0 ? void 0 : (_propertyDetails$Prop8 = _propertyDetails$Prop7[0]) === null || _propertyDetails$Prop8 === void 0 ? void 0 : _propertyDetails$Prop8.propertyId) + "&tenantId=" + (propertyDetails === null || propertyDetails === void 0 ? void 0 : (_propertyDetails$Prop9 = propertyDetails.Properties) === null || _propertyDetails$Prop9 === void 0 ? void 0 : (_propertyDetails$Prop10 = _propertyDetails$Prop9[0]) === null || _propertyDetails$Prop10 === void 0 ? void 0 : _propertyDetails$Prop10.tenantId) + "&from=TL_APPLICATION_DETAILS_LABEL",
42713
43811
  value: "",
42714
43812
  isLink: true
42715
43813
  }]
@@ -42853,8 +43951,8 @@ var TLSearch = {
42853
43951
  response && employeeResponse.push(tradedetails);
42854
43952
  (response === null || response === void 0 ? void 0 : (_response$tradeLicens57 = response.tradeLicenseDetail) === null || _response$tradeLicens57 === void 0 ? void 0 : _response$tradeLicens57.tradeUnits) && employeeResponse.push(tradeUnits);
42855
43953
  (response === null || response === void 0 ? void 0 : (_response$tradeLicens58 = response.tradeLicenseDetail) === null || _response$tradeLicens58 === void 0 ? void 0 : _response$tradeLicens58.accessories) && employeeResponse.push(accessories);
42856
- (propertyDetails === null || propertyDetails === void 0 ? void 0 : (_propertyDetails$Prop48 = propertyDetails.Properties) === null || _propertyDetails$Prop48 === void 0 ? void 0 : _propertyDetails$Prop48.length) > 0 && employeeResponse.push(PropertyDetail);
42857
- response && !((propertyDetails === null || propertyDetails === void 0 ? void 0 : (_propertyDetails$Prop49 = propertyDetails.Properties) === null || _propertyDetails$Prop49 === void 0 ? void 0 : _propertyDetails$Prop49.length) > 0) && employeeResponse.push(tradeAddress);
43954
+ (propertyDetails === null || propertyDetails === void 0 ? void 0 : (_propertyDetails$Prop11 = propertyDetails.Properties) === null || _propertyDetails$Prop11 === void 0 ? void 0 : _propertyDetails$Prop11.length) > 0 && employeeResponse.push(PropertyDetail);
43955
+ response && !((propertyDetails === null || propertyDetails === void 0 ? void 0 : (_propertyDetails$Prop12 = propertyDetails.Properties) === null || _propertyDetails$Prop12 === void 0 ? void 0 : _propertyDetails$Prop12.length) > 0) && employeeResponse.push(tradeAddress);
42858
43956
  (response === null || response === void 0 ? void 0 : (_response$tradeLicens59 = response.tradeLicenseDetail) === null || _response$tradeLicens59 === void 0 ? void 0 : _response$tradeLicens59.owners) && employeeResponse.push(owners);
42859
43957
  return {
42860
43958
  tenantId: response.tenantId,
@@ -43566,13 +44664,14 @@ var SearchMdmsTypes = {
43566
44664
  var _data$BPA3, _data$BPA3$BPAAppicat;
43567
44665
 
43568
44666
  return [].concat(data === null || data === void 0 ? void 0 : (_data$BPA3 = data.BPA) === null || _data$BPA3 === void 0 ? void 0 : (_data$BPA3$BPAAppicat = _data$BPA3.BPAAppicationMapping) === null || _data$BPA3$BPAAppicat === void 0 ? void 0 : _data$BPA3$BPAAppicat.filter(function (currentObject) {
43569
- var _currentObject$roles;
44667
+ var _userInfo$value, _currentObject$roles;
43570
44668
 
44669
+ var userInfos = sessionStorage.getItem("Digit.citizen.userRequestObject");
44670
+ var userInfo = userInfos ? JSON.parse(userInfos) : {};
44671
+ var userInformation = userInfo === null || userInfo === void 0 ? void 0 : (_userInfo$value = userInfo.value) === null || _userInfo$value === void 0 ? void 0 : _userInfo$value.info;
43571
44672
  var flag = 0;
43572
44673
  currentObject === null || currentObject === void 0 ? void 0 : (_currentObject$roles = currentObject.roles) === null || _currentObject$roles === void 0 ? void 0 : _currentObject$roles.map(function (bpaRole) {
43573
- var _Digit$UserService$ge, _Digit$UserService$ge2;
43574
-
43575
- var found = (_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.roles.some(function (role) {
44674
+ var found = userInformation === null || userInformation === void 0 ? void 0 : userInformation.roles.some(function (role) {
43576
44675
  return (role === null || role === void 0 ? void 0 : role.code) === bpaRole;
43577
44676
  });
43578
44677
  if (found == true) flag = 1;
@@ -43890,21 +44989,124 @@ var OBPSService = {
43890
44989
  isEmployee: true
43891
44990
  })).then(function (paymentRes) {
43892
44991
  return Promise.resolve(MdmsService.getMultipleTypes(License === null || License === void 0 ? void 0 : License.tenantId, "StakeholderRegistraition", ["TradeTypetoRoleMapping"])).then(function (mdmsRes) {
43893
- var _License$tradeLicense, _License$tradeLicense2, _mdmsRes$StakeholderR, _mdmsRes$StakeholderR2, _License$tradeLicense8, _License$tradeLicense9, _License$tradeLicense10, _License$tradeLicense11, _License$tradeLicense12, _License$tradeLicense13, _License$tradeLicense14, _License$tradeLicense15, _License$tradeLicense16, _License$tradeLicense17, _License$tradeLicense18, _License$tradeLicense19, _License$tradeLicense20, _License$tradeLicense21, _License$tradeLicense22, _License$tradeLicense23, _License$tradeLicense24, _License$tradeLicense25, _License$tradeLicense26, _License$tradeLicense27, _License$tradeLicense28, _License$tradeLicense29, _License$tradeLicense30, _License$tradeLicense31, _License$tradeLicense32, _License$tradeLicense33, _License$tradeLicense34, _License$tradeLicense35, _License$tradeLicense36, _License$tradeLicense37, _License$tradeLicense38, _License$tradeLicense39, _License$tradeLicense40, _License$tradeLicense41, _License$tradeLicense42, _License$tradeLicense43, _paymentRes$Payments, _paymentRes$Payments2, _paymentRes$Payments3, _paymentRes$Payments4, _paymentRes$Payments5, _ref;
44992
+ var _License$tradeLicense37, _License$tradeLicense38, _mdmsRes$StakeholderR, _mdmsRes$StakeholderR2, _License$tradeLicense44, _License$tradeLicense45;
44993
+
44994
+ function _temp2() {
44995
+ var _License$tradeLicense, _License$tradeLicense2, _License$tradeLicense3, _License$tradeLicense4, _License$tradeLicense5, _License$tradeLicense6, _License$tradeLicense7, _License$tradeLicense8, _License$tradeLicense9, _License$tradeLicense10, _License$tradeLicense11, _License$tradeLicense12, _License$tradeLicense13, _License$tradeLicense14, _License$tradeLicense15, _License$tradeLicense16, _License$tradeLicense17, _License$tradeLicense18, _License$tradeLicense19, _License$tradeLicense20, _License$tradeLicense21, _License$tradeLicense22, _License$tradeLicense23, _License$tradeLicense24, _License$tradeLicense25, _License$tradeLicense26, _License$tradeLicense27, _License$tradeLicense28, _License$tradeLicense29, _License$tradeLicense30, _License$tradeLicense31, _License$tradeLicense32, _License$tradeLicense33, _License$tradeLicense34, _License$tradeLicense35, _License$tradeLicense36, _paymentRes$Payments, _paymentRes$Payments2, _paymentRes$Payments3, _paymentRes$Payments4, _paymentRes$Payments5, _ref;
43894
44996
 
43895
- if (License !== null && License !== void 0 && (_License$tradeLicense = License.tradeLicenseDetail) !== null && _License$tradeLicense !== void 0 && (_License$tradeLicense2 = _License$tradeLicense.applicationDocuments) !== null && _License$tradeLicense2 !== void 0 && _License$tradeLicense2.length && (mdmsRes === null || mdmsRes === void 0 ? void 0 : (_mdmsRes$StakeholderR = mdmsRes.StakeholderRegistraition) === null || _mdmsRes$StakeholderR === void 0 ? void 0 : (_mdmsRes$StakeholderR2 = _mdmsRes$StakeholderR.TradeTypetoRoleMapping) === null || _mdmsRes$StakeholderR2 === void 0 ? void 0 : _mdmsRes$StakeholderR2.length) > 0) {
44997
+ var details = [{
44998
+ title: " ",
44999
+ values: [{
45000
+ title: "BPA_APPLICATION_NUMBER_LABEL",
45001
+ value: (License === null || License === void 0 ? void 0 : License.applicationNumber) || "NA"
45002
+ }]
45003
+ }, License !== null && License !== void 0 && (_License$tradeLicense = License.tradeLicenseDetail) !== null && _License$tradeLicense !== void 0 && (_License$tradeLicense2 = _License$tradeLicense.tradeUnits) !== null && _License$tradeLicense2 !== void 0 && (_License$tradeLicense3 = _License$tradeLicense2[0]) !== null && _License$tradeLicense3 !== void 0 && _License$tradeLicense3.tradeType.includes("ARCHITECT") ? {
45004
+ title: "BPA_LICENSE_DETAILS_LABEL",
45005
+ asSectionHeader: true,
45006
+ values: [{
45007
+ title: "BPA_LICENSE_TYPE",
45008
+ value: "TRADELICENSE_TRADETYPE_" + (License === null || License === void 0 ? void 0 : (_License$tradeLicense4 = License.tradeLicenseDetail) === null || _License$tradeLicense4 === void 0 ? void 0 : (_License$tradeLicense5 = _License$tradeLicense4.tradeUnits) === null || _License$tradeLicense5 === void 0 ? void 0 : (_License$tradeLicense6 = _License$tradeLicense5[0]) === null || _License$tradeLicense6 === void 0 ? void 0 : (_License$tradeLicense7 = _License$tradeLicense6.tradeType) === null || _License$tradeLicense7 === void 0 ? void 0 : _License$tradeLicense7.split(".")[0]) || "NA"
45009
+ }, {
45010
+ title: "BPA_COUNCIL_OF_ARCH_NO_LABEL",
45011
+ value: (License === null || License === void 0 ? void 0 : (_License$tradeLicense8 = License.tradeLicenseDetail) === null || _License$tradeLicense8 === void 0 ? void 0 : (_License$tradeLicense9 = _License$tradeLicense8.additionalDetail) === null || _License$tradeLicense9 === void 0 ? void 0 : _License$tradeLicense9.counsilForArchNo) || "NA"
45012
+ }]
45013
+ } : {
45014
+ title: "BPA_LICENSE_DETAILS_LABEL",
45015
+ asSectionHeader: true,
45016
+ values: [{
45017
+ title: "BPA_LICENSE_TYPE",
45018
+ value: "TRADELICENSE_TRADETYPE_" + (License === null || License === void 0 ? void 0 : (_License$tradeLicense10 = License.tradeLicenseDetail) === null || _License$tradeLicense10 === void 0 ? void 0 : (_License$tradeLicense11 = _License$tradeLicense10.tradeUnits) === null || _License$tradeLicense11 === void 0 ? void 0 : (_License$tradeLicense12 = _License$tradeLicense11[0]) === null || _License$tradeLicense12 === void 0 ? void 0 : (_License$tradeLicense13 = _License$tradeLicense12.tradeType) === null || _License$tradeLicense13 === void 0 ? void 0 : _License$tradeLicense13.split(".")[0]) || "NA"
45019
+ }]
45020
+ }, {
45021
+ title: "BPA_LICENSEE_DETAILS_HEADER_OWNER_INFO",
45022
+ asSectionHeader: true,
45023
+ values: [{
45024
+ title: "BPA_APPLICANT_NAME_LABEL",
45025
+ value: (License === null || License === void 0 ? void 0 : (_License$tradeLicense14 = License.tradeLicenseDetail) === null || _License$tradeLicense14 === void 0 ? void 0 : (_License$tradeLicense15 = _License$tradeLicense14.owners) === null || _License$tradeLicense15 === void 0 ? void 0 : (_License$tradeLicense16 = _License$tradeLicense15[0]) === null || _License$tradeLicense16 === void 0 ? void 0 : _License$tradeLicense16.name) || "NA"
45026
+ }, {
45027
+ title: "BPA_APPLICANT_GENDER_LABEL",
45028
+ value: (License === null || License === void 0 ? void 0 : (_License$tradeLicense17 = License.tradeLicenseDetail) === null || _License$tradeLicense17 === void 0 ? void 0 : (_License$tradeLicense18 = _License$tradeLicense17.owners) === null || _License$tradeLicense18 === void 0 ? void 0 : (_License$tradeLicense19 = _License$tradeLicense18[0]) === null || _License$tradeLicense19 === void 0 ? void 0 : _License$tradeLicense19.gender) || "NA"
45029
+ }, {
45030
+ title: "BPA_OWNER_MOBILE_NO_LABEL",
45031
+ value: (License === null || License === void 0 ? void 0 : (_License$tradeLicense20 = License.tradeLicenseDetail) === null || _License$tradeLicense20 === void 0 ? void 0 : (_License$tradeLicense21 = _License$tradeLicense20.owners) === null || _License$tradeLicense21 === void 0 ? void 0 : (_License$tradeLicense22 = _License$tradeLicense21[0]) === null || _License$tradeLicense22 === void 0 ? void 0 : _License$tradeLicense22.mobileNumber) || "NA"
45032
+ }, {
45033
+ title: "BPA_APPLICANT_EMAIL_LABEL",
45034
+ value: (License === null || License === void 0 ? void 0 : (_License$tradeLicense23 = License.tradeLicenseDetail) === null || _License$tradeLicense23 === void 0 ? void 0 : (_License$tradeLicense24 = _License$tradeLicense23.owners) === null || _License$tradeLicense24 === void 0 ? void 0 : (_License$tradeLicense25 = _License$tradeLicense24[0]) === null || _License$tradeLicense25 === void 0 ? void 0 : _License$tradeLicense25.emailId) || "NA"
45035
+ }, {
45036
+ title: "BPA_APPLICANT_PAN_NO",
45037
+ value: (License === null || License === void 0 ? void 0 : (_License$tradeLicense26 = License.tradeLicenseDetail) === null || _License$tradeLicense26 === void 0 ? void 0 : (_License$tradeLicense27 = _License$tradeLicense26.owners) === null || _License$tradeLicense27 === void 0 ? void 0 : (_License$tradeLicense28 = _License$tradeLicense27[0]) === null || _License$tradeLicense28 === void 0 ? void 0 : _License$tradeLicense28.pan) || "NA"
45038
+ }]
45039
+ }, {
45040
+ title: "BPA_PERMANANT_ADDRESS_LABEL",
45041
+ asSectionHeader: true,
45042
+ values: [{
45043
+ title: "BPA_PERMANANT_ADDRESS_LABEL",
45044
+ value: (License === null || License === void 0 ? void 0 : (_License$tradeLicense29 = License.tradeLicenseDetail) === null || _License$tradeLicense29 === void 0 ? void 0 : (_License$tradeLicense30 = _License$tradeLicense29.owners) === null || _License$tradeLicense30 === void 0 ? void 0 : (_License$tradeLicense31 = _License$tradeLicense30[0]) === null || _License$tradeLicense31 === void 0 ? void 0 : _License$tradeLicense31.permanentAddress) || "NA"
45045
+ }]
45046
+ }, {
45047
+ title: "BPA_APPLICANT_CORRESPONDENCE_ADDRESS_LABEL",
45048
+ asSectionHeader: true,
45049
+ values: [{
45050
+ title: "BPA_APPLICANT_CORRESPONDENCE_ADDRESS_LABEL",
45051
+ value: (License === null || License === void 0 ? void 0 : (_License$tradeLicense32 = License.tradeLicenseDetail) === null || _License$tradeLicense32 === void 0 ? void 0 : (_License$tradeLicense33 = _License$tradeLicense32.owners) === null || _License$tradeLicense33 === void 0 ? void 0 : (_License$tradeLicense34 = _License$tradeLicense33[0]) === null || _License$tradeLicense34 === void 0 ? void 0 : _License$tradeLicense34.correspondenceAddress) || "NA"
45052
+ }]
45053
+ }, {
45054
+ title: "BPA_DOCUMENT_DETAILS_LABEL",
45055
+ asSectionHeader: true,
45056
+ additionalDetails: {
45057
+ documentsWithUrl: [{
45058
+ title: "",
45059
+ values: License === null || License === void 0 ? void 0 : (_License$tradeLicense35 = License.tradeLicenseDetail) === null || _License$tradeLicense35 === void 0 ? void 0 : (_License$tradeLicense36 = _License$tradeLicense35.applicationDocuments) === null || _License$tradeLicense36 === void 0 ? void 0 : _License$tradeLicense36.map(function (doc) {
45060
+ var _doc$documentType, _fileDetails, _fileDetails2, _fileDetails2$data$do;
45061
+
45062
+ return {
45063
+ title: "BPAREG_HEADER_" + (doc === null || doc === void 0 ? void 0 : (_doc$documentType = doc.documentType) === null || _doc$documentType === void 0 ? void 0 : _doc$documentType.replaceAll('.', '_')),
45064
+ documentType: doc === null || doc === void 0 ? void 0 : doc.documentType,
45065
+ documentUid: doc === null || doc === void 0 ? void 0 : doc.documentUid,
45066
+ fileStoreId: doc === null || doc === void 0 ? void 0 : doc.fileStoreId,
45067
+ id: doc === null || doc === void 0 ? void 0 : doc.id,
45068
+ docInfo: doc === null || doc === void 0 ? void 0 : doc.info,
45069
+ url: (_fileDetails = fileDetails) !== null && _fileDetails !== void 0 && _fileDetails.data[doc === null || doc === void 0 ? void 0 : doc.fileStoreId] ? (_fileDetails2 = fileDetails) === null || _fileDetails2 === void 0 ? void 0 : (_fileDetails2$data$do = _fileDetails2.data[doc === null || doc === void 0 ? void 0 : doc.fileStoreId]) === null || _fileDetails2$data$do === void 0 ? void 0 : _fileDetails2$data$do.split(',')[0] : ""
45070
+ };
45071
+ })
45072
+ }]
45073
+ }
45074
+ }, (paymentRes === null || paymentRes === void 0 ? void 0 : (_paymentRes$Payments = paymentRes.Payments) === null || _paymentRes$Payments === void 0 ? void 0 : _paymentRes$Payments.length) > 0 && {
45075
+ title: "BPA_FEE_DETAILS_LABEL",
45076
+ additionalDetails: {
45077
+ inspectionReport: [],
45078
+ values: [{
45079
+ title: "BPAREG_FEES",
45080
+ value: /*#__PURE__*/React.createElement("span", null, "\u20B9", paymentRes === null || paymentRes === void 0 ? void 0 : (_paymentRes$Payments2 = paymentRes.Payments) === null || _paymentRes$Payments2 === void 0 ? void 0 : (_paymentRes$Payments3 = _paymentRes$Payments2[0]) === null || _paymentRes$Payments3 === void 0 ? void 0 : _paymentRes$Payments3.totalAmountPaid)
45081
+ }, (_ref = {
45082
+ title: "BPA_STATUS_LABEL",
45083
+ isTransLate: true,
45084
+ isStatus: true,
45085
+ value: paymentRes !== null && paymentRes !== void 0 && (_paymentRes$Payments4 = paymentRes.Payments) !== null && _paymentRes$Payments4 !== void 0 && (_paymentRes$Payments5 = _paymentRes$Payments4[0]) !== null && _paymentRes$Payments5 !== void 0 && _paymentRes$Payments5.totalAmountPaid ? "WF_BPA_PAID" : "NA"
45086
+ }, _ref["isTransLate"] = true, _ref)]
45087
+ }
45088
+ }];
45089
+ return {
45090
+ applicationData: License,
45091
+ applicationDetails: details,
45092
+ tenantId: License === null || License === void 0 ? void 0 : License.tenantId,
45093
+ payments: (paymentRes === null || paymentRes === void 0 ? void 0 : paymentRes.Payments) || []
45094
+ };
45095
+ }
45096
+
45097
+ if (License !== null && License !== void 0 && (_License$tradeLicense37 = License.tradeLicenseDetail) !== null && _License$tradeLicense37 !== void 0 && (_License$tradeLicense38 = _License$tradeLicense37.applicationDocuments) !== null && _License$tradeLicense38 !== void 0 && _License$tradeLicense38.length && (mdmsRes === null || mdmsRes === void 0 ? void 0 : (_mdmsRes$StakeholderR = mdmsRes.StakeholderRegistraition) === null || _mdmsRes$StakeholderR === void 0 ? void 0 : (_mdmsRes$StakeholderR2 = _mdmsRes$StakeholderR.TradeTypetoRoleMapping) === null || _mdmsRes$StakeholderR2 === void 0 ? void 0 : _mdmsRes$StakeholderR2.length) > 0) {
43896
45098
  var _mdmsRes$StakeholderR3, _mdmsRes$StakeholderR4;
43897
45099
 
43898
45100
  mdmsRes === null || mdmsRes === void 0 ? void 0 : (_mdmsRes$StakeholderR3 = mdmsRes.StakeholderRegistraition) === null || _mdmsRes$StakeholderR3 === void 0 ? void 0 : (_mdmsRes$StakeholderR4 = _mdmsRes$StakeholderR3.TradeTypetoRoleMapping) === null || _mdmsRes$StakeholderR4 === void 0 ? void 0 : _mdmsRes$StakeholderR4.map(function (doc) {
43899
- var _doc$docTypes, _License$tradeLicense3, _License$tradeLicense4, _License$tradeLicense5;
45101
+ var _doc$docTypes, _License$tradeLicense39, _License$tradeLicense40, _License$tradeLicense41;
43900
45102
 
43901
- if ((doc === null || doc === void 0 ? void 0 : (_doc$docTypes = doc.docTypes) === null || _doc$docTypes === void 0 ? void 0 : _doc$docTypes.length) > 0 && (doc === null || doc === void 0 ? void 0 : doc.tradeType) == (License === null || License === void 0 ? void 0 : (_License$tradeLicense3 = License.tradeLicenseDetail) === null || _License$tradeLicense3 === void 0 ? void 0 : (_License$tradeLicense4 = _License$tradeLicense3.tradeUnits) === null || _License$tradeLicense4 === void 0 ? void 0 : (_License$tradeLicense5 = _License$tradeLicense4[0]) === null || _License$tradeLicense5 === void 0 ? void 0 : _License$tradeLicense5.tradeType)) {
45103
+ if ((doc === null || doc === void 0 ? void 0 : (_doc$docTypes = doc.docTypes) === null || _doc$docTypes === void 0 ? void 0 : _doc$docTypes.length) > 0 && (doc === null || doc === void 0 ? void 0 : doc.tradeType) == (License === null || License === void 0 ? void 0 : (_License$tradeLicense39 = License.tradeLicenseDetail) === null || _License$tradeLicense39 === void 0 ? void 0 : (_License$tradeLicense40 = _License$tradeLicense39.tradeUnits) === null || _License$tradeLicense40 === void 0 ? void 0 : (_License$tradeLicense41 = _License$tradeLicense40[0]) === null || _License$tradeLicense41 === void 0 ? void 0 : _License$tradeLicense41.tradeType)) {
43902
45104
  var _doc$docTypes2;
43903
45105
 
43904
45106
  doc === null || doc === void 0 ? void 0 : (_doc$docTypes2 = doc.docTypes) === null || _doc$docTypes2 === void 0 ? void 0 : _doc$docTypes2.map(function (docType) {
43905
- var _License$tradeLicense6, _License$tradeLicense7;
45107
+ var _License$tradeLicense42, _License$tradeLicense43;
43906
45108
 
43907
- License === null || License === void 0 ? void 0 : (_License$tradeLicense6 = License.tradeLicenseDetail) === null || _License$tradeLicense6 === void 0 ? void 0 : (_License$tradeLicense7 = _License$tradeLicense6.applicationDocuments) === null || _License$tradeLicense7 === void 0 ? void 0 : _License$tradeLicense7.forEach(function (document) {
45109
+ License === null || License === void 0 ? void 0 : (_License$tradeLicense42 = License.tradeLicenseDetail) === null || _License$tradeLicense42 === void 0 ? void 0 : (_License$tradeLicense43 = _License$tradeLicense42.applicationDocuments) === null || _License$tradeLicense43 === void 0 ? void 0 : _License$tradeLicense43.forEach(function (document) {
43908
45110
  if ((docType === null || docType === void 0 ? void 0 : docType.code) == (document === null || document === void 0 ? void 0 : document.documentType) && docType !== null && docType !== void 0 && docType.info) document.info = docType === null || docType === void 0 ? void 0 : docType.info;
43909
45111
  });
43910
45112
  });
@@ -43912,103 +45114,20 @@ var OBPSService = {
43912
45114
  });
43913
45115
  }
43914
45116
 
43915
- var details = [{
43916
- title: " ",
43917
- values: [{
43918
- title: "BPA_APPLICATION_NUMBER_LABEL",
43919
- value: (License === null || License === void 0 ? void 0 : License.applicationNumber) || "NA"
43920
- }]
43921
- }, License !== null && License !== void 0 && (_License$tradeLicense8 = License.tradeLicenseDetail) !== null && _License$tradeLicense8 !== void 0 && (_License$tradeLicense9 = _License$tradeLicense8.tradeUnits) !== null && _License$tradeLicense9 !== void 0 && (_License$tradeLicense10 = _License$tradeLicense9[0]) !== null && _License$tradeLicense10 !== void 0 && _License$tradeLicense10.tradeType.includes("ARCHITECT") ? {
43922
- title: "BPA_LICENSE_DETAILS_LABEL",
43923
- asSectionHeader: true,
43924
- values: [{
43925
- title: "BPA_LICENSE_TYPE",
43926
- value: "TRADELICENSE_TRADETYPE_" + (License === null || License === void 0 ? void 0 : (_License$tradeLicense11 = License.tradeLicenseDetail) === null || _License$tradeLicense11 === void 0 ? void 0 : (_License$tradeLicense12 = _License$tradeLicense11.tradeUnits) === null || _License$tradeLicense12 === void 0 ? void 0 : (_License$tradeLicense13 = _License$tradeLicense12[0]) === null || _License$tradeLicense13 === void 0 ? void 0 : (_License$tradeLicense14 = _License$tradeLicense13.tradeType) === null || _License$tradeLicense14 === void 0 ? void 0 : _License$tradeLicense14.split(".")[0]) || "NA"
43927
- }, {
43928
- title: "BPA_COUNCIL_OF_ARCH_NO_LABEL",
43929
- value: (License === null || License === void 0 ? void 0 : (_License$tradeLicense15 = License.tradeLicenseDetail) === null || _License$tradeLicense15 === void 0 ? void 0 : (_License$tradeLicense16 = _License$tradeLicense15.additionalDetail) === null || _License$tradeLicense16 === void 0 ? void 0 : _License$tradeLicense16.counsilForArchNo) || "NA"
43930
- }]
43931
- } : {
43932
- title: "BPA_LICENSE_DETAILS_LABEL",
43933
- asSectionHeader: true,
43934
- values: [{
43935
- title: "BPA_LICENSE_TYPE",
43936
- value: "TRADELICENSE_TRADETYPE_" + (License === null || License === void 0 ? void 0 : (_License$tradeLicense17 = License.tradeLicenseDetail) === null || _License$tradeLicense17 === void 0 ? void 0 : (_License$tradeLicense18 = _License$tradeLicense17.tradeUnits) === null || _License$tradeLicense18 === void 0 ? void 0 : (_License$tradeLicense19 = _License$tradeLicense18[0]) === null || _License$tradeLicense19 === void 0 ? void 0 : (_License$tradeLicense20 = _License$tradeLicense19.tradeType) === null || _License$tradeLicense20 === void 0 ? void 0 : _License$tradeLicense20.split(".")[0]) || "NA"
43937
- }]
43938
- }, {
43939
- title: "BPA_LICENSEE_DETAILS_HEADER_OWNER_INFO",
43940
- asSectionHeader: true,
43941
- values: [{
43942
- title: "BPA_APPLICANT_NAME_LABEL",
43943
- value: (License === null || License === void 0 ? void 0 : (_License$tradeLicense21 = License.tradeLicenseDetail) === null || _License$tradeLicense21 === void 0 ? void 0 : (_License$tradeLicense22 = _License$tradeLicense21.owners) === null || _License$tradeLicense22 === void 0 ? void 0 : (_License$tradeLicense23 = _License$tradeLicense22[0]) === null || _License$tradeLicense23 === void 0 ? void 0 : _License$tradeLicense23.name) || "NA"
43944
- }, {
43945
- title: "BPA_APPLICANT_GENDER_LABEL",
43946
- value: (License === null || License === void 0 ? void 0 : (_License$tradeLicense24 = License.tradeLicenseDetail) === null || _License$tradeLicense24 === void 0 ? void 0 : (_License$tradeLicense25 = _License$tradeLicense24.owners) === null || _License$tradeLicense25 === void 0 ? void 0 : (_License$tradeLicense26 = _License$tradeLicense25[0]) === null || _License$tradeLicense26 === void 0 ? void 0 : _License$tradeLicense26.gender) || "NA"
43947
- }, {
43948
- title: "BPA_OWNER_MOBILE_NO_LABEL",
43949
- value: (License === null || License === void 0 ? void 0 : (_License$tradeLicense27 = License.tradeLicenseDetail) === null || _License$tradeLicense27 === void 0 ? void 0 : (_License$tradeLicense28 = _License$tradeLicense27.owners) === null || _License$tradeLicense28 === void 0 ? void 0 : (_License$tradeLicense29 = _License$tradeLicense28[0]) === null || _License$tradeLicense29 === void 0 ? void 0 : _License$tradeLicense29.mobileNumber) || "NA"
43950
- }, {
43951
- title: "BPA_APPLICANT_EMAIL_LABEL",
43952
- value: (License === null || License === void 0 ? void 0 : (_License$tradeLicense30 = License.tradeLicenseDetail) === null || _License$tradeLicense30 === void 0 ? void 0 : (_License$tradeLicense31 = _License$tradeLicense30.owners) === null || _License$tradeLicense31 === void 0 ? void 0 : (_License$tradeLicense32 = _License$tradeLicense31[0]) === null || _License$tradeLicense32 === void 0 ? void 0 : _License$tradeLicense32.emailId) || "NA"
43953
- }, {
43954
- title: "BPA_APPLICANT_PAN_NO",
43955
- value: (License === null || License === void 0 ? void 0 : (_License$tradeLicense33 = License.tradeLicenseDetail) === null || _License$tradeLicense33 === void 0 ? void 0 : (_License$tradeLicense34 = _License$tradeLicense33.owners) === null || _License$tradeLicense34 === void 0 ? void 0 : (_License$tradeLicense35 = _License$tradeLicense34[0]) === null || _License$tradeLicense35 === void 0 ? void 0 : _License$tradeLicense35.pan) || "NA"
43956
- }]
43957
- }, {
43958
- title: "BPA_PERMANANT_ADDRESS_LABEL",
43959
- asSectionHeader: true,
43960
- values: [{
43961
- title: "BPA_PERMANANT_ADDRESS_LABEL",
43962
- value: (License === null || License === void 0 ? void 0 : (_License$tradeLicense36 = License.tradeLicenseDetail) === null || _License$tradeLicense36 === void 0 ? void 0 : (_License$tradeLicense37 = _License$tradeLicense36.owners) === null || _License$tradeLicense37 === void 0 ? void 0 : (_License$tradeLicense38 = _License$tradeLicense37[0]) === null || _License$tradeLicense38 === void 0 ? void 0 : _License$tradeLicense38.permanentAddress) || "NA"
43963
- }]
43964
- }, {
43965
- title: "BPA_APPLICANT_CORRESPONDENCE_ADDRESS_LABEL",
43966
- asSectionHeader: true,
43967
- values: [{
43968
- title: "BPA_APPLICANT_CORRESPONDENCE_ADDRESS_LABEL",
43969
- value: (License === null || License === void 0 ? void 0 : (_License$tradeLicense39 = License.tradeLicenseDetail) === null || _License$tradeLicense39 === void 0 ? void 0 : (_License$tradeLicense40 = _License$tradeLicense39.owners) === null || _License$tradeLicense40 === void 0 ? void 0 : (_License$tradeLicense41 = _License$tradeLicense40[0]) === null || _License$tradeLicense41 === void 0 ? void 0 : _License$tradeLicense41.correspondenceAddress) || "NA"
43970
- }]
43971
- }, {
43972
- title: "BPA_DOCUMENT_DETAILS_LABEL",
43973
- asSectionHeader: true,
43974
- additionalDetails: {
43975
- documents: [{
43976
- title: "",
43977
- values: License === null || License === void 0 ? void 0 : (_License$tradeLicense42 = License.tradeLicenseDetail) === null || _License$tradeLicense42 === void 0 ? void 0 : (_License$tradeLicense43 = _License$tradeLicense42.applicationDocuments) === null || _License$tradeLicense43 === void 0 ? void 0 : _License$tradeLicense43.map(function (doc) {
43978
- var _doc$documentType;
45117
+ var appDocumentFileStoreIds = License === null || License === void 0 ? void 0 : (_License$tradeLicense44 = License.tradeLicenseDetail) === null || _License$tradeLicense44 === void 0 ? void 0 : (_License$tradeLicense45 = _License$tradeLicense44.applicationDocuments) === null || _License$tradeLicense45 === void 0 ? void 0 : _License$tradeLicense45.map(function (appDoc) {
45118
+ return appDoc === null || appDoc === void 0 ? void 0 : appDoc.fileStoreId;
45119
+ });
45120
+ var fileDetails = {};
43979
45121
 
43980
- return {
43981
- title: "BPAREG_HEADER_" + (doc === null || doc === void 0 ? void 0 : (_doc$documentType = doc.documentType) === null || _doc$documentType === void 0 ? void 0 : _doc$documentType.replaceAll('.', '_')),
43982
- documentType: doc === null || doc === void 0 ? void 0 : doc.documentType,
43983
- documentUid: doc === null || doc === void 0 ? void 0 : doc.documentUid,
43984
- fileStoreId: doc === null || doc === void 0 ? void 0 : doc.fileStoreId,
43985
- id: doc === null || doc === void 0 ? void 0 : doc.id,
43986
- docInfo: doc === null || doc === void 0 ? void 0 : doc.info
43987
- };
43988
- })
43989
- }]
45122
+ var _temp = function () {
45123
+ if ((appDocumentFileStoreIds === null || appDocumentFileStoreIds === void 0 ? void 0 : appDocumentFileStoreIds.length) > 0) {
45124
+ return Promise.resolve(UploadServices.Filefetch(appDocumentFileStoreIds, Digit.ULBService.getStateId())).then(function (_UploadServices$Filef) {
45125
+ fileDetails = _UploadServices$Filef;
45126
+ });
43990
45127
  }
43991
- }, (paymentRes === null || paymentRes === void 0 ? void 0 : (_paymentRes$Payments = paymentRes.Payments) === null || _paymentRes$Payments === void 0 ? void 0 : _paymentRes$Payments.length) > 0 && {
43992
- title: "BPA_FEE_DETAILS_LABEL",
43993
- additionalDetails: {
43994
- inspectionReport: [],
43995
- values: [{
43996
- title: "BPAREG_FEES",
43997
- value: /*#__PURE__*/React.createElement("span", null, "\u20B9", paymentRes === null || paymentRes === void 0 ? void 0 : (_paymentRes$Payments2 = paymentRes.Payments) === null || _paymentRes$Payments2 === void 0 ? void 0 : (_paymentRes$Payments3 = _paymentRes$Payments2[0]) === null || _paymentRes$Payments3 === void 0 ? void 0 : _paymentRes$Payments3.totalAmountPaid)
43998
- }, (_ref = {
43999
- title: "BPA_STATUS_LABEL",
44000
- isTransLate: true,
44001
- isStatus: true,
44002
- value: paymentRes !== null && paymentRes !== void 0 && (_paymentRes$Payments4 = paymentRes.Payments) !== null && _paymentRes$Payments4 !== void 0 && (_paymentRes$Payments5 = _paymentRes$Payments4[0]) !== null && _paymentRes$Payments5 !== void 0 && _paymentRes$Payments5.totalAmountPaid ? "WF_BPA_PAID" : "NA"
44003
- }, _ref["isTransLate"] = true, _ref)]
44004
- }
44005
- }];
44006
- return {
44007
- applicationData: License,
44008
- applicationDetails: details,
44009
- tenantId: License === null || License === void 0 ? void 0 : License.tenantId,
44010
- payments: (paymentRes === null || paymentRes === void 0 ? void 0 : paymentRes.Payments) || []
44011
- };
45128
+ }();
45129
+
45130
+ return _temp && _temp.then ? _temp.then(_temp2) : _temp2(_temp);
44012
45131
  });
44013
45132
  });
44014
45133
  });
@@ -44019,16 +45138,28 @@ var OBPSService = {
44019
45138
  BPADetailsPage: function (tenantId, filters) {
44020
45139
  try {
44021
45140
  return Promise.resolve(OBPSService.BPASearch(tenantId, filters)).then(function (response) {
44022
- var _response$BPA, _response$BPA2, _response$BPA2$, _response$BPA2$$addit, _response$BPA3, _response$BPA3$, _response$BPA3$$addit;
45141
+ var _response$BPA, _response$BPA$, _response$BPA$$docume, _response$BPA2, _response$BPA2$, _response$BPA2$$addit, _response$BPA2$$addit2, _response$BPA3, _response$BPA4, _response$BPA4$, _response$BPA4$$addit, _response$BPA5, _response$BPA5$, _response$BPA5$$addit;
45142
+
45143
+ var appDocumentFileStoreIds = response === null || response === void 0 ? void 0 : (_response$BPA = response.BPA) === null || _response$BPA === void 0 ? void 0 : (_response$BPA$ = _response$BPA[0]) === null || _response$BPA$ === void 0 ? void 0 : (_response$BPA$$docume = _response$BPA$.documents) === null || _response$BPA$$docume === void 0 ? void 0 : _response$BPA$$docume.map(function (docId) {
45144
+ return docId.fileStoreId;
45145
+ });
45146
+ if (!appDocumentFileStoreIds) appDocumentFileStoreIds = [];
45147
+ response === null || response === void 0 ? void 0 : (_response$BPA2 = response.BPA) === null || _response$BPA2 === void 0 ? void 0 : (_response$BPA2$ = _response$BPA2[0]) === null || _response$BPA2$ === void 0 ? void 0 : (_response$BPA2$$addit = _response$BPA2$.additionalDetails) === null || _response$BPA2$$addit === void 0 ? void 0 : (_response$BPA2$$addit2 = _response$BPA2$$addit.fieldinspection_pending) === null || _response$BPA2$$addit2 === void 0 ? void 0 : _response$BPA2$$addit2.map(function (fiData) {
45148
+ var _fiData$docs;
45149
+
45150
+ fiData === null || fiData === void 0 ? void 0 : (_fiData$docs = fiData.docs) === null || _fiData$docs === void 0 ? void 0 : _fiData$docs.map(function (fiDoc) {
45151
+ if (fiDoc !== null && fiDoc !== void 0 && fiDoc.fileStoreId) appDocumentFileStoreIds.push(fiDoc === null || fiDoc === void 0 ? void 0 : fiDoc.fileStoreId);
45152
+ });
45153
+ });
44023
45154
 
44024
- if (!(response !== null && response !== void 0 && (_response$BPA = response.BPA) !== null && _response$BPA !== void 0 && _response$BPA.length)) {
45155
+ if (!(response !== null && response !== void 0 && (_response$BPA3 = response.BPA) !== null && _response$BPA3 !== void 0 && _response$BPA3.length)) {
44025
45156
  return;
44026
45157
  }
44027
45158
 
44028
- sessionStorage.setItem("BPA_ARCHITECT_NAME", JSON.stringify(response !== null && response !== void 0 && (_response$BPA2 = response.BPA) !== null && _response$BPA2 !== void 0 && (_response$BPA2$ = _response$BPA2[0]) !== null && _response$BPA2$ !== void 0 && (_response$BPA2$$addit = _response$BPA2$.additionalDetails) !== null && _response$BPA2$$addit !== void 0 && _response$BPA2$$addit.typeOfArchitect ? response === null || response === void 0 ? void 0 : (_response$BPA3 = response.BPA) === null || _response$BPA3 === void 0 ? void 0 : (_response$BPA3$ = _response$BPA3[0]) === null || _response$BPA3$ === void 0 ? void 0 : (_response$BPA3$$addit = _response$BPA3$.additionalDetails) === null || _response$BPA3$$addit === void 0 ? void 0 : _response$BPA3$$addit.typeOfArchitect : "ARCHITECT"));
45159
+ sessionStorage.setItem("BPA_ARCHITECT_NAME", JSON.stringify(response !== null && response !== void 0 && (_response$BPA4 = response.BPA) !== null && _response$BPA4 !== void 0 && (_response$BPA4$ = _response$BPA4[0]) !== null && _response$BPA4$ !== void 0 && (_response$BPA4$$addit = _response$BPA4$.additionalDetails) !== null && _response$BPA4$$addit !== void 0 && _response$BPA4$$addit.typeOfArchitect ? response === null || response === void 0 ? void 0 : (_response$BPA5 = response.BPA) === null || _response$BPA5 === void 0 ? void 0 : (_response$BPA5$ = _response$BPA5[0]) === null || _response$BPA5$ === void 0 ? void 0 : (_response$BPA5$$addit = _response$BPA5$.additionalDetails) === null || _response$BPA5$$addit === void 0 ? void 0 : _response$BPA5$$addit.typeOfArchitect : "ARCHITECT"));
44029
45160
 
44030
- var _response$BPA4 = response === null || response === void 0 ? void 0 : response.BPA,
44031
- BPA = _response$BPA4[0];
45161
+ var _response$BPA6 = response === null || response === void 0 ? void 0 : response.BPA,
45162
+ BPA = _response$BPA6[0];
44032
45163
 
44033
45164
  return Promise.resolve(OBPSService.scrutinyDetails(BPA === null || BPA === void 0 ? void 0 : BPA.tenantId, {
44034
45165
  edcrNumber: BPA === null || BPA === void 0 ? void 0 : BPA.edcrNumber
@@ -44055,491 +45186,525 @@ var OBPSService = {
44055
45186
  ocdcrNumber: BPA !== null && BPA !== void 0 && BPA.edcrNumber.includes("OCDCR") ? BPA === null || BPA === void 0 ? void 0 : BPA.edcrNumber : bpaResponse === null || bpaResponse === void 0 ? void 0 : (_bpaResponse$BPA = bpaResponse.BPA) === null || _bpaResponse$BPA === void 0 ? void 0 : (_bpaResponse$BPA$ = _bpaResponse$BPA[0]) === null || _bpaResponse$BPA$ === void 0 ? void 0 : _bpaResponse$BPA$.edcrNumber,
44056
45187
  edcrNumber: bpaResponse !== null && bpaResponse !== void 0 && (_bpaResponse$BPA2 = bpaResponse.BPA) !== null && _bpaResponse$BPA2 !== void 0 && (_bpaResponse$BPA2$ = _bpaResponse$BPA2[0]) !== null && _bpaResponse$BPA2$ !== void 0 && _bpaResponse$BPA2$.edcrNumber.includes("OCDCR") ? BPA === null || BPA === void 0 ? void 0 : BPA.edcrNumber : bpaResponse === null || bpaResponse === void 0 ? void 0 : (_bpaResponse$BPA3 = bpaResponse.BPA) === null || _bpaResponse$BPA3 === void 0 ? void 0 : (_bpaResponse$BPA3$ = _bpaResponse$BPA3[0]) === null || _bpaResponse$BPA3$ === void 0 ? void 0 : _bpaResponse$BPA3$.edcrNumber
44057
45188
  };
45189
+ return Promise.resolve(OBPSService.comparisionReport(BPA === null || BPA === void 0 ? void 0 : BPA.tenantId, _extends({}, comparisionRep))).then(function (comparisionReport) {
45190
+ function _temp4() {
45191
+ var _BPA$additionalDetail, _BPA$additionalDetail2, _BPA$additionalDetail3, _BPA$additionalDetail4, _BPA$additionalDetail5, _BPA$additionalDetail6, _BPA$additionalDetail7, _permitcondn, _permitcondn2, _BPA$auditDetails, _BPA$auditDetails2, _edcr$planDetail3, _edcr$planDetail3$pla, _edcr$planDetail4, _edcr$planDetail4$pla, _edcr$planDetail5, _edcr$planDetail5$pla, _edcr$planDetail6, _edcr$planDetail6$pla, _edcr$planDetail7, _edcr$planDetail7$pla, _BPA$additionalDetail11, _BPA$additionalDetail12, _edcr$planDetail8, _edcr$planDetail8$blo, _edcr$planDetail8$blo2, _edcr$planDetail8$blo3, _edcr$planDetail9, _edcr$planDetail9$blo, _edcr$planDetail9$blo2, _edcr$planDetail9$blo3, _edcr$planDetail10, _edcr$planDetail10$bl, _edcr$planDetail10$bl2, _edcr$planDetail10$bl3, _edcr$planDetail11, _edcr$planDetail11$pl, _BPA$landInfo, _BPA$landInfo$address, _BPA$landInfo2, _BPA$landInfo2$addres, _BPA$landInfo3, _BPA$landInfo3$addres, _BPA$landInfo3$addres2, _BPA$landInfo4, _BPA$landInfo4$addres, _BPA$landInfo5, _BPA$landInfo5$addres, _BPA$landInfo6, _BPA$landInfo6$owners, _BPA$landInfo7, _BPA$landInfo7$owners, _BPA$landInfo9, _BPA$landInfo9$owners, _BPA$documents, _BPA$additionalDetail13, _BPA$additionalDetail14, _BPA$additionalDetail15, _BPA$additionalDetail16, _BPA$additionalDetail17, _BPA$additionalDetail18, _BPA$additionalDetail19, _details;
44058
45192
 
44059
- function ConvertEpochToValidityDate(dateEpoch) {
44060
- if (dateEpoch == null || dateEpoch == undefined || dateEpoch == '') {
44061
- return "NA";
44062
- }
45193
+ function ConvertEpochToValidityDate(dateEpoch) {
45194
+ if (dateEpoch == null || dateEpoch == undefined || dateEpoch == '') {
45195
+ return "NA";
45196
+ }
44063
45197
 
44064
- var dateFromApi = new Date(dateEpoch);
44065
- var month = dateFromApi.getMonth() + 1;
44066
- var day = dateFromApi.getDate();
44067
- var year = dateFromApi.getFullYear() - 3;
44068
- month = (month > 9 ? "" : "0") + month;
44069
- day = (day > 9 ? "" : "0") + day;
44070
- return day + "/" + month + "/" + year;
44071
- }
45198
+ var dateFromApi = new Date(dateEpoch);
45199
+ var month = dateFromApi.getMonth() + 1;
45200
+ var day = dateFromApi.getDate();
45201
+ var year = dateFromApi.getFullYear() - 3;
45202
+ month = (month > 9 ? "" : "0") + month;
45203
+ day = (day > 9 ? "" : "0") + day;
45204
+ return day + "/" + month + "/" + year;
45205
+ }
44072
45206
 
44073
- return Promise.resolve(OBPSService.comparisionReport(BPA === null || BPA === void 0 ? void 0 : BPA.tenantId, _extends({}, comparisionRep))).then(function (comparisionReport) {
44074
- var _BPA$additionalDetail, _BPA$additionalDetail2, _BPA$additionalDetail3, _BPA$additionalDetail4, _BPA$additionalDetail5, _permitcondn, _permitcondn2, _BPA$auditDetails, _BPA$auditDetails2, _edcr$planDetail3, _edcr$planDetail3$pla, _edcr$planDetail4, _edcr$planDetail4$pla, _edcr$planDetail5, _edcr$planDetail5$pla, _edcr$planDetail6, _edcr$planDetail6$pla, _edcr$planDetail7, _edcr$planDetail7$pla, _BPA$additionalDetail9, _BPA$additionalDetail10, _edcr$planDetail8, _edcr$planDetail8$blo, _edcr$planDetail8$blo2, _edcr$planDetail8$blo3, _edcr$planDetail9, _edcr$planDetail9$blo, _edcr$planDetail9$blo2, _edcr$planDetail9$blo3, _edcr$planDetail10, _edcr$planDetail10$bl, _edcr$planDetail10$bl2, _edcr$planDetail10$bl3, _edcr$planDetail11, _edcr$planDetail11$pl, _BPA$landInfo, _BPA$landInfo$address, _BPA$landInfo2, _BPA$landInfo2$addres, _BPA$landInfo3, _BPA$landInfo3$addres, _BPA$landInfo3$addres2, _BPA$landInfo4, _BPA$landInfo4$addres, _BPA$landInfo5, _BPA$landInfo5$addres, _BPA$landInfo6, _BPA$landInfo6$owners, _BPA$landInfo7, _BPA$landInfo7$owners, _BPA$landInfo9, _BPA$landInfo9$owners, _BPA$documents, _BPA$additionalDetail11, _BPA$additionalDetail12, _BPA$additionalDetail13, _BPA$additionalDetail14, _BPA$additionalDetail15, _BPA$additionalDetail16, _BPA$additionalDetail17, _details;
45207
+ BPA === null || BPA === void 0 ? void 0 : (_BPA$additionalDetail = BPA.additionalDetails) === null || _BPA$additionalDetail === void 0 ? void 0 : (_BPA$additionalDetail2 = _BPA$additionalDetail.fieldinspection_pending) === null || _BPA$additionalDetail2 === void 0 ? void 0 : _BPA$additionalDetail2.forEach(function (fiData) {
45208
+ var _fiData$docs2;
44075
45209
 
44076
- var nocDetails = noc === null || noc === void 0 ? void 0 : noc.map(function (nocDetails, index) {
44077
- var _nocDetails$additiona, _nocDetails$additiona2, _nocDetails$additiona3, _nocDetails$auditDeta, _nocDetails$documents;
45210
+ fiData === null || fiData === void 0 ? void 0 : (_fiData$docs2 = fiData.docs) === null || _fiData$docs2 === void 0 ? void 0 : _fiData$docs2.forEach(function (fiDoc) {
45211
+ var _fileDetails3, _fileDetails4, _fileDetails4$data$fi;
44078
45212
 
44079
- return {
44080
- title: index === 0 ? "BPA_NOC_DETAILS_SUMMARY" : "",
44081
- values: [{
44082
- title: "BPA_" + (nocDetails === null || nocDetails === void 0 ? void 0 : nocDetails.nocType) + "_LABEL",
44083
- value: nocDetails === null || nocDetails === void 0 ? void 0 : nocDetails.applicationNo,
44084
- isNotTranslated: true
44085
- }, {
44086
- title: "BPA_NOC_STATUS",
44087
- value: nocDetails === null || nocDetails === void 0 ? void 0 : nocDetails.applicationStatus,
44088
- field: "STATUS"
44089
- }, (nocDetails === null || nocDetails === void 0 ? void 0 : (_nocDetails$additiona = nocDetails.additionalDetails) === null || _nocDetails$additiona === void 0 ? void 0 : _nocDetails$additiona.SubmittedOn) && {
44090
- title: "BPA_SUDMITTED_ON_LABEL",
44091
- value: nocDetails !== null && nocDetails !== void 0 && (_nocDetails$additiona2 = nocDetails.additionalDetails) !== null && _nocDetails$additiona2 !== void 0 && _nocDetails$additiona2.SubmittedOn ? format(new Date(Number(nocDetails === null || nocDetails === void 0 ? void 0 : (_nocDetails$additiona3 = nocDetails.additionalDetails) === null || _nocDetails$additiona3 === void 0 ? void 0 : _nocDetails$additiona3.SubmittedOn)), 'dd/MM/yyyy') : "NA",
44092
- isNotTranslated: true
44093
- }, (nocDetails === null || nocDetails === void 0 ? void 0 : nocDetails.nocNo) && {
44094
- title: "BPA_APPROVAL_NUMBER_LABEL",
44095
- value: (nocDetails === null || nocDetails === void 0 ? void 0 : nocDetails.nocNo) || "NA",
44096
- isNotTranslated: true
44097
- }, (nocDetails === null || nocDetails === void 0 ? void 0 : nocDetails.nocNo) && {
44098
- title: "BPA_APPROVED_REJECTED_ON_LABEL",
44099
- value: (nocDetails === null || nocDetails === void 0 ? void 0 : nocDetails.applicationStatus) === "APPROVED" || (nocDetails === null || nocDetails === void 0 ? void 0 : nocDetails.applicationStatus) === "REJECTED" || (nocDetails === null || nocDetails === void 0 ? void 0 : nocDetails.applicationStatus) === "AUTO_APPROVED" || (nocDetails === null || nocDetails === void 0 ? void 0 : nocDetails.applicationStatus) === "AUTO_REJECTED" ? format(new Date(Number(nocDetails === null || nocDetails === void 0 ? void 0 : (_nocDetails$auditDeta = nocDetails.auditDetails) === null || _nocDetails$auditDeta === void 0 ? void 0 : _nocDetails$auditDeta.lastModifiedTime)), 'dd/MM/yyyy') : "NA",
44100
- isNotTranslated: true
44101
- }],
44102
- additionalDetails: {
44103
- data: nocDetails,
44104
- noc: [{
44105
- title: "BPA_DOCUMENT_DETAILS_LABEL",
44106
- values: nocDetails === null || nocDetails === void 0 ? void 0 : (_nocDetails$documents = nocDetails.documents) === null || _nocDetails$documents === void 0 ? void 0 : _nocDetails$documents.map(function (doc) {
44107
- var _doc$documentType2;
44108
-
44109
- return {
44110
- title: doc === null || doc === void 0 ? void 0 : (_doc$documentType2 = doc.documentType) === null || _doc$documentType2 === void 0 ? void 0 : _doc$documentType2.replaceAll('.', '_'),
44111
- documentType: doc === null || doc === void 0 ? void 0 : doc.documentType,
44112
- documentUid: doc === null || doc === void 0 ? void 0 : doc.documentUid,
44113
- fileStoreId: doc === null || doc === void 0 ? void 0 : doc.fileStoreId,
44114
- id: doc === null || doc === void 0 ? void 0 : doc.id
44115
- };
44116
- })
44117
- }]
44118
- }
44119
- };
44120
- });
44121
- var inspectionReport = [];
44122
- var checklist = [];
44123
- BPA === null || BPA === void 0 ? void 0 : (_BPA$additionalDetail = BPA.additionalDetails) === null || _BPA$additionalDetail === void 0 ? void 0 : (_BPA$additionalDetail2 = _BPA$additionalDetail.fieldinspection_pending) === null || _BPA$additionalDetail2 === void 0 ? void 0 : _BPA$additionalDetail2.filter(function (ob) {
44124
- return ob.docs && ob.docs.length > 0;
44125
- }).map(function (ob, ind) {
44126
- var _ob$date, _ob$date2, _ob$date3, _ob$questions, _ob$docs;
44127
-
44128
- checklist = [];
44129
- inspectionReport.push({
44130
- title: "BPA_FI_REPORT",
44131
- asSectionHeader: true,
44132
- values: [{
44133
- title: "BPA_FI_DATE_LABEL",
44134
- value: ob.date.includes("-") ? ((_ob$date = ob.date) === null || _ob$date === void 0 ? void 0 : _ob$date.split("-")[2]) + "/" + ((_ob$date2 = ob.date) === null || _ob$date2 === void 0 ? void 0 : _ob$date2.split("-")[1]) + "/" + ((_ob$date3 = ob.date) === null || _ob$date3 === void 0 ? void 0 : _ob$date3.split("-")[0]) : ob.date
44135
- }, {
44136
- title: "BPA_FI_TIME_LABEL",
44137
- value: ob.time
44138
- }]
44139
- });
44140
- ob === null || ob === void 0 ? void 0 : (_ob$questions = ob.questions) === null || _ob$questions === void 0 ? void 0 : _ob$questions.map(function (q, index) {
44141
- checklist.push({
44142
- title: q.question,
44143
- value: q.value
44144
- });
44145
- checklist.push({
44146
- title: "BPA_ENTER_REMARKS",
44147
- value: q.remarks
45213
+ if ((_fileDetails3 = fileDetails) !== null && _fileDetails3 !== void 0 && _fileDetails3.data[fiDoc === null || fiDoc === void 0 ? void 0 : fiDoc.fileStoreId]) fiDoc.url = (_fileDetails4 = fileDetails) === null || _fileDetails4 === void 0 ? void 0 : (_fileDetails4$data$fi = _fileDetails4.data[fiDoc === null || fiDoc === void 0 ? void 0 : fiDoc.fileStoreId]) === null || _fileDetails4$data$fi === void 0 ? void 0 : _fileDetails4$data$fi.split(',')[0];
44148
45214
  });
44149
45215
  });
44150
- inspectionReport.push({
44151
- title: "BPA_CHECK_LIST_DETAILS",
44152
- asSectionHeader: true,
44153
- values: checklist
45216
+ var nocDetails = noc === null || noc === void 0 ? void 0 : noc.map(function (nocDetails, index) {
45217
+ var _nocDetails$additiona, _nocDetails$additiona2, _nocDetails$additiona3, _nocDetails$auditDeta, _nocDetails$documents;
45218
+
45219
+ return {
45220
+ title: index === 0 ? "BPA_NOC_DETAILS_SUMMARY" : "",
45221
+ values: [{
45222
+ title: "BPA_" + (nocDetails === null || nocDetails === void 0 ? void 0 : nocDetails.nocType) + "_LABEL",
45223
+ value: nocDetails === null || nocDetails === void 0 ? void 0 : nocDetails.applicationNo,
45224
+ isNotTranslated: true
45225
+ }, {
45226
+ title: "BPA_NOC_STATUS",
45227
+ value: nocDetails === null || nocDetails === void 0 ? void 0 : nocDetails.applicationStatus,
45228
+ field: "STATUS"
45229
+ }, (nocDetails === null || nocDetails === void 0 ? void 0 : (_nocDetails$additiona = nocDetails.additionalDetails) === null || _nocDetails$additiona === void 0 ? void 0 : _nocDetails$additiona.SubmittedOn) && {
45230
+ title: "BPA_SUDMITTED_ON_LABEL",
45231
+ value: nocDetails !== null && nocDetails !== void 0 && (_nocDetails$additiona2 = nocDetails.additionalDetails) !== null && _nocDetails$additiona2 !== void 0 && _nocDetails$additiona2.SubmittedOn ? format(new Date(Number(nocDetails === null || nocDetails === void 0 ? void 0 : (_nocDetails$additiona3 = nocDetails.additionalDetails) === null || _nocDetails$additiona3 === void 0 ? void 0 : _nocDetails$additiona3.SubmittedOn)), 'dd/MM/yyyy') : "NA",
45232
+ isNotTranslated: true
45233
+ }, (nocDetails === null || nocDetails === void 0 ? void 0 : nocDetails.nocNo) && {
45234
+ title: "BPA_APPROVAL_NUMBER_LABEL",
45235
+ value: (nocDetails === null || nocDetails === void 0 ? void 0 : nocDetails.nocNo) || "NA",
45236
+ isNotTranslated: true
45237
+ }, (nocDetails === null || nocDetails === void 0 ? void 0 : nocDetails.nocNo) && {
45238
+ title: "BPA_APPROVED_REJECTED_ON_LABEL",
45239
+ value: (nocDetails === null || nocDetails === void 0 ? void 0 : nocDetails.applicationStatus) === "APPROVED" || (nocDetails === null || nocDetails === void 0 ? void 0 : nocDetails.applicationStatus) === "REJECTED" || (nocDetails === null || nocDetails === void 0 ? void 0 : nocDetails.applicationStatus) === "AUTO_APPROVED" || (nocDetails === null || nocDetails === void 0 ? void 0 : nocDetails.applicationStatus) === "AUTO_REJECTED" ? format(new Date(Number(nocDetails === null || nocDetails === void 0 ? void 0 : (_nocDetails$auditDeta = nocDetails.auditDetails) === null || _nocDetails$auditDeta === void 0 ? void 0 : _nocDetails$auditDeta.lastModifiedTime)), 'dd/MM/yyyy') : "NA",
45240
+ isNotTranslated: true
45241
+ }],
45242
+ additionalDetails: {
45243
+ data: nocDetails,
45244
+ noc: [{
45245
+ title: "BPA_DOCUMENT_DETAILS_LABEL",
45246
+ values: nocDetails === null || nocDetails === void 0 ? void 0 : (_nocDetails$documents = nocDetails.documents) === null || _nocDetails$documents === void 0 ? void 0 : _nocDetails$documents.map(function (doc) {
45247
+ var _doc$documentType2, _fileDetails5, _fileDetails5$data, _fileDetails6, _fileDetails6$data, _fileDetails6$data$do;
45248
+
45249
+ return {
45250
+ title: doc === null || doc === void 0 ? void 0 : (_doc$documentType2 = doc.documentType) === null || _doc$documentType2 === void 0 ? void 0 : _doc$documentType2.replaceAll('.', '_'),
45251
+ documentType: doc === null || doc === void 0 ? void 0 : doc.documentType,
45252
+ documentUid: doc === null || doc === void 0 ? void 0 : doc.documentUid,
45253
+ fileStoreId: doc === null || doc === void 0 ? void 0 : doc.fileStoreId,
45254
+ id: doc === null || doc === void 0 ? void 0 : doc.id,
45255
+ url: (_fileDetails5 = fileDetails) !== null && _fileDetails5 !== void 0 && (_fileDetails5$data = _fileDetails5.data) !== null && _fileDetails5$data !== void 0 && _fileDetails5$data[doc === null || doc === void 0 ? void 0 : doc.fileStoreId] ? (_fileDetails6 = fileDetails) === null || _fileDetails6 === void 0 ? void 0 : (_fileDetails6$data = _fileDetails6.data) === null || _fileDetails6$data === void 0 ? void 0 : (_fileDetails6$data$do = _fileDetails6$data[doc === null || doc === void 0 ? void 0 : doc.fileStoreId]) === null || _fileDetails6$data$do === void 0 ? void 0 : _fileDetails6$data$do.split(',')[0] : ""
45256
+ };
45257
+ })
45258
+ }]
45259
+ }
45260
+ };
44154
45261
  });
44155
- inspectionReport.push({
44156
- title: "BPA_DOCUMENT_DETAILS_LABEL",
44157
- asSectionHeader: true,
44158
- additionalDetails: {
44159
- obpsDocuments: [{
44160
- title: "",
44161
- values: ob === null || ob === void 0 ? void 0 : (_ob$docs = ob.docs) === null || _ob$docs === void 0 ? void 0 : _ob$docs.map(function (doc) {
44162
- var _doc$documentType3;
44163
-
44164
- return {
44165
- title: doc === null || doc === void 0 ? void 0 : (_doc$documentType3 = doc.documentType) === null || _doc$documentType3 === void 0 ? void 0 : _doc$documentType3.replaceAll('.', '_'),
44166
- documentType: doc === null || doc === void 0 ? void 0 : doc.documentType,
44167
- documentUid: doc === null || doc === void 0 ? void 0 : doc.fileStore,
44168
- fileStoreId: doc === null || doc === void 0 ? void 0 : doc.fileStoreId,
44169
- id: doc === null || doc === void 0 ? void 0 : doc.id
44170
- };
44171
- })
45262
+ var inspectionReport = [];
45263
+ var checklist = [];
45264
+ BPA === null || BPA === void 0 ? void 0 : (_BPA$additionalDetail3 = BPA.additionalDetails) === null || _BPA$additionalDetail3 === void 0 ? void 0 : (_BPA$additionalDetail4 = _BPA$additionalDetail3.fieldinspection_pending) === null || _BPA$additionalDetail4 === void 0 ? void 0 : _BPA$additionalDetail4.filter(function (ob) {
45265
+ return ob.docs && ob.docs.length > 0;
45266
+ }).map(function (ob, ind) {
45267
+ var _ob$date, _ob$date2, _ob$date3, _ob$questions, _ob$docs;
45268
+
45269
+ checklist = [];
45270
+ inspectionReport.push({
45271
+ title: "BPA_FI_REPORT",
45272
+ asSectionHeader: true,
45273
+ values: [{
45274
+ title: "BPA_FI_DATE_LABEL",
45275
+ value: ob.date.includes("-") ? ((_ob$date = ob.date) === null || _ob$date === void 0 ? void 0 : _ob$date.split("-")[2]) + "/" + ((_ob$date2 = ob.date) === null || _ob$date2 === void 0 ? void 0 : _ob$date2.split("-")[1]) + "/" + ((_ob$date3 = ob.date) === null || _ob$date3 === void 0 ? void 0 : _ob$date3.split("-")[0]) : ob.date
45276
+ }, {
45277
+ title: "BPA_FI_TIME_LABEL",
45278
+ value: ob.time
44172
45279
  }]
44173
- }
45280
+ });
45281
+ ob === null || ob === void 0 ? void 0 : (_ob$questions = ob.questions) === null || _ob$questions === void 0 ? void 0 : _ob$questions.map(function (q, index) {
45282
+ checklist.push({
45283
+ title: q.question,
45284
+ value: q.value
45285
+ });
45286
+ checklist.push({
45287
+ title: "BPA_ENTER_REMARKS",
45288
+ value: q.remarks
45289
+ });
45290
+ });
45291
+ inspectionReport.push({
45292
+ title: "BPA_CHECK_LIST_DETAILS",
45293
+ asSectionHeader: true,
45294
+ values: checklist
45295
+ });
45296
+ inspectionReport.push({
45297
+ title: "BPA_DOCUMENT_DETAILS_LABEL",
45298
+ asSectionHeader: true,
45299
+ additionalDetails: {
45300
+ obpsDocuments: [{
45301
+ title: "",
45302
+ values: ob === null || ob === void 0 ? void 0 : (_ob$docs = ob.docs) === null || _ob$docs === void 0 ? void 0 : _ob$docs.map(function (doc) {
45303
+ var _doc$documentType3, _fileDetails7, _fileDetails7$data, _fileDetails8, _fileDetails8$data, _fileDetails8$data$do;
45304
+
45305
+ return {
45306
+ title: doc === null || doc === void 0 ? void 0 : (_doc$documentType3 = doc.documentType) === null || _doc$documentType3 === void 0 ? void 0 : _doc$documentType3.replaceAll('.', '_'),
45307
+ documentType: doc === null || doc === void 0 ? void 0 : doc.documentType,
45308
+ documentUid: doc === null || doc === void 0 ? void 0 : doc.fileStore,
45309
+ fileStoreId: doc === null || doc === void 0 ? void 0 : doc.fileStoreId,
45310
+ id: doc === null || doc === void 0 ? void 0 : doc.id,
45311
+ url: (_fileDetails7 = fileDetails) !== null && _fileDetails7 !== void 0 && (_fileDetails7$data = _fileDetails7.data) !== null && _fileDetails7$data !== void 0 && _fileDetails7$data[doc === null || doc === void 0 ? void 0 : doc.fileStoreId] ? (_fileDetails8 = fileDetails) === null || _fileDetails8 === void 0 ? void 0 : (_fileDetails8$data = _fileDetails8.data) === null || _fileDetails8$data === void 0 ? void 0 : (_fileDetails8$data$do = _fileDetails8$data[doc === null || doc === void 0 ? void 0 : doc.fileStoreId]) === null || _fileDetails8$data$do === void 0 ? void 0 : _fileDetails8$data$do.split(',')[0] : ""
45312
+ };
45313
+ })
45314
+ }]
45315
+ }
45316
+ });
44174
45317
  });
44175
- });
44176
- var details = [];
44177
- var applicationDetailsInfo = {
44178
- title: " ",
44179
- isCommon: true,
44180
- values: [{
44181
- title: "BPA_APPLICATION_NUMBER_LABEL",
44182
- value: (BPA === null || BPA === void 0 ? void 0 : BPA.applicationNo) || "NA"
44183
- }]
44184
- };
44185
-
44186
- if (BPA !== null && BPA !== void 0 && BPA.businessService.includes("BPA_OC")) {
44187
- var _bpaResponse$BPA4, _bpaResponse$BPA4$, _bpaResponse$BPA5, _bpaResponse$BPA5$;
45318
+ var details = [];
45319
+ var applicationDetailsInfo = {
45320
+ title: " ",
45321
+ isCommon: true,
45322
+ values: [{
45323
+ title: "BPA_APPLICATION_NUMBER_LABEL",
45324
+ value: (BPA === null || BPA === void 0 ? void 0 : BPA.applicationNo) || "NA"
45325
+ }]
45326
+ };
44188
45327
 
44189
- applicationDetailsInfo["values"] = [].concat(applicationDetailsInfo === null || applicationDetailsInfo === void 0 ? void 0 : applicationDetailsInfo.values, [{
44190
- title: "BPA_PERMIT_APP_NUMBER",
44191
- to: "/digit-ui/employee/obps/bpa/" + (bpaResponse === null || bpaResponse === void 0 ? void 0 : (_bpaResponse$BPA4 = bpaResponse.BPA) === null || _bpaResponse$BPA4 === void 0 ? void 0 : (_bpaResponse$BPA4$ = _bpaResponse$BPA4[0]) === null || _bpaResponse$BPA4$ === void 0 ? void 0 : _bpaResponse$BPA4$.applicationNo),
44192
- value: bpaResponse === null || bpaResponse === void 0 ? void 0 : (_bpaResponse$BPA5 = bpaResponse.BPA) === null || _bpaResponse$BPA5 === void 0 ? void 0 : (_bpaResponse$BPA5$ = _bpaResponse$BPA5[0]) === null || _bpaResponse$BPA5$ === void 0 ? void 0 : _bpaResponse$BPA5$.applicationNo,
44193
- isLink: true
44194
- }]);
44195
- }
45328
+ if (BPA !== null && BPA !== void 0 && BPA.businessService.includes("BPA_OC")) {
45329
+ var _bpaResponse$BPA4, _bpaResponse$BPA4$, _bpaResponse$BPA5, _bpaResponse$BPA5$;
44196
45330
 
44197
- var permitcondn = [];
44198
- (BPA === null || BPA === void 0 ? void 0 : (_BPA$additionalDetail3 = BPA.additionalDetails) === null || _BPA$additionalDetail3 === void 0 ? void 0 : _BPA$additionalDetail3.pendingapproval) && (BPA === null || BPA === void 0 ? void 0 : (_BPA$additionalDetail4 = BPA.additionalDetails) === null || _BPA$additionalDetail4 === void 0 ? void 0 : _BPA$additionalDetail4.pendingapproval.length) > 0 && (BPA === null || BPA === void 0 ? void 0 : (_BPA$additionalDetail5 = BPA.additionalDetails) === null || _BPA$additionalDetail5 === void 0 ? void 0 : _BPA$additionalDetail5.pendingapproval.map(function (ob, index) {
44199
- permitcondn.push({
44200
- title: index + 1 + ". " + ob,
44201
- value: ""
44202
- });
44203
- }));
44204
- var PermitConditions = {
44205
- title: "BPA_PERMIT_CONDITIONS",
44206
- isTitleVisible: ((_permitcondn = permitcondn) === null || _permitcondn === void 0 ? void 0 : _permitcondn.length) > 0 ? false : true,
44207
- isNotAllowed: ((_permitcondn2 = permitcondn) === null || _permitcondn2 === void 0 ? void 0 : _permitcondn2.length) > 0 ? false : true,
44208
- additionalDetails: {
44209
- inspectionReport: [],
44210
- permit: [].concat(permitcondn)
45331
+ applicationDetailsInfo["values"] = [].concat(applicationDetailsInfo === null || applicationDetailsInfo === void 0 ? void 0 : applicationDetailsInfo.values, [{
45332
+ title: "BPA_PERMIT_APP_NUMBER",
45333
+ to: "/digit-ui/employee/obps/bpa/" + (bpaResponse === null || bpaResponse === void 0 ? void 0 : (_bpaResponse$BPA4 = bpaResponse.BPA) === null || _bpaResponse$BPA4 === void 0 ? void 0 : (_bpaResponse$BPA4$ = _bpaResponse$BPA4[0]) === null || _bpaResponse$BPA4$ === void 0 ? void 0 : _bpaResponse$BPA4$.applicationNo),
45334
+ value: bpaResponse === null || bpaResponse === void 0 ? void 0 : (_bpaResponse$BPA5 = bpaResponse.BPA) === null || _bpaResponse$BPA5 === void 0 ? void 0 : (_bpaResponse$BPA5$ = _bpaResponse$BPA5[0]) === null || _bpaResponse$BPA5$ === void 0 ? void 0 : _bpaResponse$BPA5$.applicationNo,
45335
+ isLink: true
45336
+ }]);
44211
45337
  }
44212
- };
44213
- if (permitcondn.length == 0) PermitConditions = {};
44214
45338
 
44215
- if (riskType == "LOW" && permitcondn.length > 0) {
44216
- permitcondn = [];
44217
- PermitConditions = {};
44218
- }
45339
+ var permitcondn = [];
45340
+ (BPA === null || BPA === void 0 ? void 0 : (_BPA$additionalDetail5 = BPA.additionalDetails) === null || _BPA$additionalDetail5 === void 0 ? void 0 : _BPA$additionalDetail5.pendingapproval) && (BPA === null || BPA === void 0 ? void 0 : (_BPA$additionalDetail6 = BPA.additionalDetails) === null || _BPA$additionalDetail6 === void 0 ? void 0 : _BPA$additionalDetail6.pendingapproval.length) > 0 && (BPA === null || BPA === void 0 ? void 0 : (_BPA$additionalDetail7 = BPA.additionalDetails) === null || _BPA$additionalDetail7 === void 0 ? void 0 : _BPA$additionalDetail7.pendingapproval.map(function (ob, index) {
45341
+ permitcondn.push({
45342
+ title: index + 1 + ". " + ob,
45343
+ value: ""
45344
+ });
45345
+ }));
45346
+ var PermitConditions = {
45347
+ title: "BPA_PERMIT_CONDITIONS",
45348
+ isTitleVisible: ((_permitcondn = permitcondn) === null || _permitcondn === void 0 ? void 0 : _permitcondn.length) > 0 ? false : true,
45349
+ isNotAllowed: ((_permitcondn2 = permitcondn) === null || _permitcondn2 === void 0 ? void 0 : _permitcondn2.length) > 0 ? false : true,
45350
+ additionalDetails: {
45351
+ inspectionReport: [],
45352
+ permit: [].concat(permitcondn)
45353
+ }
45354
+ };
45355
+ if (permitcondn.length == 0) PermitConditions = {};
44219
45356
 
44220
- if (BPA !== null && BPA !== void 0 && BPA.approvalNo) {
44221
- var _applicationDetailsIn, _applicationDetailsIn2, _BPA$additionalDetail6, _BPA$additionalDetail7, _BPA$additionalDetail8;
45357
+ if (riskType == "LOW" && permitcondn.length > 0) {
45358
+ permitcondn = [];
45359
+ PermitConditions = {};
45360
+ }
44222
45361
 
44223
- applicationDetailsInfo === null || applicationDetailsInfo === void 0 ? void 0 : (_applicationDetailsIn = applicationDetailsInfo.values) === null || _applicationDetailsIn === void 0 ? void 0 : _applicationDetailsIn.push({
44224
- title: (BPA === null || BPA === void 0 ? void 0 : BPA.businessService) !== "BPA_OC" ? "BPA_PERMIT_NUMBER_LABEL" : "BPA_OC_PERMIT_NUMBER_LABEL",
44225
- value: (BPA === null || BPA === void 0 ? void 0 : BPA.approvalNo) || "NA"
44226
- });
44227
- applicationDetailsInfo === null || applicationDetailsInfo === void 0 ? void 0 : (_applicationDetailsIn2 = applicationDetailsInfo.values) === null || _applicationDetailsIn2 === void 0 ? void 0 : _applicationDetailsIn2.push({
44228
- title: (BPA === null || BPA === void 0 ? void 0 : BPA.businessService) !== "BPA_OC" ? "BPA_PERMIT_VALIDITY" : "BPA_OC_PERMIT_VALIDITY",
44229
- value: BPA !== null && BPA !== void 0 && (_BPA$additionalDetail6 = BPA.additionalDetails) !== null && _BPA$additionalDetail6 !== void 0 && _BPA$additionalDetail6.validityDate ? ConvertEpochToValidityDate(BPA === null || BPA === void 0 ? void 0 : (_BPA$additionalDetail7 = BPA.additionalDetails) === null || _BPA$additionalDetail7 === void 0 ? void 0 : _BPA$additionalDetail7.validityDate) + " - " + format(new Date(BPA === null || BPA === void 0 ? void 0 : (_BPA$additionalDetail8 = BPA.additionalDetails) === null || _BPA$additionalDetail8 === void 0 ? void 0 : _BPA$additionalDetail8.validityDate), 'dd/MM/yyyy') : "NA"
44230
- });
44231
- }
45362
+ if (BPA !== null && BPA !== void 0 && BPA.approvalNo) {
45363
+ var _applicationDetailsIn, _applicationDetailsIn2, _BPA$additionalDetail8, _BPA$additionalDetail9, _BPA$additionalDetail10;
44232
45364
 
44233
- var basicDetails = {
44234
- title: "BPA_BASIC_DETAILS_TITLE",
44235
- asSectionHeader: true,
44236
- isInsert: true,
44237
- isCommon: true,
44238
- values: [{
44239
- title: "BPA_BASIC_DETAILS_APP_DATE_LABEL",
44240
- value: BPA !== null && BPA !== void 0 && (_BPA$auditDetails = BPA.auditDetails) !== null && _BPA$auditDetails !== void 0 && _BPA$auditDetails.createdTime ? format(new Date(BPA === null || BPA === void 0 ? void 0 : (_BPA$auditDetails2 = BPA.auditDetails) === null || _BPA$auditDetails2 === void 0 ? void 0 : _BPA$auditDetails2.createdTime), 'dd/MM/yyyy') : ''
44241
- }, {
44242
- title: "BPA_BASIC_DETAILS_APPLICATION_TYPE_LABEL",
44243
- value: "WF_BPA_" + (edcr === null || edcr === void 0 ? void 0 : edcr.appliactionType)
44244
- }, {
44245
- title: "BPA_BASIC_DETAILS_SERVICE_TYPE_LABEL",
44246
- value: edcr === null || edcr === void 0 ? void 0 : edcr.applicationSubType
44247
- }, {
44248
- title: "BPA_BASIC_DETAILS_OCCUPANCY_LABEL",
44249
- value: edcr === null || edcr === void 0 ? void 0 : (_edcr$planDetail3 = edcr.planDetail) === null || _edcr$planDetail3 === void 0 ? void 0 : (_edcr$planDetail3$pla = _edcr$planDetail3.planInformation) === null || _edcr$planDetail3$pla === void 0 ? void 0 : _edcr$planDetail3$pla.occupancy
44250
- }, {
44251
- title: "BPA_BASIC_DETAILS_RISK_TYPE_LABEL",
44252
- value: "WF_BPA_" + riskType,
44253
- isInsert: true
44254
- }, {
44255
- title: "BPA_BASIC_DETAILS_APPLICATION_NAME_LABEL",
44256
- value: edcr === null || edcr === void 0 ? void 0 : (_edcr$planDetail4 = edcr.planDetail) === null || _edcr$planDetail4 === void 0 ? void 0 : (_edcr$planDetail4$pla = _edcr$planDetail4.planInformation) === null || _edcr$planDetail4$pla === void 0 ? void 0 : _edcr$planDetail4$pla.applicantName
44257
- }]
44258
- };
44259
- var plotDetails = {
44260
- title: "BPA_PLOT_DETAILS_TITLE",
44261
- asSectionHeader: true,
44262
- isCommon: true,
44263
- values: [{
44264
- title: "BPA_BOUNDARY_PLOT_AREA_LABEL",
44265
- value: "" + (edcr === null || edcr === void 0 ? void 0 : (_edcr$planDetail5 = edcr.planDetail) === null || _edcr$planDetail5 === void 0 ? void 0 : (_edcr$planDetail5$pla = _edcr$planDetail5.planInformation) === null || _edcr$planDetail5$pla === void 0 ? void 0 : _edcr$planDetail5$pla.plotArea),
44266
- isNotTranslated: true,
44267
- isUnit: "BPA_SQ_FT_LABEL"
44268
- }, {
44269
- title: "BPA_PLOT_NUMBER_LABEL",
44270
- value: (edcr === null || edcr === void 0 ? void 0 : (_edcr$planDetail6 = edcr.planDetail) === null || _edcr$planDetail6 === void 0 ? void 0 : (_edcr$planDetail6$pla = _edcr$planDetail6.planInformation) === null || _edcr$planDetail6$pla === void 0 ? void 0 : _edcr$planDetail6$pla.plotNo) || "NA",
44271
- isNotTranslated: true
44272
- }, {
44273
- title: "BPA_KHATHA_NUMBER_LABEL",
44274
- value: (edcr === null || edcr === void 0 ? void 0 : (_edcr$planDetail7 = edcr.planDetail) === null || _edcr$planDetail7 === void 0 ? void 0 : (_edcr$planDetail7$pla = _edcr$planDetail7.planInformation) === null || _edcr$planDetail7$pla === void 0 ? void 0 : _edcr$planDetail7$pla.khataNo) || "NA",
44275
- isNotTranslated: true
44276
- }, {
44277
- title: "BPA_HOLDING_NUMBER_LABEL",
44278
- value: (BPA === null || BPA === void 0 ? void 0 : (_BPA$additionalDetail9 = BPA.additionalDetails) === null || _BPA$additionalDetail9 === void 0 ? void 0 : _BPA$additionalDetail9.holdingNo) || "NA",
44279
- isNotTranslated: true
44280
- }, {
44281
- title: "BPA_BOUNDARY_LAND_REG_DETAIL_LABEL",
44282
- value: (BPA === null || BPA === void 0 ? void 0 : (_BPA$additionalDetail10 = BPA.additionalDetails) === null || _BPA$additionalDetail10 === void 0 ? void 0 : _BPA$additionalDetail10.registrationDetails) || "NA",
44283
- isNotTranslated: true
44284
- }]
44285
- };
44286
- var scrutinyDetails = {
44287
- title: "BPA_STEPPER_SCRUTINY_DETAILS_HEADER",
44288
- isScrutinyDetails: true,
44289
- isBackGroundColor: true,
44290
- additionalDetails: {
45365
+ applicationDetailsInfo === null || applicationDetailsInfo === void 0 ? void 0 : (_applicationDetailsIn = applicationDetailsInfo.values) === null || _applicationDetailsIn === void 0 ? void 0 : _applicationDetailsIn.push({
45366
+ title: (BPA === null || BPA === void 0 ? void 0 : BPA.businessService) !== "BPA_OC" ? "BPA_PERMIT_NUMBER_LABEL" : "BPA_OC_PERMIT_NUMBER_LABEL",
45367
+ value: (BPA === null || BPA === void 0 ? void 0 : BPA.approvalNo) || "NA"
45368
+ });
45369
+ applicationDetailsInfo === null || applicationDetailsInfo === void 0 ? void 0 : (_applicationDetailsIn2 = applicationDetailsInfo.values) === null || _applicationDetailsIn2 === void 0 ? void 0 : _applicationDetailsIn2.push({
45370
+ title: (BPA === null || BPA === void 0 ? void 0 : BPA.businessService) !== "BPA_OC" ? "BPA_PERMIT_VALIDITY" : "BPA_OC_PERMIT_VALIDITY",
45371
+ value: BPA !== null && BPA !== void 0 && (_BPA$additionalDetail8 = BPA.additionalDetails) !== null && _BPA$additionalDetail8 !== void 0 && _BPA$additionalDetail8.validityDate ? ConvertEpochToValidityDate(BPA === null || BPA === void 0 ? void 0 : (_BPA$additionalDetail9 = BPA.additionalDetails) === null || _BPA$additionalDetail9 === void 0 ? void 0 : _BPA$additionalDetail9.validityDate) + " - " + format(new Date(BPA === null || BPA === void 0 ? void 0 : (_BPA$additionalDetail10 = BPA.additionalDetails) === null || _BPA$additionalDetail10 === void 0 ? void 0 : _BPA$additionalDetail10.validityDate), 'dd/MM/yyyy') : "NA"
45372
+ });
45373
+ }
45374
+
45375
+ var basicDetails = {
45376
+ title: "BPA_BASIC_DETAILS_TITLE",
45377
+ asSectionHeader: true,
45378
+ isInsert: true,
45379
+ isCommon: true,
44291
45380
  values: [{
44292
- title: "BPA_EDCR_DETAILS",
44293
- value: " ",
44294
- isHeader: true
45381
+ title: "BPA_BASIC_DETAILS_APP_DATE_LABEL",
45382
+ value: BPA !== null && BPA !== void 0 && (_BPA$auditDetails = BPA.auditDetails) !== null && _BPA$auditDetails !== void 0 && _BPA$auditDetails.createdTime ? format(new Date(BPA === null || BPA === void 0 ? void 0 : (_BPA$auditDetails2 = BPA.auditDetails) === null || _BPA$auditDetails2 === void 0 ? void 0 : _BPA$auditDetails2.createdTime), 'dd/MM/yyyy') : ''
44295
45383
  }, {
44296
- title: (BPA === null || BPA === void 0 ? void 0 : BPA.businessService) !== "BPA_OC" ? "BPA_EDCR_NO_LABEL" : "BPA_OC_EDCR_NO_LABEL",
44297
- value: (BPA === null || BPA === void 0 ? void 0 : BPA.edcrNumber) || "NA"
44298
- }],
44299
- scruntinyDetails: [{
44300
- title: "BPA_UPLOADED_PLAN_DIAGRAM",
44301
- value: edcr === null || edcr === void 0 ? void 0 : edcr.updatedDxfFile,
44302
- text: "BPA_UPLOADED_PLAN_DXF"
45384
+ title: "BPA_BASIC_DETAILS_APPLICATION_TYPE_LABEL",
45385
+ value: "WF_BPA_" + (edcr === null || edcr === void 0 ? void 0 : edcr.appliactionType)
44303
45386
  }, {
44304
- title: "BPA_SCRUNTINY_REPORT_OUTPUT",
44305
- value: edcr === null || edcr === void 0 ? void 0 : edcr.planReport,
44306
- text: "BPA_SCRUTINY_REPORT_PDF"
45387
+ title: "BPA_BASIC_DETAILS_SERVICE_TYPE_LABEL",
45388
+ value: edcr === null || edcr === void 0 ? void 0 : edcr.applicationSubType
45389
+ }, {
45390
+ title: "BPA_BASIC_DETAILS_OCCUPANCY_LABEL",
45391
+ value: edcr === null || edcr === void 0 ? void 0 : (_edcr$planDetail3 = edcr.planDetail) === null || _edcr$planDetail3 === void 0 ? void 0 : (_edcr$planDetail3$pla = _edcr$planDetail3.planInformation) === null || _edcr$planDetail3$pla === void 0 ? void 0 : _edcr$planDetail3$pla.occupancy
45392
+ }, {
45393
+ title: "BPA_BASIC_DETAILS_RISK_TYPE_LABEL",
45394
+ value: "WF_BPA_" + riskType,
45395
+ isInsert: true
45396
+ }, {
45397
+ title: "BPA_BASIC_DETAILS_APPLICATION_NAME_LABEL",
45398
+ value: edcr === null || edcr === void 0 ? void 0 : (_edcr$planDetail4 = edcr.planDetail) === null || _edcr$planDetail4 === void 0 ? void 0 : (_edcr$planDetail4$pla = _edcr$planDetail4.planInformation) === null || _edcr$planDetail4$pla === void 0 ? void 0 : _edcr$planDetail4$pla.applicantName
44307
45399
  }]
44308
- }
44309
- };
44310
- var buildingExtractionDetails = {
44311
- title: "",
44312
- isScrutinyDetails: true,
44313
- isBackGroundColor: true,
44314
- additionalDetails: {
45400
+ };
45401
+ var plotDetails = {
45402
+ title: "BPA_PLOT_DETAILS_TITLE",
45403
+ asSectionHeader: true,
45404
+ isCommon: true,
44315
45405
  values: [{
44316
- title: (BPA === null || BPA === void 0 ? void 0 : BPA.businessService) !== "BPA_OC" ? "BPA_BUILDING_EXTRACT_HEADER" : "BPA_ACTUAL_BUILDING_EXTRACT_HEADER",
44317
- value: " ",
44318
- isHeader: true
45406
+ title: "BPA_BOUNDARY_PLOT_AREA_LABEL",
45407
+ value: "" + (edcr === null || edcr === void 0 ? void 0 : (_edcr$planDetail5 = edcr.planDetail) === null || _edcr$planDetail5 === void 0 ? void 0 : (_edcr$planDetail5$pla = _edcr$planDetail5.planInformation) === null || _edcr$planDetail5$pla === void 0 ? void 0 : _edcr$planDetail5$pla.plotArea),
45408
+ isNotTranslated: true,
45409
+ isUnit: "BPA_SQ_FT_LABEL"
44319
45410
  }, {
44320
- title: "BPA_TOTAL_BUILT_UP_AREA_HEADER",
44321
- value: edcr === null || edcr === void 0 ? void 0 : (_edcr$planDetail8 = edcr.planDetail) === null || _edcr$planDetail8 === void 0 ? void 0 : (_edcr$planDetail8$blo = _edcr$planDetail8.blocks) === null || _edcr$planDetail8$blo === void 0 ? void 0 : (_edcr$planDetail8$blo2 = _edcr$planDetail8$blo[0]) === null || _edcr$planDetail8$blo2 === void 0 ? void 0 : (_edcr$planDetail8$blo3 = _edcr$planDetail8$blo2.building) === null || _edcr$planDetail8$blo3 === void 0 ? void 0 : _edcr$planDetail8$blo3.totalBuitUpArea,
44322
- isUnit: "BPA_SQ_MTRS_LABEL"
45411
+ title: "BPA_PLOT_NUMBER_LABEL",
45412
+ value: (edcr === null || edcr === void 0 ? void 0 : (_edcr$planDetail6 = edcr.planDetail) === null || _edcr$planDetail6 === void 0 ? void 0 : (_edcr$planDetail6$pla = _edcr$planDetail6.planInformation) === null || _edcr$planDetail6$pla === void 0 ? void 0 : _edcr$planDetail6$pla.plotNo) || "NA",
45413
+ isNotTranslated: true
44323
45414
  }, {
44324
- title: "BPA_SCRUTINY_DETAILS_NUMBER_OF_FLOORS_LABEL",
44325
- value: (edcr === null || edcr === void 0 ? void 0 : (_edcr$planDetail9 = edcr.planDetail) === null || _edcr$planDetail9 === void 0 ? void 0 : (_edcr$planDetail9$blo = _edcr$planDetail9.blocks) === null || _edcr$planDetail9$blo === void 0 ? void 0 : (_edcr$planDetail9$blo2 = _edcr$planDetail9$blo[0]) === null || _edcr$planDetail9$blo2 === void 0 ? void 0 : (_edcr$planDetail9$blo3 = _edcr$planDetail9$blo2.building) === null || _edcr$planDetail9$blo3 === void 0 ? void 0 : _edcr$planDetail9$blo3.totalFloors) || "NA"
45415
+ title: "BPA_KHATHA_NUMBER_LABEL",
45416
+ value: (edcr === null || edcr === void 0 ? void 0 : (_edcr$planDetail7 = edcr.planDetail) === null || _edcr$planDetail7 === void 0 ? void 0 : (_edcr$planDetail7$pla = _edcr$planDetail7.planInformation) === null || _edcr$planDetail7$pla === void 0 ? void 0 : _edcr$planDetail7$pla.khataNo) || "NA",
45417
+ isNotTranslated: true
44326
45418
  }, {
44327
- title: "BPA_HEIGHT_FROM_GROUND_LEVEL",
44328
- value: edcr === null || edcr === void 0 ? void 0 : (_edcr$planDetail10 = edcr.planDetail) === null || _edcr$planDetail10 === void 0 ? void 0 : (_edcr$planDetail10$bl = _edcr$planDetail10.blocks) === null || _edcr$planDetail10$bl === void 0 ? void 0 : (_edcr$planDetail10$bl2 = _edcr$planDetail10$bl[0]) === null || _edcr$planDetail10$bl2 === void 0 ? void 0 : (_edcr$planDetail10$bl3 = _edcr$planDetail10$bl2.building) === null || _edcr$planDetail10$bl3 === void 0 ? void 0 : _edcr$planDetail10$bl3.declaredBuildingHeigh,
44329
- isUnit: "BPA_MTRS_LABEL"
44330
- }],
44331
- scruntinyDetails: []
44332
- }
44333
- };
44334
- var demolitionAreaDetails = {
44335
- title: "",
44336
- isScrutinyDetails: true,
44337
- isBackGroundColor: true,
44338
- additionalDetails: {
44339
- values: [{
44340
- title: "BPA_APP_DETAILS_DEMOLITION_DETAILS_LABEL",
44341
- value: " ",
44342
- isHeader: true
45419
+ title: "BPA_HOLDING_NUMBER_LABEL",
45420
+ value: (BPA === null || BPA === void 0 ? void 0 : (_BPA$additionalDetail11 = BPA.additionalDetails) === null || _BPA$additionalDetail11 === void 0 ? void 0 : _BPA$additionalDetail11.holdingNo) || "NA",
45421
+ isNotTranslated: true
44343
45422
  }, {
44344
- title: "BPA_APPLICATION_DEMOLITION_AREA_LABEL",
44345
- value: edcr === null || edcr === void 0 ? void 0 : (_edcr$planDetail11 = edcr.planDetail) === null || _edcr$planDetail11 === void 0 ? void 0 : (_edcr$planDetail11$pl = _edcr$planDetail11.planInformation) === null || _edcr$planDetail11$pl === void 0 ? void 0 : _edcr$planDetail11$pl.demolitionArea,
44346
- isUnit: "BPA_SQ_MTRS_LABEL"
44347
- }],
44348
- scruntinyDetails: []
44349
- }
44350
- };
44351
- var subOccupancyTableDetails = {
44352
- title: "",
44353
- isSubOccupancyTable: true,
44354
- isTitleRepeat: true,
44355
- additionalDetails: {
45423
+ title: "BPA_BOUNDARY_LAND_REG_DETAIL_LABEL",
45424
+ value: (BPA === null || BPA === void 0 ? void 0 : (_BPA$additionalDetail12 = BPA.additionalDetails) === null || _BPA$additionalDetail12 === void 0 ? void 0 : _BPA$additionalDetail12.registrationDetails) || "NA",
45425
+ isNotTranslated: true
45426
+ }]
45427
+ };
45428
+ var scrutinyDetails = {
45429
+ title: "BPA_STEPPER_SCRUTINY_DETAILS_HEADER",
45430
+ isScrutinyDetails: true,
45431
+ isBackGroundColor: true,
45432
+ additionalDetails: {
45433
+ values: [{
45434
+ title: "BPA_EDCR_DETAILS",
45435
+ value: " ",
45436
+ isHeader: true
45437
+ }, {
45438
+ title: (BPA === null || BPA === void 0 ? void 0 : BPA.businessService) !== "BPA_OC" ? "BPA_EDCR_NO_LABEL" : "BPA_OC_EDCR_NO_LABEL",
45439
+ value: (BPA === null || BPA === void 0 ? void 0 : BPA.edcrNumber) || "NA"
45440
+ }],
45441
+ scruntinyDetails: [{
45442
+ title: "BPA_UPLOADED_PLAN_DIAGRAM",
45443
+ value: edcr === null || edcr === void 0 ? void 0 : edcr.updatedDxfFile,
45444
+ text: "BPA_UPLOADED_PLAN_DXF"
45445
+ }, {
45446
+ title: "BPA_SCRUNTINY_REPORT_OUTPUT",
45447
+ value: edcr === null || edcr === void 0 ? void 0 : edcr.planReport,
45448
+ text: "BPA_SCRUTINY_REPORT_PDF"
45449
+ }]
45450
+ }
45451
+ };
45452
+ var buildingExtractionDetails = {
45453
+ title: "",
45454
+ isScrutinyDetails: true,
45455
+ isBackGroundColor: true,
45456
+ additionalDetails: {
45457
+ values: [{
45458
+ title: (BPA === null || BPA === void 0 ? void 0 : BPA.businessService) !== "BPA_OC" ? "BPA_BUILDING_EXTRACT_HEADER" : "BPA_ACTUAL_BUILDING_EXTRACT_HEADER",
45459
+ value: " ",
45460
+ isHeader: true
45461
+ }, {
45462
+ title: "BPA_TOTAL_BUILT_UP_AREA_HEADER",
45463
+ value: edcr === null || edcr === void 0 ? void 0 : (_edcr$planDetail8 = edcr.planDetail) === null || _edcr$planDetail8 === void 0 ? void 0 : (_edcr$planDetail8$blo = _edcr$planDetail8.blocks) === null || _edcr$planDetail8$blo === void 0 ? void 0 : (_edcr$planDetail8$blo2 = _edcr$planDetail8$blo[0]) === null || _edcr$planDetail8$blo2 === void 0 ? void 0 : (_edcr$planDetail8$blo3 = _edcr$planDetail8$blo2.building) === null || _edcr$planDetail8$blo3 === void 0 ? void 0 : _edcr$planDetail8$blo3.totalBuitUpArea,
45464
+ isUnit: "BPA_SQ_MTRS_LABEL"
45465
+ }, {
45466
+ title: "BPA_SCRUTINY_DETAILS_NUMBER_OF_FLOORS_LABEL",
45467
+ value: (edcr === null || edcr === void 0 ? void 0 : (_edcr$planDetail9 = edcr.planDetail) === null || _edcr$planDetail9 === void 0 ? void 0 : (_edcr$planDetail9$blo = _edcr$planDetail9.blocks) === null || _edcr$planDetail9$blo === void 0 ? void 0 : (_edcr$planDetail9$blo2 = _edcr$planDetail9$blo[0]) === null || _edcr$planDetail9$blo2 === void 0 ? void 0 : (_edcr$planDetail9$blo3 = _edcr$planDetail9$blo2.building) === null || _edcr$planDetail9$blo3 === void 0 ? void 0 : _edcr$planDetail9$blo3.totalFloors) || "NA"
45468
+ }, {
45469
+ title: "BPA_HEIGHT_FROM_GROUND_LEVEL",
45470
+ value: edcr === null || edcr === void 0 ? void 0 : (_edcr$planDetail10 = edcr.planDetail) === null || _edcr$planDetail10 === void 0 ? void 0 : (_edcr$planDetail10$bl = _edcr$planDetail10.blocks) === null || _edcr$planDetail10$bl === void 0 ? void 0 : (_edcr$planDetail10$bl2 = _edcr$planDetail10$bl[0]) === null || _edcr$planDetail10$bl2 === void 0 ? void 0 : (_edcr$planDetail10$bl3 = _edcr$planDetail10$bl2.building) === null || _edcr$planDetail10$bl3 === void 0 ? void 0 : _edcr$planDetail10$bl3.declaredBuildingHeigh,
45471
+ isUnit: "BPA_MTRS_LABEL"
45472
+ }],
45473
+ scruntinyDetails: []
45474
+ }
45475
+ };
45476
+ var demolitionAreaDetails = {
45477
+ title: "",
45478
+ isScrutinyDetails: true,
45479
+ isBackGroundColor: true,
45480
+ additionalDetails: {
45481
+ values: [{
45482
+ title: "BPA_APP_DETAILS_DEMOLITION_DETAILS_LABEL",
45483
+ value: " ",
45484
+ isHeader: true
45485
+ }, {
45486
+ title: "BPA_APPLICATION_DEMOLITION_AREA_LABEL",
45487
+ value: edcr === null || edcr === void 0 ? void 0 : (_edcr$planDetail11 = edcr.planDetail) === null || _edcr$planDetail11 === void 0 ? void 0 : (_edcr$planDetail11$pl = _edcr$planDetail11.planInformation) === null || _edcr$planDetail11$pl === void 0 ? void 0 : _edcr$planDetail11$pl.demolitionArea,
45488
+ isUnit: "BPA_SQ_MTRS_LABEL"
45489
+ }],
45490
+ scruntinyDetails: []
45491
+ }
45492
+ };
45493
+ var subOccupancyTableDetails = {
45494
+ title: "",
45495
+ isSubOccupancyTable: true,
45496
+ isTitleRepeat: true,
45497
+ additionalDetails: {
45498
+ values: [{
45499
+ title: "BPA_OCC_SUBOCC_HEADER",
45500
+ value: " ",
45501
+ isHeader: true
45502
+ }],
45503
+ subOccupancyTableDetails: [{
45504
+ title: "BPA_APPLICATION_DEMOLITION_AREA_LABEL",
45505
+ value: edcr
45506
+ }, {
45507
+ title: "NO_REPEAT",
45508
+ value: ""
45509
+ }]
45510
+ }
45511
+ };
45512
+ var addressDetails = {
45513
+ title: "BPA_NEW_TRADE_DETAILS_HEADER_DETAILS",
45514
+ asSectionHeader: true,
45515
+ isCommon: true,
44356
45516
  values: [{
44357
- title: "BPA_OCC_SUBOCC_HEADER",
44358
- value: " ",
44359
- isHeader: true
44360
- }],
44361
- subOccupancyTableDetails: [{
44362
- title: "BPA_APPLICATION_DEMOLITION_AREA_LABEL",
44363
- value: edcr
45517
+ title: "BPA_DETAILS_PIN_LABEL",
45518
+ value: BPA === null || BPA === void 0 ? void 0 : (_BPA$landInfo = BPA.landInfo) === null || _BPA$landInfo === void 0 ? void 0 : (_BPA$landInfo$address = _BPA$landInfo.address) === null || _BPA$landInfo$address === void 0 ? void 0 : _BPA$landInfo$address.pincode
44364
45519
  }, {
44365
- title: "NO_REPEAT",
44366
- value: ""
45520
+ title: "BPA_CITY_LABEL",
45521
+ value: BPA === null || BPA === void 0 ? void 0 : (_BPA$landInfo2 = BPA.landInfo) === null || _BPA$landInfo2 === void 0 ? void 0 : (_BPA$landInfo2$addres = _BPA$landInfo2.address) === null || _BPA$landInfo2$addres === void 0 ? void 0 : _BPA$landInfo2$addres.city
45522
+ }, {
45523
+ title: "BPA_LOC_MOHALLA_LABEL",
45524
+ value: BPA === null || BPA === void 0 ? void 0 : (_BPA$landInfo3 = BPA.landInfo) === null || _BPA$landInfo3 === void 0 ? void 0 : (_BPA$landInfo3$addres = _BPA$landInfo3.address) === null || _BPA$landInfo3$addres === void 0 ? void 0 : (_BPA$landInfo3$addres2 = _BPA$landInfo3$addres.locality) === null || _BPA$landInfo3$addres2 === void 0 ? void 0 : _BPA$landInfo3$addres2.name
45525
+ }, {
45526
+ title: "BPA_DETAILS_SRT_NAME_LABEL",
45527
+ value: BPA === null || BPA === void 0 ? void 0 : (_BPA$landInfo4 = BPA.landInfo) === null || _BPA$landInfo4 === void 0 ? void 0 : (_BPA$landInfo4$addres = _BPA$landInfo4.address) === null || _BPA$landInfo4$addres === void 0 ? void 0 : _BPA$landInfo4$addres.street
45528
+ }, {
45529
+ title: "ES_NEW_APPLICATION_LOCATION_LANDMARK",
45530
+ value: BPA === null || BPA === void 0 ? void 0 : (_BPA$landInfo5 = BPA.landInfo) === null || _BPA$landInfo5 === void 0 ? void 0 : (_BPA$landInfo5$addres = _BPA$landInfo5.address) === null || _BPA$landInfo5$addres === void 0 ? void 0 : _BPA$landInfo5$addres.landmark
44367
45531
  }]
44368
- }
44369
- };
44370
- var addressDetails = {
44371
- title: "BPA_NEW_TRADE_DETAILS_HEADER_DETAILS",
44372
- asSectionHeader: true,
44373
- isCommon: true,
44374
- values: [{
44375
- title: "BPA_DETAILS_PIN_LABEL",
44376
- value: BPA === null || BPA === void 0 ? void 0 : (_BPA$landInfo = BPA.landInfo) === null || _BPA$landInfo === void 0 ? void 0 : (_BPA$landInfo$address = _BPA$landInfo.address) === null || _BPA$landInfo$address === void 0 ? void 0 : _BPA$landInfo$address.pincode
44377
- }, {
44378
- title: "BPA_CITY_LABEL",
44379
- value: BPA === null || BPA === void 0 ? void 0 : (_BPA$landInfo2 = BPA.landInfo) === null || _BPA$landInfo2 === void 0 ? void 0 : (_BPA$landInfo2$addres = _BPA$landInfo2.address) === null || _BPA$landInfo2$addres === void 0 ? void 0 : _BPA$landInfo2$addres.city
44380
- }, {
44381
- title: "BPA_LOC_MOHALLA_LABEL",
44382
- value: BPA === null || BPA === void 0 ? void 0 : (_BPA$landInfo3 = BPA.landInfo) === null || _BPA$landInfo3 === void 0 ? void 0 : (_BPA$landInfo3$addres = _BPA$landInfo3.address) === null || _BPA$landInfo3$addres === void 0 ? void 0 : (_BPA$landInfo3$addres2 = _BPA$landInfo3$addres.locality) === null || _BPA$landInfo3$addres2 === void 0 ? void 0 : _BPA$landInfo3$addres2.name
44383
- }, {
44384
- title: "BPA_DETAILS_SRT_NAME_LABEL",
44385
- value: BPA === null || BPA === void 0 ? void 0 : (_BPA$landInfo4 = BPA.landInfo) === null || _BPA$landInfo4 === void 0 ? void 0 : (_BPA$landInfo4$addres = _BPA$landInfo4.address) === null || _BPA$landInfo4$addres === void 0 ? void 0 : _BPA$landInfo4$addres.street
44386
- }, {
44387
- title: "ES_NEW_APPLICATION_LOCATION_LANDMARK",
44388
- value: BPA === null || BPA === void 0 ? void 0 : (_BPA$landInfo5 = BPA.landInfo) === null || _BPA$landInfo5 === void 0 ? void 0 : (_BPA$landInfo5$addres = _BPA$landInfo5.address) === null || _BPA$landInfo5$addres === void 0 ? void 0 : _BPA$landInfo5$addres.landmark
44389
- }]
44390
- };
44391
- var checkOwnerLength = (BPA === null || BPA === void 0 ? void 0 : (_BPA$landInfo6 = BPA.landInfo) === null || _BPA$landInfo6 === void 0 ? void 0 : (_BPA$landInfo6$owners = _BPA$landInfo6.owners) === null || _BPA$landInfo6$owners === void 0 ? void 0 : _BPA$landInfo6$owners.length) || 1;
45532
+ };
45533
+ var checkOwnerLength = (BPA === null || BPA === void 0 ? void 0 : (_BPA$landInfo6 = BPA.landInfo) === null || _BPA$landInfo6 === void 0 ? void 0 : (_BPA$landInfo6$owners = _BPA$landInfo6.owners) === null || _BPA$landInfo6$owners === void 0 ? void 0 : _BPA$landInfo6$owners.length) || 1;
44392
45534
 
44393
- if ((BPA === null || BPA === void 0 ? void 0 : (_BPA$landInfo7 = BPA.landInfo) === null || _BPA$landInfo7 === void 0 ? void 0 : (_BPA$landInfo7$owners = _BPA$landInfo7.owners) === null || _BPA$landInfo7$owners === void 0 ? void 0 : _BPA$landInfo7$owners.length) > 0) {
44394
- var _BPA$landInfo8, _BPA$landInfo8$owners;
45535
+ if ((BPA === null || BPA === void 0 ? void 0 : (_BPA$landInfo7 = BPA.landInfo) === null || _BPA$landInfo7 === void 0 ? void 0 : (_BPA$landInfo7$owners = _BPA$landInfo7.owners) === null || _BPA$landInfo7$owners === void 0 ? void 0 : _BPA$landInfo7$owners.length) > 0) {
45536
+ var _BPA$landInfo8, _BPA$landInfo8$owners;
44395
45537
 
44396
- BPA === null || BPA === void 0 ? void 0 : (_BPA$landInfo8 = BPA.landInfo) === null || _BPA$landInfo8 === void 0 ? void 0 : (_BPA$landInfo8$owners = _BPA$landInfo8.owners) === null || _BPA$landInfo8$owners === void 0 ? void 0 : _BPA$landInfo8$owners.forEach(function (ownerD) {
44397
- if (!ownerD.isPrimaryOwner) ownerD.isPrimaryOwner = "false";
44398
- });
44399
- }
44400
-
44401
- var ownerDetails = {
44402
- title: "BPA_APPLICANT_DETAILS_HEADER",
44403
- isOwnerDetails: true,
44404
- additionalDetails: {
44405
- owners: BPA === null || BPA === void 0 ? void 0 : (_BPA$landInfo9 = BPA.landInfo) === null || _BPA$landInfo9 === void 0 ? void 0 : (_BPA$landInfo9$owners = _BPA$landInfo9.owners) === null || _BPA$landInfo9$owners === void 0 ? void 0 : _BPA$landInfo9$owners.map(function (owner, index) {
44406
- return {
44407
- title: Number(checkOwnerLength) > 1 ? "COMMON_OWNER" : "",
44408
- values: [{
44409
- title: "CORE_COMMON_NAME",
44410
- value: owner === null || owner === void 0 ? void 0 : owner.name
44411
- }, {
44412
- title: "BPA_APPLICANT_GENDER_LABEL",
44413
- value: owner === null || owner === void 0 ? void 0 : owner.gender
44414
- }, {
44415
- title: "CORE_COMMON_MOBILE_NUMBER",
44416
- value: owner === null || owner === void 0 ? void 0 : owner.mobileNumber
44417
- }, {
44418
- title: "BPA_IS_PRIMARY_OWNER_LABEL",
44419
- value: owner === null || owner === void 0 ? void 0 : owner.isPrimaryOwner,
44420
- isNotTranslated: false
44421
- }]
44422
- };
44423
- })
45538
+ BPA === null || BPA === void 0 ? void 0 : (_BPA$landInfo8 = BPA.landInfo) === null || _BPA$landInfo8 === void 0 ? void 0 : (_BPA$landInfo8$owners = _BPA$landInfo8.owners) === null || _BPA$landInfo8$owners === void 0 ? void 0 : _BPA$landInfo8$owners.forEach(function (ownerD) {
45539
+ if (!ownerD.isPrimaryOwner) ownerD.isPrimaryOwner = "false";
45540
+ });
44424
45541
  }
44425
- };
44426
- var documentDetails = {
44427
- title: "BPA_DOCUMENT_DETAILS_LABEL",
44428
- asSectionHeader: true,
44429
- isDocumentDetails: true,
44430
- additionalDetails: {
44431
- obpsDocuments: [{
44432
- title: "",
44433
- values: BPA === null || BPA === void 0 ? void 0 : (_BPA$documents = BPA.documents) === null || _BPA$documents === void 0 ? void 0 : _BPA$documents.map(function (doc) {
44434
- var _doc$documentType4;
44435
45542
 
45543
+ var ownerDetails = {
45544
+ title: "BPA_APPLICANT_DETAILS_HEADER",
45545
+ isOwnerDetails: true,
45546
+ additionalDetails: {
45547
+ owners: BPA === null || BPA === void 0 ? void 0 : (_BPA$landInfo9 = BPA.landInfo) === null || _BPA$landInfo9 === void 0 ? void 0 : (_BPA$landInfo9$owners = _BPA$landInfo9.owners) === null || _BPA$landInfo9$owners === void 0 ? void 0 : _BPA$landInfo9$owners.map(function (owner, index) {
44436
45548
  return {
44437
- title: doc === null || doc === void 0 ? void 0 : (_doc$documentType4 = doc.documentType) === null || _doc$documentType4 === void 0 ? void 0 : _doc$documentType4.replaceAll('.', '_'),
44438
- documentType: doc === null || doc === void 0 ? void 0 : doc.documentType,
44439
- documentUid: doc === null || doc === void 0 ? void 0 : doc.documentUid,
44440
- fileStoreId: doc === null || doc === void 0 ? void 0 : doc.fileStoreId,
44441
- id: doc === null || doc === void 0 ? void 0 : doc.id
45549
+ title: Number(checkOwnerLength) > 1 ? "COMMON_OWNER" : "",
45550
+ values: [{
45551
+ title: "CORE_COMMON_NAME",
45552
+ value: owner === null || owner === void 0 ? void 0 : owner.name
45553
+ }, {
45554
+ title: "BPA_APPLICANT_GENDER_LABEL",
45555
+ value: owner === null || owner === void 0 ? void 0 : owner.gender
45556
+ }, {
45557
+ title: "CORE_COMMON_MOBILE_NUMBER",
45558
+ value: owner === null || owner === void 0 ? void 0 : owner.mobileNumber
45559
+ }, {
45560
+ title: "BPA_IS_PRIMARY_OWNER_LABEL",
45561
+ value: owner === null || owner === void 0 ? void 0 : owner.isPrimaryOwner,
45562
+ isNotTranslated: false
45563
+ }]
44442
45564
  };
44443
45565
  })
44444
- }]
44445
- }
44446
- };
44447
- var approvalChecks = [];
44448
- var approvalChecksDetails = {};
44449
-
44450
- if ((BPA === null || BPA === void 0 ? void 0 : BPA.status) === "APPROVAL_INPROGRESS") {
44451
- var _mdmsRes$BPA2;
44452
-
44453
- mdmsRes === null || mdmsRes === void 0 ? void 0 : (_mdmsRes$BPA2 = mdmsRes.BPA) === null || _mdmsRes$BPA2 === void 0 ? void 0 : _mdmsRes$BPA2.CheckList.forEach(function (checklist) {
44454
- var _checklist$conditions;
44455
-
44456
- if ((checklist === null || checklist === void 0 ? void 0 : checklist.RiskType) === riskType && (checklist === null || checklist === void 0 ? void 0 : checklist.applicationType) === (edcr === null || edcr === void 0 ? void 0 : edcr.appliactionType) && (checklist === null || checklist === void 0 ? void 0 : checklist.ServiceType) === (edcr === null || edcr === void 0 ? void 0 : edcr.applicationSubType) && (checklist === null || checklist === void 0 ? void 0 : checklist.WFState) === "PENDINGAPPROVAL" && (checklist === null || checklist === void 0 ? void 0 : (_checklist$conditions = checklist.conditions) === null || _checklist$conditions === void 0 ? void 0 : _checklist$conditions.length) > 0) {
44457
- approvalChecks.push.apply(approvalChecks, checklist === null || checklist === void 0 ? void 0 : checklist.conditions);
44458
45566
  }
44459
- });
44460
- approvalChecksDetails = {
44461
- title: "",
44462
- isTitleVisible: (approvalChecks === null || approvalChecks === void 0 ? void 0 : approvalChecks.length) > 0 ? false : true,
45567
+ };
45568
+ var documentDetails = {
45569
+ title: "BPA_DOCUMENT_DETAILS_LABEL",
44463
45570
  asSectionHeader: true,
44464
- isPermissions: true,
45571
+ isDocumentDetails: true,
44465
45572
  additionalDetails: {
44466
- permissions: approvalChecks
45573
+ obpsDocuments: [{
45574
+ title: "",
45575
+ values: BPA === null || BPA === void 0 ? void 0 : (_BPA$documents = BPA.documents) === null || _BPA$documents === void 0 ? void 0 : _BPA$documents.map(function (doc) {
45576
+ var _doc$documentType4, _fileDetails9, _fileDetails9$data, _fileDetails10, _fileDetails10$data, _fileDetails10$data$d;
45577
+
45578
+ return {
45579
+ title: doc === null || doc === void 0 ? void 0 : (_doc$documentType4 = doc.documentType) === null || _doc$documentType4 === void 0 ? void 0 : _doc$documentType4.replaceAll('.', '_'),
45580
+ documentType: doc === null || doc === void 0 ? void 0 : doc.documentType,
45581
+ documentUid: doc === null || doc === void 0 ? void 0 : doc.documentUid,
45582
+ fileStoreId: doc === null || doc === void 0 ? void 0 : doc.fileStoreId,
45583
+ id: doc === null || doc === void 0 ? void 0 : doc.id,
45584
+ url: (_fileDetails9 = fileDetails) !== null && _fileDetails9 !== void 0 && (_fileDetails9$data = _fileDetails9.data) !== null && _fileDetails9$data !== void 0 && _fileDetails9$data[doc === null || doc === void 0 ? void 0 : doc.fileStoreId] ? (_fileDetails10 = fileDetails) === null || _fileDetails10 === void 0 ? void 0 : (_fileDetails10$data = _fileDetails10.data) === null || _fileDetails10$data === void 0 ? void 0 : (_fileDetails10$data$d = _fileDetails10$data[doc === null || doc === void 0 ? void 0 : doc.fileStoreId]) === null || _fileDetails10$data$d === void 0 ? void 0 : _fileDetails10$data$d.split(',')[0] : ""
45585
+ };
45586
+ })
45587
+ }]
44467
45588
  }
44468
45589
  };
44469
- }
45590
+ var approvalChecks = [];
45591
+ var approvalChecksDetails = {};
44470
45592
 
44471
- if (riskType == "LOW" && approvalChecks.length > 0) approvalChecksDetails = {};
44472
- var val;
44473
- var i;
44474
- var FieldInspectionData = [];
44475
- inspectionReport && (BPA === null || BPA === void 0 ? void 0 : (_BPA$additionalDetail11 = BPA.additionalDetails) === null || _BPA$additionalDetail11 === void 0 ? void 0 : (_BPA$additionalDetail12 = _BPA$additionalDetail11.fieldinspection_pending) === null || _BPA$additionalDetail12 === void 0 ? void 0 : (_BPA$additionalDetail13 = _BPA$additionalDetail12[0]) === null || _BPA$additionalDetail13 === void 0 ? void 0 : _BPA$additionalDetail13.questions.length) > 0 && inspectionReport.map(function (ob, index) {
44476
- if (ob.title.includes("FI_REPORT")) FieldInspectionData = [].concat(FieldInspectionData, [{
44477
- title: ob.title,
44478
- additionalDetails: {
44479
- inspectionReport: [],
44480
- values: ob.values
44481
- }
44482
- }]);else if (ob.title.includes("CHECK_LIST")) FieldInspectionData = [].concat(FieldInspectionData, [{
44483
- title: ob.title,
44484
- additionalDetails: {
44485
- isChecklist: true,
44486
- inspectionReport: [],
44487
- values: ob.values
44488
- }
44489
- }]);else {
44490
- var _ob$additionalDetails, _ob$additionalDetails2;
45593
+ if ((BPA === null || BPA === void 0 ? void 0 : BPA.status) === "APPROVAL_INPROGRESS") {
45594
+ var _mdmsRes$BPA2;
44491
45595
 
44492
- var improvedDoc = [].concat((_ob$additionalDetails = ob.additionalDetails.obpsDocuments) === null || _ob$additionalDetails === void 0 ? void 0 : (_ob$additionalDetails2 = _ob$additionalDetails[0]) === null || _ob$additionalDetails2 === void 0 ? void 0 : _ob$additionalDetails2.values);
44493
- improvedDoc.map(function (ob) {
44494
- ob["isNotDuplicate"] = true;
44495
- });
44496
- improvedDoc.map(function (ob, index) {
44497
- val = ob.documentType;
44498
- if (ob.isNotDuplicate == true) for (i = index + 1; i < improvedDoc.length; i++) {
44499
- if (val === improvedDoc[i].documentType) improvedDoc[i].isNotDuplicate = false;
45596
+ mdmsRes === null || mdmsRes === void 0 ? void 0 : (_mdmsRes$BPA2 = mdmsRes.BPA) === null || _mdmsRes$BPA2 === void 0 ? void 0 : _mdmsRes$BPA2.CheckList.forEach(function (checklist) {
45597
+ var _checklist$conditions;
45598
+
45599
+ if ((checklist === null || checklist === void 0 ? void 0 : checklist.RiskType) === riskType && (checklist === null || checklist === void 0 ? void 0 : checklist.applicationType) === (edcr === null || edcr === void 0 ? void 0 : edcr.appliactionType) && (checklist === null || checklist === void 0 ? void 0 : checklist.ServiceType) === (edcr === null || edcr === void 0 ? void 0 : edcr.applicationSubType) && (checklist === null || checklist === void 0 ? void 0 : checklist.WFState) === "PENDINGAPPROVAL" && (checklist === null || checklist === void 0 ? void 0 : (_checklist$conditions = checklist.conditions) === null || _checklist$conditions === void 0 ? void 0 : _checklist$conditions.length) > 0) {
45600
+ approvalChecks.push.apply(approvalChecks, checklist === null || checklist === void 0 ? void 0 : checklist.conditions);
44500
45601
  }
44501
45602
  });
44502
- FieldInspectionData = [].concat(FieldInspectionData, [{
44503
- title: ob.title,
45603
+ approvalChecksDetails = {
45604
+ title: "",
45605
+ isTitleVisible: (approvalChecks === null || approvalChecks === void 0 ? void 0 : approvalChecks.length) > 0 ? false : true,
45606
+ asSectionHeader: true,
45607
+ isPermissions: true,
44504
45608
  additionalDetails: {
44505
- FIdocuments: [],
44506
- "documents": [{
44507
- values: improvedDoc
44508
- }]
45609
+ permissions: approvalChecks
44509
45610
  }
44510
- }]);
45611
+ };
44511
45612
  }
44512
- });
44513
- var fiReports = {
44514
- title: "",
44515
- isFieldInspection: true,
44516
- isNotAllowed: (BPA === null || BPA === void 0 ? void 0 : (_BPA$additionalDetail14 = BPA.additionalDetails) === null || _BPA$additionalDetail14 === void 0 ? void 0 : (_BPA$additionalDetail15 = _BPA$additionalDetail14.fieldinspection_pending) === null || _BPA$additionalDetail15 === void 0 ? void 0 : _BPA$additionalDetail15.length) > 0 ? false : true,
44517
- additionalDetails: {
44518
- values: [],
44519
- fiReport: (BPA === null || BPA === void 0 ? void 0 : (_BPA$additionalDetail16 = BPA.additionalDetails) === null || _BPA$additionalDetail16 === void 0 ? void 0 : (_BPA$additionalDetail17 = _BPA$additionalDetail16.fieldinspection_pending) === null || _BPA$additionalDetail17 === void 0 ? void 0 : _BPA$additionalDetail17.length) > 0 ? true : false
45613
+
45614
+ if (riskType == "LOW" && approvalChecks.length > 0) approvalChecksDetails = {};
45615
+ var val;
45616
+ var i;
45617
+ var FieldInspectionData = [];
45618
+ inspectionReport && (BPA === null || BPA === void 0 ? void 0 : (_BPA$additionalDetail13 = BPA.additionalDetails) === null || _BPA$additionalDetail13 === void 0 ? void 0 : (_BPA$additionalDetail14 = _BPA$additionalDetail13.fieldinspection_pending) === null || _BPA$additionalDetail14 === void 0 ? void 0 : (_BPA$additionalDetail15 = _BPA$additionalDetail14[0]) === null || _BPA$additionalDetail15 === void 0 ? void 0 : _BPA$additionalDetail15.questions.length) > 0 && inspectionReport.map(function (ob, index) {
45619
+ if (ob.title.includes("FI_REPORT")) FieldInspectionData = [].concat(FieldInspectionData, [{
45620
+ title: ob.title,
45621
+ additionalDetails: {
45622
+ inspectionReport: [],
45623
+ values: ob.values
45624
+ }
45625
+ }]);else if (ob.title.includes("CHECK_LIST")) FieldInspectionData = [].concat(FieldInspectionData, [{
45626
+ title: ob.title,
45627
+ additionalDetails: {
45628
+ isChecklist: true,
45629
+ inspectionReport: [],
45630
+ values: ob.values
45631
+ }
45632
+ }]);else {
45633
+ var _ob$additionalDetails, _ob$additionalDetails2;
45634
+
45635
+ var improvedDoc = [].concat((_ob$additionalDetails = ob.additionalDetails.obpsDocuments) === null || _ob$additionalDetails === void 0 ? void 0 : (_ob$additionalDetails2 = _ob$additionalDetails[0]) === null || _ob$additionalDetails2 === void 0 ? void 0 : _ob$additionalDetails2.values);
45636
+ improvedDoc.map(function (ob) {
45637
+ ob["isNotDuplicate"] = true;
45638
+ });
45639
+ improvedDoc.map(function (ob, index) {
45640
+ val = ob.documentType;
45641
+ if (ob.isNotDuplicate == true) for (i = index + 1; i < improvedDoc.length; i++) {
45642
+ if (val === improvedDoc[i].documentType) improvedDoc[i].isNotDuplicate = false;
45643
+ }
45644
+ });
45645
+ FieldInspectionData = [].concat(FieldInspectionData, [{
45646
+ title: ob.title,
45647
+ additionalDetails: {
45648
+ FIdocuments: [],
45649
+ "documents": [{
45650
+ values: improvedDoc
45651
+ }]
45652
+ }
45653
+ }]);
45654
+ }
45655
+ });
45656
+ var fiReports = {
45657
+ title: "",
45658
+ isFieldInspection: true,
45659
+ isNotAllowed: (BPA === null || BPA === void 0 ? void 0 : (_BPA$additionalDetail16 = BPA.additionalDetails) === null || _BPA$additionalDetail16 === void 0 ? void 0 : (_BPA$additionalDetail17 = _BPA$additionalDetail16.fieldinspection_pending) === null || _BPA$additionalDetail17 === void 0 ? void 0 : _BPA$additionalDetail17.length) > 0 ? false : true,
45660
+ additionalDetails: {
45661
+ values: [],
45662
+ fiReport: (BPA === null || BPA === void 0 ? void 0 : (_BPA$additionalDetail18 = BPA.additionalDetails) === null || _BPA$additionalDetail18 === void 0 ? void 0 : (_BPA$additionalDetail19 = _BPA$additionalDetail18.fieldinspection_pending) === null || _BPA$additionalDetail19 === void 0 ? void 0 : _BPA$additionalDetail19.length) > 0 ? true : false
45663
+ }
45664
+ };
45665
+
45666
+ if ((BPA === null || BPA === void 0 ? void 0 : BPA.businessService) !== "BPA_OC") {
45667
+ details = [].concat(details, [applicationDetailsInfo, basicDetails, plotDetails, scrutinyDetails, buildingExtractionDetails, subOccupancyTableDetails, demolitionAreaDetails, addressDetails, ownerDetails, documentDetails, fiReports], nocDetails, [approvalChecksDetails, PermitConditions]);
45668
+ } else {
45669
+ details = [].concat(details, [applicationDetailsInfo, basicDetails, plotDetails, scrutinyDetails, buildingExtractionDetails, subOccupancyTableDetails, demolitionAreaDetails, documentDetails, fiReports], nocDetails, [PermitConditions]);
44520
45670
  }
44521
- };
44522
45671
 
44523
- if ((BPA === null || BPA === void 0 ? void 0 : BPA.businessService) !== "BPA_OC") {
44524
- details = [].concat(details, [applicationDetailsInfo, basicDetails, plotDetails, scrutinyDetails, buildingExtractionDetails, subOccupancyTableDetails, demolitionAreaDetails, addressDetails, ownerDetails, documentDetails, fiReports], nocDetails, [approvalChecksDetails, PermitConditions]);
44525
- } else {
44526
- details = [].concat(details, [applicationDetailsInfo, basicDetails, plotDetails, scrutinyDetails, buildingExtractionDetails, subOccupancyTableDetails, demolitionAreaDetails, documentDetails, fiReports], nocDetails, [PermitConditions]);
45672
+ var bpaFilterDetails = (_details = details) === null || _details === void 0 ? void 0 : _details.filter(function (data) {
45673
+ return data;
45674
+ });
45675
+ return {
45676
+ applicationData: BPA,
45677
+ applicationDetails: bpaFilterDetails,
45678
+ tenantId: BPA === null || BPA === void 0 ? void 0 : BPA.tenantId,
45679
+ edcrDetails: edcr,
45680
+ nocData: noc,
45681
+ comparisionReport: comparisionReport === null || comparisionReport === void 0 ? void 0 : comparisionReport.comparisonDetail,
45682
+ businessService: BPA === null || BPA === void 0 ? void 0 : BPA.businessService,
45683
+ applicationNo: BPA === null || BPA === void 0 ? void 0 : BPA.applicationNo,
45684
+ applicationStatus: BPA === null || BPA === void 0 ? void 0 : BPA.status
45685
+ };
44527
45686
  }
44528
45687
 
44529
- var bpaFilterDetails = (_details = details) === null || _details === void 0 ? void 0 : _details.filter(function (data) {
44530
- return data;
45688
+ noc === null || noc === void 0 ? void 0 : noc.map(function (nocDetails) {
45689
+ var _nocDetails$documents2;
45690
+
45691
+ nocDetails === null || nocDetails === void 0 ? void 0 : (_nocDetails$documents2 = nocDetails.documents) === null || _nocDetails$documents2 === void 0 ? void 0 : _nocDetails$documents2.map(function (nocDoc) {
45692
+ if (nocDoc !== null && nocDoc !== void 0 && nocDoc.fileStoreId) appDocumentFileStoreIds.push(nocDoc === null || nocDoc === void 0 ? void 0 : nocDoc.fileStoreId);
45693
+ });
44531
45694
  });
44532
- return {
44533
- applicationData: BPA,
44534
- applicationDetails: bpaFilterDetails,
44535
- tenantId: BPA === null || BPA === void 0 ? void 0 : BPA.tenantId,
44536
- edcrDetails: edcr,
44537
- nocData: noc,
44538
- comparisionReport: comparisionReport === null || comparisionReport === void 0 ? void 0 : comparisionReport.comparisonDetail,
44539
- businessService: BPA === null || BPA === void 0 ? void 0 : BPA.businessService,
44540
- applicationNo: BPA === null || BPA === void 0 ? void 0 : BPA.applicationNo,
44541
- applicationStatus: BPA === null || BPA === void 0 ? void 0 : BPA.status
44542
- };
45695
+ var fileDetails = {};
45696
+
45697
+ var _temp3 = function () {
45698
+ var _appDocumentFileStore;
45699
+
45700
+ if (((_appDocumentFileStore = appDocumentFileStoreIds) === null || _appDocumentFileStore === void 0 ? void 0 : _appDocumentFileStore.length) > 0) {
45701
+ return Promise.resolve(UploadServices.Filefetch(appDocumentFileStoreIds, Digit.ULBService.getStateId())).then(function (_UploadServices$Filef2) {
45702
+ fileDetails = _UploadServices$Filef2;
45703
+ });
45704
+ }
45705
+ }();
45706
+
45707
+ return _temp3 && _temp3.then ? _temp3.then(_temp4) : _temp4(_temp3);
44543
45708
  });
44544
45709
  });
44545
45710
  });
@@ -44824,6 +45989,34 @@ var useOBPSDocumentSearch = function useOBPSDocumentSearch(_ref, config, Code, i
44824
45989
  };
44825
45990
  };
44826
45991
 
45992
+ var updateNOCAPI = function updateNOCAPI(data, tenantId) {
45993
+ try {
45994
+ return Promise.resolve(_catch(function () {
45995
+ return Promise.resolve(OBPSService.updateNOC(data, tenantId));
45996
+ }, function (error) {
45997
+ var _error$response, _error$response$data;
45998
+
45999
+ throw new Error(error === null || error === void 0 ? void 0 : (_error$response = error.response) === null || _error$response === void 0 ? void 0 : (_error$response$data = _error$response.data) === null || _error$response$data === void 0 ? void 0 : _error$response$data.Errors[0].code);
46000
+ }));
46001
+ } catch (e) {
46002
+ return Promise.reject(e);
46003
+ }
46004
+ };
46005
+
46006
+ var updateAPI = function updateAPI(data, tenantId) {
46007
+ try {
46008
+ return Promise.resolve(_catch(function () {
46009
+ return Promise.resolve(OBPSService.update(data, tenantId));
46010
+ }, function (error) {
46011
+ var _error$response2, _error$response2$data;
46012
+
46013
+ throw new Error(error === null || error === void 0 ? void 0 : (_error$response2 = error.response) === null || _error$response2 === void 0 ? void 0 : (_error$response2$data = _error$response2.data) === null || _error$response2$data === void 0 ? void 0 : _error$response2$data.Errors[0].code);
46014
+ }));
46015
+ } catch (e) {
46016
+ return Promise.reject(e);
46017
+ }
46018
+ };
46019
+
44827
46020
  var useObpsAPI = function useObpsAPI(tenantId, type) {
44828
46021
  if (type === void 0) {
44829
46022
  type = false;
@@ -44831,11 +46024,11 @@ var useObpsAPI = function useObpsAPI(tenantId, type) {
44831
46024
 
44832
46025
  if (type) {
44833
46026
  return useMutation(function (data) {
44834
- return OBPSService.updateNOC(data, tenantId);
46027
+ return updateNOCAPI(data, tenantId);
44835
46028
  });
44836
46029
  } else {
44837
46030
  return useMutation(function (data) {
44838
- return OBPSService.update(data, tenantId);
46031
+ return updateAPI(data, tenantId);
44839
46032
  });
44840
46033
  }
44841
46034
  };
@@ -45019,7 +46212,7 @@ var useBPAInbox = function useBPAInbox(_ref) {
45019
46212
  processSearchCriteria: _extends({
45020
46213
  assignee: assignee === "ASSIGNED_TO_ME" ? user === null || user === void 0 ? void 0 : (_user$info = user.info) === null || _user$info === void 0 ? void 0 : _user$info.uuid : "",
45021
46214
  moduleName: moduleName !== "BPAREG" ? "bpa-services" : "BPAREG",
45022
- businessService: moduleName !== "BPAREG" ? businessService ? [businessService] : ["BPA_LOW", "BPA", "BPA_OC"] : businessService ? [businessService.identifier] : ["ARCHITECT", "BUILDER", "ENGINEER", "STRUCTURALENGINEER"]
46215
+ businessService: moduleName !== "BPAREG" ? businessService ? [businessService] : ["BPA_LOW", "BPA", "BPA_OC"] : businessService ? [businessService.identifier] : ["ARCHITECT", "BUILDER", "ENGINEER", "STRUCTURALENGINEER", "TOWNPLANNER", "SUPERVISOR"]
45023
46216
  }, (applicationStatus === null || applicationStatus === void 0 ? void 0 : applicationStatus.length) > 0 ? {
45024
46217
  status: applicationStatus
45025
46218
  } : {}),
@@ -45042,9 +46235,15 @@ var useBPAInbox = function useBPAInbox(_ref) {
45042
46235
  return item.code.split("_").pop();
45043
46236
  }).join(",")
45044
46237
  } : {}),
45045
- limit: limit,
45046
- offset: offset
46238
+ limit: limit
45047
46239
  };
46240
+
46241
+ if (!applicationNo) {
46242
+ _filters = _extends({}, _filters, {
46243
+ offset: offset
46244
+ });
46245
+ }
46246
+
45048
46247
  return useInbox({
45049
46248
  tenantId: tenantId,
45050
46249
  filters: _filters,
@@ -45441,8 +46640,8 @@ var useBusinessServiceData = function useBusinessServiceData(tenantId, businessS
45441
46640
  }, config);
45442
46641
  };
45443
46642
 
45444
- var useBPATaxDocuments = function useBPATaxDocuments(stateId, formData, PrevStateDocuments) {
45445
- var _bpaDocs$BPA, _filtredBpaDocs, _filtredBpaDocs$, _filtredBpaDocs$$docT;
46643
+ var useBPATaxDocuments = function useBPATaxDocuments(stateId, formData, beforeUploadDocuments) {
46644
+ var _beforeUploadDocument, _data$pdfFiles, _bpaDocs$BPA, _filtredBpaDocs, _filtredBpaDocs$, _filtredBpaDocs$$docT;
45446
46645
 
45447
46646
  var _Digit$Hooks$obps$use = Digit.Hooks.obps.useMDMS(stateId, "BPA", ["DocTypeMapping"]),
45448
46647
  bpaDocsLoading = _Digit$Hooks$obps$use.isLoading,
@@ -45452,6 +46651,17 @@ var useBPATaxDocuments = function useBPATaxDocuments(stateId, formData, PrevStat
45452
46651
  commonDocsLoading = _Digit$Hooks$obps$use2.isLoading,
45453
46652
  commonDocs = _Digit$Hooks$obps$use2.data;
45454
46653
 
46654
+ var documents = beforeUploadDocuments;
46655
+
46656
+ var _Digit$Hooks$useDocum = Digit.Hooks.useDocumentSearch(documents, {
46657
+ enabled: ((_beforeUploadDocument = beforeUploadDocuments) === null || _beforeUploadDocument === void 0 ? void 0 : _beforeUploadDocument.length) > 0 ? true : false
46658
+ }),
46659
+ data = _Digit$Hooks$useDocum.data;
46660
+
46661
+ if ((data === null || data === void 0 ? void 0 : (_data$pdfFiles = data.pdfFiles) === null || _data$pdfFiles === void 0 ? void 0 : _data$pdfFiles.length) > 0) {
46662
+ beforeUploadDocuments = data === null || data === void 0 ? void 0 : data.pdfFiles;
46663
+ }
46664
+
45455
46665
  var filtredBpaDocs = [];
45456
46666
 
45457
46667
  if (bpaDocs !== null && bpaDocs !== void 0 && (_bpaDocs$BPA = bpaDocs.BPA) !== null && _bpaDocs$BPA !== void 0 && _bpaDocs$BPA.DocTypeMapping) {
@@ -45482,7 +46692,7 @@ var useBPATaxDocuments = function useBPATaxDocuments(stateId, formData, PrevStat
45482
46692
  });
45483
46693
  doc.uploadedDocuments[0] = {};
45484
46694
  doc.uploadedDocuments[0].values = [];
45485
- PrevStateDocuments.map(function (upDocs) {
46695
+ beforeUploadDocuments.map(function (upDocs) {
45486
46696
  var _upDocs$documentType, _upDocs$documentType2;
45487
46697
 
45488
46698
  if (code === (upDocs === null || upDocs === void 0 ? void 0 : (_upDocs$documentType = upDocs.documentType) === null || _upDocs$documentType === void 0 ? void 0 : _upDocs$documentType.split('.')[0]) + "." + (upDocs === null || upDocs === void 0 ? void 0 : (_upDocs$documentType2 = upDocs.documentType) === null || _upDocs$documentType2 === void 0 ? void 0 : _upDocs$documentType2.split('.')[1])) {
@@ -46171,7 +47381,7 @@ var getDate = function getDate(epochdate) {
46171
47381
  return epochdate ? new Date(epochdate).getDate() + "/" + (new Date(epochdate).getMonth() + 1) + "/" + new Date(epochdate).getFullYear().toString() : "NA";
46172
47382
  };
46173
47383
 
46174
- var getAddress = function getAddress(address, t) {
47384
+ var getAddress$1 = function getAddress(address, t) {
46175
47385
  return (address !== null && address !== void 0 && address.doorNo ? (address === null || address === void 0 ? void 0 : address.doorNo) + ", " : "") + " " + (address !== null && address !== void 0 && address.street ? (address === null || address === void 0 ? void 0 : address.street) + ", " : "") + (address !== null && address !== void 0 && address.landmark ? (address === null || address === void 0 ? void 0 : address.landmark) + ", " : "") + t(address === null || address === void 0 ? void 0 : address.locality.code) + ", " + t(address === null || address === void 0 ? void 0 : address.city.code) + "," + (t(address === null || address === void 0 ? void 0 : address.pincode) ? "" + address.pincode : " ");
46176
47386
  };
46177
47387
 
@@ -46188,7 +47398,7 @@ var combineResponse$4 = function combineResponse(WaterConnections, properties, b
46188
47398
  })[0]) === null || _properties$filter$ === void 0 ? void 0 : (_properties$filter$$o = _properties$filter$.owners) === null || _properties$filter$$o === void 0 ? void 0 : _properties$filter$$o.map(function (ow) {
46189
47399
  return ow.name;
46190
47400
  }).join(","),
46191
- Address: getAddress(properties.filter(function (prop) {
47401
+ Address: getAddress$1(properties.filter(function (prop) {
46192
47402
  return prop.propertyId === (app === null || app === void 0 ? void 0 : app.propertyId);
46193
47403
  })[0].address, t),
46194
47404
  AmountDue: billData ? billData !== null && billData !== void 0 && (_billData$filter$ = billData.filter(function (bill) {
@@ -46272,7 +47482,7 @@ var getDate$1 = function getDate(epochdate) {
46272
47482
  return epochdate ? new Date(epochdate).getDate() + "/" + (new Date(epochdate).getMonth() + 1) + "/" + new Date(epochdate).getFullYear().toString() : "NA";
46273
47483
  };
46274
47484
 
46275
- var getAddress$1 = function getAddress(address, t) {
47485
+ var getAddress$2 = function getAddress(address, t) {
46276
47486
  return (address !== null && address !== void 0 && address.doorNo ? (address === null || address === void 0 ? void 0 : address.doorNo) + ", " : "") + " " + (address !== null && address !== void 0 && address.street ? (address === null || address === void 0 ? void 0 : address.street) + ", " : "") + (address !== null && address !== void 0 && address.landmark ? (address === null || address === void 0 ? void 0 : address.landmark) + ", " : "") + t(address === null || address === void 0 ? void 0 : address.locality.code) + ", " + t(address === null || address === void 0 ? void 0 : address.city.code) + "," + (t(address === null || address === void 0 ? void 0 : address.pincode) ? "" + address.pincode : " ");
46277
47487
  };
46278
47488
 
@@ -46289,7 +47499,7 @@ var combineResponse$5 = function combineResponse(WaterConnections, properties, b
46289
47499
  })[0]) === null || _properties$filter$ === void 0 ? void 0 : (_properties$filter$$o = _properties$filter$.owners) === null || _properties$filter$$o === void 0 ? void 0 : _properties$filter$$o.map(function (ow) {
46290
47500
  return ow.name;
46291
47501
  }).join(","),
46292
- Address: getAddress$1(properties.filter(function (prop) {
47502
+ Address: getAddress$2(properties.filter(function (prop) {
46293
47503
  return prop.propertyId === (app === null || app === void 0 ? void 0 : app.propertyId);
46294
47504
  })[0].address, t),
46295
47505
  AmountDue: billData ? billData !== null && billData !== void 0 && (_billData$filter$0$bi = billData.filter(function (bill) {
@@ -46563,6 +47773,7 @@ var Hooks = {
46563
47773
  useClearNotifications: useClearNotifications,
46564
47774
  useNotificationCount: useNotificationCount,
46565
47775
  useStore: useStore$1,
47776
+ useDocumentSearch: useDocumentSearch,
46566
47777
  useTenants: useTenants,
46567
47778
  useInbox: useTLInbox,
46568
47779
  pgr: pgr,