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