@argusoft/medplat-core 1.0.30 → 1.0.32

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.
Files changed (226) hide show
  1. package/dist/{AccessRights-xrday-L1.js → AccessRights-DBjTQA1-.js} +395 -390
  2. package/dist/AccessRights-DBjTQA1-.js.map +1 -0
  3. package/dist/{AddFeatures-D1sU8RjY.js → AddFeatures-COj4ZTIM.js} +2 -2
  4. package/dist/{AddFeatures-D1sU8RjY.js.map → AddFeatures-COj4ZTIM.js.map} +1 -1
  5. package/dist/AddMenuConfiguration-Creeib5X.js +11223 -0
  6. package/dist/AddMenuConfiguration-Creeib5X.js.map +1 -0
  7. package/dist/AddMenuConfiguration.css +1 -1
  8. package/dist/{BrandsPage-DmRW5bhm-Bk1szrjI.js → BrandsPage-CdcAvaml-ZtVTX6vX.js} +43 -43
  9. package/dist/{BrandsPage-DmRW5bhm-Bk1szrjI.js.map → BrandsPage-CdcAvaml-ZtVTX6vX.js.map} +1 -1
  10. package/dist/{CategoriesPage-BsS5IQh3-B03lWRY5.js → CategoriesPage-BprQEYJw-CclreTv1.js} +109 -102
  11. package/dist/CategoriesPage-BprQEYJw-CclreTv1.js.map +1 -0
  12. package/dist/{ChangePasswordModalCore-BPsJquTS.js → ChangePasswordModalCore-DZGOkbRY.js} +3 -3
  13. package/dist/{ChangePasswordModalCore-BPsJquTS.js.map → ChangePasswordModalCore-DZGOkbRY.js.map} +1 -1
  14. package/dist/ConditionConfig-Bpm6OoV5.js +408 -0
  15. package/dist/ConditionConfig-Bpm6OoV5.js.map +1 -0
  16. package/dist/{DashboardPage-C3bKc5na-sBd9Yqbi.js → DashboardPage-CTiGSx71-CsYohJ5e.js} +32 -32
  17. package/dist/{DashboardPage-C3bKc5na-sBd9Yqbi.js.map → DashboardPage-CTiGSx71-CsYohJ5e.js.map} +1 -1
  18. package/dist/EntityManagement-BGwJGl9k.js +62 -0
  19. package/dist/EntityManagement-BGwJGl9k.js.map +1 -0
  20. package/dist/EventConfig-BY2cgGyx.js +27 -0
  21. package/dist/{EventConfig-BmLemzX3.js.map → EventConfig-BY2cgGyx.js.map} +1 -1
  22. package/dist/EventConfigurations-B-z7xHh_.js +544 -0
  23. package/dist/EventConfigurations-B-z7xHh_.js.map +1 -0
  24. package/dist/EventConfigurations.css +1 -1
  25. package/dist/EventsExceptionModal-DafomIv6.js +188 -0
  26. package/dist/EventsExceptionModal-DafomIv6.js.map +1 -0
  27. package/dist/EventsUi-Dl_yckSA.js +263 -0
  28. package/dist/EventsUi-Dl_yckSA.js.map +1 -0
  29. package/dist/FacilityPicker-BXa2VF7i-Dab_Jwa5.js +112 -0
  30. package/dist/FacilityPicker-BXa2VF7i-Dab_Jwa5.js.map +1 -0
  31. package/dist/{FeatureMenu-DYJmDt7q.js → FeatureMenu-Kc73yPHH.js} +9 -5
  32. package/dist/FeatureMenu-Kc73yPHH.js.map +1 -0
  33. package/dist/{FhirServerList-DuTwnngN.js → FhirServerList-CrIHMAxz.js} +16 -16
  34. package/dist/{FhirServerList-DuTwnngN.js.map → FhirServerList-CrIHMAxz.js.map} +1 -1
  35. package/dist/{FhirServerProfile-CUOwC6Wb.js → FhirServerProfile-D3aYcpwY.js} +8 -8
  36. package/dist/{FhirServerProfile-CUOwC6Wb.js.map → FhirServerProfile-D3aYcpwY.js.map} +1 -1
  37. package/dist/{FhirServerWizard-DZI8Olku.js → FhirServerWizard-Db6Hm4bQ.js} +15 -15
  38. package/dist/{FhirServerWizard-DZI8Olku.js.map → FhirServerWizard-Db6Hm4bQ.js.map} +1 -1
  39. package/dist/{GrantPermissionModal-BDN66Atn.js → GrantPermissionModal-D7iNZd0M.js} +54 -51
  40. package/dist/GrantPermissionModal-D7iNZd0M.js.map +1 -0
  41. package/dist/ImmunizationConfigurationBase-lKsJZMak.js +8060 -0
  42. package/dist/ImmunizationConfigurationBase-lKsJZMak.js.map +1 -0
  43. package/dist/InventoryPage-JadYMCzU-CzJQfQ2A.js +1017 -0
  44. package/dist/InventoryPage-JadYMCzU-CzJQfQ2A.js.map +1 -0
  45. package/dist/LocationWiseExpectedTargetPage-CjKk1aTF.js +1344 -0
  46. package/dist/LocationWiseExpectedTargetPage-CjKk1aTF.js.map +1 -0
  47. package/dist/{ManageDynamicFeature-BU0I45dd.js → ManageDynamicFeature-CuyYfx_P.js} +104 -97
  48. package/dist/ManageDynamicFeature-CuyYfx_P.js.map +1 -0
  49. package/dist/ManageEventConfiguration-DqPbn3Oi.js +1216 -0
  50. package/dist/ManageEventConfiguration-DqPbn3Oi.js.map +1 -0
  51. package/dist/ManageEventConfiguration.css +1 -1
  52. package/dist/ManageRole-CyfpySt9.js +981 -0
  53. package/dist/ManageRole-CyfpySt9.js.map +1 -0
  54. package/dist/{ManageUser-DCFkUMV9.js → ManageUser-Dm0l833u.js} +286 -286
  55. package/dist/{ManageUser-DCFkUMV9.js.map → ManageUser-Dm0l833u.js.map} +1 -1
  56. package/dist/{MemberProfileCard-BdUNgHRB-VywqQdFF.js → MemberProfileCard-01d_jz3w-DYHtbgMX.js} +46 -46
  57. package/dist/{MemberProfileCard-BdUNgHRB-VywqQdFF.js.map → MemberProfileCard-01d_jz3w-DYHtbgMX.js.map} +1 -1
  58. package/dist/MobileAnalytics-C9oc2yAo.js +18399 -0
  59. package/dist/MobileAnalytics-C9oc2yAo.js.map +1 -0
  60. package/dist/MobileMenuManagement-BmzTPXy7.js +231 -0
  61. package/dist/MobileMenuManagement-BmzTPXy7.js.map +1 -0
  62. package/dist/MobileTypeEventConfigModal-DodU3beR.js +752 -0
  63. package/dist/MobileTypeEventConfigModal-DodU3beR.js.map +1 -0
  64. package/dist/{NewServerManagement-Cxe0dV0O.js → NewServerManagement-BdayO78D.js} +368 -352
  65. package/dist/NewServerManagement-BdayO78D.js.map +1 -0
  66. package/dist/OtherTypeEventConfigModal-D_9S50aI.js +1414 -0
  67. package/dist/OtherTypeEventConfigModal-D_9S50aI.js.map +1 -0
  68. package/dist/{PaymentCreatePage-CIVe0P0p-25BQVpOX.js → PaymentCreatePage-D6NZBUC3-DxXf2kvH.js} +58 -58
  69. package/dist/{PaymentCreatePage-CIVe0P0p-25BQVpOX.js.map → PaymentCreatePage-D6NZBUC3-DxXf2kvH.js.map} +1 -1
  70. package/dist/{PaymentsPage-BvPe5Q9F-D2gfziwW.js → PaymentsPage-CHieGNrn-BnYCtqHd.js} +37 -37
  71. package/dist/{PaymentsPage-BvPe5Q9F-D2gfziwW.js.map → PaymentsPage-CHieGNrn-BnYCtqHd.js.map} +1 -1
  72. package/dist/{PermissionsModal-CCYkcKlC.js → PermissionsModal-Dxbkkrqe.js} +18 -18
  73. package/dist/PermissionsModal-Dxbkkrqe.js.map +1 -0
  74. package/dist/{PickupBatchLinesEditor-DHmcAG23-DL2p6IKJ.js → PickupBatchLinesEditor-QPaqFtUO-CY7BShYh.js} +2 -2
  75. package/dist/{PickupBatchLinesEditor-DHmcAG23-DL2p6IKJ.js.map → PickupBatchLinesEditor-QPaqFtUO-CY7BShYh.js.map} +1 -1
  76. package/dist/PickupCreatePage-C7_67u_u-OId8-e2a.js +801 -0
  77. package/dist/PickupCreatePage-C7_67u_u-OId8-e2a.js.map +1 -0
  78. package/dist/{PickupsPage-Ctpghavs-CUp4uIZq.js → PickupsPage-BWblMlic-CWkgeBw0.js} +132 -132
  79. package/dist/PickupsPage-BWblMlic-CWkgeBw0.js.map +1 -0
  80. package/dist/PmGuard-BvUUbU80-BpYNaDzl.js +641 -0
  81. package/dist/PmGuard-BvUUbU80-BpYNaDzl.js.map +1 -0
  82. package/dist/ProductEditPage-Dbq4vUAA-BoBmTPPL.js +1523 -0
  83. package/dist/ProductEditPage-Dbq4vUAA-BoBmTPPL.js.map +1 -0
  84. package/dist/{ProductsPage-CupVmOD4-D45a_hf-.js → ProductsPage-BI22nPb4-CQBjnc-n.js} +44 -43
  85. package/dist/ProductsPage-BI22nPb4-CQBjnc-n.js.map +1 -0
  86. package/dist/PurchaseCreatePage-C0EK9z4w-BQMTsjE7.js +724 -0
  87. package/dist/PurchaseCreatePage-C0EK9z4w-BQMTsjE7.js.map +1 -0
  88. package/dist/{PurchaseRequestDetailPage-Dg_MRY_N-D1bgTEAn.js → PurchaseRequestDetailPage-DhBuOGHZ-CWZPqzt9.js} +428 -418
  89. package/dist/PurchaseRequestDetailPage-DhBuOGHZ-CWZPqzt9.js.map +1 -0
  90. package/dist/{PurchaseRequestsPage-DPAPzpmm-mDH2IrTl.js → PurchaseRequestsPage-Bj9HUMxb-B7-AxT8m.js} +65 -65
  91. package/dist/{PurchaseRequestsPage-DPAPzpmm-mDH2IrTl.js.map → PurchaseRequestsPage-Bj9HUMxb-B7-AxT8m.js.map} +1 -1
  92. package/dist/{PurchasesPage-It1GHiXl-eH4IsF_U.js → PurchasesPage-Djl1AqD_-DXeYFMrX.js} +55 -55
  93. package/dist/{PurchasesPage-It1GHiXl-eH4IsF_U.js.map → PurchasesPage-Djl1AqD_-DXeYFMrX.js.map} +1 -1
  94. package/dist/{RoleManagement-s8iNx2Mu.js → RoleManagement-DVYufwy-.js} +3 -3
  95. package/dist/{RoleManagement-s8iNx2Mu.js.map → RoleManagement-DVYufwy-.js.map} +1 -1
  96. package/dist/Roles-BoNGJhtR.js +19 -0
  97. package/dist/Roles-BoNGJhtR.js.map +1 -0
  98. package/dist/{SaleCreatePage-C9kFmTvm-B3Y0o4CX.js → SaleCreatePage-DHBLmlBr-BlgjVsq6.js} +39 -39
  99. package/dist/{SaleCreatePage-C9kFmTvm-B3Y0o4CX.js.map → SaleCreatePage-DHBLmlBr-BlgjVsq6.js.map} +1 -1
  100. package/dist/{SalesPage-D18DCseD-BxktGDRQ.js → SalesPage-eF9Yr42z-BQ9FlXC3.js} +61 -61
  101. package/dist/{SalesPage-D18DCseD-BxktGDRQ.js.map → SalesPage-eF9Yr42z-BQ9FlXC3.js.map} +1 -1
  102. package/dist/SettingsPage-Cre-UE3r-9ntnLYsQ.js +741 -0
  103. package/dist/SettingsPage-Cre-UE3r-9ntnLYsQ.js.map +1 -0
  104. package/dist/{ShowFlywayQuery-D1y_4A1u.js → ShowFlywayQuery-DIOUdYfG.js} +26 -19
  105. package/dist/{ShowFlywayQuery-D1y_4A1u.js.map → ShowFlywayQuery-DIOUdYfG.js.map} +1 -1
  106. package/dist/{StorageUnitsPage-7EqwuMOI-BwUso1Th.js → StorageUnitsPage-CTEVuemZ-B4osG74N.js} +253 -223
  107. package/dist/StorageUnitsPage-CTEVuemZ-B4osG74N.js.map +1 -0
  108. package/dist/{SubMenu-eEDhZUvh.js → SubMenu-OO2zhKiu.js} +5 -3
  109. package/dist/SubMenu-OO2zhKiu.js.map +1 -0
  110. package/dist/{TableDetails-BtafRxXb.js → TableDetails-Cc40dEUs.js} +272 -267
  111. package/dist/TableDetails-Cc40dEUs.js.map +1 -0
  112. package/dist/{TableList-Dpo6dO7S.js → TableList-B5tX4wII.js} +316 -312
  113. package/dist/TableList-B5tX4wII.js.map +1 -0
  114. package/dist/{TransactionsPage-DrH53pVS-BkhIGB6C.js → TransactionsPage-Zuu7sjID-B-ACzvd1.js} +195 -180
  115. package/dist/TransactionsPage-Zuu7sjID-B-ACzvd1.js.map +1 -0
  116. package/dist/TransferCreatePage-DlT0nCDj-B2SdPgYB.js +635 -0
  117. package/dist/TransferCreatePage-DlT0nCDj-B2SdPgYB.js.map +1 -0
  118. package/dist/TransfersPage-DqaSvHda-G2tFa5Jq.js +600 -0
  119. package/dist/TransfersPage-DqaSvHda-G2tFa5Jq.js.map +1 -0
  120. package/dist/TypeConfiguration-EaFiOzRE.js +114 -0
  121. package/dist/TypeConfiguration-EaFiOzRE.js.map +1 -0
  122. package/dist/UserList-Cf5B-o_1.js +1904 -0
  123. package/dist/UserList-Cf5B-o_1.js.map +1 -0
  124. package/dist/Users-MC7txo1V.js +43 -0
  125. package/dist/{Users-Bpc4Sazd.js.map → Users-MC7txo1V.js.map} +1 -1
  126. package/dist/VaccineEducation-T_UE57Ef.js +231 -0
  127. package/dist/VaccineEducation-T_UE57Ef.js.map +1 -0
  128. package/dist/VaccineEducation.css +1 -0
  129. package/dist/VaccineEducationConfigurator-CWc20_rv.js +50948 -0
  130. package/dist/VaccineEducationConfigurator-CWc20_rv.js.map +1 -0
  131. package/dist/VaccineEducationConfigurator.css +4 -0
  132. package/dist/VaccineEducationList-Ok7_5EFb.js +334 -0
  133. package/dist/VaccineEducationList-Ok7_5EFb.js.map +1 -0
  134. package/dist/VialsPage-LoDaUqVv-DmMXbK8j.js +457 -0
  135. package/dist/VialsPage-LoDaUqVv-DmMXbK8j.js.map +1 -0
  136. package/dist/{constants-ClZJY2x1-MkSWn6TZ.js → constants-BTpJFQe_-CYPZIqQF.js} +166 -56
  137. package/dist/constants-BTpJFQe_-CYPZIqQF.js.map +1 -0
  138. package/dist/dashboardLayoutUtils--xUnoKPa.js +615 -0
  139. package/dist/dashboardLayoutUtils--xUnoKPa.js.map +1 -0
  140. package/dist/index-mfoqII2U.js +524 -0
  141. package/dist/index-mfoqII2U.js.map +1 -0
  142. package/dist/{index-D9YNFPn9.js → index-o8Pyt1Bt.js} +445 -439
  143. package/dist/index-o8Pyt1Bt.js.map +1 -0
  144. package/dist/index.css +1 -1
  145. package/dist/index.js +1 -1
  146. package/dist/index.lib-BySa9-Z-.js +936 -0
  147. package/dist/index.lib-BySa9-Z-.js.map +1 -0
  148. package/dist/listValueStore-5d4vNGQM-WclZ5nBG.js +43 -0
  149. package/dist/listValueStore-5d4vNGQM-WclZ5nBG.js.map +1 -0
  150. package/package.json +5 -1
  151. package/dist/AccessRights-xrday-L1.js.map +0 -1
  152. package/dist/AddMenuConfiguration-e5BVXhmw.js +0 -8547
  153. package/dist/AddMenuConfiguration-e5BVXhmw.js.map +0 -1
  154. package/dist/CategoriesPage-BsS5IQh3-B03lWRY5.js.map +0 -1
  155. package/dist/ConditionConfig-Ddz9halE.js +0 -395
  156. package/dist/ConditionConfig-Ddz9halE.js.map +0 -1
  157. package/dist/ConditionConfig.css +0 -1
  158. package/dist/EntityManagement-CPQL6qBj.js +0 -50
  159. package/dist/EntityManagement-CPQL6qBj.js.map +0 -1
  160. package/dist/EventConfig-BmLemzX3.js +0 -26
  161. package/dist/EventConfigurations-Bzh1qWXU.js +0 -450
  162. package/dist/EventConfigurations-Bzh1qWXU.js.map +0 -1
  163. package/dist/EventsExceptionModal-B2SRrnB1.js +0 -200
  164. package/dist/EventsExceptionModal-B2SRrnB1.js.map +0 -1
  165. package/dist/EventsSkeleton-BIcPks4T.js +0 -61
  166. package/dist/EventsSkeleton-BIcPks4T.js.map +0 -1
  167. package/dist/FacilityPicker-BiZeupmP-CyPHmj6b.js +0 -79
  168. package/dist/FacilityPicker-BiZeupmP-CyPHmj6b.js.map +0 -1
  169. package/dist/FeatureMenu-DYJmDt7q.js.map +0 -1
  170. package/dist/GrantPermissionModal-BDN66Atn.js.map +0 -1
  171. package/dist/ImmunizationConfigurationBase-Di1KO3oW.js +0 -7639
  172. package/dist/ImmunizationConfigurationBase-Di1KO3oW.js.map +0 -1
  173. package/dist/InventoryPage-C_AxSy7A-QLvlL4rE.js +0 -665
  174. package/dist/InventoryPage-C_AxSy7A-QLvlL4rE.js.map +0 -1
  175. package/dist/ManageDynamicFeature-BU0I45dd.js.map +0 -1
  176. package/dist/ManageEventConfiguration-CoYcpjR9.js +0 -1085
  177. package/dist/ManageEventConfiguration-CoYcpjR9.js.map +0 -1
  178. package/dist/ManageRole-CNZBRKGU.js +0 -776
  179. package/dist/ManageRole-CNZBRKGU.js.map +0 -1
  180. package/dist/MobileAnalytics-pQoE8cG1.js +0 -16888
  181. package/dist/MobileAnalytics-pQoE8cG1.js.map +0 -1
  182. package/dist/MobileMenuManagement-Cf8IZlla.js +0 -108
  183. package/dist/MobileMenuManagement-Cf8IZlla.js.map +0 -1
  184. package/dist/MobileTypeEventConfigModal-BeveaX0C.js +0 -783
  185. package/dist/MobileTypeEventConfigModal-BeveaX0C.js.map +0 -1
  186. package/dist/NewServerManagement-Cxe0dV0O.js.map +0 -1
  187. package/dist/OtherTypeEventConfigModal-CM6VkdmY.js +0 -2046
  188. package/dist/OtherTypeEventConfigModal-CM6VkdmY.js.map +0 -1
  189. package/dist/PermissionsModal-CCYkcKlC.js.map +0 -1
  190. package/dist/PickupCreatePage-CB0Sl0Hb-Mmj7zESG.js +0 -783
  191. package/dist/PickupCreatePage-CB0Sl0Hb-Mmj7zESG.js.map +0 -1
  192. package/dist/PickupsPage-Ctpghavs-CUp4uIZq.js.map +0 -1
  193. package/dist/PmGuard-b10TGXEi-G3N0G_Wg.js +0 -599
  194. package/dist/PmGuard-b10TGXEi-G3N0G_Wg.js.map +0 -1
  195. package/dist/ProductEditPage-C1thoKHu-URQaZ6st.js +0 -1302
  196. package/dist/ProductEditPage-C1thoKHu-URQaZ6st.js.map +0 -1
  197. package/dist/ProductsPage-CupVmOD4-D45a_hf-.js.map +0 -1
  198. package/dist/PurchaseCreatePage-YD3NmhPQ-2j4etSjM.js +0 -648
  199. package/dist/PurchaseCreatePage-YD3NmhPQ-2j4etSjM.js.map +0 -1
  200. package/dist/PurchaseRequestDetailPage-Dg_MRY_N-D1bgTEAn.js.map +0 -1
  201. package/dist/Roles-BIyiic67.js +0 -14
  202. package/dist/Roles-BIyiic67.js.map +0 -1
  203. package/dist/SettingsPage-VsxI-ano-DcmtUUEj.js +0 -747
  204. package/dist/SettingsPage-VsxI-ano-DcmtUUEj.js.map +0 -1
  205. package/dist/StorageUnitsPage-7EqwuMOI-BwUso1Th.js.map +0 -1
  206. package/dist/SubMenu-eEDhZUvh.js.map +0 -1
  207. package/dist/TableDetails-BtafRxXb.js.map +0 -1
  208. package/dist/TableList-Dpo6dO7S.js.map +0 -1
  209. package/dist/TransactionsPage-DrH53pVS-BkhIGB6C.js.map +0 -1
  210. package/dist/TransferCreatePage-CuvoMrYH-DTTfHjz-.js +0 -315
  211. package/dist/TransferCreatePage-CuvoMrYH-DTTfHjz-.js.map +0 -1
  212. package/dist/TransfersPage-Cf701t8s-BBbN7cBf.js +0 -476
  213. package/dist/TransfersPage-Cf701t8s-BBbN7cBf.js.map +0 -1
  214. package/dist/TypeConfiguration-3O6ABrK-.js +0 -117
  215. package/dist/TypeConfiguration-3O6ABrK-.js.map +0 -1
  216. package/dist/UserList-DgPxsnj2.js +0 -1129
  217. package/dist/UserList-DgPxsnj2.js.map +0 -1
  218. package/dist/Users-Bpc4Sazd.js +0 -41
  219. package/dist/VialsPage-8oAc1yFv-Cl3FUXBJ.js +0 -321
  220. package/dist/VialsPage-8oAc1yFv-Cl3FUXBJ.js.map +0 -1
  221. package/dist/constants-ClZJY2x1-MkSWn6TZ.js.map +0 -1
  222. package/dist/dashboardLayoutUtils-D1xCAxp3.js +0 -405
  223. package/dist/dashboardLayoutUtils-D1xCAxp3.js.map +0 -1
  224. package/dist/index-D9YNFPn9.js.map +0 -1
  225. package/dist/index.lib-Dn8PMkeD.js +0 -862
  226. package/dist/index.lib-Dn8PMkeD.js.map +0 -1
@@ -1,75 +1,75 @@
1
- import { jsxs as R, jsx as o, Fragment as gs } from "react/jsx-runtime";
2
- import { Box as A, Autocomplete as Is, TextField as Me, Button as xs, InputAdornment as Ue, IconButton as me, Typography as ne, Accordion as Ss, AccordionSummary as Ns, Chip as bs, Tooltip as pe, AccordionDetails as Cs, FormControlLabel as ks, Checkbox as vs, Menu as Os, MenuItem as Ds } from "@mui/material";
1
+ import { jsxs as R, jsx as o, Fragment as xs } from "react/jsx-runtime";
2
+ import { Box as J, Autocomplete as Ss, TextField as Me, Button as Ns, InputAdornment as $e, IconButton as me, Typography as ie, Accordion as Cs, AccordionSummary as bs, Chip as ks, Tooltip as he, AccordionDetails as vs, FormControlLabel as Os, Checkbox as Ds, Menu as Js, MenuItem as Ps } from "@mui/material";
3
3
  import x from "prop-types";
4
- import Js from "@/views/custom-components/CustomConfirmationModal";
5
- import As from "@/views/custom-components/DebouncedSearchInput";
6
- import { useState as c, useMemo as re, useEffect as ae, createElement as $e, useRef as ie, useCallback as Be, Suspense as Ps, lazy as je } from "react";
7
- import { a as V, d as _s, b as Ce, c as Ts, p as Rs, e as Es, f as Ls } from "./Features-Dne21RWu.js";
8
- import { execute as oe, getRoleList as Fs } from "@/common/services/GlobalApis.js";
4
+ import As from "@/views/custom-components/CustomConfirmationModal";
5
+ import _s from "@/views/custom-components/DebouncedSearchInput";
6
+ import { useState as c, useMemo as ae, useEffect as le, createElement as Be, useRef as oe, useCallback as We, Suspense as Rs, lazy as Ge } from "react";
7
+ import { a as ee, d as Ts, b as ve, c as Es, p as Ls, e as Fs, f as zs } from "./Features-Dne21RWu.js";
8
+ import { execute as re, getRoleList as Us } from "@/common/services/GlobalApis.js";
9
9
  import "@/assets/scss/scrollBar.scss";
10
- import { useForm as we, Controller as zs } from "react-hook-form";
10
+ import { useForm as He, Controller as Ms } from "react-hook-form";
11
11
  import { showToast as v } from "@/common/toaster/toaster";
12
- import Ms from "@/hooks/useTrackEvent";
13
- import { useTranslateProvider as Us } from "@/common/languageTranslator/TranslationContext";
14
- import j from "@/common/fontAwesomeIcons/FontAwesomeIcons";
15
- import { execute as $s } from "@/common/services/GlobalApis";
16
- import { alpha as Bs } from "@mui/material/styles";
17
- import Ws, { VirtualListbox as js } from "@/views/custom-components/CustomAutoComplete";
18
- import Ge from "@/hooks/useCaching";
19
- import ke from "@/common/services/util/GeneralUtil";
20
- import { A as ws } from "./FeatureMenu-DYJmDt7q.js";
21
- const We = 200;
22
- function He({
23
- translate: a,
24
- onSubmit: K,
12
+ import $s from "@/hooks/useTrackEvent";
13
+ import { useTranslateProvider as Bs } from "@/common/languageTranslator/TranslationContext";
14
+ import W from "@/common/fontAwesomeIcons/FontAwesomeIcons";
15
+ import { execute as Ws } from "@/common/services/GlobalApis";
16
+ import { alpha as ws } from "@mui/material/styles";
17
+ import js, { VirtualListbox as Gs } from "@/views/custom-components/CustomAutoComplete";
18
+ import Ke from "@/hooks/useCaching";
19
+ import we from "@/common/services/util/GeneralUtil";
20
+ import { A as Hs } from "./FeatureMenu-Kc73yPHH.js";
21
+ const je = 200;
22
+ function Xe({
23
+ translate: l,
24
+ onSubmit: X,
25
25
  roleList: w,
26
26
  featureData: O
27
27
  }) {
28
- const [P, X] = c(""), [U, G] = c(""), [L, k] = c([]), { control: y, handleSubmit: $, reset: H } = we({}), { getCachedData: T } = Ge(), F = re(() => {
29
- const d = /* @__PURE__ */ new Set(), _ = /* @__PURE__ */ new Set();
28
+ const [P, Z] = c(""), [U, j] = c(""), [E, b] = c([]), { control: g, handleSubmit: M, reset: G } = He({}), { getCachedData: _ } = Ke(), L = ae(() => {
29
+ const d = /* @__PURE__ */ new Set(), A = /* @__PURE__ */ new Set();
30
30
  return (O || []).forEach((S) => {
31
- S != null && S.designationId && d.add(S.designationId), S != null && S.userId && _.add(S.userId);
32
- }), { roles: d, users: _ };
33
- }, [O]), ee = re(
34
- () => w.filter((d) => !F.roles.has(d == null ? void 0 : d.id)),
35
- [w, F]
31
+ S != null && S.designationId && d.add(S.designationId), S != null && S.userId && A.add(S.userId);
32
+ }), { roles: d, users: A };
33
+ }, [O]), se = ae(
34
+ () => w.filter((d) => !L.roles.has(d == null ? void 0 : d.id)),
35
+ [w, L]
36
36
  );
37
- ae(() => {
37
+ le(() => {
38
38
  const d = setTimeout(() => {
39
- G(P);
39
+ j(P);
40
40
  }, 300);
41
41
  return () => clearTimeout(d);
42
- }, [P]), ae(() => {
43
- U !== "" && B(U);
44
- }, [U]), ae(() => {
45
- B("");
42
+ }, [P]), le(() => {
43
+ U !== "" && $(U);
44
+ }, [U]), le(() => {
45
+ $("");
46
46
  }, []);
47
- const B = async (d, _ = O) => {
47
+ const $ = async (d, A = O) => {
48
48
  try {
49
49
  const S = async (m) => {
50
- const { data: z } = await $s({
50
+ const { data: F } = await Ws({
51
51
  code: "user_search_for_selectize",
52
52
  parameters: { searchString: m }
53
53
  });
54
- return z;
55
- }, g = d ? await S(d) : await T({
54
+ return F;
55
+ }, y = d ? await S(d) : await _({
56
56
  cacheKey: ["user_search_for_selectize", ""],
57
57
  fetchFn: () => S(""),
58
58
  staleTime: 3e5,
59
59
  cacheTime: 18e5
60
- }), b = _ === O ? F.users : new Set(
61
- (_ || []).map((m) => m == null ? void 0 : m.userId).filter(Boolean)
62
- ), I = ((g == null ? void 0 : g.result) || []).filter((m) => (m == null ? void 0 : m.id) && !b.has(m.id)).map((m) => ({
60
+ }), C = A === O ? L.users : new Set(
61
+ (A || []).map((m) => m == null ? void 0 : m.userId).filter(Boolean)
62
+ ), I = ((y == null ? void 0 : y.result) || []).filter((m) => (m == null ? void 0 : m.id) && !C.has(m.id)).map((m) => ({
63
63
  ...m,
64
64
  displayName: `${m.firstName || ""} ${m.lastName || ""} (${m.userName || ""})`.trim()
65
65
  }));
66
- k(I);
66
+ b(I);
67
67
  } catch (S) {
68
68
  console.error(S);
69
69
  }
70
70
  };
71
71
  return /* @__PURE__ */ R(
72
- A,
72
+ J,
73
73
  {
74
74
  sx: {
75
75
  display: "flex",
@@ -80,73 +80,73 @@ function He({
80
80
  minWidth: 0
81
81
  },
82
82
  children: [
83
- /* @__PURE__ */ o(A, { sx: { flex: 1, minWidth: 0 }, children: /* @__PURE__ */ o(
84
- zs,
83
+ /* @__PURE__ */ o(J, { sx: { flex: 1, minWidth: 0 }, children: /* @__PURE__ */ o(
84
+ Ms,
85
85
  {
86
86
  name: "roles",
87
87
  id: "roles",
88
- control: y,
88
+ control: g,
89
89
  defaultValue: null,
90
- render: ({ field: { onChange: d, value: _, ref: S } }) => /* @__PURE__ */ o(
91
- Is,
90
+ render: ({ field: { onChange: d, value: A, ref: S } }) => /* @__PURE__ */ o(
91
+ Ss,
92
92
  {
93
- options: L,
93
+ options: E,
94
94
  size: "small",
95
95
  slots: {
96
- listbox: L.length > We ? js : void 0
96
+ listbox: E.length > je ? Gs : void 0
97
97
  },
98
- getOptionLabel: (g) => g.displayName || "",
99
- isOptionEqualToValue: (g, b) => g.id === (b == null ? void 0 : b.id),
100
- value: _ || null,
101
- onChange: (g, b, I) => {
102
- I === "clear" && B(""), d(b);
98
+ getOptionLabel: (y) => y.displayName || "",
99
+ isOptionEqualToValue: (y, C) => y.id === (C == null ? void 0 : C.id),
100
+ value: A || null,
101
+ onChange: (y, C, I) => {
102
+ I === "clear" && $(""), d(C);
103
103
  },
104
- onInputChange: (g, b, I) => {
105
- I === "input" && X(b);
104
+ onInputChange: (y, C, I) => {
105
+ I === "input" && Z(C);
106
106
  },
107
- renderOption: (g, b) => {
108
- const I = b.displayName || "", m = P.trim(), z = I.toLowerCase().indexOf(m.toLowerCase());
109
- if (z === -1)
110
- return /* @__PURE__ */ $e(
107
+ renderOption: (y, C) => {
108
+ const I = C.displayName || "", m = P.trim(), F = I.toLowerCase().indexOf(m.toLowerCase());
109
+ if (F === -1)
110
+ return /* @__PURE__ */ Be(
111
111
  "li",
112
112
  {
113
- ...g,
114
- key: b.id,
113
+ ...y,
114
+ key: C.id,
115
115
  style: { lineHeight: 1.5, fontSize: "14px" }
116
116
  },
117
117
  I
118
118
  );
119
- const Z = I.substring(0, z), he = I.substring(z, z + m.length), se = I.substring(z + m.length);
120
- return /* @__PURE__ */ $e(
119
+ const q = I.substring(0, F), ge = I.substring(F, F + m.length), te = I.substring(F + m.length);
120
+ return /* @__PURE__ */ Be(
121
121
  "li",
122
122
  {
123
- ...g,
124
- key: b.id,
123
+ ...y,
124
+ key: C.id,
125
125
  style: { lineHeight: 1.5, fontSize: "14px" }
126
126
  },
127
127
  /* @__PURE__ */ R("span", { children: [
128
- Z,
128
+ q,
129
129
  /* @__PURE__ */ o(
130
- A,
130
+ J,
131
131
  {
132
132
  component: "span",
133
133
  sx: {
134
134
  fontWeight: 700,
135
135
  borderRadius: "2px",
136
- backgroundColor: (le) => Bs(le.palette.primary.main, 0.18)
136
+ backgroundColor: (ce) => ws(ce.palette.primary.main, 0.18)
137
137
  },
138
- children: he
138
+ children: ge
139
139
  }
140
140
  ),
141
- se
141
+ te
142
142
  ] })
143
143
  );
144
144
  },
145
- renderInput: (g) => /* @__PURE__ */ o(
145
+ renderInput: (y) => /* @__PURE__ */ o(
146
146
  Me,
147
147
  {
148
- ...g,
149
- label: a("User"),
148
+ ...y,
149
+ label: l("User"),
150
150
  variant: "outlined",
151
151
  size: "small",
152
152
  inputRef: S
@@ -156,21 +156,21 @@ function He({
156
156
  )
157
157
  }
158
158
  ) }),
159
- /* @__PURE__ */ o(A, { sx: { flex: 1, minWidth: 0 }, children: /* @__PURE__ */ o(
160
- Ws,
159
+ /* @__PURE__ */ o(J, { sx: { flex: 1, minWidth: 0 }, children: /* @__PURE__ */ o(
160
+ js,
161
161
  {
162
162
  id: "selectedRoles",
163
163
  name: "selectedRoles",
164
- options: ee,
165
- control: y,
166
- isVirtualized: ee.length > We,
164
+ options: se,
165
+ control: g,
166
+ isVirtualized: se.length > je,
167
167
  getOptionLabel: (d) => d == null ? void 0 : d.name,
168
168
  dataTestId: "accessrights-select-role",
169
169
  renderInput: (d) => /* @__PURE__ */ o(
170
170
  Me,
171
171
  {
172
172
  ...d,
173
- label: a("Role"),
173
+ label: l("Role"),
174
174
  variant: "outlined",
175
175
  size: "small"
176
176
  }
@@ -178,25 +178,25 @@ function He({
178
178
  }
179
179
  ) }),
180
180
  /* @__PURE__ */ o(
181
- xs,
181
+ Ns,
182
182
  {
183
183
  variant: "contained",
184
184
  size: "small",
185
185
  "data-testid": "accessrights-add-button",
186
- startIcon: /* @__PURE__ */ o(j, { iconName: "faPlus" }),
186
+ startIcon: /* @__PURE__ */ o(W, { iconName: "faPlus" }),
187
187
  sx: { flexShrink: 0, alignSelf: { xs: "flex-end", md: "center" } },
188
- onClick: $((d) => {
189
- var _;
190
- K(d), B("", [...O, { userId: (_ = d.roles) == null ? void 0 : _.id }]), H();
188
+ onClick: M((d) => {
189
+ var A;
190
+ X(d), $("", [...O, { userId: (A = d.roles) == null ? void 0 : A.id }]), G();
191
191
  }),
192
- children: a("add")
192
+ children: l("Add")
193
193
  }
194
194
  )
195
195
  ]
196
196
  }
197
197
  );
198
198
  }
199
- He.propTypes = {
199
+ Xe.propTypes = {
200
200
  translate: x.any,
201
201
  permissionDetailsList: x.any,
202
202
  getPermissionDetails: x.any,
@@ -205,69 +205,73 @@ He.propTypes = {
205
205
  roleList: x.any,
206
206
  featureData: x.any
207
207
  };
208
- const Gs = je(() => import("./GrantPermissionModal-BDN66Atn.js")), Hs = je(() => import("./PermissionsModal-CCYkcKlC.js"));
209
- function Ke({ config: a, row: K }) {
210
- var L;
211
- const [w, O] = c(null), P = !!w, X = (k) => {
212
- k.stopPropagation(), O(k.currentTarget), typeof a.menuClick == "function" && a.menuClick(K);
213
- }, U = (k) => {
214
- k && k.stopPropagation(), O(null);
215
- }, G = (k) => (y) => {
216
- y.stopPropagation(), typeof k.onClick == "function" && k.onClick(K), O(null);
208
+ const Ks = Ge(() => import("./GrantPermissionModal-D7iNZd0M.js")), Xs = Ge(() => import("./PermissionsModal-Dxbkkrqe.js"));
209
+ function Ze({ config: l, row: X }) {
210
+ var E;
211
+ const [w, O] = c(null), P = !!w, Z = (b) => {
212
+ b.stopPropagation(), O(b.currentTarget), typeof l.menuClick == "function" && l.menuClick(X);
213
+ }, U = (b) => {
214
+ b && b.stopPropagation(), O(null);
215
+ }, j = (b) => (g) => {
216
+ g.stopPropagation(), typeof b.onClick == "function" && b.onClick(X), O(null);
217
217
  };
218
- return /* @__PURE__ */ R(gs, { children: [
219
- /* @__PURE__ */ o(pe, { title: a.tooltip, children: /* @__PURE__ */ o(
218
+ return /* @__PURE__ */ R(xs, { children: [
219
+ /* @__PURE__ */ o(he, { title: l.tooltip, children: /* @__PURE__ */ o(
220
220
  me,
221
221
  {
222
222
  size: "small",
223
- "aria-label": a.tooltip,
224
- onClick: X,
225
- "data-testid": a.dataTestId,
226
- children: a.icon
223
+ "aria-label": l.tooltip,
224
+ onClick: Z,
225
+ "data-testid": l.dataTestId,
226
+ children: l.icon
227
227
  }
228
228
  ) }),
229
229
  /* @__PURE__ */ o(
230
- Os,
230
+ Js,
231
231
  {
232
232
  anchorEl: w,
233
233
  open: P,
234
234
  onClose: U,
235
235
  anchorOrigin: { vertical: "bottom", horizontal: "right" },
236
236
  transformOrigin: { vertical: "top", horizontal: "right" },
237
- children: (L = a.menuItems) == null ? void 0 : L.map((k, y) => /* @__PURE__ */ o(Ds, { onClick: G(k), children: k.label }, y))
237
+ children: (E = l.menuItems) == null ? void 0 : E.map((b, g) => /* @__PURE__ */ o(Ps, { onClick: j(b), children: b.label }, g))
238
238
  }
239
239
  )
240
240
  ] });
241
241
  }
242
- Ke.propTypes = {
242
+ Ze.propTypes = {
243
243
  config: x.any,
244
244
  row: x.any
245
245
  };
246
- function Ks({
247
- subMenuId: a,
246
+ function Zs({
247
+ subMenuId: l,
248
248
  // subMenuGroupName,
249
- subMenuFeatureVal: K,
249
+ subMenuFeatureVal: X,
250
250
  // selectedTab,
251
251
  parentLoading: w,
252
252
  onNewAPIChange: O,
253
253
  rights: P
254
254
  }) {
255
- const X = ie(null), U = ie(!1), G = Ms(), L = ie(!ke.isTecho), { getCachedData: k } = Ge(), [y, $] = c([]), [H, T] = c([]), [F, ee] = c([]), [B, d] = c([]), [_, S] = c([]), [g, b] = c(""), [I, m] = c({}), [z, Z] = c(!1), [he, se] = c(!1), [le, Xe] = c(""), [N, Ze] = c(null), [qe, Qe] = c({}), [Ye, q] = c(!1), [Q, ve] = c(!1), [Ve, ce] = c(null), [E, es] = c([]), [ss, ye] = c(0), [de, Oe] = c(""), { translate: p } = Us(), [ts, ge] = c(""), [ns, Ie] = c([]), [te, ue] = c(null), fe = ke.hasCheckRights(
256
- P == null ? void 0 : P["update.manage.featurelist"]
257
- ), is = ke.hasCheckRights(
258
- P == null ? void 0 : P["delete.manage.featurelist"]
259
- ), De = re(() => {
255
+ const Z = oe(null), U = oe(!1), j = $s(), E = oe(!1), { getCachedData: b } = Ke(), [g, M] = c([]), [G, _] = c([]), [L, se] = c([]), [$, d] = c([]), [A, S] = c([]), [y, C] = c(""), [I, m] = c({}), [F, q] = c(!1), [ge, te] = c(!1), [ce, qe] = c(""), [N, Qe] = c(null), [Ye, Ve] = c({}), [es, Q] = c(!1), [Y, Oe] = c(!1), [ss, de] = c(null), [T, ts] = c([]), [ns, ye] = c(0), [ue, De] = c(""), { translate: h } = Bs(), [is, Ie] = c(""), [os, xe] = c([]), [ne, fe] = c(null), Se = we.hasCheckRights(
256
+ P == null ? void 0 : P["update.manage.featurelist"],
257
+ void 0,
258
+ !0
259
+ ), rs = we.hasCheckRights(
260
+ P == null ? void 0 : P["delete.manage.featurelist"],
261
+ void 0,
262
+ !0
263
+ ), Je = ae(() => {
260
264
  const e = /* @__PURE__ */ new Map();
261
- return (E || []).forEach((n) => e.set(String(n.id), n)), e;
262
- }, [E]), os = re(() => {
265
+ return (T || []).forEach((n) => e.set(String(n.id), n)), e;
266
+ }, [T]), as = ae(() => {
263
267
  const e = /* @__PURE__ */ new Map();
264
- return (y || []).forEach((n) => {
268
+ return (g || []).forEach((n) => {
265
269
  n != null && n.feature_name && e.set(n.feature_name, n.display_name);
266
270
  }), e;
267
- }, [y]), rs = () => {
271
+ }, [g]), ls = () => {
268
272
  var n;
269
- if (!E || E.length === 0) return null;
270
- const e = E.filter(
273
+ if (!T || T.length === 0) return null;
274
+ const e = T.filter(
271
275
  (i) => {
272
276
  var t;
273
277
  return (t = i == null ? void 0 : i.id) == null ? void 0 : t.startsWith("view");
@@ -283,31 +287,31 @@ function Ks({
283
287
  if (t.length > 0)
284
288
  return t[0].id;
285
289
  }
286
- return (n = E[0]) == null ? void 0 : n.id;
290
+ return (n = T[0]) == null ? void 0 : n.id;
287
291
  };
288
- ae(() => {
289
- let e = X.current;
292
+ le(() => {
293
+ let e = Z.current;
290
294
  return () => {
291
- G("conversion_event", {
295
+ j("conversion_event", {
292
296
  form: e,
293
297
  form_name: "Access Rights",
294
298
  submit: U.current
295
299
  });
296
300
  };
297
301
  }, []);
298
- const xe = (e) => {
302
+ const Ne = (e) => {
299
303
  var i;
300
304
  let n;
301
305
  return n = (i = e.userMenuItemDtos) == null ? void 0 : i.toSorted((t, s) => t.designationId !== void 0 && s.designationId !== void 0 ? t.designationId - s.designationId : t.designationId !== void 0 && s.designationId === void 0 ? -1 : t.designationId === void 0 && s.designationId !== void 0 ? 1 : t.userId !== void 0 && s.userId !== void 0 ? t.userId - s.userId : t.userId !== void 0 && s.userId === void 0 ? -1 : t.userId === void 0 && s.userId !== void 0 ? 1 : 0), n;
302
- }, Se = (e) => (e == null || e.userMenuItemDtos.forEach((n) => {
303
- n.featureJson = us(
306
+ }, Ce = (e) => (e == null || e.userMenuItemDtos.forEach((n) => {
307
+ n.featureJson = ps(
304
308
  JSON.parse(e.featureJson || "{}"),
305
309
  JSON.parse(n.featureJson || "{}")
306
310
  ), n.designationId ? (n.code = "Role", n.displayName = n.roleName) : (n.code = "User", n.displayName = n.fullName);
307
- }), e), as = async () => {
311
+ }), e), cs = async () => {
308
312
  var e, n;
309
313
  try {
310
- if (q((i) => !i), Q) {
314
+ if (Q((i) => !i), Y) {
311
315
  const i = [];
312
316
  Object.entries(JSON.parse(N == null ? void 0 : N.featureJson)).forEach(
313
317
  ([t, s]) => {
@@ -315,7 +319,7 @@ function Ks({
315
319
  }
316
320
  );
317
321
  try {
318
- await oe({
322
+ await re({
319
323
  code: "delete_permissions",
320
324
  parameters: {
321
325
  permissionList: i,
@@ -326,8 +330,8 @@ function Ks({
326
330
  type: "success",
327
331
  message: "Permission Deleted Successfully"
328
332
  });
329
- const { data: t } = await V(a);
330
- Y(t);
333
+ const { data: t } = await ee(l);
334
+ V(t);
331
335
  } catch {
332
336
  v({
333
337
  type: "error",
@@ -335,44 +339,44 @@ function Ks({
335
339
  });
336
340
  }
337
341
  } else {
338
- await _s(le);
339
- let { data: i } = await Ce(a);
340
- (i == null ? void 0 : i.userMenuItemDtos.length) > 0 && (i = Se(i)), T(i.userMenuItemDtos);
342
+ await Ts(ce);
343
+ let { data: i } = await ve(l);
344
+ (i == null ? void 0 : i.userMenuItemDtos.length) > 0 && (i = Ce(i)), _(i.userMenuItemDtos);
341
345
  }
342
- Z(!1), q((i) => !i);
346
+ q(!1), Q((i) => !i);
343
347
  } catch (i) {
344
348
  v({
345
349
  type: "error",
346
350
  message: `Error Deleting data: ${(n = (e = i == null ? void 0 : i.response) == null ? void 0 : e.data) == null ? void 0 : n.message}`
347
- }), q((t) => !t), Z(!1);
351
+ }), Q((t) => !t), q(!1);
348
352
  }
349
- }, ls = (e, n) => {
353
+ }, ds = (e, n) => {
350
354
  const i = new Set(e.map((s) => s.id)), t = [];
351
- return Object.entries(n).forEach(([s, r]) => {
352
- r === !0 && !i.has(s) && t.push({ id: s, action: "grant" });
355
+ return Object.entries(n).forEach(([s, a]) => {
356
+ a === !0 && !i.has(s) && t.push({ id: s, action: "grant" });
353
357
  }), e.forEach((s) => {
354
358
  n[s.id] || t.push({ id: s.id, action: "revoke" });
355
359
  }), t;
356
- }, { handleSubmit: cs } = we({}), Je = async (e) => {
357
- var n, i, t, s, r, D;
360
+ }, { handleSubmit: us } = He({}), Pe = async (e) => {
361
+ var n, i, t, s, a, k;
358
362
  try {
359
- if (Q) {
363
+ if (Y) {
360
364
  e = { ...e, featureJson: JSON.parse(e == null ? void 0 : e.featureJson) };
361
- const l = ls(
365
+ const r = ds(
362
366
  e.permissions,
363
367
  e == null ? void 0 : e.featureJson
364
368
  );
365
- if (((n = l[0]) == null ? void 0 : n.action) === "grant")
366
- ce({
369
+ if (((n = r[0]) == null ? void 0 : n.action) === "grant")
370
+ de({
367
371
  ...e,
368
- id: (i = l[0]) == null ? void 0 : i.id
372
+ id: (i = r[0]) == null ? void 0 : i.id
369
373
  }), ye(1);
370
- else if (((t = l[0]) == null ? void 0 : t.action) === "revoke")
374
+ else if (((t = r[0]) == null ? void 0 : t.action) === "revoke")
371
375
  try {
372
- await oe({
376
+ await re({
373
377
  code: "revoke_permission",
374
378
  parameters: {
375
- featureName: (s = l[0]) == null ? void 0 : s.id,
379
+ featureName: (s = r[0]) == null ? void 0 : s.id,
376
380
  roleId: parseInt(e == null ? void 0 : e.designationId),
377
381
  userId: parseInt(e == null ? void 0 : e.userId)
378
382
  }
@@ -386,27 +390,31 @@ function Ks({
386
390
  message: "Error in revoking permission"
387
391
  });
388
392
  }
389
- const { data: u } = await V(a);
390
- Y(u);
393
+ const { data: u } = await ee(l);
394
+ V(u);
391
395
  } else
392
- await Ts(e);
393
- } catch (l) {
396
+ await Es(e);
397
+ } catch (r) {
394
398
  v({
395
399
  type: "error",
396
- message: `Error Updating data: ${(D = (r = l == null ? void 0 : l.response) == null ? void 0 : r.data) == null ? void 0 : D.message}`
400
+ message: `Error Updating data: ${(k = (a = r == null ? void 0 : r.response) == null ? void 0 : a.data) == null ? void 0 : k.message}`
397
401
  });
398
402
  }
399
- }, ds = async (e) => {
403
+ }, fs = async (e) => {
400
404
  try {
401
405
  if (e = {
402
406
  ...e,
403
407
  featureJson: JSON.parse(e == null ? void 0 : e.featureJson)
404
408
  }, e != null && e.checkAll) {
405
- const i = Object.keys(e == null ? void 0 : e.featureJson).filter((t) => (e == null ? void 0 : e.featureJson[t]) === !1).join(",");
406
- await oe({
409
+ const i = Object.keys(e == null ? void 0 : e.featureJson).filter(
410
+ (a) => (e == null ? void 0 : e.featureJson[a]) === !1
411
+ ), t = /^view\.report\.[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i, s = i.flatMap(
412
+ (a) => t.test(a) ? [a, `${a}.candrilldown`] : [a]
413
+ ).join(",");
414
+ await re({
407
415
  code: "grant_permission_bulk",
408
416
  parameters: {
409
- permission_id_list: i,
417
+ permission_id_list: s,
410
418
  role_id: parseInt(e == null ? void 0 : e.designationId),
411
419
  user_id: parseInt(e == null ? void 0 : e.userId)
412
420
  }
@@ -415,13 +423,13 @@ function Ks({
415
423
  message: "Permission granted Successfully"
416
424
  });
417
425
  }
418
- const { data: n } = await V(a);
419
- Y(n);
426
+ const { data: n } = await ee(l);
427
+ V(n);
420
428
  } catch (n) {
421
429
  console.error(n);
422
430
  }
423
431
  }, Ae = async (e) => {
424
- var n, i, t, s;
432
+ var n, i, t, s, a, k;
425
433
  if (!(e != null && e.roles || e != null && e.selectedRoles)) {
426
434
  v({
427
435
  message: "Please select either user or role !!",
@@ -429,7 +437,7 @@ function Ks({
429
437
  });
430
438
  return;
431
439
  }
432
- if (Q && y.length < 1) {
440
+ if (Y && g.length < 1) {
433
441
  v({
434
442
  message: "Please add permissions first for this feature !!",
435
443
  type: "info"
@@ -437,60 +445,60 @@ function Ks({
437
445
  return;
438
446
  }
439
447
  try {
440
- const r = ((n = e == null ? void 0 : e.selectedRoles) == null ? void 0 : n.map((h) => h == null ? void 0 : h.id)) || [], D = I != null && I.id ? H.some((h) => (h == null ? void 0 : h.userId) === (I == null ? void 0 : I.id)) : !1, l = (r == null ? void 0 : r.length) > 0 ? H.some(
441
- (h) => r.includes(h == null ? void 0 : h.designationId)
448
+ const r = ((n = e == null ? void 0 : e.selectedRoles) == null ? void 0 : n.map((f) => f == null ? void 0 : f.id)) || [], u = I != null && I.id ? G.some((f) => (f == null ? void 0 : f.userId) === (I == null ? void 0 : I.id)) : !1, H = (r == null ? void 0 : r.length) > 0 ? G.some(
449
+ (f) => r.includes(f == null ? void 0 : f.designationId)
442
450
  ) : !1;
443
- if (D || l)
451
+ if (u || H)
444
452
  v({
445
453
  message: "Selected User Already found please select another id",
446
454
  type: "warning"
447
455
  });
448
456
  else {
449
- const h = r == null ? void 0 : r.join(","), W = {
457
+ const f = r == null ? void 0 : r.join(","), K = {
450
458
  userId: (i = e == null ? void 0 : e.roles) == null ? void 0 : i.id,
451
- designationId: h || null
452
- }, C = E.filter(
453
- (f) => {
454
- var M;
455
- return (M = f == null ? void 0 : f.id) == null ? void 0 : M.startsWith("view");
459
+ designationId: f || null
460
+ }, B = T.filter(
461
+ (p) => {
462
+ var z;
463
+ return (z = p == null ? void 0 : p.id) == null ? void 0 : z.startsWith("view");
456
464
  }
457
465
  );
458
- if (Q) {
459
- const f = (t = C.find(
460
- (J) => /^view\.report\.[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i.test(J.id)
466
+ if (Y) {
467
+ const p = (t = B.find(
468
+ (D) => /^view\.report\.[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i.test(D.id)
461
469
  )) == null ? void 0 : t.id;
462
- f ? ce({
463
- ...W,
464
- id: f
465
- }) : C.some((J) => J.id === "view.report") ? ce({
466
- ...W,
470
+ p ? de({
471
+ ...K,
472
+ id: p
473
+ }) : B.some((D) => D.id === "view.report") ? de({
474
+ ...K,
467
475
  id: "view.report"
468
- }) : ce({
469
- ...W,
470
- id: (C == null ? void 0 : C.filter((J) => J.id.split(".").length === 3).map((J) => J.id)[0]) || ((s = E[0]) == null ? void 0 : s.id)
476
+ }) : de({
477
+ ...K,
478
+ id: (B == null ? void 0 : B.filter((D) => D.id.split(".").length === 3).map((D) => D.id)[0]) || ((s = T[0]) == null ? void 0 : s.id)
471
479
  }), ye(1);
472
- const { data: M } = await V(a);
473
- Y(M);
480
+ const { data: z } = await ee(l);
481
+ V(z);
474
482
  } else {
475
- await Rs(a, W);
476
- let { data: f } = await Ce(a);
477
- (f == null ? void 0 : f.userMenuItemDtos.length) > 0 && (f == null ? void 0 : f.userMenuItemDtos.length) > 0 && (f = Se(f)), b(f == null ? void 0 : f.featureJson);
478
- const M = xe(f);
479
- T(M);
480
- const J = f.featureJson ? Object.keys(JSON.parse(f.featureJson)) : [];
481
- if (J.length > 0) {
482
- const { data: Ne } = await oe({
483
+ await Ls(l, K);
484
+ let { data: p } = await ve(l);
485
+ (p == null ? void 0 : p.userMenuItemDtos.length) > 0 && (p == null ? void 0 : p.userMenuItemDtos.length) > 0 && (p = Ce(p)), C(p == null ? void 0 : p.featureJson);
486
+ const z = Ne(p);
487
+ _(z);
488
+ const D = p.featureJson ? Object.keys(JSON.parse(p.featureJson)) : [];
489
+ if (D.length > 0) {
490
+ const { data: be } = await re({
483
491
  code: "retrieve_display_name_for_feature",
484
492
  parameters: {
485
- menu_id: a,
486
- feature_name_list: J
493
+ menu_id: l,
494
+ feature_name_list: D
487
495
  }
488
496
  });
489
- $(Ne.result);
497
+ M(be.result);
490
498
  } else
491
- $([]);
499
+ M([]);
492
500
  v({
493
- message: "menu item added successfully",
501
+ message: (a = e == null ? void 0 : e.roles) != null && a.id && r.length > 0 ? "Permission granted to User and Role Successfully" : (k = e == null ? void 0 : e.roles) != null && k.id ? "Permission granted to User Successfully" : "Permission granted to Role Successfully",
494
502
  type: "success"
495
503
  });
496
504
  }
@@ -498,43 +506,43 @@ function Ks({
498
506
  }
499
507
  } catch (r) {
500
508
  console.error(r), v({
501
- message: "cannot add menu item",
509
+ message: "Cannot grant permission",
502
510
  type: "error"
503
511
  });
504
512
  }
505
- }, Pe = Be(
513
+ }, _e = We(
506
514
  (e) => {
507
515
  const n = (e || "").toLowerCase();
508
- if (Oe(n), !n) {
509
- T(F);
516
+ if (De(n), !n) {
517
+ _(L);
510
518
  return;
511
519
  }
512
- const i = F == null ? void 0 : F.filter(
520
+ const i = L == null ? void 0 : L.filter(
513
521
  (t) => {
514
- var s, r;
515
- return t != null && t.designationId ? (s = t.roleName) == null ? void 0 : s.toLowerCase().includes(n) : (r = t.fullName) == null ? void 0 : r.toLowerCase().includes(n);
522
+ var s, a;
523
+ return t != null && t.designationId ? (s = t.roleName) == null ? void 0 : s.toLowerCase().includes(n) : (a = t.fullName) == null ? void 0 : a.toLowerCase().includes(n);
516
524
  }
517
525
  );
518
- G("search_tracking", {
526
+ j("search_tracking", {
519
527
  searchTerm: n,
520
528
  results_count: i.length,
521
529
  search_type: "Page Search"
522
- }), T(i);
530
+ }), _(i);
523
531
  },
524
- [F, G]
525
- ), us = (e, n = {}) => {
532
+ [L, j]
533
+ ), ps = (e, n = {}) => {
526
534
  const i = {};
527
535
  return Object.keys(e).forEach((t) => {
528
536
  Object.prototype.hasOwnProperty.call(n, t) ? i[t] = n[t] : i[t] = e[t];
529
537
  }), JSON.stringify(i);
530
- }, _e = (e, n) => {
538
+ }, Re = (e, n) => {
531
539
  const i = new Set(n.map((s) => s.id)), t = {};
532
540
  return e.forEach((s) => {
533
541
  t[s.id] = i.has(s.id);
534
542
  }), JSON.stringify(t);
535
- }, Y = (e) => {
543
+ }, V = (e) => {
536
544
  e == null || e.userMenuItemDtos.forEach((t) => {
537
- t.id = (t == null ? void 0 : t.designationId) || (t == null ? void 0 : t.userId), t.featureJson = _e(
545
+ t.id = (t == null ? void 0 : t.designationId) || (t == null ? void 0 : t.userId), t.featureJson = Re(
538
546
  e == null ? void 0 : e.permissions,
539
547
  t == null ? void 0 : t.permissions
540
548
  ), t.designationId ? (t.code = "Role", t.displayName = t.roleName) : (t.code = "User", t.displayName = t.fullName);
@@ -542,179 +550,176 @@ function Ks({
542
550
  const n = [
543
551
  ...new Set(e.permissions.map((t) => t.id))
544
552
  ];
545
- $(n), es(e == null ? void 0 : e.permissions);
546
- const i = xe(e);
547
- T(i), ee(i);
553
+ M(n), ts(e == null ? void 0 : e.permissions);
554
+ const i = Ne(e);
555
+ _(i), se(i);
548
556
  };
549
- ae(() => {
557
+ le(() => {
550
558
  (async () => {
551
559
  var n, i, t;
552
560
  try {
553
- if (a) {
554
- ue(null), Te(!1), q((u) => !u), Oe("");
555
- let s, r;
556
- if (K) {
557
- if (L.current)
558
- s = (await V(a)).data;
561
+ if (l) {
562
+ fe(null), Te(!1), Q((u) => !u), De("");
563
+ let s, a;
564
+ if (X) {
565
+ if (E.current)
566
+ s = (await ee(l)).data;
559
567
  else
560
568
  try {
561
- s = (await Es(a)).data;
569
+ s = (await Fs(l)).data;
562
570
  } catch (u) {
563
- console.error("configtypesV2/summary unavailable, falling back to full bundle", u), L.current = !0, s = (await V(a)).data;
571
+ console.error("configtypesV2/summary unavailable, falling back to full bundle", u), E.current = !0, s = (await ee(l)).data;
564
572
  }
565
- r = !0, ve(!0), O({ id: a, val: !0 });
573
+ a = !0, Oe(!0), O({ id: l, val: !0 });
566
574
  } else
567
- s = (await Ce(a)).data, r = !1, ve(!1), O({ id: a, val: !1 });
568
- if (r)
569
- Y(s);
575
+ s = (await ve(l)).data, a = !1, Oe(!1), O({ id: l, val: !1 });
576
+ if (a)
577
+ V(s);
570
578
  else {
571
- (s == null ? void 0 : s.userMenuItemDtos.length) > 0 && (s = Se(s)), b(s == null ? void 0 : s.featureJson);
572
- const u = xe(s);
573
- T(u), ee(u);
579
+ (s == null ? void 0 : s.userMenuItemDtos.length) > 0 && (s = Ce(s)), C(s == null ? void 0 : s.featureJson);
580
+ const u = Ne(s);
581
+ _(u), se(u);
574
582
  }
575
- let D = _;
576
- if (!B || B.length === 0) {
577
- const u = await k({
583
+ let k = A;
584
+ if (!$ || $.length === 0) {
585
+ const u = await b({
578
586
  cacheKey: ["roleList"],
579
- fetchFn: async () => (await Fs()).data,
587
+ fetchFn: async () => (await Us()).data,
580
588
  staleTime: 3e5,
581
589
  cacheTime: 18e5
582
590
  });
583
- S(u), D = u;
591
+ S(u), k = u;
584
592
  }
585
- let l;
586
- if (r)
587
- l = s.permissions.map((u) => u.id), $(l);
588
- else if (l = s.featureJson ? Object.keys(JSON.parse(s.featureJson)) : [], l.length > 0) {
593
+ let r;
594
+ if (a)
595
+ r = s.permissions.map((u) => u.id), M(r);
596
+ else if (r = s.featureJson ? Object.keys(JSON.parse(s.featureJson)) : [], r.length > 0) {
589
597
  const [u] = await Promise.all([
590
- await oe({
598
+ await re({
591
599
  code: "retrieve_display_name_for_feature",
592
600
  parameters: {
593
- menu_id: a,
594
- feature_name_list: l
601
+ menu_id: l,
602
+ feature_name_list: r
595
603
  }
596
604
  })
597
605
  ]);
598
- $((n = u.data) == null ? void 0 : n.result);
606
+ M((n = u.data) == null ? void 0 : n.result);
599
607
  } else
600
- $([]);
601
- if (D && D.length > 0)
608
+ M([]);
609
+ if (k && k.length > 0)
602
610
  if (s.isDynamicFeature) {
603
- const h = JSON.parse(JSON.stringify(D)).filter((W) => {
604
- const C = W.roleType;
605
- return C === null || s != null && s.isMobileFeature && (s != null && s.isWebFeature) ? !0 : s.isMobileFeature ? C === "MOBILE" || C === "BOTH" : s.isWebFeature ? C === "WEB" || C === "BOTH" : !1;
611
+ const H = JSON.parse(JSON.stringify(k)).filter((pe) => {
612
+ const f = pe.roleType;
613
+ return f === null || s != null && s.isMobileFeature && (s != null && s.isWebFeature) ? !0 : s.isMobileFeature ? f === "MOBILE" || f === "BOTH" : s.isWebFeature ? f === "WEB" || f === "BOTH" : !1;
606
614
  });
607
- d(h);
615
+ d(H);
608
616
  } else
609
- d(D);
610
- q((u) => !u);
617
+ d(k);
618
+ Q((u) => !u);
611
619
  }
612
620
  } catch (s) {
613
621
  v({
614
622
  type: "error",
615
623
  message: `Error loading initial data: ${(t = (i = s == null ? void 0 : s.response) == null ? void 0 : i.data) == null ? void 0 : t.message}`
616
- }), q((r) => !r);
624
+ }), Q((a) => !a);
617
625
  }
618
626
  })();
619
- }, [a, O]);
620
- const fs = Be(
621
- (e) => De.get(String(e)) || null,
622
- [De]
623
- ), ms = re(
624
- () => rs(),
625
- [E]
626
- ), [ps, Te] = c(!1), hs = (e) => async (n, i) => {
627
+ }, [l, O]);
628
+ const ms = We(
629
+ (e) => Je.get(String(e)) || null,
630
+ [Je]
631
+ ), hs = ae(
632
+ () => ls(),
633
+ [T]
634
+ ), [gs, Te] = c(!1), ys = (e) => async (n, i) => {
627
635
  const t = `panel${e == null ? void 0 : e.id}`;
628
- if (Te(i ? t : !1), i && Q && e && !e._permissionsLoaded && !L.current)
636
+ if (Te(i ? t : !1), i && Y && e && !e._permissionsLoaded && !E.current)
629
637
  try {
630
- const { data: s } = await Ls(a, {
638
+ const { data: s } = await zs(l, {
631
639
  userId: e.userId,
632
640
  roleId: e.designationId
633
641
  });
634
- e.permissions = s, e.featureJson = _e(E, s), e._permissionsLoaded = !0, T((r) => [...r]);
642
+ e.permissions = s, e.featureJson = Re(T, s), e._permissionsLoaded = !0, _((a) => [...a]);
635
643
  } catch (s) {
636
644
  console.error(s), v({ type: "error", message: "Error loading permissions for row" });
637
645
  }
638
- }, Re = ({
646
+ }, Ee = ({
639
647
  row: e,
640
648
  featureState: n,
641
649
  featureKey: i,
642
650
  lookupKey: t,
643
651
  index: s,
644
- withModal: r
652
+ withModal: a
645
653
  }) => {
646
- var M;
647
- const D = n[i] || !1, l = fs(t), u = (((M = l == null ? void 0 : l.child) == null ? void 0 : M.length) || 0) > 0, h = i === ms, W = !fe || h, C = (te == null ? void 0 : te.id) === (l == null ? void 0 : l.id), f = /* @__PURE__ */ o(
648
- ks,
654
+ var z;
655
+ const k = n[i] || !1, r = ms(t), u = (((z = r == null ? void 0 : r.child) == null ? void 0 : z.length) || 0) > 0, H = i === hs, pe = !Se || H, f = (ne == null ? void 0 : ne.id) === (r == null ? void 0 : r.id), K = /* @__PURE__ */ o(
656
+ Os,
649
657
  {
650
658
  sx: { mr: 0, minWidth: 0, flex: 1 },
651
659
  control: /* @__PURE__ */ o(
652
- vs,
660
+ Ds,
653
661
  {
654
662
  size: "small",
655
- disabled: W,
656
- checked: D,
663
+ disabled: pe,
664
+ checked: k,
657
665
  name: i,
658
666
  onClick: () => {
659
- const J = {
667
+ const D = {
660
668
  ...n,
661
- [i]: !D
669
+ [i]: !k
662
670
  };
663
- T(
664
- (Ne) => Ne.map(
665
- (be) => be.id === e.id ? {
666
- ...be,
667
- featureJson: JSON.stringify(J)
668
- } : be
671
+ _(
672
+ (be) => be.map(
673
+ (ke) => ke.id === e.id ? {
674
+ ...ke,
675
+ featureJson: JSON.stringify(D)
676
+ } : ke
669
677
  )
670
- ), Je({
678
+ ), Pe({
671
679
  ...e,
672
- featureJson: JSON.stringify(J),
680
+ featureJson: JSON.stringify(D),
673
681
  code: e.designationId ? "Role" : "User",
674
- menuConfigId: a,
682
+ menuConfigId: l,
675
683
  displayName: e.designationId ? e.roleName : e.fullName
676
684
  });
677
685
  }
678
686
  }
679
687
  ),
680
- label: /* @__PURE__ */ o(ne, { variant: "body2", children: l ? l.name : t })
688
+ label: /* @__PURE__ */ o(ie, { variant: "body2", children: r ? r.name : t })
681
689
  }
682
- );
690
+ ), B = H ? [
691
+ r == null ? void 0 : r.desc,
692
+ h(
693
+ "This is the base right for the sub menu and cannot be changed here."
694
+ )
695
+ ].filter(Boolean).join(" — ") : (r == null ? void 0 : r.desc) || "";
683
696
  return /* @__PURE__ */ R(
684
- A,
697
+ J,
685
698
  {
686
699
  sx: { display: "flex", alignItems: "center", gap: 0.5, minWidth: 0 },
687
700
  children: [
688
- h && fe ? /* @__PURE__ */ o(
689
- pe,
690
- {
691
- title: p(
692
- "This is the base right for the sub menu and cannot be changed here."
693
- ),
694
- children: /* @__PURE__ */ o("span", { style: { display: "flex", flex: 1, minWidth: 0 }, children: f })
695
- }
696
- ) : f,
701
+ B ? /* @__PURE__ */ o(he, { title: B, children: /* @__PURE__ */ o("span", { style: { display: "flex", flex: 1, minWidth: 0 }, children: K }) }) : K,
697
702
  u && /* @__PURE__ */ o(
698
- pe,
703
+ he,
699
704
  {
700
- title: p(C ? "Close Permissions" : "View Permissions"),
705
+ title: h(f ? "Close Permissions" : "View Permissions"),
701
706
  children: /* @__PURE__ */ o(
702
707
  me,
703
708
  {
704
709
  size: "small",
705
710
  color: "primary",
706
- "aria-label": p(C ? "Close Permissions" : "View Permissions"),
711
+ "aria-label": h(f ? "Close Permissions" : "View Permissions"),
707
712
  onClick: () => {
708
- if (C) {
709
- ue(null), r && (se(!1), ge(""), Ie([]));
713
+ if (f) {
714
+ fe(null), a && (te(!1), Ie(""), xe([]));
710
715
  return;
711
716
  }
712
- r && (ge(i), Ie(n), se(!0)), ue(l);
717
+ a && (Ie(i), xe(n), te(!0)), fe(r);
713
718
  },
714
719
  children: /* @__PURE__ */ o(
715
- j,
720
+ W,
716
721
  {
717
- iconName: C ? "faEyeSlash" : "faEye",
722
+ iconName: f ? "faEyeSlash" : "faEye",
718
723
  size: "sm"
719
724
  }
720
725
  )
@@ -726,45 +731,45 @@ function Ks({
726
731
  },
727
732
  `featureName-${s}`
728
733
  );
729
- }, ys = y.length > 0 || Object.keys(JSON.parse(g || "{}")).length > 0, Ee = !!(he && te), Le = ss === 1, Fe = ie(!1), ze = ie(!1);
730
- return Ee && (Fe.current = !0), Le && (ze.current = !0), /* @__PURE__ */ o(ws, { isLoading: Ye || w, children: /* @__PURE__ */ R(A, { sx: { width: "100%" }, children: [
734
+ }, Is = g.length > 0 || Object.keys(JSON.parse(y || "{}")).length > 0, Le = !!(ge && ne), Fe = ns === 1, ze = oe(!1), Ue = oe(!1);
735
+ return Le && (ze.current = !0), Fe && (Ue.current = !0), /* @__PURE__ */ o(Hs, { isLoading: es || w, children: /* @__PURE__ */ R(J, { sx: { width: "100%" }, children: [
731
736
  /* @__PURE__ */ o(
732
- Js,
737
+ As,
733
738
  {
734
739
  description: N != null && N.displayName ? `Remove all access to this sub menu for ${N.code === "Role" ? "the role" : ""} ${N.displayName}? Every right listed below will be revoked.` : "Remove all access to this sub menu? Every right listed below will be revoked.",
735
- title: p("Remove access"),
736
- open: z && le === (N == null ? void 0 : N.id),
737
- handleClick: as,
738
- handleClose: () => Z((e) => !e),
740
+ title: h("Remove access"),
741
+ open: F && ce === (N == null ? void 0 : N.id),
742
+ handleClick: cs,
743
+ handleClose: () => q((e) => !e),
739
744
  dataTestId: "accessrights-delete-modal"
740
745
  }
741
746
  ),
742
- /* @__PURE__ */ R(Ps, { fallback: null, children: [
743
- Fe.current && /* @__PURE__ */ o(
744
- Hs,
747
+ /* @__PURE__ */ R(Rs, { fallback: null, children: [
748
+ ze.current && /* @__PURE__ */ o(
749
+ Xs,
745
750
  {
746
- isOpen: Ee,
751
+ isOpen: Le,
747
752
  onClose: () => {
748
- se((e) => !e), ue(null), ge(""), Ie([]);
753
+ te((e) => !e), fe(null), Ie(""), xe([]);
749
754
  },
750
- featureState: ns,
751
- featureName: ts,
752
- permissions: te
755
+ featureState: os,
756
+ featureName: is,
757
+ permissions: ne
753
758
  }
754
759
  ),
755
- ze.current && /* @__PURE__ */ o(
756
- Gs,
760
+ Ue.current && /* @__PURE__ */ o(
761
+ Ks,
757
762
  {
758
- isOpen: Le,
763
+ isOpen: Fe,
759
764
  onClose: () => ye(0),
760
- pendingGrant: Ve,
761
- subMenuId: a,
762
- newApiData: Y
765
+ pendingGrant: ss,
766
+ subMenuId: l,
767
+ newApiData: V
763
768
  }
764
769
  )
765
770
  ] }),
766
- /* @__PURE__ */ o("form", { ref: X, onSubmit: cs(Ae), children: /* @__PURE__ */ R(
767
- A,
771
+ /* @__PURE__ */ o("form", { ref: Z, onSubmit: us(Ae), children: /* @__PURE__ */ R(
772
+ J,
768
773
  {
769
774
  sx: {
770
775
  display: "flex",
@@ -778,47 +783,47 @@ function Ks({
778
783
  },
779
784
  children: [
780
785
  /* @__PURE__ */ o(
781
- As,
786
+ _s,
782
787
  {
783
- value: de,
784
- onChange: Pe,
785
- placeholder: p("Search roles and users"),
788
+ value: ue,
789
+ onChange: _e,
790
+ placeholder: h("Search roles and users"),
786
791
  autoFocus: !1,
787
792
  "data-testid": "access-rights-textfield-search",
788
793
  sx: { width: { xs: "100%", lg: 240 }, flexShrink: 0 },
789
794
  slotProps: {
790
795
  htmlInput: {
791
- "aria-label": p("Search roles and users")
796
+ "aria-label": h("Search roles and users")
792
797
  }
793
798
  },
794
799
  inputProps: {
795
- startAdornment: /* @__PURE__ */ o(Ue, { position: "start", children: /* @__PURE__ */ o(A, { sx: { color: "text.disabled", display: "flex" }, children: /* @__PURE__ */ o(j, { iconName: "faMagnifyingGlass", size: "sm" }) }) }),
796
- endAdornment: de ? /* @__PURE__ */ o(Ue, { position: "end", children: /* @__PURE__ */ o(
800
+ startAdornment: /* @__PURE__ */ o($e, { position: "start", children: /* @__PURE__ */ o(J, { sx: { color: "text.disabled", display: "flex" }, children: /* @__PURE__ */ o(W, { iconName: "faMagnifyingGlass", size: "sm" }) }) }),
801
+ endAdornment: ue ? /* @__PURE__ */ o($e, { position: "end", children: /* @__PURE__ */ o(
797
802
  me,
798
803
  {
799
804
  size: "small",
800
- "aria-label": p("Clear search"),
801
- onClick: () => Pe(""),
802
- children: /* @__PURE__ */ o(j, { iconName: "faXmark", size: "sm" })
805
+ "aria-label": h("Clear search"),
806
+ onClick: () => _e(""),
807
+ children: /* @__PURE__ */ o(W, { iconName: "faXmark", size: "sm" })
803
808
  }
804
809
  ) }) : null
805
810
  }
806
811
  }
807
812
  ),
808
- fe && /* @__PURE__ */ o(
809
- He,
813
+ Se && /* @__PURE__ */ o(
814
+ Xe,
810
815
  {
811
- translate: p,
816
+ translate: h,
812
817
  onSubmit: Ae,
813
- roleList: B,
814
- featureData: H
818
+ roleList: $,
819
+ featureData: G
815
820
  }
816
821
  )
817
822
  ]
818
823
  }
819
824
  ) }),
820
- H.length === 0 ? /* @__PURE__ */ R(
821
- A,
825
+ G.length === 0 ? /* @__PURE__ */ R(
826
+ J,
822
827
  {
823
828
  "data-testid": "accessrights-empty-state",
824
829
  sx: {
@@ -832,22 +837,22 @@ function Ks({
832
837
  py: 6
833
838
  },
834
839
  children: [
835
- /* @__PURE__ */ o(A, { sx: { color: "text.disabled" }, children: /* @__PURE__ */ o(j, { iconName: "faUserShield", size: "2x" }) }),
836
- /* @__PURE__ */ o(ne, { variant: "subtitle1", sx: { fontWeight: 700 }, children: p(de ? "No roles or users match your search" : "No access granted yet") }),
837
- /* @__PURE__ */ o(ne, { variant: "body2", color: "text.secondary", children: p(de ? "Clear the search to see everyone with access." : "Pick a user or a role above and select Add to grant access to this sub menu.") })
840
+ /* @__PURE__ */ o(J, { sx: { color: "text.disabled" }, children: /* @__PURE__ */ o(W, { iconName: "faUserShield", size: "2x" }) }),
841
+ /* @__PURE__ */ o(ie, { variant: "subtitle1", sx: { fontWeight: 700 }, children: h(ue ? "No roles or users match your search" : "No access granted yet") }),
842
+ /* @__PURE__ */ o(ie, { variant: "body2", color: "text.secondary", children: h(ue ? "Clear the search to see everyone with access." : "Pick a user or a role above and select Add to grant access to this sub menu.") })
838
843
  ]
839
844
  }
840
- ) : /* @__PURE__ */ o(A, { children: H.map((e) => /* @__PURE__ */ R(
841
- Ss,
845
+ ) : /* @__PURE__ */ o(J, { children: G.map((e) => /* @__PURE__ */ R(
846
+ Cs,
842
847
  {
843
- expanded: ps === `panel${e == null ? void 0 : e.id}`,
844
- onChange: hs(e),
848
+ expanded: gs === `panel${e == null ? void 0 : e.id}`,
849
+ onChange: ys(e),
845
850
  slotProps: { transition: { unmountOnExit: !0 } },
846
851
  children: [
847
852
  /* @__PURE__ */ R(
848
- Ns,
853
+ bs,
849
854
  {
850
- expandIcon: /* @__PURE__ */ o(j, { iconName: "faAngleDown" }),
855
+ expandIcon: /* @__PURE__ */ o(W, { iconName: "faAngleDown" }),
851
856
  "aria-controls": `accessrights-panel-${e == null ? void 0 : e.id}-content`,
852
857
  id: `accessrights-panel-${e == null ? void 0 : e.id}-header`,
853
858
  sx: {
@@ -859,16 +864,16 @@ function Ks({
859
864
  },
860
865
  children: [
861
866
  /* @__PURE__ */ o(
862
- bs,
867
+ ks,
863
868
  {
864
869
  size: "small",
865
- label: p(e.code),
870
+ label: h(e.code),
866
871
  color: e.code === "Role" ? "primary" : "default",
867
872
  variant: "outlined"
868
873
  }
869
874
  ),
870
875
  /* @__PURE__ */ o(
871
- ne,
876
+ ie,
872
877
  {
873
878
  variant: "body2",
874
879
  noWrap: !0,
@@ -877,7 +882,7 @@ function Ks({
877
882
  }
878
883
  ),
879
884
  /* @__PURE__ */ R(
880
- A,
885
+ J,
881
886
  {
882
887
  sx: {
883
888
  ml: "auto",
@@ -887,31 +892,31 @@ function Ks({
887
892
  gap: 0.5
888
893
  },
889
894
  children: [
890
- is && /* @__PURE__ */ o(pe, { title: p("Remove access"), children: /* @__PURE__ */ o(
895
+ rs && /* @__PURE__ */ o(he, { title: h("Remove access"), children: /* @__PURE__ */ o(
891
896
  me,
892
897
  {
893
898
  size: "small",
894
899
  color: "error",
895
- "aria-label": `${p("Remove access")}: ${e.displayName}`,
900
+ "aria-label": `${h("Remove access")}: ${e.displayName}`,
896
901
  "data-testid": "accessrights-delete-icon",
897
902
  onClick: (n) => {
898
- n.stopPropagation(), n.preventDefault(), Z(!0), Xe(e.id), Ze(e);
903
+ n.stopPropagation(), n.preventDefault(), q(!0), qe(e.id), Qe(e);
899
904
  },
900
- children: /* @__PURE__ */ o(j, { iconName: "faTrash", size: "sm" })
905
+ children: /* @__PURE__ */ o(W, { iconName: "faTrash", size: "sm" })
901
906
  }
902
907
  ) }),
903
- fe && /* @__PURE__ */ o(
904
- Ke,
908
+ Se && /* @__PURE__ */ o(
909
+ Ze,
905
910
  {
906
911
  config: {
907
- tooltip: p("Bulk actions"),
908
- icon: /* @__PURE__ */ o(j, { iconName: "faPen", size: "sm" }),
912
+ tooltip: h("Bulk actions"),
913
+ icon: /* @__PURE__ */ o(W, { iconName: "faPen", size: "sm" }),
909
914
  dataTestId: "accessrights-edit-icon",
910
915
  menuClick: (n) => {
911
- Qe(() => ({
916
+ Ve(() => ({
912
917
  ...n,
913
918
  code: n.designationId ? "Role" : "User",
914
- menuConfigId: a,
919
+ menuConfigId: l,
915
920
  displayName: n.designationId ? n.roleName : n.fullName
916
921
  }));
917
922
  },
@@ -919,26 +924,26 @@ function Ks({
919
924
  {
920
925
  label: "Check All",
921
926
  onClick: (n) => {
922
- if (Q)
923
- ds({
927
+ if (Y)
928
+ fs({
924
929
  ...n,
925
930
  checkAll: !0
926
931
  });
927
932
  else {
928
- let i = JSON.parse(g);
929
- const t = (y == null ? void 0 : y.length) > 0 ? y.reduce(
930
- (s, { feature_name: r }) => (s[r] = !0, s),
933
+ let i = JSON.parse(y);
934
+ const t = (g == null ? void 0 : g.length) > 0 ? g.reduce(
935
+ (s, { feature_name: a }) => (s[a] = !0, s),
931
936
  {}
932
- ) : Object.keys(i).reduce((s, r) => (s[r] = !0, s), {});
933
- T(
937
+ ) : Object.keys(i).reduce((s, a) => (s[a] = !0, s), {});
938
+ _(
934
939
  (s) => s.map(
935
- (r) => r.id === n.id ? {
936
- ...r,
940
+ (a) => a.id === n.id ? {
941
+ ...a,
937
942
  featureJson: JSON.stringify(t)
938
- } : r
943
+ } : a
939
944
  )
940
- ), Je({
941
- ...qe,
945
+ ), Pe({
946
+ ...Ye,
942
947
  featureJson: JSON.stringify(t)
943
948
  });
944
949
  }
@@ -955,8 +960,8 @@ function Ks({
955
960
  ]
956
961
  }
957
962
  ),
958
- /* @__PURE__ */ o(Cs, { id: `accessrights-panel-${e == null ? void 0 : e.id}-content`, children: ys ? /* @__PURE__ */ o(
959
- A,
963
+ /* @__PURE__ */ o(vs, { id: `accessrights-panel-${e == null ? void 0 : e.id}-content`, children: Is ? /* @__PURE__ */ o(
964
+ J,
960
965
  {
961
966
  sx: {
962
967
  display: "grid",
@@ -970,17 +975,17 @@ function Ks({
970
975
  },
971
976
  children: (() => {
972
977
  const n = JSON.parse(e.featureJson || "{}");
973
- return (y == null ? void 0 : y.length) > 0 ? Object.keys(n).map(
974
- (i, t) => Re({
978
+ return (g == null ? void 0 : g.length) > 0 ? Object.keys(n).map(
979
+ (i, t) => Ee({
975
980
  row: e,
976
981
  featureState: n,
977
982
  featureKey: i,
978
- lookupKey: os.get(i) || i,
983
+ lookupKey: as.get(i) || i,
979
984
  index: t,
980
985
  withModal: !0
981
986
  })
982
- ) : Object.keys(JSON.parse(g || "{}")).map(
983
- (i, t) => Re({
987
+ ) : Object.keys(JSON.parse(y || "{}")).map(
988
+ (i, t) => Ee({
984
989
  row: e,
985
990
  featureState: n,
986
991
  featureKey: i,
@@ -992,12 +997,12 @@ function Ks({
992
997
  })()
993
998
  }
994
999
  ) : /* @__PURE__ */ o(
995
- ne,
1000
+ ie,
996
1001
  {
997
1002
  variant: "body2",
998
1003
  color: "text.secondary",
999
1004
  sx: { fontStyle: "italic", px: 1, py: 0.5 },
1000
- children: p("No rights configured for this sub menu yet")
1005
+ children: h("No rights configured for this sub menu yet")
1001
1006
  }
1002
1007
  ) })
1003
1008
  ]
@@ -1006,7 +1011,7 @@ function Ks({
1006
1011
  )) })
1007
1012
  ] }) });
1008
1013
  }
1009
- Ks.propTypes = {
1014
+ Zs.propTypes = {
1010
1015
  subMenuId: x.any,
1011
1016
  subMenuGroupName: x.any,
1012
1017
  selectedTab: x.any,
@@ -1018,6 +1023,6 @@ Ks.propTypes = {
1018
1023
  rights: x.any
1019
1024
  };
1020
1025
  export {
1021
- Ks as default
1026
+ Zs as default
1022
1027
  };
1023
- //# sourceMappingURL=AccessRights-xrday-L1.js.map
1028
+ //# sourceMappingURL=AccessRights-DBjTQA1-.js.map