@tap-payments/auth-jsconnect 2.8.60-development → 2.8.61-beta

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 (453) hide show
  1. package/build/@types/app.d.ts +17 -17
  2. package/build/@types/config.d.ts +1 -1
  3. package/build/@types/form.d.ts +23 -23
  4. package/build/@types/redux.d.ts +0 -1
  5. package/build/@types/theme.d.ts +1 -1
  6. package/build/api/account.d.ts +2 -2
  7. package/build/api/auth.d.ts +13 -13
  8. package/build/api/availabilityServices.d.ts +3 -3
  9. package/build/api/axios.js +1 -1
  10. package/build/api/board.d.ts +3 -3
  11. package/build/api/brand.d.ts +1 -1
  12. package/build/api/country.d.ts +1 -1
  13. package/build/api/data.d.ts +11 -11
  14. package/build/api/document.d.ts +2 -2
  15. package/build/api/entity.d.ts +12 -12
  16. package/build/api/entity.js +4 -12
  17. package/build/api/file.d.ts +1 -1
  18. package/build/api/firebase.js +1 -1
  19. package/build/api/index.d.ts +2 -2
  20. package/build/api/individual.d.ts +5 -5
  21. package/build/api/init.d.ts +1 -1
  22. package/build/api/lead.d.ts +12 -12
  23. package/build/api/lead.js +1 -1
  24. package/build/api/operator.d.ts +2 -2
  25. package/build/api/operator.js +1 -1
  26. package/build/api/user.d.ts +2 -2
  27. package/build/app/settings.d.ts +3 -21
  28. package/build/app/settings.js +1 -1
  29. package/build/app/store.d.ts +4 -4
  30. package/build/components/AnimationFlow/AnimationFlow.d.ts +1 -1
  31. package/build/components/AnimationFlow/BottomSheet.d.ts +1 -1
  32. package/build/components/AnimationFlow/Dialog.d.ts +1 -1
  33. package/build/components/AnimationFlow/Error.d.ts +2 -1
  34. package/build/components/AnimationFlow/Loader.d.ts +2 -1
  35. package/build/components/ArabicDatePicker/ArabicDatePicker.d.ts +1 -1
  36. package/build/components/Button/Button.d.ts +1 -1
  37. package/build/components/CheckBox/CheckBox.d.ts +1 -1
  38. package/build/components/Collapse/Collapse.d.ts +2 -1
  39. package/build/components/DatePicker/DatePicker.d.ts +1 -1
  40. package/build/components/ExpandIcon/ExpandIcon.d.ts +2 -1
  41. package/build/components/FileInput/DragAndDrop.d.ts +2 -1
  42. package/build/components/FileInput/UploadInput.d.ts +2 -1
  43. package/build/components/Footer/Footer.d.ts +1 -1
  44. package/build/components/Form/Form.d.ts +1 -1
  45. package/build/components/Input/Input.d.ts +1 -1
  46. package/build/components/InputAdornment/InputAdornment.d.ts +1 -1
  47. package/build/components/List/List.d.ts +1 -1
  48. package/build/components/ListItem/ListItem.d.ts +1 -1
  49. package/build/components/Loader/Loader.d.ts +1 -1
  50. package/build/components/LogoBadge/LogoBadge.d.ts +1 -1
  51. package/build/components/OTPField/OTPField.d.ts +1 -1
  52. package/build/components/OTPTimer/OTPTimer.d.ts +1 -1
  53. package/build/components/ProgressBar/CircularProgressBar.d.ts +2 -1
  54. package/build/components/ProgressBar/ProgressBar.d.ts +1 -1
  55. package/build/components/Providers/ReduxProvider.d.ts +1 -1
  56. package/build/components/Providers/ThemeProvider.d.ts +1 -1
  57. package/build/components/Radio/Radio.d.ts +1 -1
  58. package/build/components/RadioGroup/RadioGroup.d.ts +1 -1
  59. package/build/components/RadioLabel/RadioLabel.d.ts +1 -1
  60. package/build/components/SimpleList/SimpleList.d.ts +1 -1
  61. package/build/components/Slide/Slide.d.ts +1 -1
  62. package/build/components/SocialMediaGroup/SocialMediaGroup.d.ts +1 -1
  63. package/build/components/Text/Text.d.ts +1 -1
  64. package/build/components/ToggleButton/ToggleButton.d.ts +1 -1
  65. package/build/components/ToggleButtonGroup/ToggleButtonGroup.d.ts +1 -1
  66. package/build/components/Tooltip/Tooltip.d.ts +1 -1
  67. package/build/components/Tooltip/Tooltip.js +1 -1
  68. package/build/components/Warning/Warning.d.ts +1 -1
  69. package/build/constants/api.d.ts +1 -0
  70. package/build/constants/api.js +2 -0
  71. package/build/constants/app.d.ts +3 -1
  72. package/build/constants/app.js +2 -0
  73. package/build/features/app/auth/authStore.d.ts +21 -201
  74. package/build/features/app/auth/authStore.js +1 -1
  75. package/build/features/app/bank/bankStore.d.ts +29 -104
  76. package/build/features/app/bank/bankStore.js +166 -184
  77. package/build/features/app/board/boardStore.d.ts +5 -41
  78. package/build/features/app/board/boardStore.js +11 -17
  79. package/build/features/app/brand/brandStore.d.ts +46 -157
  80. package/build/features/app/brand/brandStore.js +240 -244
  81. package/build/features/app/business/businessStore.d.ts +18 -162
  82. package/build/features/app/business/businessStore.js +2 -8
  83. package/build/features/app/connect/connectStore.d.ts +16 -151
  84. package/build/features/app/connect/connectStore.js +1 -1
  85. package/build/features/app/connectExpress/connectExpressStore.d.ts +29 -281
  86. package/build/features/app/connectExpress/connectExpressStore.js +1 -1
  87. package/build/features/app/entity/entityStore.d.ts +44 -111
  88. package/build/features/app/entity/entityStore.js +250 -205
  89. package/build/features/app/individual/individualStore.d.ts +58 -201
  90. package/build/features/app/individual/individualStore.js +271 -222
  91. package/build/features/app/password/passwordStore.d.ts +37 -139
  92. package/build/features/app/password/passwordStore.js +217 -171
  93. package/build/features/app/signIn/signInStore.d.ts +7 -61
  94. package/build/features/app/signIn/signInStore.js +1 -1
  95. package/build/features/app/tax/taxStore.d.ts +16 -94
  96. package/build/features/app/tax/taxStore.js +148 -169
  97. package/build/features/auth/Auth.d.ts +2 -1
  98. package/build/features/auth/Auth.js +1 -1
  99. package/build/features/auth/screens/AccountCreatedLoader/AccountCreatedLoader.d.ts +1 -1
  100. package/build/features/auth/screens/AccountNotFound/AccountNotFound.d.ts +1 -1
  101. package/build/features/auth/screens/AuthMerchant/AuthMerchant.d.ts +1 -1
  102. package/build/features/auth/screens/AuthSwitch/AuthSwitch.d.ts +1 -1
  103. package/build/features/auth/screens/AuthenticationList/AuthenticationList.d.ts +1 -1
  104. package/build/features/auth/screens/AuthenticationList/BrandList.d.ts +1 -1
  105. package/build/features/auth/screens/AuthenticationList/EntityLegalName.d.ts +2 -1
  106. package/build/features/auth/screens/AuthenticationList/EntityLicenseType.d.ts +27 -5
  107. package/build/features/auth/screens/AuthenticationList/EntityList.d.ts +1 -1
  108. package/build/features/auth/screens/AuthenticationList/LicenseNumber.d.ts +1 -1
  109. package/build/features/auth/screens/BusinessCountry/BusinessCountry.d.ts +1 -1
  110. package/build/features/auth/screens/BusinessCountry/BusinessCountry.js +1 -1
  111. package/build/features/auth/screens/CivilID/CivilID.d.ts +1 -1
  112. package/build/features/auth/screens/Email/Email.d.ts +1 -1
  113. package/build/features/auth/screens/EmailSent/EmailSent.d.ts +1 -1
  114. package/build/features/auth/screens/MigratingData/MigratingData.d.ts +1 -1
  115. package/build/features/auth/screens/Mobile/Mobile.d.ts +1 -1
  116. package/build/features/auth/screens/NID/DOB.d.ts +2 -1
  117. package/build/features/auth/screens/NID/NID.d.ts +1 -1
  118. package/build/features/auth/screens/OTP/OTP.d.ts +1 -1
  119. package/build/features/auth/screens/OTP/OTPInput.d.ts +1 -1
  120. package/build/features/auth/screens/OperatorError/OperatorError.d.ts +1 -1
  121. package/build/features/auth/screens/Password/Password.d.ts +1 -1
  122. package/build/features/auth/screens/Password/PasswordField.d.ts +1 -1
  123. package/build/features/auth/screens/PreparingData/PreparingData.d.ts +1 -1
  124. package/build/features/auth/screens/ResetPasswordMessage/ResetPasswordMessage.d.ts +1 -1
  125. package/build/features/auth/screens/VerifyPACI/VerifyPACI.d.ts +1 -1
  126. package/build/features/bank/Bank.d.ts +2 -1
  127. package/build/features/bank/screens/BankDetails/BankDetails.d.ts +2 -1
  128. package/build/features/bank/screens/BankDetails/BankDetails.js +4 -17
  129. package/build/features/bank/screens/BankDetails/BankName.d.ts +3 -2
  130. package/build/features/bank/screens/BankDetails/BankStatement.d.ts +3 -2
  131. package/build/features/bank/screens/BankDetails/Beneficiary.d.ts +2 -1
  132. package/build/features/bank/screens/BankDetails/ConfirmPolicy.d.ts +3 -2
  133. package/build/features/bank/screens/BankDetails/IBAN.d.ts +2 -1
  134. package/build/features/bank/screens/BankDetails/IBAN.js +1 -1
  135. package/build/features/bank/screens/OperatorError/OperatorError.d.ts +1 -1
  136. package/build/features/bank/screens/PrepareDataLoading/PrepareDataLoading.d.ts +2 -2
  137. package/build/features/bank/screens/ResetPasswordSuccess/ResetPasswordSuccess.d.ts +1 -1
  138. package/build/features/bank/screens/Success/Success.d.ts +1 -1
  139. package/build/features/bank/screens/SuccessWithFlowButtons/SuccessWithFlowButtons.d.ts +1 -1
  140. package/build/features/bank/screens/Verify/OTPInput.d.ts +1 -1
  141. package/build/features/bank/screens/Verify/Verify.d.ts +1 -1
  142. package/build/features/board/Board.d.ts +2 -1
  143. package/build/features/board/screens/OperatorError/OperatorError.d.ts +1 -1
  144. package/build/features/board/screens/ResetPasswordSuccess/ResetPasswordSuccess.d.ts +1 -1
  145. package/build/features/board/screens/SuccessWithFlowButtons/SuccessWithFlowButtons.d.ts +1 -1
  146. package/build/features/board/screens/Verify/OTPInput.d.ts +1 -1
  147. package/build/features/board/screens/Verify/Verify.d.ts +1 -1
  148. package/build/features/brand/Brand.d.ts +2 -1
  149. package/build/features/brand/screens/BrandActivities/ActivitiesList.d.ts +58 -15
  150. package/build/features/brand/screens/BrandActivities/BrandActivities.d.ts +2 -1
  151. package/build/features/brand/screens/BrandActivities/BrandActivities.js +11 -48
  152. package/build/features/brand/screens/BrandActivities/CustomerBase.d.ts +37 -13
  153. package/build/features/brand/screens/BrandActivities/ExpectedCustomers.d.ts +2 -1
  154. package/build/features/brand/screens/BrandActivities/ExpectedSalesRange.d.ts +2 -1
  155. package/build/features/brand/screens/BrandActivities/RefundPolicy.d.ts +31 -10
  156. package/build/features/brand/screens/BrandActivities/TAC.d.ts +8 -3
  157. package/build/features/brand/screens/BrandActivities/TransactionPolicy.d.ts +3 -2
  158. package/build/features/brand/screens/BrandInfo/BrandInfo.d.ts +2 -1
  159. package/build/features/brand/screens/BrandInfo/BrandInfo.js +4 -22
  160. package/build/features/brand/screens/BrandInfo/BrandLogo.d.ts +3 -2
  161. package/build/features/brand/screens/BrandInfo/BrandName.d.ts +1 -1
  162. package/build/features/brand/screens/BrandInfo/BrandName.js +1 -1
  163. package/build/features/brand/screens/BrandInfo/SalesChannels.d.ts +2 -1
  164. package/build/features/brand/screens/BrandSegmentInfo/BrandSegmentInfo.d.ts +2 -1
  165. package/build/features/brand/screens/BrandSegmentInfo/BrandSegmentInfo.js +6 -22
  166. package/build/features/brand/screens/BrandSegmentInfo/SegmentLocations.d.ts +2 -1
  167. package/build/features/brand/screens/BrandSegmentInfo/SegmentProfits.d.ts +2 -1
  168. package/build/features/brand/screens/BrandSegmentInfo/SegmentTechs.d.ts +2 -1
  169. package/build/features/brand/screens/BrandSegmentInfo/TeamSize.d.ts +2 -1
  170. package/build/features/brand/screens/OperatorError/OperatorError.d.ts +1 -1
  171. package/build/features/brand/screens/PrepareDataLoading/PrepareDataLoading.d.ts +2 -2
  172. package/build/features/brand/screens/ResetPasswordSuccess/ResetPasswordSuccess.d.ts +1 -1
  173. package/build/features/brand/screens/Success/Success.d.ts +1 -1
  174. package/build/features/brand/screens/SuccessWithFlowButtons/SuccessWithFlowButtons.d.ts +1 -1
  175. package/build/features/brand/screens/Verify/OTPInput.d.ts +1 -1
  176. package/build/features/brand/screens/Verify/Verify.d.ts +1 -1
  177. package/build/features/business/Business.d.ts +2 -1
  178. package/build/features/business/screens/Activities/Activities.d.ts +2 -1
  179. package/build/features/business/screens/Activities/Activities.js +1 -9
  180. package/build/features/business/screens/Activities/ActivitiesList.d.ts +25 -9
  181. package/build/features/business/screens/Activities/LicenseName.d.ts +1 -1
  182. package/build/features/business/screens/Activities/OperationStartDate.d.ts +13 -5
  183. package/build/features/business/screens/BrandDetails/BrandDetails.d.ts +1 -1
  184. package/build/features/business/screens/BrandDetails/BrandName.d.ts +1 -1
  185. package/build/features/business/screens/BrandDetails/Header.d.ts +1 -1
  186. package/build/features/business/screens/BrandDetails/LicenseInfo.d.ts +1 -1
  187. package/build/features/business/screens/BrandDetails/SalesChannel.d.ts +13 -5
  188. package/build/features/business/screens/BusinessType/Article.d.ts +3 -2
  189. package/build/features/business/screens/BusinessType/BusinessType.d.ts +1 -1
  190. package/build/features/business/screens/BusinessType/EntityLicenseList.d.ts +1 -1
  191. package/build/features/business/screens/BusinessType/EntityName.d.ts +2 -1
  192. package/build/features/business/screens/BusinessType/LicenseCertificate.d.ts +2 -1
  193. package/build/features/business/screens/BusinessType/LicenseList.d.ts +1 -1
  194. package/build/features/business/screens/BusinessType/LicenseNumber.d.ts +1 -1
  195. package/build/features/business/screens/BusinessType/LicenseType.d.ts +28 -6
  196. package/build/features/business/screens/BusinessType/SelectType.d.ts +1 -1
  197. package/build/features/business/screens/BusinessType/Switch.d.ts +1 -1
  198. package/build/features/business/screens/CivilID/CivilID.d.ts +1 -1
  199. package/build/features/business/screens/Customers/CustomerLocations.d.ts +70 -19
  200. package/build/features/business/screens/Customers/Customers.d.ts +1 -1
  201. package/build/features/business/screens/Customers/Customers.js +1 -9
  202. package/build/features/business/screens/Customers/ExpectedCustomers.d.ts +2 -1
  203. package/build/features/business/screens/Customers/ExpectedSalesRange.d.ts +2 -1
  204. package/build/features/business/screens/Customers/RefundPolicy.d.ts +31 -10
  205. package/build/features/business/screens/Customers/TransactionPolicy.d.ts +3 -2
  206. package/build/features/business/screens/IDBOD/DOB.d.ts +1 -1
  207. package/build/features/business/screens/IDBOD/ID.d.ts +1 -1
  208. package/build/features/business/screens/IDBOD/IDBOD.d.ts +1 -1
  209. package/build/features/business/screens/OTP/OTP.d.ts +1 -1
  210. package/build/features/business/screens/OTP/OTPInput.d.ts +1 -1
  211. package/build/features/business/screens/OperatorError/OperatorError.d.ts +1 -1
  212. package/build/features/business/screens/ResetPasswordSuccess/ResetPasswordSuccess.d.ts +1 -1
  213. package/build/features/business/screens/Success/Success.d.ts +1 -1
  214. package/build/features/business/screens/SuccessWithFlowButtons/SuccessWithFlowButtons.d.ts +1 -1
  215. package/build/features/business/screens/Verify/OTPInput.d.ts +1 -1
  216. package/build/features/business/screens/Verify/Verify.d.ts +1 -1
  217. package/build/features/business/screens/VerifyPACI/VerifyPACI.d.ts +1 -1
  218. package/build/features/connect/Connect.d.ts +2 -1
  219. package/build/features/connect/Connect.js +1 -1
  220. package/build/features/connect/screens/BrandSegment/BrandSegment.d.ts +1 -1
  221. package/build/features/connect/screens/BrandSegment/TeamSize.d.ts +2 -1
  222. package/build/features/connect/screens/BusinessCountry/BusinessCountry.d.ts +1 -1
  223. package/build/features/connect/screens/BusinessCountry/BusinessCountry.js +2 -8
  224. package/build/features/connect/screens/CivilID/CivilID.d.ts +1 -1
  225. package/build/features/connect/screens/Individual/Email.d.ts +1 -1
  226. package/build/features/connect/screens/Individual/Email.js +1 -1
  227. package/build/features/connect/screens/Individual/Individual.d.ts +1 -1
  228. package/build/features/connect/screens/Individual/Name.d.ts +1 -1
  229. package/build/features/connect/screens/Merchant/BrandList.d.ts +1 -1
  230. package/build/features/connect/screens/Merchant/BrandName.d.ts +1 -1
  231. package/build/features/connect/screens/Merchant/BrandName.js +1 -1
  232. package/build/features/connect/screens/Merchant/Merchant.d.ts +1 -1
  233. package/build/features/connect/screens/Merchant/SalesChannels.d.ts +2 -1
  234. package/build/features/connect/screens/Merchant/TAC.d.ts +1 -1
  235. package/build/features/connect/screens/Mobile/Mobile.d.ts +1 -1
  236. package/build/features/connect/screens/Mobile/Title.d.ts +1 -1
  237. package/build/features/connect/screens/NID/DOB.d.ts +2 -1
  238. package/build/features/connect/screens/NID/NID.d.ts +1 -1
  239. package/build/features/connect/screens/OTP/OTP.d.ts +1 -1
  240. package/build/features/connect/screens/OTP/OTPInput.d.ts +1 -1
  241. package/build/features/connect/screens/OperatorError/OperatorError.d.ts +1 -1
  242. package/build/features/connect/screens/ThankYou/ThankYou.d.ts +1 -1
  243. package/build/features/connect/screens/VerifyPACI/VerifyPACI.d.ts +1 -1
  244. package/build/features/connectExpress/ConnectExpress.d.ts +2 -1
  245. package/build/features/connectExpress/ConnectExpress.js +1 -1
  246. package/build/features/connectExpress/screens/AccountAlreadyCreated/AccountAlreadyCreated.d.ts +1 -1
  247. package/build/features/connectExpress/screens/AccountCreatedLoader/AccountCreatedLoader.d.ts +1 -1
  248. package/build/features/connectExpress/screens/AuthMerchant/AuthMerchant.d.ts +1 -1
  249. package/build/features/connectExpress/screens/AuthenticationList/AuthenticationList.d.ts +1 -1
  250. package/build/features/connectExpress/screens/AuthenticationList/BrandList.d.ts +1 -1
  251. package/build/features/connectExpress/screens/AuthenticationList/EntityLegalName.d.ts +2 -1
  252. package/build/features/connectExpress/screens/AuthenticationList/EntityLicenseType.d.ts +27 -5
  253. package/build/features/connectExpress/screens/AuthenticationList/EntityList.d.ts +1 -1
  254. package/build/features/connectExpress/screens/AuthenticationList/LicenseNumber.d.ts +1 -1
  255. package/build/features/connectExpress/screens/Brand/Brand.d.ts +1 -1
  256. package/build/features/connectExpress/screens/BusinessCountry/BusinessCountry.d.ts +1 -1
  257. package/build/features/connectExpress/screens/BusinessCountry/BusinessCountry.js +1 -1
  258. package/build/features/connectExpress/screens/CivilID/CivilID.d.ts +1 -1
  259. package/build/features/connectExpress/screens/CivilIDMissed/CivilID.d.ts +1 -1
  260. package/build/features/connectExpress/screens/CollectBusinessInfo/BrandName.d.ts +1 -1
  261. package/build/features/connectExpress/screens/CollectBusinessInfo/BrandName.js +1 -1
  262. package/build/features/connectExpress/screens/CollectBusinessInfo/CollectBusinessInfo.d.ts +1 -1
  263. package/build/features/connectExpress/screens/CollectBusinessInfo/LicenseList.d.ts +1 -1
  264. package/build/features/connectExpress/screens/CollectBusinessInfo/LicenseNumber.d.ts +1 -1
  265. package/build/features/connectExpress/screens/CollectBusinessInfo/LicenseType.d.ts +28 -6
  266. package/build/features/connectExpress/screens/CollectBusinessInfo/TAC.d.ts +8 -3
  267. package/build/features/connectExpress/screens/CollectIndividualInfo/CollectIndividualInfo.d.ts +1 -1
  268. package/build/features/connectExpress/screens/CollectIndividualInfo/Email.d.ts +1 -1
  269. package/build/features/connectExpress/screens/CollectIndividualInfo/Email.js +1 -1
  270. package/build/features/connectExpress/screens/CollectIndividualInfo/Name.d.ts +1 -1
  271. package/build/features/connectExpress/screens/CreateAccountLoader/CreateAccountLoader.d.ts +1 -1
  272. package/build/features/connectExpress/screens/IdentityOTP/OTP.d.ts +1 -1
  273. package/build/features/connectExpress/screens/IdentityOTP/OTPInput.d.ts +1 -1
  274. package/build/features/connectExpress/screens/IdentityVerifyPACI/VerifyPACI.d.ts +1 -1
  275. package/build/features/connectExpress/screens/Mobile/Mobile.d.ts +1 -1
  276. package/build/features/connectExpress/screens/Mobile/TAC.d.ts +1 -1
  277. package/build/features/connectExpress/screens/Mobile/Title.d.ts +1 -1
  278. package/build/features/connectExpress/screens/NID/DOB.d.ts +2 -1
  279. package/build/features/connectExpress/screens/NID/NID.d.ts +1 -1
  280. package/build/features/connectExpress/screens/NID/TAC.d.ts +8 -3
  281. package/build/features/connectExpress/screens/NIDMissed/DOB.d.ts +2 -1
  282. package/build/features/connectExpress/screens/NIDMissed/NID.d.ts +1 -1
  283. package/build/features/connectExpress/screens/OTP/OTP.d.ts +1 -1
  284. package/build/features/connectExpress/screens/OTP/OTPInput.d.ts +1 -1
  285. package/build/features/connectExpress/screens/OperatorError/OperatorError.d.ts +1 -1
  286. package/build/features/connectExpress/screens/PrepareDataLoading/PrepareDataLoading.d.ts +1 -1
  287. package/build/features/connectExpress/screens/SuccessWithFlowButtons/SuccessWithFlowButtons.d.ts +1 -1
  288. package/build/features/connectExpress/screens/VerifyPACI/VerifyPACI.d.ts +1 -1
  289. package/build/features/entity/Entity.d.ts +2 -1
  290. package/build/features/entity/screens/EntityCapital/ActivityList.d.ts +25 -9
  291. package/build/features/entity/screens/EntityCapital/CapitalPaid.d.ts +1 -1
  292. package/build/features/entity/screens/EntityCapital/CapitalShareCount.d.ts +1 -1
  293. package/build/features/entity/screens/EntityCapital/CapitalShareValue.d.ts +1 -1
  294. package/build/features/entity/screens/EntityCapital/EntityCapital.d.ts +2 -1
  295. package/build/features/entity/screens/EntityCapital/EntityCapital.js +9 -33
  296. package/build/features/entity/screens/EntityName/Article.d.ts +3 -2
  297. package/build/features/entity/screens/EntityName/EntityName.d.ts +2 -1
  298. package/build/features/entity/screens/EntityName/EntityName.js +14 -31
  299. package/build/features/entity/screens/EntityName/EntityTypeList.d.ts +58 -15
  300. package/build/features/entity/screens/EntityName/ExpiryDate.d.ts +13 -5
  301. package/build/features/entity/screens/EntityName/IssuingDate.d.ts +13 -5
  302. package/build/features/entity/screens/EntityName/LegalName.d.ts +1 -1
  303. package/build/features/entity/screens/EntityName/LicenseCertificate.d.ts +2 -1
  304. package/build/features/entity/screens/EntityName/LicenseNumber.d.ts +1 -1
  305. package/build/features/entity/screens/EntityName/UnifiedNumber.d.ts +1 -1
  306. package/build/features/entity/screens/OperatorError/OperatorError.d.ts +1 -1
  307. package/build/features/entity/screens/PrepareDataLoading/PrepareDataLoading.d.ts +2 -2
  308. package/build/features/entity/screens/ResetPasswordSuccess/ResetPasswordSuccess.d.ts +1 -1
  309. package/build/features/entity/screens/Success/Success.d.ts +1 -1
  310. package/build/features/entity/screens/SuccessWithFlowButtons/SuccessWithFlowButtons.d.ts +1 -1
  311. package/build/features/entity/screens/Verify/OTPInput.d.ts +1 -1
  312. package/build/features/entity/screens/Verify/Verify.d.ts +1 -1
  313. package/build/features/individual/Individual.d.ts +2 -1
  314. package/build/features/individual/screens/AdditionalIndividualInfo/AdditionalIndividualInfo.d.ts +13 -5
  315. package/build/features/individual/screens/AdditionalIndividualInfo/AdditionalIndividualInfo.js +10 -43
  316. package/build/features/individual/screens/AdditionalIndividualInfo/CivilIDFile.d.ts +3 -2
  317. package/build/features/individual/screens/AdditionalIndividualInfo/InfluencerSwitch.d.ts +1 -1
  318. package/build/features/individual/screens/AdditionalIndividualInfo/IsAuthorizedSwitch.d.ts +27 -5
  319. package/build/features/individual/screens/AdditionalIndividualInfo/MonthlyIncome.d.ts +1 -1
  320. package/build/features/individual/screens/AdditionalIndividualInfo/Occupation.d.ts +2 -1
  321. package/build/features/individual/screens/AdditionalIndividualInfo/PEPSwitch.d.ts +27 -5
  322. package/build/features/individual/screens/AdditionalIndividualInfo/ShareCount.d.ts +1 -1
  323. package/build/features/individual/screens/AdditionalIndividualInfo/ShareValue.d.ts +1 -1
  324. package/build/features/individual/screens/AdditionalIndividualInfo/SignatureFile.d.ts +2 -1
  325. package/build/features/individual/screens/AdditionalIndividualInfo/SourceOfIncome.d.ts +1 -1
  326. package/build/features/individual/screens/IndividualList/CollectPhoneEmail.d.ts +1 -1
  327. package/build/features/individual/screens/IndividualList/Email.d.ts +1 -1
  328. package/build/features/individual/screens/IndividualList/Email.js +1 -1
  329. package/build/features/individual/screens/IndividualList/IndividualList.d.ts +25 -9
  330. package/build/features/individual/screens/IndividualList/IndividualList.js +0 -7
  331. package/build/features/individual/screens/IndividualList/UserList.d.ts +2 -1
  332. package/build/features/individual/screens/IndividualList/UserList.js +3 -3
  333. package/build/features/individual/screens/IndividualPersonalInfo/DOB.d.ts +1 -1
  334. package/build/features/individual/screens/IndividualPersonalInfo/Email.d.ts +1 -1
  335. package/build/features/individual/screens/IndividualPersonalInfo/ExpiryDate.d.ts +1 -1
  336. package/build/features/individual/screens/IndividualPersonalInfo/Gender.d.ts +28 -6
  337. package/build/features/individual/screens/IndividualPersonalInfo/ID.d.ts +1 -1
  338. package/build/features/individual/screens/IndividualPersonalInfo/IndividualPersonalInfo.d.ts +13 -5
  339. package/build/features/individual/screens/IndividualPersonalInfo/IndividualPersonalInfo.js +18 -73
  340. package/build/features/individual/screens/IndividualPersonalInfo/Name.d.ts +1 -1
  341. package/build/features/individual/screens/IndividualPhoneInfo/PhoneInfo.d.ts +1 -1
  342. package/build/features/individual/screens/OperatorError/OperatorError.d.ts +1 -1
  343. package/build/features/individual/screens/PrepareDataLoading/PrepareDataLoading.d.ts +2 -2
  344. package/build/features/individual/screens/ResetPasswordSuccess/ResetPasswordSuccess.d.ts +1 -1
  345. package/build/features/individual/screens/Success/Success.d.ts +1 -1
  346. package/build/features/individual/screens/SuccessWithFlowButtons/SuccessWithFlowButtons.d.ts +1 -1
  347. package/build/features/individual/screens/Verify/OTPInput.d.ts +1 -1
  348. package/build/features/individual/screens/Verify/Verify.d.ts +1 -1
  349. package/build/features/password/Password.d.ts +2 -1
  350. package/build/features/password/Password.js +2 -2
  351. package/build/features/password/screens/CreatePassword/ConditionText.d.ts +2 -1
  352. package/build/features/password/screens/CreatePassword/ConfirmPassword.d.ts +1 -1
  353. package/build/features/password/screens/CreatePassword/CreatePassword.d.ts +1 -1
  354. package/build/features/password/screens/CreatePassword/Password.d.ts +1 -1
  355. package/build/features/password/screens/CreatePassword/PasswordBar.d.ts +2 -1
  356. package/build/features/password/screens/OTP/OTP.d.ts +1 -1
  357. package/build/features/password/screens/OTP/OTPInput.d.ts +1 -1
  358. package/build/features/password/screens/OperatorError/OperatorError.d.ts +1 -1
  359. package/build/features/password/screens/PrepareDataLoading/PrepareDataLoading.d.ts +2 -2
  360. package/build/features/password/screens/ResetPasswordSuccess/ResetPasswordSuccess.d.ts +1 -1
  361. package/build/features/password/screens/Success/Success.d.ts +1 -1
  362. package/build/features/password/screens/SuccessWithFlowButtons/SuccessWithFlowButtons.d.ts +1 -1
  363. package/build/features/password/screens/Verify/OTPInput.d.ts +1 -1
  364. package/build/features/password/screens/Verify/Verify.d.ts +1 -1
  365. package/build/features/shared/AcceptancePayouts/AcceptancePayouts.d.ts +2 -1
  366. package/build/features/shared/Address/Address.d.ts +2 -1
  367. package/build/features/shared/Address/CountryList.d.ts +46 -14
  368. package/build/features/shared/Address/InputSelect.d.ts +46 -14
  369. package/build/features/shared/Address/InputSelect.js +1 -1
  370. package/build/features/shared/Address/InputText.d.ts +1 -1
  371. package/build/features/shared/Background/Background.d.ts +1 -1
  372. package/build/features/shared/Background/LogoBackground.d.ts +1 -1
  373. package/build/features/shared/BouncingDotsLoader/BouncingDotsLoader.d.ts +2 -1
  374. package/build/features/shared/BusinessCountry/BusinessCountry.d.ts +2 -1
  375. package/build/features/shared/BusinessCountry/BusinessCountry.js +1 -1
  376. package/build/features/shared/Button/AbsherButton.d.ts +2 -1
  377. package/build/features/shared/Button/Button.d.ts +2 -1
  378. package/build/features/shared/Button/EmailProvidersButtons.d.ts +3 -2
  379. package/build/features/shared/Button/FlowsButtons.d.ts +3 -2
  380. package/build/features/shared/Button/FlowsButtons.js +2 -8
  381. package/build/features/shared/Button/IndividualActionButtons.d.ts +2 -2
  382. package/build/features/shared/Button/MobileButton.d.ts +2 -1
  383. package/build/features/shared/Button/SuccessButton.d.ts +2 -1
  384. package/build/features/shared/Calender/Calender.d.ts +2 -1
  385. package/build/features/shared/CheckIcon/CheckIcon.d.ts +3 -2
  386. package/build/features/shared/Chip/Chip.d.ts +2 -1
  387. package/build/features/shared/ClearIcon/ClearIcon.d.ts +2 -1
  388. package/build/features/shared/Containers/FeatureContainer.d.ts +1 -1
  389. package/build/features/shared/Containers/ScreenContainer.d.ts +1 -1
  390. package/build/features/shared/CreateAccountLoading/CreateAccountLoading.d.ts +1 -1
  391. package/build/features/shared/DataLoading/DataLoading.d.ts +1 -1
  392. package/build/features/shared/Dialog/CloseDialog.d.ts +2 -1
  393. package/build/features/shared/Dialog/DialogContainer.d.ts +1 -1
  394. package/build/features/shared/Dot/Dot.d.ts +2 -1
  395. package/build/features/shared/EndAdornment/EndAdornment.d.ts +2 -1
  396. package/build/features/shared/EndAdornment/EndAdornmentExpanded.d.ts +2 -1
  397. package/build/features/shared/Footer/Footer.d.ts +2 -1
  398. package/build/features/shared/Footer/PoweredByFooter.d.ts +3 -2
  399. package/build/features/shared/GenericError/GenericError.d.ts +1 -1
  400. package/build/features/shared/Input/Input.d.ts +14 -6
  401. package/build/features/shared/InputSelect/InputSelect.d.ts +2 -1
  402. package/build/features/shared/Mandatory/Mandatory.d.ts +2 -1
  403. package/build/features/shared/OTP/OTP.d.ts +1 -1
  404. package/build/features/shared/PaciVerification/PaciVerification.d.ts +1 -1
  405. package/build/features/shared/PasswordIcon/PasswordIcon.d.ts +2 -1
  406. package/build/features/shared/SalesChannels/SaleChannelIconsInput.d.ts +2 -1
  407. package/build/features/shared/SalesChannels/SalesChannel.d.ts +1 -1
  408. package/build/features/shared/Search/Search.d.ts +2 -1
  409. package/build/features/shared/SearchIcon/SearchIcon.d.ts +2 -1
  410. package/build/features/shared/SuccessFlowButtons/SuccessFlowButtons.d.ts +1 -1
  411. package/build/features/shared/SuccessScreen/SuccessScreen.d.ts +1 -1
  412. package/build/features/shared/UploadFile/FileUpload.d.ts +9 -4
  413. package/build/features/shared/UploadFile/FileUpload.js +1 -1
  414. package/build/features/shared/UploadFile/UploadFile.d.ts +8 -3
  415. package/build/features/shared/UploadFile/UploadWrapper.d.ts +8 -3
  416. package/build/features/shared/UploadMultipleFile/UploadFile.d.ts +9 -4
  417. package/build/features/shared/UploadMultipleFile/UploadFile.js +1 -1
  418. package/build/features/shared/UploadMultipleFile/UploadMultipleFile.d.ts +8 -3
  419. package/build/features/signIn/SignIn.d.ts +2 -1
  420. package/build/features/signIn/SignIn.js +2 -10
  421. package/build/features/signIn/screens/Email/Email.d.ts +1 -1
  422. package/build/features/signIn/screens/Mobile/Mobile.d.ts +1 -1
  423. package/build/features/signIn/screens/OTP/OTP.d.ts +1 -1
  424. package/build/features/signIn/screens/OTP/OTPInput.d.ts +1 -1
  425. package/build/features/signIn/screens/OperatorError/OperatorError.d.ts +1 -1
  426. package/build/features/signIn/screens/Password/Password.d.ts +1 -1
  427. package/build/features/signIn/screens/Password/PasswordInput.d.ts +1 -1
  428. package/build/features/tax/Tax.d.ts +2 -1
  429. package/build/features/tax/screens/OperatorError/OperatorError.d.ts +1 -1
  430. package/build/features/tax/screens/PrepareDataLoading/PrepareDataLoading.d.ts +2 -2
  431. package/build/features/tax/screens/ResetPasswordSuccess/ResetPasswordSuccess.d.ts +1 -1
  432. package/build/features/tax/screens/Success/Success.d.ts +1 -1
  433. package/build/features/tax/screens/SuccessWithFlowButtons/SuccessWithFlowButtons.d.ts +1 -1
  434. package/build/features/tax/screens/TaxDetails/ConfirmPolicy.d.ts +3 -2
  435. package/build/features/tax/screens/TaxDetails/TaxDetails.d.ts +2 -1
  436. package/build/features/tax/screens/TaxDetails/TaxDetails.js +2 -7
  437. package/build/features/tax/screens/TaxDetails/TaxDocument.d.ts +2 -1
  438. package/build/features/tax/screens/TaxDetails/VATId.d.ts +3 -2
  439. package/build/features/tax/screens/Verify/OTPInput.d.ts +1 -1
  440. package/build/features/tax/screens/Verify/Verify.d.ts +1 -1
  441. package/build/hooks/index.d.ts +0 -1
  442. package/build/hooks/index.js +0 -1
  443. package/build/hooks/useDataVerified.d.ts +1 -1
  444. package/build/hooks/useExcludeReadOnlyFelids.d.ts +2 -2
  445. package/build/hooks/useFormErrorAndUpdateReadOnly.d.ts +2 -2
  446. package/build/hooks/useFormReadOnly.d.ts +2 -2
  447. package/build/hooks/useSetFromDefaultValues.d.ts +1 -1
  448. package/build/index.css +21 -1
  449. package/build/utils/array.js +1 -1
  450. package/build/utils/common.js +4 -4
  451. package/package.json +2 -2
  452. package/build/hooks/useFormDirtyCheck.d.ts +0 -10
  453. package/build/hooks/useFormDirtyCheck.js +0 -66
@@ -24,7 +24,7 @@ var __generator = (this && this.__generator) || function (thisArg, body) {
24
24
  function verb(n) { return function (v) { return step([n, v]); }; }
25
25
  function step(op) {
26
26
  if (f) throw new TypeError("Generator is already executing.");
27
- while (g && (g = 0, op[0] && (_ = 0)), _) try {
27
+ while (_) try {
28
28
  if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
29
29
  if (y = 0, t) op = [op[0] & 2, t.value];
30
30
  switch (op[0]) {
@@ -63,14 +63,14 @@ import { BusinessType, DocumentPurpose, FlowsTypes, LicenseType } from '../../..
63
63
  import { handleNextScreenStep, handlePrevScreenStep, handlePublicKey, handleSetCountryByIso2, onCloseComplete } from '../../../app/settings';
64
64
  import { ENTITY_STEP_NAMES } from '../../../constants';
65
65
  import moment from 'moment';
66
- import { convertNumbers2English, getRecentDocumentBasedOnPurpose, hasVerifiedValue, hasNoneEditableValue, sleep, formatNumberAsCurrency, removeAllCharsFromNumber, retrieveIndividualData, sendCustomEventToGTM } from '../../../utils';
66
+ import { convertNumbers2English, getRecentDocumentBasedOnPurpose, hasVerifiedValue, hasNoneEditableValue, sleep, formatNumberAsCurrency, removeAllCharsFromNumber, retrieveIndividualData } from '../../../utils';
67
67
  export var verifyLeadToken = createAsyncThunk('entityVerifyLeadToken', function (_a, thunkApi) {
68
68
  var token = _a.token, isInternally = _a.isInternally;
69
69
  return __awaiter(void 0, void 0, void 0, function () {
70
- var payload, data, entityData, entityTypes, _b, country_code, config, publicKey, _c, entity_id, boardId, data_1;
71
- var _d, _e, _f;
72
- return __generator(this, function (_g) {
73
- switch (_g.label) {
70
+ var payload, data, boardData, boardInfoData, entityData, entityTypes, individualData, countryIso2, publicKey, _b, board_id, board_info_id, _c, id_1, type_1, serviceCallBack, _d, boardRes, individualRes, entityId;
71
+ var _e, _f, _g, _h, _j, _k, _l;
72
+ return __generator(this, function (_m) {
73
+ switch (_m.label) {
74
74
  case 0:
75
75
  payload = __assign({ service_name: 'tap_email', verify_token: token }, (isInternally && {
76
76
  notification: {
@@ -79,47 +79,76 @@ export var verifyLeadToken = createAsyncThunk('entityVerifyLeadToken', function
79
79
  }));
80
80
  return [4, API.leadService.verifyLeadToken(payload)];
81
81
  case 1:
82
- data = (_g.sent()).data;
83
- entityTypes = undefined;
84
- if (((_d = data === null || data === void 0 ? void 0 : data.errors) === null || _d === void 0 ? void 0 : _d.length) || (data === null || data === void 0 ? void 0 : data.mw_error))
85
- throw new Error(data.errors[0].description || (data === null || data === void 0 ? void 0 : data.mw_error));
82
+ data = (_m.sent()).data;
83
+ countryIso2 = undefined;
84
+ if (!(!(data === null || data === void 0 ? void 0 : data.errors) && !(data === null || data === void 0 ? void 0 : data.mw_error))) return [3, 10];
86
85
  if (isInternally)
87
86
  data.step_name = ENTITY_STEP_NAMES.ENTITY_INFO;
88
- _b = data || {}, country_code = _b.country_code, config = _b.config;
89
- publicKey = config === null || config === void 0 ? void 0 : config.public_key;
90
- if (country_code)
91
- thunkApi.dispatch(handleSetCountryByIso2(country_code));
92
- if (publicKey)
87
+ if (data === null || data === void 0 ? void 0 : data.country_code) {
88
+ countryIso2 = data.country_code;
89
+ if (countryIso2)
90
+ thunkApi.dispatch(handleSetCountryByIso2(countryIso2));
91
+ }
92
+ publicKey = (_e = data === null || data === void 0 ? void 0 : data.config) === null || _e === void 0 ? void 0 : _e.public_key;
93
+ if (publicKey) {
93
94
  thunkApi.dispatch(handlePublicKey(publicKey));
94
- if (!(data.step_name !== ENTITY_STEP_NAMES.PHONE_AUTH)) return [3, 7];
95
- _c = data || {}, entity_id = _c.entity_id, boardId = _c.id;
96
- if (!!entity_id) return [3, 3];
97
- return [4, API.boardService.retrieveBoardDetails(boardId)];
95
+ }
96
+ if (!(data.step_name !== ENTITY_STEP_NAMES.PHONE_AUTH)) return [3, 10];
97
+ _b = data || {}, board_id = _b.id, board_info_id = _b.board_info_id;
98
+ if (!board_id) return [3, 6];
99
+ return [4, API.boardService.retrieveBoardDetails(board_id)];
98
100
  case 2:
99
- data_1 = _g.sent();
100
- if (!((_e = data_1 === null || data_1 === void 0 ? void 0 : data_1.entity) === null || _e === void 0 ? void 0 : _e.id))
101
- throw new Error('entity_id_missing');
102
- entityData = data_1;
103
- return [3, 5];
104
- case 3: return [4, API.entityService.retrieveEntity(entity_id)];
101
+ boardData = _m.sent();
102
+ if (!board_info_id) return [3, 4];
103
+ return [4, API.boardService.retrieveBoardInfo({ id: board_id, infoId: board_info_id })];
104
+ case 3:
105
+ boardInfoData = _m.sent();
106
+ _m.label = 4;
105
107
  case 4:
106
- entityData = _g.sent();
107
- _g.label = 5;
108
+ _c = ((_f = boardInfoData === null || boardInfoData === void 0 ? void 0 : boardInfoData.notification) === null || _f === void 0 ? void 0 : _f.recipient) || {}, id_1 = _c.id, type_1 = _c.type;
109
+ serviceCallBack = function () { return API.individualService.retrieveIndividual(id_1, type_1); };
110
+ return [4, retrieveIndividualData(type_1, boardData, serviceCallBack)];
108
111
  case 5:
109
- if (!country_code && ((_f = entityData === null || entityData === void 0 ? void 0 : entityData.entity) === null || _f === void 0 ? void 0 : _f.country))
110
- thunkApi.dispatch(handleSetCountryByIso2(entityData.entity.country));
111
- return [4, API.entityService.retrieveEntityType()];
112
+ _d = _m.sent(), boardRes = _d.boardRes, individualRes = _d.individualRes;
113
+ boardData = boardRes;
114
+ individualData = individualRes;
115
+ _m.label = 6;
112
116
  case 6:
113
- entityTypes = _g.sent();
117
+ entityId = (_g = boardData === null || boardData === void 0 ? void 0 : boardData.entity) === null || _g === void 0 ? void 0 : _g.id;
118
+ if (!entityId) return [3, 8];
119
+ return [4, API.entityService.retrieveEntity(entityId)];
120
+ case 7:
121
+ entityData = _m.sent();
122
+ _m.label = 8;
123
+ case 8:
124
+ if (!countryIso2 && ((_h = entityData === null || entityData === void 0 ? void 0 : entityData.entity) === null || _h === void 0 ? void 0 : _h.country)) {
125
+ countryIso2 = (_j = entityData === null || entityData === void 0 ? void 0 : entityData.entity) === null || _j === void 0 ? void 0 : _j.country;
126
+ thunkApi.dispatch(handleSetCountryByIso2(countryIso2));
127
+ }
128
+ return [4, API.entityService.retrieveEntityType()];
129
+ case 9:
130
+ entityTypes = _m.sent();
114
131
  if (isInternally)
115
132
  sleep(100).then(function () { return thunkApi.dispatch(handleNextScreenStep('ENTITY_NAME_STEP')); });
116
133
  else
117
134
  thunkApi.dispatch(handleNextScreenStep('ENTITY_NAME_STEP'));
118
- _g.label = 7;
119
- case 7: return [2, {
135
+ _m.label = 10;
136
+ case 10: return [2, {
120
137
  data: data,
121
- entityData: entityData === null || entityData === void 0 ? void 0 : entityData.entity,
122
- entityTypes: entityTypes,
138
+ individualData: individualData,
139
+ boardResponse: {
140
+ user: boardData === null || boardData === void 0 ? void 0 : boardData.user,
141
+ brand: boardData === null || boardData === void 0 ? void 0 : boardData.brand,
142
+ bank_account: boardData === null || boardData === void 0 ? void 0 : boardData.bank_account,
143
+ entity: entityData === null || entityData === void 0 ? void 0 : entityData.entity,
144
+ merchant: boardData === null || boardData === void 0 ? void 0 : boardData.merchant,
145
+ name: (_k = boardData === null || boardData === void 0 ? void 0 : boardData.user) === null || _k === void 0 ? void 0 : _k.names,
146
+ contact: (_l = boardData === null || boardData === void 0 ? void 0 : boardData.user) === null || _l === void 0 ? void 0 : _l.contact,
147
+ individuals: boardData === null || boardData === void 0 ? void 0 : boardData.individuals,
148
+ business: boardData === null || boardData === void 0 ? void 0 : boardData.business,
149
+ entityTypes: entityTypes,
150
+ notification: boardInfoData === null || boardInfoData === void 0 ? void 0 : boardInfoData.notification
151
+ },
123
152
  token: token
124
153
  }];
125
154
  }
@@ -144,119 +173,132 @@ export var resendOTP = createAsyncThunk('entityResendOTP', function (params, thu
144
173
  });
145
174
  }); });
146
175
  export var verifyEntityLeadOTP = createAsyncThunk('verifyEntityLeadOTP', function (params, thunkApi) { return __awaiter(void 0, void 0, void 0, function () {
147
- var _a, entity, settings, responseBody, payload, data, _b, entity_id, config, boardId, country_code, entityData, publicKey, countryIso2, data_2, entityTypes;
148
- var _c, _d, _e, _f, _g, _h;
149
- return __generator(this, function (_j) {
150
- switch (_j.label) {
176
+ var _a, entity, settings, responseBody, payload, data, boardData, entityData, entityTypes, boardInfoData, individualData, countryIso2, _b, board_id, board_info_id, config, country_code, publicKey, _c, id_2, type_2, serviceCallBack, _d, boardRes, individualRes, entityId;
177
+ var _e, _f, _g, _h, _j, _k, _l, _m, _o;
178
+ return __generator(this, function (_p) {
179
+ switch (_p.label) {
151
180
  case 0:
152
181
  _a = thunkApi.getState(), entity = _a.entity, settings = _a.settings;
153
182
  responseBody = entity.data.verify.responseBody;
154
183
  payload = {
155
184
  data: params.otp,
156
- service_name: (_c = responseBody === null || responseBody === void 0 ? void 0 : responseBody.verification_by) === null || _c === void 0 ? void 0 : _c.service_name,
185
+ service_name: (_e = responseBody === null || responseBody === void 0 ? void 0 : responseBody.verification_by) === null || _e === void 0 ? void 0 : _e.service_name,
157
186
  verify_token: responseBody === null || responseBody === void 0 ? void 0 : responseBody.verify_token,
158
187
  step_name: ENTITY_STEP_NAMES.PHONE_AUTH,
159
188
  encryption_contract: ['data']
160
189
  };
161
190
  return [4, API.leadService.verifyLeadOTP(payload)];
162
191
  case 1:
163
- data = (_j.sent()).data;
164
- if ((_d = data === null || data === void 0 ? void 0 : data.errors) === null || _d === void 0 ? void 0 : _d.length)
192
+ data = (_p.sent()).data;
193
+ if ((_f = data === null || data === void 0 ? void 0 : data.errors) === null || _f === void 0 ? void 0 : _f.length)
165
194
  throw new Error(data.errors[0].description);
166
- _b = data || {}, entity_id = _b.entity_id, config = _b.config, boardId = _b.id, country_code = _b.country_code;
167
- entityData = undefined;
195
+ countryIso2 = undefined;
196
+ if (!!data.errors) return [3, 10];
197
+ _b = data || {}, board_id = _b.id, board_info_id = _b.board_info_id, config = _b.config, country_code = _b.country_code;
168
198
  publicKey = config === null || config === void 0 ? void 0 : config.public_key;
169
- countryIso2 = country_code || (responseBody === null || responseBody === void 0 ? void 0 : responseBody.country_code);
170
- if (publicKey)
199
+ if (publicKey) {
171
200
  thunkApi.dispatch(handlePublicKey(publicKey));
172
- if (countryIso2)
201
+ }
202
+ if (country_code) {
203
+ countryIso2 = country_code;
173
204
  thunkApi.dispatch(handleSetCountryByIso2(countryIso2));
174
- if (!!entity_id) return [3, 3];
175
- return [4, API.boardService.retrieveBoardDetails(boardId)];
205
+ }
206
+ if (!board_id) return [3, 6];
207
+ return [4, API.boardService.retrieveBoardDetails(board_id)];
176
208
  case 2:
177
- data_2 = _j.sent();
178
- if (!((_e = data_2 === null || data_2 === void 0 ? void 0 : data_2.entity) === null || _e === void 0 ? void 0 : _e.id))
179
- throw new Error('entity_id_missing');
180
- entityData = data_2;
181
- return [3, 5];
182
- case 3: return [4, API.entityService.retrieveEntity(entity_id)];
209
+ boardData = _p.sent();
210
+ if (!board_info_id) return [3, 4];
211
+ return [4, API.boardService.retrieveBoardInfo({ id: board_id, infoId: board_info_id })];
212
+ case 3:
213
+ boardInfoData = _p.sent();
214
+ _p.label = 4;
183
215
  case 4:
184
- entityData = _j.sent();
185
- _j.label = 5;
216
+ _c = ((_g = boardInfoData === null || boardInfoData === void 0 ? void 0 : boardInfoData.notification) === null || _g === void 0 ? void 0 : _g.recipient) || {}, id_2 = _c.id, type_2 = _c.type;
217
+ serviceCallBack = function () { return API.individualService.retrieveIndividual(id_2, type_2); };
218
+ return [4, retrieveIndividualData(type_2, boardData, serviceCallBack)];
186
219
  case 5:
187
- if (!countryIso2 && ((_f = entityData === null || entityData === void 0 ? void 0 : entityData.entity) === null || _f === void 0 ? void 0 : _f.country))
188
- thunkApi.dispatch(handleSetCountryByIso2(entityData.entity.country));
189
- (_h = (_g = settings.data.appConfig).onStepCompleted) === null || _h === void 0 ? void 0 : _h.call(_g, settings.data.activeScreen.name, { otp: params.otp });
190
- return [4, API.entityService.retrieveEntityType()];
220
+ _d = _p.sent(), boardRes = _d.boardRes, individualRes = _d.individualRes;
221
+ boardData = boardRes;
222
+ individualData = individualRes;
223
+ _p.label = 6;
191
224
  case 6:
192
- entityTypes = _j.sent();
225
+ entityId = (_h = boardData === null || boardData === void 0 ? void 0 : boardData.entity) === null || _h === void 0 ? void 0 : _h.id;
226
+ if (!entityId) return [3, 8];
227
+ return [4, API.entityService.retrieveEntity(entityId)];
228
+ case 7:
229
+ entityData = _p.sent();
230
+ _p.label = 8;
231
+ case 8:
232
+ if (!countryIso2 && ((_j = entityData === null || entityData === void 0 ? void 0 : entityData.entity) === null || _j === void 0 ? void 0 : _j.country)) {
233
+ countryIso2 = entityData.entity.country;
234
+ thunkApi.dispatch(handleSetCountryByIso2(countryIso2));
235
+ }
236
+ (_l = (_k = settings.data.appConfig).onStepCompleted) === null || _l === void 0 ? void 0 : _l.call(_k, settings.data.activeScreen.name, { otp: params.otp });
237
+ return [4, API.entityService.retrieveEntityType()];
238
+ case 9:
239
+ entityTypes = _p.sent();
193
240
  sleep(100).then(function () { return thunkApi.dispatch(handleNextScreenStep('ENTITY_NAME_STEP')); });
194
- return [2, {
195
- data: data,
196
- entityData: entityData === null || entityData === void 0 ? void 0 : entityData.entity,
241
+ _p.label = 10;
242
+ case 10: return [2, {
243
+ data: data,
244
+ individualData: individualData,
245
+ boardResponse: {
246
+ user: boardData === null || boardData === void 0 ? void 0 : boardData.user,
247
+ brand: boardData === null || boardData === void 0 ? void 0 : boardData.brand,
248
+ bank_account: boardData === null || boardData === void 0 ? void 0 : boardData.bank_account,
249
+ entity: entityData === null || entityData === void 0 ? void 0 : entityData.entity,
250
+ merchant: boardData === null || boardData === void 0 ? void 0 : boardData.merchant,
251
+ name: (_m = boardData === null || boardData === void 0 ? void 0 : boardData.user) === null || _m === void 0 ? void 0 : _m.names,
252
+ contact: (_o = boardData === null || boardData === void 0 ? void 0 : boardData.user) === null || _o === void 0 ? void 0 : _o.contact,
253
+ individuals: boardData === null || boardData === void 0 ? void 0 : boardData.individuals,
254
+ business: boardData === null || boardData === void 0 ? void 0 : boardData.business,
197
255
  entityTypes: entityTypes,
198
- formData: params
199
- }];
256
+ notification: boardInfoData === null || boardInfoData === void 0 ? void 0 : boardInfoData.notification
257
+ },
258
+ formData: params
259
+ }];
200
260
  }
201
261
  });
202
262
  }); });
203
263
  export var retrieveBoardStatus = createAsyncThunk('entity/retrieveBoardStatus', function (parmas, thunkApi) { return __awaiter(void 0, void 0, void 0, function () {
204
- var entity, _a, board_id, board_info_id, recipient, _b, id, type, data;
205
- return __generator(this, function (_c) {
206
- switch (_c.label) {
264
+ var entity, board_id, data;
265
+ return __generator(this, function (_a) {
266
+ switch (_a.label) {
207
267
  case 0:
208
268
  entity = thunkApi.getState().entity;
209
- _a = entity.data.verify.responseBody || {}, board_id = _a.board_id, board_info_id = _a.board_info_id, recipient = _a.recipient;
210
- if (!board_id || !board_info_id)
211
- throw new Error('Internal server error');
212
- _b = recipient || {}, id = _b.id, type = _b.type;
213
- return [4, Promise.all([
214
- API.boardService.retrieveBoardInfoStatus(board_id),
215
- thunkApi.dispatch(retrieveBoardDetails({ boardId: board_id, individualId: id, individualType: type })).unwrap()
216
- ])];
269
+ board_id = (entity.data.verify.responseBody || {}).board_id;
270
+ return [4, API.boardService.retrieveBoardInfoStatus(board_id)];
217
271
  case 1:
218
- data = (_c.sent())[0];
272
+ data = _a.sent();
219
273
  thunkApi.dispatch(handlePrevScreenStep());
220
274
  return [2, { flows: (data === null || data === void 0 ? void 0 : data.info) || [] }];
221
275
  }
222
276
  });
223
277
  }); });
224
- export var retrieveBoardDetails = createAsyncThunk('entityRetrieveEntityInfo', function (_a) {
225
- var boardId = _a.boardId, id = _a.individualId, type = _a.individualType;
226
- return __awaiter(void 0, void 0, void 0, function () {
227
- var data, individualData, boardData, serviceCallBack, _b, boardRes, individualRes;
228
- var _c, _d, _e;
229
- return __generator(this, function (_f) {
230
- switch (_f.label) {
231
- case 0: return [4, API.boardService.retrieveBoardDetails(boardId)];
232
- case 1:
233
- data = _f.sent();
234
- individualData = data === null || data === void 0 ? void 0 : data.user;
235
- boardData = data;
236
- if (!(((_c = data === null || data === void 0 ? void 0 : data.user) === null || _c === void 0 ? void 0 : _c.id) !== id)) return [3, 3];
237
- serviceCallBack = function () { return API.individualService.retrieveIndividual(id, type); };
238
- return [4, retrieveIndividualData(type, data, serviceCallBack)];
239
- case 2:
240
- _b = _f.sent(), boardRes = _b.boardRes, individualRes = _b.individualRes;
241
- individualData = individualRes;
242
- boardData = boardRes;
243
- _f.label = 3;
244
- case 3: return [2, __assign(__assign({}, boardData), { brand: boardData === null || boardData === void 0 ? void 0 : boardData.brand, bank_account: boardData === null || boardData === void 0 ? void 0 : boardData.bank_account, entity: boardData === null || boardData === void 0 ? void 0 : boardData.entity, merchant: boardData === null || boardData === void 0 ? void 0 : boardData.merchant, name: (_d = boardData === null || boardData === void 0 ? void 0 : boardData.user) === null || _d === void 0 ? void 0 : _d.names, individuals: boardData === null || boardData === void 0 ? void 0 : boardData.individuals, contact: (_e = boardData === null || boardData === void 0 ? void 0 : boardData.user) === null || _e === void 0 ? void 0 : _e.contact, user: individualData, board_status: boardData === null || boardData === void 0 ? void 0 : boardData.status })];
245
- }
246
- });
278
+ export var retrieveBoardDetails = createAsyncThunk('entityRetrieveEntityInfo', function (boardId) { return __awaiter(void 0, void 0, void 0, function () {
279
+ var data;
280
+ var _a, _b;
281
+ return __generator(this, function (_c) {
282
+ switch (_c.label) {
283
+ case 0: return [4, API.boardService.retrieveBoardDetails(boardId)];
284
+ case 1:
285
+ data = _c.sent();
286
+ return [2, {
287
+ data: __assign(__assign({}, data), { user: data === null || data === void 0 ? void 0 : data.user, brand: data === null || data === void 0 ? void 0 : data.brand, bank_account: data === null || data === void 0 ? void 0 : data.bank_account, entity: data === null || data === void 0 ? void 0 : data.entity, merchant: data === null || data === void 0 ? void 0 : data.merchant, name: (_a = data === null || data === void 0 ? void 0 : data.user) === null || _a === void 0 ? void 0 : _a.names, contact: (_b = data === null || data === void 0 ? void 0 : data.user) === null || _b === void 0 ? void 0 : _b.contact, individuals: data === null || data === void 0 ? void 0 : data.individuals, board_status: data === null || data === void 0 ? void 0 : data.status })
288
+ }];
289
+ }
247
290
  });
248
- });
291
+ }); });
249
292
  export var updateEntityName = createAsyncThunk('entityUpdateEntityName', function (_a, thunkApi) {
250
- var formData = _a.formData, originalFormData = _a.originalFormData, isDirty = _a.isDirty;
293
+ var formData = _a.formData, originalFormData = _a.originalFormData;
251
294
  return __awaiter(void 0, void 0, void 0, function () {
252
- var _b, settings, entity, entityRes, _c, id, data_status, data_verification, documents, issuingDate, expiryDate, licenseType, licenseNumber, articleId, unifiedNumber, legalName, certificateId, entityType, issueDate, expDate, isFL, isLegalNameENNonEditable, isLegalNameARNonEditable, isLicenseTypeNonEditable, isEntityTypeNonEditable, isLicenseNumberNonEditable, isUnifiedNumberNonEditable, isIssuingDateNonEditable, isExpiryDateNonEditable, isDocumentsNonEditable, isAOAFileNonEditable, isEntityTypeVerified, isLicenseNonEditable, isLicenseAvailable, payload, entityData, documentData, activityList, entity_1, documentResponse, document, documentBody, documentBody, entity_2, list;
253
- var _d, _e;
254
- return __generator(this, function (_f) {
255
- switch (_f.label) {
295
+ var _b, settings, entity, _c, id, data_status, data_verification, documents, issuingDate, expiryDate, licenseType, licenseNumber, articleId, unifiedNumber, legalName, certificateId, entityType, issueDate, expDate, isFL, isLegalNameENNonEditable, isLegalNameARNonEditable, isLicenseTypeNonEditable, isEntityTypeNonEditable, isLicenseNumberNonEditable, isUnifiedNumberNonEditable, isIssuingDateNonEditable, isExpiryDateNonEditable, isDocumentsNonEditable, isAOAFileNonEditable, isEntityTypeVerified, isLicenseNonEditable, isLicenseAvailable, payload, data, documentResponse, document, documentBody, documentBody, list;
296
+ var _d, _e, _f;
297
+ return __generator(this, function (_g) {
298
+ switch (_g.label) {
256
299
  case 0:
257
300
  _b = thunkApi.getState(), settings = _b.settings, entity = _b.entity;
258
- entityRes = (entity.data.verify.responseBody || {}).entity;
259
- _c = entityRes || {}, id = _c.id, data_status = _c.data_status, data_verification = _c.data_verification, documents = _c.documents;
301
+ _c = ((_d = entity.data.verify.responseBody) === null || _d === void 0 ? void 0 : _d.entity) || {}, id = _c.id, data_status = _c.data_status, data_verification = _c.data_verification, documents = _c.documents;
260
302
  issuingDate = formData.issuingDate, expiryDate = formData.expiryDate, licenseType = formData.licenseType, licenseNumber = formData.licenseNumber, articleId = formData.articleId, unifiedNumber = formData.unifiedNumber, legalName = formData.legalName, certificateId = formData.certificateId, entityType = formData.entityType;
261
303
  issueDate = issuingDate && new Date(issuingDate).getTime();
262
304
  expDate = expiryDate && new Date(expiryDate).getTime();
@@ -296,27 +338,22 @@ export var updateEntityName = createAsyncThunk('entityUpdateEntityName', functio
296
338
  'license.additional_info.unified_number',
297
339
  'type'
298
340
  ] });
299
- entityData = entityRes, activityList = undefined;
300
- if (!isDirty) return [3, 2];
301
341
  return [4, API.entityService.updateEntity(payload)];
302
342
  case 1:
303
- entity_1 = (_f.sent()).entity;
304
- entityData = entity_1;
305
- _f.label = 2;
306
- case 2:
343
+ data = _g.sent();
307
344
  documentResponse = undefined;
308
345
  document = getRecentDocumentBasedOnPurpose(documents, DocumentPurpose.CR);
309
- if (!(!isDocumentsNonEditable && (certificateId || []).length > 0)) return [3, 8];
310
- if (!(document === null || document === void 0 ? void 0 : document.id)) return [3, 4];
346
+ if (!(!isDocumentsNonEditable && (certificateId || []).length > 0)) return [3, 7];
347
+ if (!(document === null || document === void 0 ? void 0 : document.id)) return [3, 3];
311
348
  documentBody = {
312
349
  id: document.id,
313
350
  images: certificateId
314
351
  };
315
352
  return [4, API.documentService.addFilesToExistingDocument(documentBody)];
353
+ case 2:
354
+ documentResponse = _g.sent();
355
+ return [3, 5];
316
356
  case 3:
317
- documentResponse = _f.sent();
318
- return [3, 6];
319
- case 4:
320
357
  documentBody = {
321
358
  entity_id: id || '',
322
359
  documents: [
@@ -327,48 +364,45 @@ export var updateEntityName = createAsyncThunk('entityUpdateEntityName', functio
327
364
  ]
328
365
  };
329
366
  return [4, API.documentService.updateDocumentInfo(documentBody)];
330
- case 5:
331
- documentResponse = _f.sent();
332
- _f.label = 6;
333
- case 6: return [4, API.entityService.retrieveEntity(id)];
334
- case 7:
335
- entity_2 = (_f.sent()).entity;
336
- entityData = entity_2;
337
- documentData = documentResponse;
338
- _f.label = 8;
339
- case 8: return [4, API.dataService.getActivitiesIsIc()];
340
- case 9:
341
- list = (_f.sent()).list;
342
- activityList = list;
367
+ case 4:
368
+ documentResponse = _g.sent();
369
+ _g.label = 5;
370
+ case 5: return [4, API.entityService.retrieveEntity(id)];
371
+ case 6:
372
+ data = _g.sent();
373
+ data.documentData = documentResponse;
374
+ _g.label = 7;
375
+ case 7: return [4, API.dataService.getActivitiesIsIc()];
376
+ case 8:
377
+ list = (_g.sent()).list;
378
+ data.activityList = list;
343
379
  sleep(100).then(function () { return thunkApi.dispatch(handleNextScreenStep()); });
344
- (_e = (_d = settings.data.appConfig).onStepCompleted) === null || _e === void 0 ? void 0 : _e.call(_d, settings.data.activeScreen.name, id);
345
- return [2, { data: { entity: entityData, documentData: documentData, activityList: activityList }, formData: originalFormData }];
380
+ (_f = (_e = settings.data.appConfig).onStepCompleted) === null || _f === void 0 ? void 0 : _f.call(_e, settings.data.activeScreen.name, id);
381
+ return [2, { data: data, formData: originalFormData }];
346
382
  }
347
383
  });
348
384
  });
349
385
  });
350
386
  export var updateEntityCapital = createAsyncThunk('entityUpdateEntityCapital', function (_a, thunkApi) {
351
- var formData = _a.formData, originalFormData = _a.originalFormData, isDirty = _a.isDirty;
387
+ var formData = _a.formData, originalFormData = _a.originalFormData;
352
388
  return __awaiter(void 0, void 0, void 0, function () {
353
- var _b, settings, entity, entityRes, _c, id, data_status, entityActivities, isCapitalPaidNonEditable, isCapitalShareCountNonEditable, isCapitalShareValueNonEditable, isActivitiesNonEditable, capitalShareCount, capitalShareValue, activities, capitalPaid, entityData, hasCapitalShares, isCapitalNonEditable, removedActivities, payload_1, activityIds, payload, entity_3;
354
- var _d, _e;
355
- return __generator(this, function (_f) {
356
- switch (_f.label) {
389
+ var _b, settings, entity, _c, id, data_status, entityActivities, isCapitalPaidNonEditable, isCapitalShareCountNonEditable, isCapitalShareValueNonEditable, isActivitiesNonEditable, capitalShareCount, capitalShareValue, activities, capitalPaid, hasCapitalShares, isCapitalNonEditable, removedActivities, payload_1, activityIds, payload, data;
390
+ var _d, _e, _f;
391
+ return __generator(this, function (_g) {
392
+ switch (_g.label) {
357
393
  case 0:
358
394
  _b = thunkApi.getState(), settings = _b.settings, entity = _b.entity;
359
- entityRes = (entity.data.verify.responseBody || {}).entity;
360
- _c = entityRes || {}, id = _c.id, data_status = _c.data_status, entityActivities = _c.activities;
395
+ _c = ((_d = entity.data.verify.responseBody) === null || _d === void 0 ? void 0 : _d.entity) || {}, id = _c.id, data_status = _c.data_status, entityActivities = _c.activities;
361
396
  isCapitalPaidNonEditable = hasNoneEditableValue(data_status === null || data_status === void 0 ? void 0 : data_status.capital, 'paid');
362
397
  isCapitalShareCountNonEditable = hasNoneEditableValue(data_status === null || data_status === void 0 ? void 0 : data_status.capital, 'shares.count');
363
398
  isCapitalShareValueNonEditable = hasNoneEditableValue(data_status === null || data_status === void 0 ? void 0 : data_status.capital, 'shares.value');
364
399
  isActivitiesNonEditable = hasNoneEditableValue(data_status, 'activities');
365
400
  capitalShareCount = formData.capitalShareCount, capitalShareValue = formData.capitalShareValue, activities = formData.activities, capitalPaid = formData.capitalPaid;
366
- entityData = entityRes;
367
401
  hasCapitalShares = capitalShareCount || capitalShareValue;
368
402
  isCapitalNonEditable = (isCapitalPaidNonEditable && isCapitalShareCountNonEditable && isCapitalShareValueNonEditable) || (!capitalPaid && !hasCapitalShares);
369
403
  removedActivities = (activities === null || activities === void 0 ? void 0 : activities.length) > 0 &&
370
404
  (entityActivities || []).filter(function (entityActivity) { return !(activities || []).some(function (activity) { return activity.id === entityActivity.id; }); });
371
- if (!(!isActivitiesNonEditable && (removedActivities === null || removedActivities === void 0 ? void 0 : removedActivities.length) > 0 && isDirty)) return [3, 2];
405
+ if (!(!isActivitiesNonEditable && (removedActivities === null || removedActivities === void 0 ? void 0 : removedActivities.length) > 0)) return [3, 2];
372
406
  payload_1 = {
373
407
  id: id,
374
408
  activities: removedActivities.map(function (a) { return ({
@@ -377,8 +411,8 @@ export var updateEntityCapital = createAsyncThunk('entityUpdateEntityCapital', f
377
411
  };
378
412
  return [4, API.entityService.removeEntityActivities(payload_1)];
379
413
  case 1:
380
- _f.sent();
381
- _f.label = 2;
414
+ _g.sent();
415
+ _g.label = 2;
382
416
  case 2:
383
417
  activityIds = (activities || []).map(function (_a) {
384
418
  var id = _a.id;
@@ -392,61 +426,50 @@ export var updateEntityCapital = createAsyncThunk('entityUpdateEntityCapital', f
392
426
  }
393
427
  }))
394
428
  }));
395
- if (!isDirty) return [3, 4];
396
429
  return [4, API.entityService.updateEntity(payload)];
397
430
  case 3:
398
- entity_3 = (_f.sent()).entity;
399
- entityData = entity_3;
400
- _f.label = 4;
401
- case 4:
431
+ data = _g.sent();
402
432
  thunkApi.dispatch(handleNextScreenStep());
403
- (_e = (_d = settings.data.appConfig).onStepCompleted) === null || _e === void 0 ? void 0 : _e.call(_d, settings.data.activeScreen.name, id);
404
- return [2, { data: entityData, formData: originalFormData }];
433
+ (_f = (_e = settings.data.appConfig).onStepCompleted) === null || _f === void 0 ? void 0 : _f.call(_e, settings.data.activeScreen.name, id);
434
+ return [2, { data: data, formData: originalFormData }];
405
435
  }
406
436
  });
407
437
  });
408
438
  });
409
439
  export var updateBoardSuccess = createAsyncThunk('updateBoardEntitySuccess', function (params, thunkApi) { return __awaiter(void 0, void 0, void 0, function () {
410
- var _a, settings, entity, _b, board_id, infoId, _c, showBoard, mode, payload, data, _d, id, type, boardInfoStatusData;
411
- var _e, _f, _g, _h, _j, _k, _l, _m, _o;
412
- return __generator(this, function (_p) {
413
- switch (_p.label) {
440
+ var _a, settings, entity, _b, id, infoId, _c, showBoard, mode, payload, data, boardInfoData;
441
+ var _d, _e, _f, _g, _h, _j, _k, _l;
442
+ return __generator(this, function (_m) {
443
+ switch (_m.label) {
414
444
  case 0:
415
445
  _a = thunkApi.getState(), settings = _a.settings, entity = _a.entity;
416
- _b = entity.data.verify.responseBody || {}, board_id = _b.board_id, infoId = _b.board_info_id;
446
+ _b = entity.data.verify.responseBody || {}, id = _b.board_id, infoId = _b.board_info_id;
417
447
  _c = settings.data.appConfig, showBoard = _c.showBoard, mode = _c.mode;
418
- if (!board_id)
448
+ if (!id)
419
449
  return [2];
420
450
  payload = {
421
451
  lang: settings.data.language,
422
452
  step_name: ENTITY_STEP_NAMES.ENTITY_SUCCESS,
423
- id: board_id
453
+ id: id
424
454
  };
425
- return [4, API.boardService.updateBoardInfo(__assign({ id: board_id, infoId: infoId }, payload))];
455
+ return [4, API.boardService.updateBoardInfo(__assign({ id: id, infoId: infoId }, payload))];
426
456
  case 1:
427
- data = _p.sent();
428
- sendCustomEventToGTM({
429
- event: 'Send Event',
430
- event_category: 'Board Flows - Entity',
431
- event_action: 'Entity Update Success Page',
432
- event_label: settings.data.businessCountry.iso2
433
- });
457
+ data = _m.sent();
434
458
  if (!showBoard && mode === 'content') {
435
- (_f = (_e = settings.data.appConfig).onStepCompleted) === null || _f === void 0 ? void 0 : _f.call(_e, settings.data.activeScreen.name, {});
436
- (_h = (_g = settings.data.appConfig).onFlowCompleted) === null || _h === void 0 ? void 0 : _h.call(_g, { data: data });
437
- return [2, { data: data }];
459
+ (_e = (_d = settings.data.appConfig).onStepCompleted) === null || _e === void 0 ? void 0 : _e.call(_d, settings.data.activeScreen.name, {});
460
+ (_g = (_f = settings.data.appConfig).onFlowCompleted) === null || _g === void 0 ? void 0 : _g.call(_f, { data: data });
461
+ return [2, { response: __assign({}, data), formData: params }];
438
462
  }
439
- _d = ((_j = data === null || data === void 0 ? void 0 : data.notification) === null || _j === void 0 ? void 0 : _j.recipient) || {}, id = _d.id, type = _d.type;
440
- return [4, Promise.all([
441
- API.boardService.retrieveBoardInfoStatus(board_id),
442
- thunkApi.dispatch(retrieveBoardDetails({ boardId: board_id, individualId: id, individualType: type })).unwrap()
443
- ])];
463
+ return [4, API.boardService.retrieveBoardInfoStatus(id)];
444
464
  case 2:
445
- boardInfoStatusData = (_p.sent())[0];
446
- (_l = (_k = settings.data.appConfig).onStepCompleted) === null || _l === void 0 ? void 0 : _l.call(_k, settings.data.activeScreen.name, {});
447
- (_o = (_m = settings.data.appConfig).onFlowCompleted) === null || _o === void 0 ? void 0 : _o.call(_m, { data: data });
465
+ boardInfoData = _m.sent();
466
+ return [4, thunkApi.dispatch(retrieveBoardDetails(id))];
467
+ case 3:
468
+ _m.sent();
469
+ (_j = (_h = settings.data.appConfig).onStepCompleted) === null || _j === void 0 ? void 0 : _j.call(_h, settings.data.activeScreen.name, {});
470
+ (_l = (_k = settings.data.appConfig).onFlowCompleted) === null || _l === void 0 ? void 0 : _l.call(_k, { data: data });
448
471
  thunkApi.dispatch(handleNextScreenStep());
449
- return [2, { data: data, flows: (boardInfoStatusData === null || boardInfoStatusData === void 0 ? void 0 : boardInfoStatusData.info) || [] }];
472
+ return [2, { response: __assign(__assign({}, data), { flows: (boardInfoData === null || boardInfoData === void 0 ? void 0 : boardInfoData.info) || [] }), formData: params }];
450
473
  }
451
474
  });
452
475
  }); });
@@ -526,22 +549,28 @@ export var entitySlice = createSlice({
526
549
  state.customLoading = true;
527
550
  })
528
551
  .addCase(verifyLeadToken.fulfilled, function (state, action) {
529
- var _a, _b, _c;
552
+ var _a, _b, _c, _d;
530
553
  state.error = null;
531
554
  state.customLoading = false;
532
- var _d = action.payload, data = _d.data, token = _d.token, entity = _d.entityData, entityTypes = _d.entityTypes;
533
- state.data.verify.responseBody = __assign(__assign(__assign({}, data), state.data.verify.responseBody), { entity: entity, entityTypes: entityTypes, board_id: data.id });
555
+ var _e = action.payload, data = _e.data, token = _e.token, boardResponse = _e.boardResponse, individualData = _e.individualData;
556
+ var description = (((_a = data === null || data === void 0 ? void 0 : data.errors) === null || _a === void 0 ? void 0 : _a[0]) || {}).description;
557
+ if (description) {
558
+ state.error = description;
559
+ return;
560
+ }
561
+ state.data.verify.responseBody = __assign(__assign(__assign(__assign({}, data), state.data.verify.responseBody), boardResponse), { board_id: data.id, individualData: individualData });
534
562
  state.data.verify.token = token;
563
+ var _f = boardResponse || {}, entity = _f.entity, entityTypes = _f.entityTypes;
535
564
  if (entity) {
536
- var _e = entity || {}, license = _e.license, type = _e.type, capital = _e.capital, activities = _e.activities, legal_name = _e.legal_name;
565
+ var _g = entity || {}, license = _g.license, type = _g.type, capital = _g.capital, activities = _g.activities, legal_name = _g.legal_name;
537
566
  var legalName = legal_name;
538
567
  var licenseNumber = license === null || license === void 0 ? void 0 : license.number;
539
- var unifiedNumber = (_a = license === null || license === void 0 ? void 0 : license.additional_info) === null || _a === void 0 ? void 0 : _a.unified_number;
568
+ var unifiedNumber = (_b = license === null || license === void 0 ? void 0 : license.additional_info) === null || _b === void 0 ? void 0 : _b.unified_number;
540
569
  var licenseType = (license === null || license === void 0 ? void 0 : license.type) === 'freelance' ? BusinessType.FL : BusinessType.CR;
541
570
  var entityType = type || (entityTypes === null || entityTypes === void 0 ? void 0 : entityTypes[0]);
542
- var _f = capital || {}, paid = _f.paid, shares = _f.shares;
543
- var entityIssueDate = (_b = entity === null || entity === void 0 ? void 0 : entity.license) === null || _b === void 0 ? void 0 : _b.issuing_date;
544
- var entityExpiredDate = (_c = entity === null || entity === void 0 ? void 0 : entity.license) === null || _c === void 0 ? void 0 : _c.expiry_date;
571
+ var _h = capital || {}, paid = _h.paid, shares = _h.shares;
572
+ var entityIssueDate = (_c = entity === null || entity === void 0 ? void 0 : entity.license) === null || _c === void 0 ? void 0 : _c.issuing_date;
573
+ var entityExpiredDate = (_d = entity === null || entity === void 0 ? void 0 : entity.license) === null || _d === void 0 ? void 0 : _d.expiry_date;
545
574
  var issuingDate = void 0, expiryDate = undefined;
546
575
  if (entityIssueDate) {
547
576
  var date = new Date(entityIssueDate);
@@ -601,22 +630,28 @@ export var entitySlice = createSlice({
601
630
  state.error = null;
602
631
  })
603
632
  .addCase(verifyEntityLeadOTP.fulfilled, function (state, action) {
604
- var _a, _b, _c;
633
+ var _a, _b, _c, _d;
605
634
  state.loading = false;
606
635
  state.error = null;
607
- var _d = action.payload, data = _d.data, entity = _d.entityData, entityTypes = _d.entityTypes, formData = _d.formData;
636
+ var _e = action.payload, data = _e.data, boardResponse = _e.boardResponse, formData = _e.formData, individualData = _e.individualData;
637
+ var description = (((_a = data === null || data === void 0 ? void 0 : data.errors) === null || _a === void 0 ? void 0 : _a[0]) || {}).description;
638
+ if (description) {
639
+ state.error = description;
640
+ return;
641
+ }
608
642
  state.data.otpData = formData;
609
643
  state.data.otpData.responseBody = data;
610
- state.data.verify.responseBody = __assign(__assign(__assign({}, data), state.data.verify.responseBody), { entity: entity, entityTypes: entityTypes });
611
- var _e = entity || {}, license = _e.license, type = _e.type, capital = _e.capital, activities = _e.activities, legal_name = _e.legal_name;
644
+ state.data.verify.responseBody = __assign(__assign(__assign({}, state.data.verify.responseBody), boardResponse), { individualData: individualData });
645
+ var _f = boardResponse || {}, entity = _f.entity, entityTypes = _f.entityTypes;
646
+ var _g = entity || {}, license = _g.license, type = _g.type, capital = _g.capital, activities = _g.activities, legal_name = _g.legal_name;
612
647
  var legalName = legal_name;
613
648
  var licenseNumber = license === null || license === void 0 ? void 0 : license.number;
614
- var unifiedNumber = (_a = license === null || license === void 0 ? void 0 : license.additional_info) === null || _a === void 0 ? void 0 : _a.unified_number;
649
+ var unifiedNumber = (_b = license === null || license === void 0 ? void 0 : license.additional_info) === null || _b === void 0 ? void 0 : _b.unified_number;
615
650
  var licenseType = (license === null || license === void 0 ? void 0 : license.type) === 'freelance' ? BusinessType.FL : BusinessType.CR;
616
651
  var entityType = type || (entityTypes === null || entityTypes === void 0 ? void 0 : entityTypes[0]);
617
- var _f = capital || {}, paid = _f.paid, shares = _f.shares;
618
- var entityIssueDate = (_b = entity === null || entity === void 0 ? void 0 : entity.license) === null || _b === void 0 ? void 0 : _b.issuing_date;
619
- var entityExpiredDate = (_c = entity === null || entity === void 0 ? void 0 : entity.license) === null || _c === void 0 ? void 0 : _c.expiry_date;
652
+ var _h = capital || {}, paid = _h.paid, shares = _h.shares;
653
+ var entityIssueDate = (_c = entity === null || entity === void 0 ? void 0 : entity.license) === null || _c === void 0 ? void 0 : _c.issuing_date;
654
+ var entityExpiredDate = (_d = entity === null || entity === void 0 ? void 0 : entity.license) === null || _d === void 0 ? void 0 : _d.expiry_date;
620
655
  var issuingDate, expiryDate = undefined;
621
656
  if (entityIssueDate) {
622
657
  var date = new Date(entityIssueDate);
@@ -661,12 +696,12 @@ export var entitySlice = createSlice({
661
696
  state.loading = false;
662
697
  state.error = null;
663
698
  var _a = action.payload, data = _a.data, formData = _a.formData;
664
- var _b = data || {}, entity = _b.entity, activityList = _b.activityList, rest = __rest(_b, ["entity", "activityList"]);
699
+ var _b = data || {}, activityList = _b.activityList, rest = __rest(_b, ["activityList"]);
665
700
  state.data.entityNameData = __assign(__assign({}, formData), { certificateId: undefined });
666
701
  state.data.entityNameData.responseBody = __assign(__assign({}, state.data.entityNameData.responseBody), { rest: rest });
667
- state.data.verify.responseBody = __assign(__assign({}, state.data.verify.responseBody), { entity: entity, activityList: activityList });
668
- if (entity === null || entity === void 0 ? void 0 : entity.activities)
669
- state.data.entityCapitalData = __assign(__assign({}, state.data.entityCapitalData), { activities: entity === null || entity === void 0 ? void 0 : entity.activities });
702
+ state.data.verify.responseBody = __assign(__assign({}, state.data.verify.responseBody), { entity: data === null || data === void 0 ? void 0 : data.entity, activityList: activityList });
703
+ if (rest === null || rest === void 0 ? void 0 : rest.activities)
704
+ state.data.entityCapitalData = __assign(__assign({}, state.data.entityCapitalData), { activities: rest === null || rest === void 0 ? void 0 : rest.activities });
670
705
  })
671
706
  .addCase(updateEntityName.rejected, function (state, action) {
672
707
  state.loading = false;
@@ -694,7 +729,7 @@ export var entitySlice = createSlice({
694
729
  .addCase(retrieveBoardDetails.fulfilled, function (state, action) {
695
730
  state.error = null;
696
731
  state.loading = false;
697
- var data = action.payload || {};
732
+ var data = (action.payload || {}).data;
698
733
  state.data.verify.responseBody = __assign(__assign({}, state.data.verify.responseBody), data);
699
734
  })
700
735
  .addCase(retrieveBoardDetails.rejected, function (state, action) {
@@ -708,7 +743,7 @@ export var entitySlice = createSlice({
708
743
  .addCase(retrieveBoardStatus.fulfilled, function (state, action) {
709
744
  state.error = null;
710
745
  state.loading = false;
711
- var flows = (action.payload || {}).flows;
746
+ var flows = action.payload.flows;
712
747
  state.data.verify.responseBody = __assign(__assign({}, state.data.verify.responseBody), { flows: flows });
713
748
  })
714
749
  .addCase(retrieveBoardStatus.rejected, function (state, action) {
@@ -719,8 +754,18 @@ export var entitySlice = createSlice({
719
754
  var _a;
720
755
  state.loading = false;
721
756
  state.error = null;
722
- var _b = action.payload || {}, flows = _b.flows, data = _b.data;
723
- state.data.verify.responseBody = __assign(__assign({}, state.data.verify.responseBody), { flows: flows, recipient: (_a = data === null || data === void 0 ? void 0 : data.notification) === null || _a === void 0 ? void 0 : _a.recipient });
757
+ var response = (action.payload || {}).response;
758
+ var description = (((_a = response === null || response === void 0 ? void 0 : response.errors) === null || _a === void 0 ? void 0 : _a[0]) || {}).description;
759
+ if (description) {
760
+ state.error = description;
761
+ return;
762
+ }
763
+ var flows = response.flows;
764
+ var _b = state.data.verify.responseBody || {}, individuals = _b.individuals, individualData = _b.individualData;
765
+ var data_state = (((individualData === null || individualData === void 0 ? void 0 : individualData.is_authorized) ? individuals : individualData) || {}).data_state;
766
+ state.data.verify.responseBody = __assign(__assign(__assign(__assign({}, state.data.verify.responseBody), { flows: flows }), (individualData && { user: individualData })), (data_state && {
767
+ individuals: __assign(__assign({}, individuals), { data_state: data_state })
768
+ }));
724
769
  })
725
770
  .addCase(updateBoardSuccess.pending, function (state) {
726
771
  state.loading = true;