@os1-platform/dispatch-mobile 2.1.21 → 2.1.23

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 (614) hide show
  1. package/README.md +122 -11
  2. package/lib/commonjs/analytics/firebase/FirebaseLogging.js +1 -1
  3. package/lib/commonjs/analytics/firebase/FirebaseLogging.js.map +1 -1
  4. package/lib/commonjs/analytics/sentry/SentryAnalyticsSingleton.js +5 -5
  5. package/lib/commonjs/analytics/sentry/SentryAnalyticsSingleton.js.map +1 -1
  6. package/lib/commonjs/analytics/sentry/SentryAnalyticsUtils.js +9 -10
  7. package/lib/commonjs/analytics/sentry/SentryAnalyticsUtils.js.map +1 -1
  8. package/lib/commonjs/components/dispatch/DispatchExecNavigator.js +16 -6
  9. package/lib/commonjs/components/dispatch/DispatchExecNavigator.js.map +1 -1
  10. package/lib/commonjs/components/executiontasks/ExecutionTasksIndex.js +8 -1
  11. package/lib/commonjs/components/executiontasks/ExecutionTasksIndex.js.map +1 -1
  12. package/lib/commonjs/components/executiontasks/cancellation/CancelET.js +8 -10
  13. package/lib/commonjs/components/executiontasks/cancellation/CancelET.js.map +1 -1
  14. package/lib/commonjs/components/executiontasks/captureInput/CaptureText.js +2 -2
  15. package/lib/commonjs/components/executiontasks/captureInput/CaptureText.js.map +1 -1
  16. package/lib/commonjs/components/executiontasks/collectPayment/CollectPayment.js +40 -0
  17. package/lib/commonjs/components/executiontasks/collectPayment/CollectPayment.js.map +1 -0
  18. package/lib/commonjs/components/executiontasks/collectPayment/CollectPaymentSchema.js +35 -0
  19. package/lib/commonjs/components/executiontasks/collectPayment/CollectPaymentSchema.js.map +1 -0
  20. package/lib/commonjs/components/executiontasks/collectPayment/PaymentStyles.js +102 -0
  21. package/lib/commonjs/components/executiontasks/collectPayment/PaymentStyles.js.map +1 -0
  22. package/lib/commonjs/components/executiontasks/collectPayment/PaymentUtils.js +151 -0
  23. package/lib/commonjs/components/executiontasks/collectPayment/PaymentUtils.js.map +1 -0
  24. package/lib/commonjs/components/executiontasks/collectPayment/components/CompletePayment.js +188 -0
  25. package/lib/commonjs/components/executiontasks/collectPayment/components/CompletePayment.js.map +1 -0
  26. package/lib/commonjs/components/executiontasks/collectPayment/components/CustomContactsModal.js +2 -0
  27. package/lib/commonjs/components/executiontasks/collectPayment/components/CustomContactsModal.js.map +1 -0
  28. package/lib/commonjs/components/executiontasks/collectPayment/components/InitPayment.js +442 -0
  29. package/lib/commonjs/components/executiontasks/collectPayment/components/InitPayment.js.map +1 -0
  30. package/lib/commonjs/components/executiontasks/collectPayment/components/PaymentContactDetails.js +538 -0
  31. package/lib/commonjs/components/executiontasks/collectPayment/components/PaymentContactDetails.js.map +1 -0
  32. package/lib/commonjs/components/executiontasks/collectPayment/components/ProcessPayment.js +887 -0
  33. package/lib/commonjs/components/executiontasks/collectPayment/components/ProcessPayment.js.map +1 -0
  34. package/lib/commonjs/components/executiontasks/deliver/DeliverET.js +14 -20
  35. package/lib/commonjs/components/executiontasks/deliver/DeliverET.js.map +1 -1
  36. package/lib/commonjs/components/executiontasks/deliver/SLDeliverET.js +24 -27
  37. package/lib/commonjs/components/executiontasks/deliver/SLDeliverET.js.map +1 -1
  38. package/lib/commonjs/components/executiontasks/display/DisplayModalET.js +1 -1
  39. package/lib/commonjs/components/executiontasks/display/DisplayModalET.js.map +1 -1
  40. package/lib/commonjs/components/executiontasks/doodle/SignatureET.js +2 -3
  41. package/lib/commonjs/components/executiontasks/doodle/SignatureET.js.map +1 -1
  42. package/lib/commonjs/components/executiontasks/dropCash/DropCashET.js +1 -1
  43. package/lib/commonjs/components/executiontasks/dropCash/DropCashET.js.map +1 -1
  44. package/lib/commonjs/components/executiontasks/dropCash/SLDropCash.js +9 -3
  45. package/lib/commonjs/components/executiontasks/dropCash/SLDropCash.js.map +1 -1
  46. package/lib/commonjs/components/executiontasks/forms/FormGenerator.js +2 -2
  47. package/lib/commonjs/components/executiontasks/forms/FormGenerator.js.map +1 -1
  48. package/lib/commonjs/components/executiontasks/forms/widgets/DateTimeWidget.js +13 -14
  49. package/lib/commonjs/components/executiontasks/forms/widgets/DateTimeWidget.js.map +1 -1
  50. package/lib/commonjs/components/executiontasks/forms/widgets/DropdownWidget.js +2 -2
  51. package/lib/commonjs/components/executiontasks/forms/widgets/DropdownWidget.js.map +1 -1
  52. package/lib/commonjs/components/executiontasks/forms/widgets/QRBarcodeScannerWidget.js +11 -12
  53. package/lib/commonjs/components/executiontasks/forms/widgets/QRBarcodeScannerWidget.js.map +1 -1
  54. package/lib/commonjs/components/executiontasks/forms/widgets/TimeRangeSelector.js +3 -3
  55. package/lib/commonjs/components/executiontasks/forms/widgets/TimeRangeSelector.js.map +1 -1
  56. package/lib/commonjs/components/executiontasks/httpRequest/HttpEtUtils.js +1 -1
  57. package/lib/commonjs/components/executiontasks/httpRequest/HttpEtUtils.js.map +1 -1
  58. package/lib/commonjs/components/executiontasks/httpRequest/HttpRequestET.js +2 -2
  59. package/lib/commonjs/components/executiontasks/httpRequest/HttpRequestET.js.map +1 -1
  60. package/lib/commonjs/components/executiontasks/imageCapture/CaptureUtils.js +2 -2
  61. package/lib/commonjs/components/executiontasks/imageCapture/CaptureUtils.js.map +1 -1
  62. package/lib/commonjs/components/executiontasks/imageCapture/ImageCapture.js +11 -13
  63. package/lib/commonjs/components/executiontasks/imageCapture/ImageCapture.js.map +1 -1
  64. package/lib/commonjs/components/executiontasks/payments/PaymentUtils.js +11 -2
  65. package/lib/commonjs/components/executiontasks/payments/PaymentUtils.js.map +1 -1
  66. package/lib/commonjs/components/executiontasks/payments/completePayment/CompletePaymentET.js +2 -2
  67. package/lib/commonjs/components/executiontasks/payments/completePayment/CompletePaymentET.js.map +1 -1
  68. package/lib/commonjs/components/executiontasks/payments/init/InitPaymentET.js +5 -6
  69. package/lib/commonjs/components/executiontasks/payments/init/InitPaymentET.js.map +1 -1
  70. package/lib/commonjs/components/executiontasks/payments/processPayment/ProcessPaymentET.js +2 -2
  71. package/lib/commonjs/components/executiontasks/payments/processPayment/ProcessPaymentET.js.map +1 -1
  72. package/lib/commonjs/components/executiontasks/pickup/PickupET.js +14 -20
  73. package/lib/commonjs/components/executiontasks/pickup/PickupET.js.map +1 -1
  74. package/lib/commonjs/components/executiontasks/pickup/SLPickupET.js +18 -24
  75. package/lib/commonjs/components/executiontasks/pickup/SLPickupET.js.map +1 -1
  76. package/lib/commonjs/components/executiontasks/scan/ScanET.js +4 -6
  77. package/lib/commonjs/components/executiontasks/scan/ScanET.js.map +1 -1
  78. package/lib/commonjs/components/executiontasks/scan/constants.js.map +1 -1
  79. package/lib/commonjs/components/executiontasks/scan/interfaces.js.map +1 -1
  80. package/lib/commonjs/components/executiontasks/scan/modalConstant.js.map +1 -1
  81. package/lib/commonjs/components/executiontasks/scan/sub_components/CScanner.js +4 -5
  82. package/lib/commonjs/components/executiontasks/scan/sub_components/CScanner.js.map +1 -1
  83. package/lib/commonjs/components/executiontasks/scan/sub_components/DropDownUtils.js +1 -2
  84. package/lib/commonjs/components/executiontasks/scan/sub_components/DropDownUtils.js.map +1 -1
  85. package/lib/commonjs/components/executiontasks/scan/sub_components/ERDropDown.js +2 -4
  86. package/lib/commonjs/components/executiontasks/scan/sub_components/ERDropDown.js.map +1 -1
  87. package/lib/commonjs/components/executiontasks/scan/sub_components/SummaryPage.js +3 -6
  88. package/lib/commonjs/components/executiontasks/scan/sub_components/SummaryPage.js.map +1 -1
  89. package/lib/commonjs/components/executiontasks/scan/utils.js +14 -8
  90. package/lib/commonjs/components/executiontasks/scan/utils.js.map +1 -1
  91. package/lib/commonjs/components/executiontasks/validateOTP/ValidateOTPET.js +2 -2
  92. package/lib/commonjs/components/executiontasks/validateOTP/ValidateOTPET.js.map +1 -1
  93. package/lib/commonjs/components/executiontasks/validateOTP/constants.js.map +1 -1
  94. package/lib/commonjs/components/executiontasks/validateOTP/sub-components/OTPInput.js +2 -2
  95. package/lib/commonjs/components/executiontasks/validateOTP/sub-components/OTPInput.js.map +1 -1
  96. package/lib/commonjs/components/executiontasks/validateOTP/utils.js +1 -1
  97. package/lib/commonjs/components/executiontasks/validateOTP/utils.js.map +1 -1
  98. package/lib/commonjs/components/executiontasks/verifyLocation/GeofenceUtils.js +2 -2
  99. package/lib/commonjs/components/executiontasks/verifyLocation/GeofenceUtils.js.map +1 -1
  100. package/lib/commonjs/components/executiontasks/verifyLocation/VerifyLocationET.js +2 -2
  101. package/lib/commonjs/components/executiontasks/verifyLocation/VerifyLocationET.js.map +1 -1
  102. package/lib/commonjs/components/executiontasks/verifyOtp/VerifyOtpET.js +2 -2
  103. package/lib/commonjs/components/executiontasks/verifyOtp/VerifyOtpET.js.map +1 -1
  104. package/lib/commonjs/components/widgets/AlertDisplay.js +1 -1
  105. package/lib/commonjs/components/widgets/AlertDisplay.js.map +1 -1
  106. package/lib/commonjs/components/widgets/CancelOrderDialog.js +2 -2
  107. package/lib/commonjs/components/widgets/CancelOrderDialog.js.map +1 -1
  108. package/lib/commonjs/components/widgets/Card.js +1 -2
  109. package/lib/commonjs/components/widgets/Card.js.map +1 -1
  110. package/lib/commonjs/components/widgets/GoBackModal.js +1 -1
  111. package/lib/commonjs/components/widgets/GoBackModal.js.map +1 -1
  112. package/lib/commonjs/components/widgets/IconButton.js +20 -23
  113. package/lib/commonjs/components/widgets/IconButton.js.map +1 -1
  114. package/lib/commonjs/components/widgets/ModalWidget.js +3 -1
  115. package/lib/commonjs/components/widgets/ModalWidget.js.map +1 -1
  116. package/lib/commonjs/components/widgets/ProgressDialog.js +3 -3
  117. package/lib/commonjs/components/widgets/ProgressDialog.js.map +1 -1
  118. package/lib/commonjs/components/widgets/SearchBar.js +1 -1
  119. package/lib/commonjs/components/widgets/SearchBar.js.map +1 -1
  120. package/lib/commonjs/components/widgets/SnackBarCustom.js +22 -21
  121. package/lib/commonjs/components/widgets/SnackBarCustom.js.map +1 -1
  122. package/lib/commonjs/components/widgets/SplitTextInput.js +10 -11
  123. package/lib/commonjs/components/widgets/SplitTextInput.js.map +1 -1
  124. package/lib/commonjs/components/widgets/TabsComponent.js +1 -1
  125. package/lib/commonjs/components/widgets/TabsComponent.js.map +1 -1
  126. package/lib/commonjs/components/widgets/Timer.js +40 -0
  127. package/lib/commonjs/components/widgets/Timer.js.map +1 -0
  128. package/lib/commonjs/constants/apiConstants.js +4 -1
  129. package/lib/commonjs/constants/apiConstants.js.map +1 -1
  130. package/lib/commonjs/constants/constants.js +4 -1
  131. package/lib/commonjs/constants/constants.js.map +1 -1
  132. package/lib/commonjs/errors/BaseError.js +3 -3
  133. package/lib/commonjs/events/EventDispatcher.js +5 -1
  134. package/lib/commonjs/events/EventDispatcher.js.map +1 -1
  135. package/lib/commonjs/events/constants.js +2 -1
  136. package/lib/commonjs/events/constants.js.map +1 -1
  137. package/lib/commonjs/events/index.js +1 -1
  138. package/lib/commonjs/events/index.js.map +1 -1
  139. package/lib/commonjs/events/interface.js.map +1 -1
  140. package/lib/commonjs/icons/CircleMark.js +27 -0
  141. package/lib/commonjs/icons/CircleMark.js.map +1 -0
  142. package/lib/commonjs/icons/FailedIcon.js +69 -0
  143. package/lib/commonjs/icons/FailedIcon.js.map +1 -0
  144. package/lib/commonjs/icons/FailureCloseIcon.js +42 -0
  145. package/lib/commonjs/icons/FailureCloseIcon.js.map +1 -0
  146. package/lib/commonjs/icons/ScanIcon.js +1 -1
  147. package/lib/commonjs/icons/ScanIcon.js.map +1 -1
  148. package/lib/commonjs/icons/SuccessCompleteIcon.js +42 -0
  149. package/lib/commonjs/icons/SuccessCompleteIcon.js.map +1 -0
  150. package/lib/commonjs/icons/file.js +1 -1
  151. package/lib/commonjs/icons/file.js.map +1 -1
  152. package/lib/commonjs/index.js +2 -2
  153. package/lib/commonjs/index.js.map +1 -1
  154. package/lib/commonjs/locale/i18n.js +1 -1
  155. package/lib/commonjs/locale/i18n.js.map +1 -1
  156. package/lib/commonjs/locale/util.js +1 -1
  157. package/lib/commonjs/locale/util.js.map +1 -1
  158. package/lib/commonjs/manager/dispatch/DispatchStateContainer.js +11 -9
  159. package/lib/commonjs/manager/dispatch/DispatchStateContainer.js.map +1 -1
  160. package/lib/commonjs/manager/dispatchCodes/EventCodeContainer.js +6 -6
  161. package/lib/commonjs/manager/dispatchCodes/EventCodeContainer.js.map +1 -1
  162. package/lib/commonjs/manager/dispatchCodes/EventCodeRepo.js +6 -6
  163. package/lib/commonjs/manager/dispatchCodes/EventCodeRepo.js.map +1 -1
  164. package/lib/commonjs/manager/dispatchCodes/ReasonCodeContainer.js +7 -7
  165. package/lib/commonjs/manager/dispatchCodes/ReasonCodeContainer.js.map +1 -1
  166. package/lib/commonjs/manager/dispatchCodes/ReasonCodeRepo.js +6 -6
  167. package/lib/commonjs/manager/dispatchCodes/ReasonCodeRepo.js.map +1 -1
  168. package/lib/commonjs/manager/location/LocationManager.js +6 -6
  169. package/lib/commonjs/manager/location/LocationManager.js.map +1 -1
  170. package/lib/commonjs/manager/sdk/DispatchSDKManager.js +8 -8
  171. package/lib/commonjs/manager/sdk/DispatchSDKManager.js.map +1 -1
  172. package/lib/commonjs/manager/sdk/DispatchSdkCache.js +6 -6
  173. package/lib/commonjs/manager/sdk/DispatchSdkCache.js.map +1 -1
  174. package/lib/commonjs/manager/sdk/callbacksHandler.js +4 -4
  175. package/lib/commonjs/manager/sdk/callbacksHandler.js.map +1 -1
  176. package/lib/commonjs/manager/syncmanager/AppSyncManager.js +7 -7
  177. package/lib/commonjs/manager/syncmanager/AppSyncManager.js.map +1 -1
  178. package/lib/commonjs/manager/syncmanager/database.js +2 -2
  179. package/lib/commonjs/manager/syncmanager/database.js.map +1 -1
  180. package/lib/commonjs/manager/syncmanager/document/DocumentHttpClient.js +2 -2
  181. package/lib/commonjs/manager/syncmanager/document/DocumentHttpClient.js.map +1 -1
  182. package/lib/commonjs/manager/syncmanager/document/DocumentManager.js +6 -6
  183. package/lib/commonjs/manager/syncmanager/document/DocumentManager.js.map +1 -1
  184. package/lib/commonjs/manager/syncmanager/document/DocumentSyncManager.js +8 -16
  185. package/lib/commonjs/manager/syncmanager/document/DocumentSyncManager.js.map +1 -1
  186. package/lib/commonjs/manager/syncmanager/events/ETEventsManager.js +6 -7
  187. package/lib/commonjs/manager/syncmanager/events/ETEventsManager.js.map +1 -1
  188. package/lib/commonjs/manager/syncmanager/events/EventsSyncManager.js +7 -8
  189. package/lib/commonjs/manager/syncmanager/events/EventsSyncManager.js.map +1 -1
  190. package/lib/commonjs/manager/syncmanager/events/SyncHttpClient.js +5 -9
  191. package/lib/commonjs/manager/syncmanager/events/SyncHttpClient.js.map +1 -1
  192. package/lib/commonjs/models/DispatchModels.js.map +1 -1
  193. package/lib/commonjs/models/execTasks/ETConfig.js +3 -0
  194. package/lib/commonjs/models/execTasks/ETConfig.js.map +1 -1
  195. package/lib/commonjs/models/sdk.js.map +1 -1
  196. package/lib/commonjs/native/signature/SignatureCapture.js +5 -5
  197. package/lib/commonjs/native/signature/SignatureCapture.js.map +1 -1
  198. package/lib/commonjs/network/GraphQLClient.js +15 -19
  199. package/lib/commonjs/network/GraphQLClient.js.map +1 -1
  200. package/lib/commonjs/network/NetworkClient.js +30 -3
  201. package/lib/commonjs/network/NetworkClient.js.map +1 -1
  202. package/lib/commonjs/network/NetworkUtils.js +2 -5
  203. package/lib/commonjs/network/NetworkUtils.js.map +1 -1
  204. package/lib/commonjs/network/Queries.js.map +1 -1
  205. package/lib/commonjs/network/client.js +5 -5
  206. package/lib/commonjs/network/client.js.map +1 -1
  207. package/lib/commonjs/resources/Login.js +4 -4
  208. package/lib/commonjs/resources/Login.js.map +1 -1
  209. package/lib/commonjs/resources/network.js +4 -4
  210. package/lib/commonjs/resources/network.js.map +1 -1
  211. package/lib/commonjs/styles/executionTasks/CommonStyles.js +13 -3
  212. package/lib/commonjs/styles/executionTasks/CommonStyles.js.map +1 -1
  213. package/lib/commonjs/ui/screens/CancellationScreen.js +7 -8
  214. package/lib/commonjs/ui/screens/CancellationScreen.js.map +1 -1
  215. package/lib/commonjs/ui/screens/CaptureInputScreen.js +8 -9
  216. package/lib/commonjs/ui/screens/CaptureInputScreen.js.map +1 -1
  217. package/lib/commonjs/ui/screens/CollectPaymentScreen.js +251 -0
  218. package/lib/commonjs/ui/screens/CollectPaymentScreen.js.map +1 -0
  219. package/lib/commonjs/ui/screens/CompleteObjectiveScreen.js +7 -8
  220. package/lib/commonjs/ui/screens/CompleteObjectiveScreen.js.map +1 -1
  221. package/lib/commonjs/ui/screens/DeliverScreen.js +8 -9
  222. package/lib/commonjs/ui/screens/DeliverScreen.js.map +1 -1
  223. package/lib/commonjs/ui/screens/DisplayScreen.js +8 -9
  224. package/lib/commonjs/ui/screens/DisplayScreen.js.map +1 -1
  225. package/lib/commonjs/ui/screens/DoodleScreen.js +8 -9
  226. package/lib/commonjs/ui/screens/DoodleScreen.js.map +1 -1
  227. package/lib/commonjs/ui/screens/DropCashScreen.js +43 -11
  228. package/lib/commonjs/ui/screens/DropCashScreen.js.map +1 -1
  229. package/lib/commonjs/ui/screens/ETScreensIndex.js +8 -1
  230. package/lib/commonjs/ui/screens/ETScreensIndex.js.map +1 -1
  231. package/lib/commonjs/ui/screens/FormsScreen.js +8 -9
  232. package/lib/commonjs/ui/screens/FormsScreen.js.map +1 -1
  233. package/lib/commonjs/ui/screens/GeofenceScreen.js +8 -9
  234. package/lib/commonjs/ui/screens/GeofenceScreen.js.map +1 -1
  235. package/lib/commonjs/ui/screens/HttpRequestScreen.js +7 -8
  236. package/lib/commonjs/ui/screens/HttpRequestScreen.js.map +1 -1
  237. package/lib/commonjs/ui/screens/ImageCaptureScreen.js +8 -9
  238. package/lib/commonjs/ui/screens/ImageCaptureScreen.js.map +1 -1
  239. package/lib/commonjs/ui/screens/PaymentScreen.js +9 -9
  240. package/lib/commonjs/ui/screens/PaymentScreen.js.map +1 -1
  241. package/lib/commonjs/ui/screens/PickupScreen.js +8 -9
  242. package/lib/commonjs/ui/screens/PickupScreen.js.map +1 -1
  243. package/lib/commonjs/ui/screens/ScanScreen.js +8 -10
  244. package/lib/commonjs/ui/screens/ScanScreen.js.map +1 -1
  245. package/lib/commonjs/ui/screens/StartWorkFlowScreen.js +13 -9
  246. package/lib/commonjs/ui/screens/StartWorkFlowScreen.js.map +1 -1
  247. package/lib/commonjs/ui/screens/ValidateOTPScreen.js +8 -9
  248. package/lib/commonjs/ui/screens/ValidateOTPScreen.js.map +1 -1
  249. package/lib/commonjs/ui/screens/WithBaseDispatchScreen.js +3 -3
  250. package/lib/commonjs/ui/screens/WithBaseDispatchScreen.js.map +1 -1
  251. package/lib/commonjs/ui/uiConfig/RouteParams.js +2 -1
  252. package/lib/commonjs/ui/uiConfig/RouteParams.js.map +1 -1
  253. package/lib/commonjs/utils/ApiUtils.js +3 -1
  254. package/lib/commonjs/utils/ApiUtils.js.map +1 -1
  255. package/lib/commonjs/utils/ExecTaskUtils.js +35 -5
  256. package/lib/commonjs/utils/ExecTaskUtils.js.map +1 -1
  257. package/lib/commonjs/utils/Logger.js +6 -7
  258. package/lib/commonjs/utils/Logger.js.map +1 -1
  259. package/lib/commonjs/utils/NetworkUtil.js +4 -4
  260. package/lib/commonjs/utils/NetworkUtil.js.map +1 -1
  261. package/lib/commonjs/utils/SdkUtils.js +2 -2
  262. package/lib/commonjs/utils/SdkUtils.js.map +1 -1
  263. package/lib/commonjs/utils/SyncManagerUtils.js +3 -3
  264. package/lib/commonjs/utils/SyncManagerUtils.js.map +1 -1
  265. package/lib/commonjs/utils/context/paymentContext.js +9 -0
  266. package/lib/commonjs/utils/context/paymentContext.js.map +1 -0
  267. package/lib/commonjs/utils/fcm/FCM.js +22 -4
  268. package/lib/commonjs/utils/fcm/FCM.js.map +1 -1
  269. package/lib/commonjs/utils/fcm/FcmUtils.js +12 -2
  270. package/lib/commonjs/utils/fcm/FcmUtils.js.map +1 -1
  271. package/lib/commonjs/utils/helper.js +6 -6
  272. package/lib/commonjs/utils/helper.js.map +1 -1
  273. package/lib/commonjs/utils/hooks/useModal.js +4 -3
  274. package/lib/commonjs/utils/hooks/useModal.js.map +1 -1
  275. package/lib/commonjs/utils/hooks/useTimer.js.map +1 -1
  276. package/lib/commonjs/utils/loginHelper.js +1 -1
  277. package/lib/commonjs/utils/loginHelper.js.map +1 -1
  278. package/lib/commonjs/utils/storage.js +11 -17
  279. package/lib/commonjs/utils/storage.js.map +1 -1
  280. package/lib/commonjs/utils/utils.js +2 -3
  281. package/lib/commonjs/utils/utils.js.map +1 -1
  282. package/lib/module/analytics/sentry/SentryAnalyticsSingleton.js +5 -5
  283. package/lib/module/analytics/sentry/SentryAnalyticsSingleton.js.map +1 -1
  284. package/lib/module/analytics/sentry/SentryAnalyticsUtils.js +7 -8
  285. package/lib/module/analytics/sentry/SentryAnalyticsUtils.js.map +1 -1
  286. package/lib/module/components/dispatch/DispatchExecNavigator.js +14 -4
  287. package/lib/module/components/dispatch/DispatchExecNavigator.js.map +1 -1
  288. package/lib/module/components/executiontasks/ExecutionTasksIndex.js +2 -1
  289. package/lib/module/components/executiontasks/ExecutionTasksIndex.js.map +1 -1
  290. package/lib/module/components/executiontasks/cancellation/CancelET.js +6 -8
  291. package/lib/module/components/executiontasks/cancellation/CancelET.js.map +1 -1
  292. package/lib/module/components/executiontasks/collectPayment/CollectPayment.js +32 -0
  293. package/lib/module/components/executiontasks/collectPayment/CollectPayment.js.map +1 -0
  294. package/lib/module/components/executiontasks/collectPayment/CollectPaymentSchema.js +29 -0
  295. package/lib/module/components/executiontasks/collectPayment/CollectPaymentSchema.js.map +1 -0
  296. package/lib/module/components/executiontasks/collectPayment/PaymentStyles.js +96 -0
  297. package/lib/module/components/executiontasks/collectPayment/PaymentStyles.js.map +1 -0
  298. package/lib/module/components/executiontasks/collectPayment/PaymentUtils.js +132 -0
  299. package/lib/module/components/executiontasks/collectPayment/PaymentUtils.js.map +1 -0
  300. package/lib/module/components/executiontasks/collectPayment/components/CompletePayment.js +179 -0
  301. package/lib/module/components/executiontasks/collectPayment/components/CompletePayment.js.map +1 -0
  302. package/lib/module/components/executiontasks/collectPayment/components/CustomContactsModal.js +2 -0
  303. package/lib/module/components/executiontasks/collectPayment/components/CustomContactsModal.js.map +1 -0
  304. package/lib/module/components/executiontasks/collectPayment/components/InitPayment.js +433 -0
  305. package/lib/module/components/executiontasks/collectPayment/components/InitPayment.js.map +1 -0
  306. package/lib/module/components/executiontasks/collectPayment/components/PaymentContactDetails.js +531 -0
  307. package/lib/module/components/executiontasks/collectPayment/components/PaymentContactDetails.js.map +1 -0
  308. package/lib/module/components/executiontasks/collectPayment/components/ProcessPayment.js +880 -0
  309. package/lib/module/components/executiontasks/collectPayment/components/ProcessPayment.js.map +1 -0
  310. package/lib/module/components/executiontasks/deliver/DeliverET.js +13 -19
  311. package/lib/module/components/executiontasks/deliver/DeliverET.js.map +1 -1
  312. package/lib/module/components/executiontasks/deliver/SLDeliverET.js +21 -24
  313. package/lib/module/components/executiontasks/deliver/SLDeliverET.js.map +1 -1
  314. package/lib/module/components/executiontasks/doodle/SignatureET.js +0 -1
  315. package/lib/module/components/executiontasks/doodle/SignatureET.js.map +1 -1
  316. package/lib/module/components/executiontasks/dropCash/DropCashET.js.map +1 -1
  317. package/lib/module/components/executiontasks/dropCash/SLDropCash.js +6 -1
  318. package/lib/module/components/executiontasks/dropCash/SLDropCash.js.map +1 -1
  319. package/lib/module/components/executiontasks/forms/widgets/DateTimeWidget.js +11 -12
  320. package/lib/module/components/executiontasks/forms/widgets/DateTimeWidget.js.map +1 -1
  321. package/lib/module/components/executiontasks/forms/widgets/QRBarcodeScannerWidget.js +9 -10
  322. package/lib/module/components/executiontasks/forms/widgets/QRBarcodeScannerWidget.js.map +1 -1
  323. package/lib/module/components/executiontasks/forms/widgets/TimeRangeSelector.js +1 -1
  324. package/lib/module/components/executiontasks/imageCapture/CaptureUtils.js.map +1 -1
  325. package/lib/module/components/executiontasks/imageCapture/ImageCapture.js +9 -11
  326. package/lib/module/components/executiontasks/imageCapture/ImageCapture.js.map +1 -1
  327. package/lib/module/components/executiontasks/payments/PaymentUtils.js +11 -2
  328. package/lib/module/components/executiontasks/payments/PaymentUtils.js.map +1 -1
  329. package/lib/module/components/executiontasks/payments/init/InitPaymentET.js +3 -4
  330. package/lib/module/components/executiontasks/payments/init/InitPaymentET.js.map +1 -1
  331. package/lib/module/components/executiontasks/payments/processPayment/ProcessPaymentET.js.map +1 -1
  332. package/lib/module/components/executiontasks/pickup/PickupET.js +13 -19
  333. package/lib/module/components/executiontasks/pickup/PickupET.js.map +1 -1
  334. package/lib/module/components/executiontasks/pickup/SLPickupET.js +15 -21
  335. package/lib/module/components/executiontasks/pickup/SLPickupET.js.map +1 -1
  336. package/lib/module/components/executiontasks/scan/ScanET.js +2 -4
  337. package/lib/module/components/executiontasks/scan/ScanET.js.map +1 -1
  338. package/lib/module/components/executiontasks/scan/constants.js.map +1 -1
  339. package/lib/module/components/executiontasks/scan/interfaces.js.map +1 -1
  340. package/lib/module/components/executiontasks/scan/modalConstant.js.map +1 -1
  341. package/lib/module/components/executiontasks/scan/sub_components/CScanner.js +3 -4
  342. package/lib/module/components/executiontasks/scan/sub_components/CScanner.js.map +1 -1
  343. package/lib/module/components/executiontasks/scan/sub_components/DropDownUtils.js +0 -1
  344. package/lib/module/components/executiontasks/scan/sub_components/DropDownUtils.js.map +1 -1
  345. package/lib/module/components/executiontasks/scan/sub_components/ERDropDown.js +0 -2
  346. package/lib/module/components/executiontasks/scan/sub_components/ERDropDown.js.map +1 -1
  347. package/lib/module/components/executiontasks/scan/sub_components/SummaryPage.js +1 -4
  348. package/lib/module/components/executiontasks/scan/sub_components/SummaryPage.js.map +1 -1
  349. package/lib/module/components/executiontasks/scan/utils.js +11 -6
  350. package/lib/module/components/executiontasks/scan/utils.js.map +1 -1
  351. package/lib/module/components/executiontasks/validateOTP/ValidateOTPET.js.map +1 -1
  352. package/lib/module/components/executiontasks/validateOTP/constants.js.map +1 -1
  353. package/lib/module/components/widgets/Card.js +0 -1
  354. package/lib/module/components/widgets/Card.js.map +1 -1
  355. package/lib/module/components/widgets/IconButton.js +19 -22
  356. package/lib/module/components/widgets/IconButton.js.map +1 -1
  357. package/lib/module/components/widgets/ModalWidget.js +1 -0
  358. package/lib/module/components/widgets/ModalWidget.js.map +1 -1
  359. package/lib/module/components/widgets/ProgressDialog.js +2 -2
  360. package/lib/module/components/widgets/ProgressDialog.js.map +1 -1
  361. package/lib/module/components/widgets/SnackBarCustom.js +21 -20
  362. package/lib/module/components/widgets/SnackBarCustom.js.map +1 -1
  363. package/lib/module/components/widgets/SplitTextInput.js +9 -10
  364. package/lib/module/components/widgets/SplitTextInput.js.map +1 -1
  365. package/lib/module/components/widgets/Timer.js +32 -0
  366. package/lib/module/components/widgets/Timer.js.map +1 -0
  367. package/lib/module/constants/apiConstants.js +4 -1
  368. package/lib/module/constants/apiConstants.js.map +1 -1
  369. package/lib/module/constants/constants.js +3 -0
  370. package/lib/module/constants/constants.js.map +1 -1
  371. package/lib/module/errors/BaseError.js +3 -3
  372. package/lib/module/events/EventDispatcher.js +3 -0
  373. package/lib/module/events/EventDispatcher.js.map +1 -1
  374. package/lib/module/events/constants.js +2 -1
  375. package/lib/module/events/constants.js.map +1 -1
  376. package/lib/module/events/interface.js.map +1 -1
  377. package/lib/module/icons/CircleMark.js +20 -0
  378. package/lib/module/icons/CircleMark.js.map +1 -0
  379. package/lib/module/icons/FailedIcon.js +62 -0
  380. package/lib/module/icons/FailedIcon.js.map +1 -0
  381. package/lib/module/icons/FailureCloseIcon.js +35 -0
  382. package/lib/module/icons/FailureCloseIcon.js.map +1 -0
  383. package/lib/module/icons/SuccessCompleteIcon.js +35 -0
  384. package/lib/module/icons/SuccessCompleteIcon.js.map +1 -0
  385. package/lib/module/manager/dispatch/DispatchStateContainer.js +10 -8
  386. package/lib/module/manager/dispatch/DispatchStateContainer.js.map +1 -1
  387. package/lib/module/manager/dispatchCodes/EventCodeContainer.js +5 -5
  388. package/lib/module/manager/dispatchCodes/EventCodeContainer.js.map +1 -1
  389. package/lib/module/manager/dispatchCodes/EventCodeRepo.js +5 -5
  390. package/lib/module/manager/dispatchCodes/EventCodeRepo.js.map +1 -1
  391. package/lib/module/manager/dispatchCodes/ReasonCodeContainer.js +5 -5
  392. package/lib/module/manager/dispatchCodes/ReasonCodeContainer.js.map +1 -1
  393. package/lib/module/manager/dispatchCodes/ReasonCodeRepo.js +5 -5
  394. package/lib/module/manager/dispatchCodes/ReasonCodeRepo.js.map +1 -1
  395. package/lib/module/manager/location/LocationManager.js +5 -5
  396. package/lib/module/manager/location/LocationManager.js.map +1 -1
  397. package/lib/module/manager/sdk/DispatchSDKManager.js +6 -6
  398. package/lib/module/manager/sdk/DispatchSDKManager.js.map +1 -1
  399. package/lib/module/manager/sdk/DispatchSdkCache.js +5 -5
  400. package/lib/module/manager/sdk/DispatchSdkCache.js.map +1 -1
  401. package/lib/module/manager/sdk/callbacksHandler.js +3 -3
  402. package/lib/module/manager/syncmanager/AppSyncManager.js +5 -5
  403. package/lib/module/manager/syncmanager/AppSyncManager.js.map +1 -1
  404. package/lib/module/manager/syncmanager/DBConfig.js +1 -0
  405. package/lib/module/manager/syncmanager/DBConfig.js.map +1 -1
  406. package/lib/module/manager/syncmanager/document/DocumentHttpClient.js.map +1 -1
  407. package/lib/module/manager/syncmanager/document/DocumentManager.js +5 -5
  408. package/lib/module/manager/syncmanager/document/DocumentManager.js.map +1 -1
  409. package/lib/module/manager/syncmanager/document/DocumentSyncManager.js +6 -14
  410. package/lib/module/manager/syncmanager/document/DocumentSyncManager.js.map +1 -1
  411. package/lib/module/manager/syncmanager/events/ETEventsManager.js +5 -6
  412. package/lib/module/manager/syncmanager/events/ETEventsManager.js.map +1 -1
  413. package/lib/module/manager/syncmanager/events/EventsSyncManager.js +5 -6
  414. package/lib/module/manager/syncmanager/events/EventsSyncManager.js.map +1 -1
  415. package/lib/module/manager/syncmanager/events/SyncHttpClient.js +3 -7
  416. package/lib/module/manager/syncmanager/events/SyncHttpClient.js.map +1 -1
  417. package/lib/module/models/DispatchModels.js.map +1 -1
  418. package/lib/module/models/execTasks/ETConfig.js +3 -0
  419. package/lib/module/models/execTasks/ETConfig.js.map +1 -1
  420. package/lib/module/models/sdk.js.map +1 -1
  421. package/lib/module/native/signature/SignatureCapture.js +4 -4
  422. package/lib/module/network/GraphQLClient.js +14 -18
  423. package/lib/module/network/GraphQLClient.js.map +1 -1
  424. package/lib/module/network/NetworkClient.js +29 -2
  425. package/lib/module/network/NetworkClient.js.map +1 -1
  426. package/lib/module/network/NetworkUtils.js +1 -4
  427. package/lib/module/network/NetworkUtils.js.map +1 -1
  428. package/lib/module/network/Queries.js.map +1 -1
  429. package/lib/module/network/client.js +4 -4
  430. package/lib/module/network/client.js.map +1 -1
  431. package/lib/module/resources/Login.js +3 -3
  432. package/lib/module/resources/network.js +3 -3
  433. package/lib/module/styles/executionTasks/CommonStyles.js +12 -2
  434. package/lib/module/styles/executionTasks/CommonStyles.js.map +1 -1
  435. package/lib/module/ui/screens/CancellationScreen.js +5 -6
  436. package/lib/module/ui/screens/CancellationScreen.js.map +1 -1
  437. package/lib/module/ui/screens/CaptureInputScreen.js +6 -7
  438. package/lib/module/ui/screens/CaptureInputScreen.js.map +1 -1
  439. package/lib/module/ui/screens/CollectPaymentScreen.js +244 -0
  440. package/lib/module/ui/screens/CollectPaymentScreen.js.map +1 -0
  441. package/lib/module/ui/screens/CompleteObjectiveScreen.js +5 -6
  442. package/lib/module/ui/screens/CompleteObjectiveScreen.js.map +1 -1
  443. package/lib/module/ui/screens/DeliverScreen.js +6 -7
  444. package/lib/module/ui/screens/DeliverScreen.js.map +1 -1
  445. package/lib/module/ui/screens/DisplayScreen.js +6 -7
  446. package/lib/module/ui/screens/DisplayScreen.js.map +1 -1
  447. package/lib/module/ui/screens/DoodleScreen.js +6 -7
  448. package/lib/module/ui/screens/DoodleScreen.js.map +1 -1
  449. package/lib/module/ui/screens/DropCashScreen.js +41 -10
  450. package/lib/module/ui/screens/DropCashScreen.js.map +1 -1
  451. package/lib/module/ui/screens/ETScreensIndex.js +2 -1
  452. package/lib/module/ui/screens/ETScreensIndex.js.map +1 -1
  453. package/lib/module/ui/screens/FormsScreen.js +6 -7
  454. package/lib/module/ui/screens/FormsScreen.js.map +1 -1
  455. package/lib/module/ui/screens/GeofenceScreen.js +6 -7
  456. package/lib/module/ui/screens/GeofenceScreen.js.map +1 -1
  457. package/lib/module/ui/screens/HttpRequestScreen.js +6 -7
  458. package/lib/module/ui/screens/HttpRequestScreen.js.map +1 -1
  459. package/lib/module/ui/screens/ImageCaptureScreen.js +6 -7
  460. package/lib/module/ui/screens/ImageCaptureScreen.js.map +1 -1
  461. package/lib/module/ui/screens/PaymentScreen.js +7 -7
  462. package/lib/module/ui/screens/PaymentScreen.js.map +1 -1
  463. package/lib/module/ui/screens/PickupScreen.js +6 -7
  464. package/lib/module/ui/screens/PickupScreen.js.map +1 -1
  465. package/lib/module/ui/screens/ScanScreen.js +6 -8
  466. package/lib/module/ui/screens/ScanScreen.js.map +1 -1
  467. package/lib/module/ui/screens/StartWorkFlowScreen.js +11 -7
  468. package/lib/module/ui/screens/StartWorkFlowScreen.js.map +1 -1
  469. package/lib/module/ui/screens/ValidateOTPScreen.js +6 -7
  470. package/lib/module/ui/screens/ValidateOTPScreen.js.map +1 -1
  471. package/lib/module/ui/screens/WithBaseDispatchScreen.js +1 -1
  472. package/lib/module/ui/uiConfig/RouteParams.js +2 -1
  473. package/lib/module/ui/uiConfig/RouteParams.js.map +1 -1
  474. package/lib/module/utils/ApiUtils.js +2 -0
  475. package/lib/module/utils/ApiUtils.js.map +1 -1
  476. package/lib/module/utils/ExecTaskUtils.js +31 -4
  477. package/lib/module/utils/ExecTaskUtils.js.map +1 -1
  478. package/lib/module/utils/Logger.js +5 -6
  479. package/lib/module/utils/Logger.js.map +1 -1
  480. package/lib/module/utils/NetworkUtil.js +3 -3
  481. package/lib/module/utils/NetworkUtil.js.map +1 -1
  482. package/lib/module/utils/SdkUtils.js.map +1 -1
  483. package/lib/module/utils/SyncManagerUtils.js +1 -1
  484. package/lib/module/utils/SyncManagerUtils.js.map +1 -1
  485. package/lib/module/utils/context/paymentContext.js +3 -0
  486. package/lib/module/utils/context/paymentContext.js.map +1 -0
  487. package/lib/module/utils/fcm/FCM.js +20 -2
  488. package/lib/module/utils/fcm/FCM.js.map +1 -1
  489. package/lib/module/utils/fcm/FcmUtils.js +10 -0
  490. package/lib/module/utils/fcm/FcmUtils.js.map +1 -1
  491. package/lib/module/utils/helper.js +5 -5
  492. package/lib/module/utils/helper.js.map +1 -1
  493. package/lib/module/utils/hooks/useModal.js +2 -1
  494. package/lib/module/utils/hooks/useModal.js.map +1 -1
  495. package/lib/module/utils/hooks/useTimer.js.map +1 -1
  496. package/lib/module/utils/storage.js +9 -15
  497. package/lib/module/utils/storage.js.map +1 -1
  498. package/lib/module/utils/utils.js +1 -2
  499. package/lib/module/utils/utils.js.map +1 -1
  500. package/lib/typescript/components/executiontasks/ExecutionTasksIndex.d.ts +4 -2
  501. package/lib/typescript/components/executiontasks/collectPayment/CollectPayment.d.ts +4 -0
  502. package/lib/typescript/components/executiontasks/collectPayment/CollectPaymentSchema.d.ts +155 -0
  503. package/lib/typescript/components/executiontasks/collectPayment/PaymentStyles.d.ts +92 -0
  504. package/lib/typescript/components/executiontasks/collectPayment/PaymentUtils.d.ts +16 -0
  505. package/lib/typescript/components/executiontasks/collectPayment/components/CompletePayment.d.ts +4 -0
  506. package/lib/typescript/components/executiontasks/collectPayment/components/InitPayment.d.ts +4 -0
  507. package/lib/typescript/components/executiontasks/collectPayment/components/PaymentContactDetails.d.ts +4 -0
  508. package/lib/typescript/components/executiontasks/collectPayment/components/ProcessPayment.d.ts +4 -0
  509. package/lib/typescript/components/executiontasks/scan/interfaces.d.ts +1 -1
  510. package/lib/typescript/components/executiontasks/scan/utils.d.ts +1 -0
  511. package/lib/typescript/components/widgets/ProgressDialog.d.ts +3 -0
  512. package/lib/typescript/components/widgets/SnackBarCustom.d.ts +3 -2
  513. package/lib/typescript/components/widgets/Timer.d.ts +7 -0
  514. package/lib/typescript/constants/apiConstants.d.ts +3 -0
  515. package/lib/typescript/constants/constants.d.ts +3 -0
  516. package/lib/typescript/events/EventDispatcher.d.ts +1 -0
  517. package/lib/typescript/events/constants.d.ts +1 -0
  518. package/lib/typescript/events/interface.d.ts +1 -1
  519. package/lib/typescript/icons/CircleMark.d.ts +3 -0
  520. package/lib/typescript/icons/FailedIcon.d.ts +4 -0
  521. package/lib/typescript/icons/FailureCloseIcon.d.ts +4 -0
  522. package/lib/typescript/icons/SuccessCompleteIcon.d.ts +4 -0
  523. package/lib/typescript/models/DispatchModels.d.ts +11 -0
  524. package/lib/typescript/models/execTasks/ETConfig.d.ts +6 -3
  525. package/lib/typescript/models/sdk.d.ts +12 -0
  526. package/lib/typescript/network/NetworkClient.d.ts +3 -1
  527. package/lib/typescript/styles/executionTasks/CommonStyles.d.ts +10 -1
  528. package/lib/typescript/ui/screens/CollectPaymentScreen.d.ts +3 -0
  529. package/lib/typescript/ui/screens/ETScreensIndex.d.ts +2 -1
  530. package/lib/typescript/ui/uiConfig/RouteParams.d.ts +1 -0
  531. package/lib/typescript/utils/ExecTaskUtils.d.ts +2 -0
  532. package/lib/typescript/utils/context/paymentContext.d.ts +7 -0
  533. package/package.json +6 -5
  534. package/src/components/dispatch/DispatchExecNavigator.tsx +14 -0
  535. package/src/components/executiontasks/ExecutionTasksIndex.ts +8 -0
  536. package/src/components/executiontasks/collectPayment/CollectPayment.tsx +60 -0
  537. package/src/components/executiontasks/collectPayment/CollectPaymentSchema.ts +182 -0
  538. package/src/components/executiontasks/collectPayment/PaymentStyles.ts +102 -0
  539. package/src/components/executiontasks/collectPayment/PaymentUtils.ts +200 -0
  540. package/src/components/executiontasks/collectPayment/components/CompletePayment.tsx +273 -0
  541. package/src/components/executiontasks/collectPayment/components/InitPayment.tsx +658 -0
  542. package/src/components/executiontasks/collectPayment/components/PaymentContactDetails.tsx +790 -0
  543. package/src/components/executiontasks/collectPayment/components/ProcessPayment.tsx +1352 -0
  544. package/src/components/executiontasks/deliver/SLDeliverET.tsx +132 -60
  545. package/src/components/executiontasks/dropCash/SLDropCash.tsx +35 -12
  546. package/src/components/executiontasks/payments/PaymentUtils.ts +10 -2
  547. package/src/components/executiontasks/pickup/SLPickupET.tsx +6 -3
  548. package/src/components/executiontasks/scan/ScanET.tsx +1 -1
  549. package/src/components/executiontasks/scan/interfaces.ts +1 -1
  550. package/src/components/executiontasks/scan/utils.ts +16 -8
  551. package/src/components/widgets/ModalWidget.tsx +26 -8
  552. package/src/components/widgets/ProgressDialog.tsx +23 -3
  553. package/src/components/widgets/SnackBarCustom.tsx +8 -1
  554. package/src/components/widgets/SplitTextInput.tsx +1 -1
  555. package/src/components/widgets/Timer.tsx +53 -0
  556. package/src/constants/apiConstants.ts +3 -0
  557. package/src/constants/constants.ts +3 -0
  558. package/src/events/EventDispatcher.ts +4 -0
  559. package/src/events/constants.ts +1 -0
  560. package/src/events/interface.ts +7 -1
  561. package/src/icons/CircleMark.tsx +18 -0
  562. package/src/icons/FailedIcon.tsx +80 -0
  563. package/src/icons/FailureCloseIcon.tsx +35 -0
  564. package/src/icons/SuccessCompleteIcon.tsx +35 -0
  565. package/src/manager/dispatch/DispatchStateContainer.tsx +6 -4
  566. package/src/manager/sdk/DispatchSDKManager.ts +1 -0
  567. package/src/models/DispatchModels.ts +12 -0
  568. package/src/models/execTasks/ETConfig.ts +3 -0
  569. package/src/models/sdk.ts +13 -0
  570. package/src/network/NetworkClient.ts +34 -1
  571. package/src/network/client.ts +1 -0
  572. package/src/styles/executionTasks/CommonStyles.ts +32 -8
  573. package/src/ui/screens/CollectPaymentScreen.tsx +315 -0
  574. package/src/ui/screens/DropCashScreen.tsx +49 -2
  575. package/src/ui/screens/ETScreensIndex.ts +2 -0
  576. package/src/ui/screens/PaymentScreen.tsx +1 -0
  577. package/src/ui/screens/StartWorkFlowScreen.tsx +15 -0
  578. package/src/ui/uiConfig/RouteParams.ts +8 -1
  579. package/src/utils/ApiUtils.ts +1 -0
  580. package/src/utils/ExecTaskUtils.ts +44 -3
  581. package/src/utils/SyncManagerUtils.ts +1 -0
  582. package/src/utils/context/paymentContext.ts +8 -0
  583. package/src/utils/fcm/FCM.ts +30 -0
  584. package/src/utils/fcm/FcmUtils.ts +53 -29
  585. package/android/.gradle/6.8/fileChanges/last-build.bin +0 -0
  586. package/android/.gradle/6.8/fileHashes/fileHashes.lock +0 -0
  587. package/android/.gradle/7.5/checksums/checksums.lock +0 -0
  588. package/android/.gradle/7.5/checksums/md5-checksums.bin +0 -0
  589. package/android/.gradle/7.5/checksums/sha1-checksums.bin +0 -0
  590. package/android/.gradle/7.5/dependencies-accessors/dependencies-accessors.lock +0 -0
  591. package/android/.gradle/7.5/executionHistory/executionHistory.lock +0 -0
  592. package/android/.gradle/7.5/fileChanges/last-build.bin +0 -0
  593. package/android/.gradle/7.5/fileHashes/fileHashes.bin +0 -0
  594. package/android/.gradle/7.5/fileHashes/fileHashes.lock +0 -0
  595. package/android/.gradle/7.5/gc.properties +0 -0
  596. package/android/.gradle/buildOutputCleanup/buildOutputCleanup.lock +0 -0
  597. package/android/.gradle/buildOutputCleanup/cache.properties +0 -2
  598. package/android/.gradle/buildOutputCleanup/outputFiles.bin +0 -0
  599. package/android/.gradle/checksums/checksums.lock +0 -0
  600. package/android/.gradle/config.properties +0 -2
  601. package/android/.gradle/configuration-cache/gc.properties +0 -0
  602. package/android/.gradle/vcs-1/gc.properties +0 -0
  603. package/android/.idea/compiler.xml +0 -6
  604. package/android/.idea/gradle.xml +0 -18
  605. package/android/.idea/kotlinc.xml +0 -6
  606. package/android/.idea/migrations.xml +0 -10
  607. package/android/.idea/misc.xml +0 -10
  608. package/android/.idea/other.xml +0 -263
  609. package/android/.idea/vcs.xml +0 -6
  610. package/lib/commonjs/icons/circleMark.svg +0 -3
  611. package/lib/module/icons/circleMark.svg +0 -3
  612. package/src/icons/circleMark.svg +0 -3
  613. /package/{android/.gradle/6.8/gc.properties → lib/typescript/components/executiontasks/collectPayment/components/CustomContactsModal.d.ts} +0 -0
  614. /package/{android/.gradle/7.5/dependencies-accessors/gc.properties → src/components/executiontasks/collectPayment/components/CustomContactsModal.tsx} +0 -0
@@ -0,0 +1,790 @@
1
+ import React, { useEffect, useState, useLayoutEffect, useContext } from 'react';
2
+ import { BackHandler, FlatList, Platform, StyleSheet, Text, View } from 'react-native';
3
+ import {
4
+ // PAYMENT_SHARED_PREF_KEY,
5
+ getPaymentDataMO,
6
+ getPaymentType,
7
+ removeSharedPrefPaymentData,
8
+ } from '../PaymentUtils';
9
+ import {
10
+ getBaseETResponse,
11
+ maskContact,
12
+ } from '../../../../utils/ExecTaskUtils';
13
+ import {
14
+ EntityCode,
15
+ ExecutionTaskID,
16
+ } from '../../../../models/execTasks/ETConfig';
17
+ import { getEventCodeByET } from '../../../../manager/dispatchCodes/EventCodeContainer';
18
+ import {
19
+ CommonStyles,
20
+ Fonts,
21
+ } from '../../../../styles/executionTasks/CommonStyles';
22
+ import { Button, Provider, RadioButton, TextInput } from 'react-native-paper';
23
+ import Icon from 'react-native-vector-icons/MaterialIcons';
24
+ import {
25
+ EMAIL_REGEX,
26
+ PAYMENT_NOTIFICATION,
27
+ } from '../../../../constants/constants';
28
+ import EventListener from '../../../../events';
29
+ import {
30
+ CollectPaymentInput,
31
+ PAYMENT_SCREEN,
32
+ PaymentStatusResponse,
33
+ ProcessPaymentInput,
34
+ STATUS,
35
+ SUB_STATUS,
36
+ TRANSACTION_TYPE,
37
+ notificationPaymentStatus,
38
+ sharedPrefPaymentDataInterface,
39
+ } from '../CollectPaymentSchema';
40
+ import { useFocusEffect } from '@react-navigation/native';
41
+ import { RouteParams } from '../../../../ui/uiConfig/RouteParams';
42
+ import { DispatchExecutor as dispatchExecutor } from '@os1-platform/platform-coreos-execution-engine-sdk';
43
+ import callbackHandler from '../../../../manager/sdk/callbacksHandler';
44
+ import ModalWidget from '../../../../components/widgets/ModalWidget';
45
+ import Storage from '../../../../utils/storage';
46
+ import { PaymentContext } from '../../../../utils/context/paymentContext';
47
+ import { ENDPOINTS } from '../../../../constants/apiConstants';
48
+ import { PROGRESS_GROUP } from '../../../../utils/Constants';
49
+ import Logger, { LOG_TYPE } from '../../../../utils/Logger';
50
+
51
+ interface manualContacts {
52
+ title: string;
53
+ type: 'EMAIL' | 'PHONE';
54
+ }
55
+
56
+ let storage = Storage.getInstance();
57
+
58
+ const PaymentContactDetails = (
59
+ props: CollectPaymentInput & ProcessPaymentInput
60
+ ) => {
61
+ const paymentConfigContext = useContext(PaymentContext);
62
+ const [selectedContact, setSelectedContact] = useState<string>('');
63
+ const [displayContactModal, setDisplayContactModal] =
64
+ useState<boolean>(false);
65
+ const [manualContactDetails, setManualContactDetails] =
66
+ useState<manualContacts>();
67
+ const [displayError, setErrorDisplay] = useState(false);
68
+ const [manualContact, setManualContact] = useState('');
69
+ const [contactList, setContactList] = useState<string[]>([]);
70
+
71
+ const paymentRefId =
72
+ props.route.params[RouteParams.ROOT_META_DATA].paymentConfig?.paymentRefId;
73
+
74
+ useEffect(() => {
75
+ (async () => {
76
+ if (props.route.params[RouteParams.ROOT_META_DATA]) {
77
+ //Call objectiveDetails fn and fetch sds ids
78
+ let progressGroup = null;
79
+ try {
80
+ progressGroup = await Storage.getInstance().getSharedItem(
81
+ PROGRESS_GROUP,
82
+ false
83
+ );
84
+ } catch (error: any) {
85
+ Logger.getInstance().logEvent('~ getPaymentStatus triggered ', JSON.stringify(error?.response?.data || error), LOG_TYPE.SDK_ERROR);
86
+ progressGroup = null;
87
+ }
88
+ const { contact } = await dispatchExecutor.getObjectiveTaskDetails(
89
+ props.mergedObjectiveId[0],
90
+ progressGroup,
91
+ props.route.params[RouteParams.ROOT_META_DATA].statusFilter
92
+ );
93
+
94
+ // run callback to get corresponding phone numbers
95
+ const phoneNumbers = await callbackHandler.getPhoneNumbers(contact);
96
+
97
+ if (phoneNumbers && phoneNumbers.value?.length) {
98
+ setContactList(phoneNumbers.value);
99
+ }
100
+ }
101
+ })();
102
+
103
+ EventListener.on(
104
+ PAYMENT_NOTIFICATION,
105
+ async (data: notificationPaymentStatus) => {
106
+ console.log("PaymentCollectDetail:",JSON.stringify(data));
107
+
108
+ let sharedPrefPaymentData: sharedPrefPaymentDataInterface | null = null;
109
+ if (
110
+ data &&
111
+ (data.status === STATUS.SUCCESS || data.status === STATUS.FAILED)
112
+ ) {
113
+ sharedPrefPaymentData = await getPaymentDataMO(
114
+ props.mergedObjectiveId,
115
+ data.refId,
116
+ storage
117
+ );
118
+ }
119
+ if (sharedPrefPaymentData && data && data.status === STATUS.SUCCESS) {
120
+ props.next({
121
+ paymentMode:
122
+ sharedPrefPaymentData?.paymentMode || props.paymentMode,
123
+ collectedAmount: {
124
+ value:
125
+ sharedPrefPaymentData?.amount.value || props.expectedAmount,
126
+ currencyCode:
127
+ sharedPrefPaymentData?.amount.currencyCode ||
128
+ paymentConfigContext?.sdkConfig?.etConfig?.currencyCode ||
129
+ '',
130
+ },
131
+ refId: data.refId,
132
+ screen: PAYMENT_SCREEN.COMPLETE,
133
+ sourceScreen: PAYMENT_SCREEN.CONTACTS,
134
+ ...(await getBaseETResponse(
135
+ EntityCode.COLLECT_PAYMENT_ET,
136
+ true,
137
+ getEventCodeByET(
138
+ ExecutionTaskID.COLLECT_PAYMENT_ET,
139
+ true,
140
+ props.applicableReasons?.success
141
+ ),
142
+ '',
143
+ props.mergedObjectiveId,
144
+ ExecutionTaskID.COLLECT_PAYMENT_ET
145
+ )),
146
+ });
147
+ } else if (
148
+ sharedPrefPaymentData &&
149
+ data &&
150
+ data.status === STATUS.FAILED
151
+ ) {
152
+ /* const _sharedPrefPaymentData = JSON.parse(
153
+ JSON.stringify(sharedPrefPaymentData)
154
+ ); */
155
+ /* await storage.removeSharedItems(
156
+ props.mergedObjectiveId.map((_id) => PAYMENT_SHARED_PREF_KEY + _id)
157
+ ); */
158
+ await removeSharedPrefPaymentData(data.refId, storage);
159
+ }
160
+ }
161
+ );
162
+
163
+ return () => EventListener.remove(PAYMENT_NOTIFICATION);
164
+ }, []);
165
+
166
+ const handleOnCancelClick = async () => {
167
+ props.onSubmitET({
168
+ paymentMode: props.paymentMode,
169
+ refId: paymentRefId,
170
+ ...(await getBaseETResponse(
171
+ EntityCode.COLLECT_PAYMENT_ET,
172
+ false,
173
+ getEventCodeByET(
174
+ ExecutionTaskID.COLLECT_PAYMENT_ET,
175
+ false,
176
+ props.applicableReasons?.failure
177
+ ),
178
+ '',
179
+ props.mergedObjectiveId,
180
+ ExecutionTaskID.COLLECT_PAYMENT_ET
181
+ )),
182
+ collectedAmount: {
183
+ value: props.expectedAmount,
184
+ currencyCode:
185
+ paymentConfigContext?.sdkConfig?.etConfig?.currencyCode || '',
186
+ },
187
+ });
188
+ };
189
+
190
+ const getPaymentStatus = async (isProceed: boolean | null) => {
191
+ try {
192
+ let sharedPrefPaymentData: sharedPrefPaymentDataInterface | null = null;
193
+ const paymentResp =
194
+ await paymentConfigContext?.networkInstance.requestGet(
195
+ ENDPOINTS.PAYMENT_STATUS + paymentRefId,
196
+ {
197
+ requestId: 'payment:' + paymentRefId,
198
+ },
199
+ {
200
+ appAbbr: paymentConfigContext.sdkConfig.etConfig.appAbbr,
201
+ latest: true,
202
+ }
203
+ );
204
+ // const paymentResp = {
205
+ // data: {
206
+ // data: {
207
+ // meta: { totalCount: 1 },
208
+ // transactions: [
209
+ // {
210
+ // refId: paymentRefId,
211
+ // status: STATUS.FAILED,
212
+ // subStatus: SUB_STATUS.completed,
213
+ // money: {
214
+ // amount: 1000,
215
+ // currency: 'INR',
216
+ // },
217
+ // txnId: '123',
218
+ // txnType: TRANSACTION_TYPE.LINK,
219
+ // appAbbr: 'testApp31',
220
+ // },
221
+ // ],
222
+ // },
223
+ // },
224
+ // };
225
+ const _ps: PaymentStatusResponse = paymentResp?.data;
226
+ console.log('Contact getPaymentStatus _ps: ', JSON.stringify(_ps));
227
+
228
+ sharedPrefPaymentData = await getPaymentDataMO(
229
+ props.mergedObjectiveId,
230
+ paymentRefId,
231
+ storage
232
+ );
233
+ if (
234
+ _ps?.data.transactions?.length &&
235
+ (sharedPrefPaymentData ||
236
+ getPaymentType(_ps?.data.transactions[0].txnType)) &&
237
+ _ps.data.meta?.totalCount &&
238
+ _ps?.data.transactions[0].status === STATUS.SUCCESS
239
+ ) {
240
+ props.next({
241
+ paymentMode:
242
+ sharedPrefPaymentData?.paymentMode ||
243
+ getPaymentType(_ps?.data.transactions[0].txnType) ||
244
+ props.paymentMode,
245
+ collectedAmount: {
246
+ value:
247
+ sharedPrefPaymentData?.amount.value ||
248
+ _ps?.data.transactions[0].money.amount ||
249
+ props.expectedAmount,
250
+ currencyCode:
251
+ sharedPrefPaymentData?.amount.currencyCode ||
252
+ _ps?.data.transactions[0].money.currency ||
253
+ paymentConfigContext?.sdkConfig?.etConfig?.currencyCode ||
254
+ '',
255
+ },
256
+ refId: _ps.data.transactions[0].refId,
257
+ screen: PAYMENT_SCREEN.COMPLETE,
258
+ sourceScreen: PAYMENT_SCREEN.CONTACTS,
259
+ ...(await getBaseETResponse(
260
+ EntityCode.COLLECT_PAYMENT_ET,
261
+ true,
262
+ getEventCodeByET(
263
+ ExecutionTaskID.COLLECT_PAYMENT_ET,
264
+ true,
265
+ props.applicableReasons?.success
266
+ ),
267
+ '',
268
+ props.mergedObjectiveId,
269
+ ExecutionTaskID.COLLECT_PAYMENT_ET
270
+ )),
271
+ });
272
+ return;
273
+ } else if (
274
+ sharedPrefPaymentData &&
275
+ _ps.data.meta?.totalCount &&
276
+ _ps?.data.transactions?.length &&
277
+ _ps?.data.transactions[0].status === STATUS.FAILED
278
+ ) {
279
+ await removeSharedPrefPaymentData(paymentRefId, storage);
280
+ }
281
+
282
+ if (isProceed) await sendPaymentLink(selectedContact);
283
+ else if (isProceed === false) await handleOnCancelClick();
284
+ } catch (err: any) {
285
+ Logger.getInstance().logEvent('~ getPaymentStatus triggered ', JSON.stringify(err?.response?.data || err), LOG_TYPE.SDK_ERROR);
286
+ console.error('STATUS: ', err?.response?.data || err.message);
287
+ }
288
+ };
289
+
290
+ // Handle back-button click
291
+ useFocusEffect(
292
+ React.useCallback(() => {
293
+ const onBackPress = () => {
294
+ (async () =>
295
+ props.next({
296
+ paymentMode: props.paymentMode,
297
+ refId: paymentRefId,
298
+ ...(await getBaseETResponse(
299
+ EntityCode.COLLECT_PAYMENT_ET,
300
+ true,
301
+ getEventCodeByET(
302
+ ExecutionTaskID.COLLECT_PAYMENT_ET,
303
+ true,
304
+ props.applicableReasons?.success
305
+ ),
306
+ '',
307
+ props.mergedObjectiveId,
308
+ ExecutionTaskID.COLLECT_PAYMENT_ET
309
+ )),
310
+ screen: PAYMENT_SCREEN.INIT,
311
+ sourceScreen: PAYMENT_SCREEN.CONTACTS,
312
+ collectedAmount: {
313
+ value: props.expectedAmount,
314
+ currencyCode:
315
+ paymentConfigContext?.sdkConfig?.etConfig?.currencyCode || '',
316
+ },
317
+ }))();
318
+ return true;
319
+ };
320
+ BackHandler.addEventListener('hardwareBackPress', onBackPress);
321
+ return () =>
322
+ BackHandler.removeEventListener('hardwareBackPress', onBackPress);
323
+ }, [])
324
+ );
325
+
326
+ useLayoutEffect(() => {
327
+ props.navigation.setOptions({
328
+ headerShown: true,
329
+ title: 'Payment Link',
330
+ headerLeft: () => {
331
+ return (
332
+ <Icon
333
+ onPress={async () => {
334
+ props.next({
335
+ paymentMode: props.paymentMode,
336
+ refId: paymentRefId,
337
+ ...(await getBaseETResponse(
338
+ EntityCode.COLLECT_PAYMENT_ET,
339
+ true,
340
+ getEventCodeByET(
341
+ ExecutionTaskID.COLLECT_PAYMENT_ET,
342
+ true,
343
+ props.applicableReasons?.success
344
+ ),
345
+ '',
346
+ props.mergedObjectiveId,
347
+ ExecutionTaskID.COLLECT_PAYMENT_ET
348
+ )),
349
+ screen: PAYMENT_SCREEN.INIT,
350
+ sourceScreen: PAYMENT_SCREEN.CONTACTS,
351
+ collectedAmount: {
352
+ value: props.expectedAmount,
353
+ currencyCode:
354
+ paymentConfigContext?.sdkConfig?.etConfig?.currencyCode ||
355
+ '',
356
+ },
357
+ });
358
+ }}
359
+ name="arrow-back"
360
+ color={'black'}
361
+ size={25}
362
+ style={{
363
+ paddingRight: 15,
364
+ paddingTop: 5,
365
+ }}
366
+ />
367
+ );
368
+ },
369
+ });
370
+ }, [props.navigation, props.title]);
371
+
372
+ const renderItem = ({ item }: { item: string }) => {
373
+ return (
374
+ <View style={styles.reasonItemStyle}>
375
+ <RadioButton
376
+ color={'#5B80F7'}
377
+ value={item}
378
+ status={selectedContact === item ? 'checked' : 'unchecked'}
379
+ onPress={() => {
380
+ setSelectedContact(item);
381
+ }}
382
+ />
383
+ <Text
384
+ style={[styles.reasonTextStyle, { fontWeight: 'bold' }]}
385
+ onPress={() => {
386
+ setSelectedContact(item);
387
+ }}
388
+ >
389
+ {maskContact(item)}
390
+ </Text>
391
+ </View>
392
+ );
393
+ };
394
+
395
+ const inputValidation = (data: string, _regex: string) => {
396
+ if (_regex) {
397
+ const regex = new RegExp(_regex);
398
+ return regex.test(data);
399
+ }
400
+ return false;
401
+ };
402
+
403
+ const sendPaymentLink = async (contactDetails: string) => {
404
+ props.next({
405
+ paymentMode: props.paymentMode,
406
+ refId: paymentRefId,
407
+ ...(await getBaseETResponse(
408
+ EntityCode.COLLECT_PAYMENT_ET,
409
+ true,
410
+ getEventCodeByET(
411
+ ExecutionTaskID.COLLECT_PAYMENT_ET,
412
+ true,
413
+ props.applicableReasons?.success
414
+ ),
415
+ '',
416
+ props.mergedObjectiveId,
417
+ ExecutionTaskID.COLLECT_PAYMENT_ET
418
+ )),
419
+ screen: PAYMENT_SCREEN.PROCESS,
420
+ sourceScreen: PAYMENT_SCREEN.CONTACTS,
421
+ collectedAmount: {
422
+ value: props.expectedAmount,
423
+ currencyCode:
424
+ paymentConfigContext?.sdkConfig?.etConfig?.currencyCode || '',
425
+ },
426
+ contactDetails,
427
+ });
428
+ };
429
+
430
+ const onModalSubmit = () => {
431
+ const regex =
432
+ manualContactDetails?.type === 'PHONE'
433
+ ? paymentConfigContext?.sdkConfig?.etConfig?.mobilePhoneRegex || ''
434
+ : EMAIL_REGEX;
435
+
436
+ if (inputValidation(manualContact, regex)) {
437
+ setErrorDisplay(false);
438
+ (async () => {
439
+ const contact =
440
+ manualContactDetails?.type === 'PHONE'
441
+ ? paymentConfigContext?.sdkConfig?.etConfig?.phoneCode +
442
+ manualContact
443
+ : manualContact;
444
+
445
+ await sendPaymentLink(contact);
446
+ })();
447
+ } else {
448
+ setErrorDisplay(true);
449
+ }
450
+ };
451
+
452
+ const renderManualContactsModal = () => {
453
+ return (
454
+ <ModalWidget
455
+ title={{ label: manualContactDetails?.title || '' }}
456
+ contentContainerStyle={{ marginBottom: 120 }}
457
+ showModal={displayContactModal}
458
+ renderChildren={() =>
459
+ manualContactDetails?.type === 'PHONE' ? (
460
+ <View style={{ marginVertical: 10 }}>
461
+ <View>
462
+ <Text style={[styles.inputLabel, { marginBottom: 8 }]}>
463
+ Phone Number
464
+ </Text>
465
+ </View>
466
+ <View
467
+ style={[
468
+ {
469
+ justifyContent: 'flex-start',
470
+ display: 'flex',
471
+ flexDirection: 'row',
472
+ },
473
+ ]}
474
+ >
475
+ {paymentConfigContext?.sdkConfig?.etConfig?.phoneCode ? (
476
+ <TextInput
477
+ style={[
478
+ styles.input,
479
+ { borderTopEndRadius: 0, borderBottomEndRadius: 0 },
480
+ displayError
481
+ ? {
482
+ borderColor: 'red',
483
+ }
484
+ : {},
485
+ ]}
486
+ disabled={true}
487
+ value={
488
+ '(' +
489
+ paymentConfigContext?.sdkConfig?.etConfig?.phoneCode +
490
+ ')'
491
+ }
492
+ />
493
+ ) : null}
494
+ <TextInput
495
+ style={[
496
+ styles.input,
497
+ {
498
+ flexGrow: 1,
499
+ flex: 1,
500
+ },
501
+ paymentConfigContext?.sdkConfig?.etConfig?.phoneCode
502
+ ? {
503
+ borderLeftWidth: 0,
504
+ borderTopStartRadius: 0,
505
+ borderBottomStartRadius: 0,
506
+ }
507
+ : {},
508
+ displayError
509
+ ? {
510
+ borderColor: 'red',
511
+ }
512
+ : {},
513
+ ]}
514
+ autoFocus={true}
515
+ placeholder="Add Phone Number"
516
+ onChangeText={setManualContact}
517
+ activeUnderlineColor="transparent"
518
+ />
519
+ </View>
520
+ {displayError ? (
521
+ <Text style={{ color: 'red' }}>Enter valid phone number.</Text>
522
+ ) : null}
523
+ </View>
524
+ ) : (
525
+ <View style={{ marginVertical: 10 }}>
526
+ <View>
527
+ <Text style={[styles.inputLabel, { marginBottom: 8 }]}>
528
+ Email Address
529
+ </Text>
530
+ </View>
531
+ <View>
532
+ <TextInput
533
+ style={[
534
+ styles.input,
535
+ displayError
536
+ ? {
537
+ borderColor: 'red',
538
+ }
539
+ : {},
540
+ ]}
541
+ autoFocus={true}
542
+ placeholder="Add Email Address"
543
+ onChangeText={setManualContact}
544
+ activeUnderlineColor={'transparent'}
545
+ />
546
+ </View>
547
+ {displayError ? (
548
+ <Text style={{ color: 'red' }}>Enter valid email address.</Text>
549
+ ) : null}
550
+ </View>
551
+ )
552
+ }
553
+ primaryButton={{
554
+ label: 'Send Payment Link',
555
+ onPress: () => {
556
+ onModalSubmit();
557
+ },
558
+ labelStyles: {
559
+ ...CommonStyles.nextButtonLabel,
560
+ },
561
+ styles: {
562
+ ...CommonStyles.nextButton,
563
+ padding: 8,
564
+ borderRadius: 5,
565
+ marginVertical: 10,
566
+ marginTop: 15,
567
+ },
568
+ }}
569
+ secondaryButton={{
570
+ label: 'Cancel',
571
+ onPress: () => {
572
+ setErrorDisplay(false);
573
+ setDisplayContactModal(false);
574
+ },
575
+ labelStyles: {
576
+ ...CommonStyles.cancelButtonLabel,
577
+ },
578
+ styles: {
579
+ ...CommonStyles.cancelButton,
580
+ padding: 8,
581
+ borderRadius: 5,
582
+ },
583
+ }}
584
+ />
585
+ );
586
+ };
587
+
588
+ return (
589
+ <Provider>
590
+ {renderManualContactsModal()}
591
+ <View style={CommonStyles.mainContainer}>
592
+ <Text style={[styles.title, { paddingBottom: 0 }]}>
593
+ Select or add contact details to send the payment link
594
+ </Text>
595
+ {contactList.length ? (
596
+ <View style={{ marginBottom: 16, maxHeight: 500 }}>
597
+ <FlatList
598
+ data={contactList}
599
+ renderItem={renderItem}
600
+ keyExtractor={(item) => item}
601
+ />
602
+ </View>
603
+ ) : null}
604
+ {props.onsiteLinkSharing?.length ? (
605
+ <View
606
+ style={[
607
+ {
608
+ backgroundColor: 'white',
609
+ padding: 16,
610
+ flexDirection: 'row',
611
+ justifyContent: 'space-evenly',
612
+ },
613
+ props.onsiteLinkSharing.includes('Email') &&
614
+ props.onsiteLinkSharing.includes('Phone Number')
615
+ ? {}
616
+ : { justifyContent: 'flex-start', paddingStart: 55 },
617
+ ]}
618
+ >
619
+ {props.onsiteLinkSharing.includes('Email') ? (
620
+ <View>
621
+ <Text
622
+ style={[styles.link]}
623
+ onPress={() => {
624
+ setDisplayContactModal(true);
625
+ setManualContactDetails({
626
+ title: 'Add Email Address',
627
+ type: 'EMAIL',
628
+ });
629
+ }}
630
+ >
631
+ Add Email Address
632
+ </Text>
633
+ </View>
634
+ ) : null}
635
+ {props.onsiteLinkSharing.includes('Email') &&
636
+ props.onsiteLinkSharing.includes('Phone Number') ? (
637
+ <View style={{ borderLeftWidth: 1, borderColor: '#cccccc' }} />
638
+ ) : null}
639
+ {props.onsiteLinkSharing.includes('Phone Number') ? (
640
+ <View>
641
+ <Text
642
+ style={[styles.link]}
643
+ onPress={() => {
644
+ setDisplayContactModal(true);
645
+ setManualContactDetails({
646
+ title: 'Add Phone Number',
647
+ type: 'PHONE',
648
+ });
649
+ }}
650
+ >
651
+ Add Phone Number
652
+ </Text>
653
+ </View>
654
+ ) : null}
655
+ </View>
656
+ ) : null}
657
+ <View style={styles.btnContainer}>
658
+ <View style={styles.buttonParentContainer}>
659
+ <Button
660
+ style={[
661
+ CommonStyles.cancelButton,
662
+ {
663
+ marginEnd: 5,
664
+ flex: 1,
665
+ },
666
+ ]}
667
+ labelStyle={{
668
+ ...CommonStyles.cancelButtonLabel,
669
+ color: '#5B80F7',
670
+ textTransform: 'capitalize',
671
+ }}
672
+ mode={'outlined'}
673
+ onPress={async () => {
674
+ await getPaymentStatus(false);
675
+ }}
676
+ >
677
+ Cancel
678
+ </Button>
679
+ <Button
680
+ style={[
681
+ CommonStyles.nextButton,
682
+ {
683
+ flex: 1,
684
+ marginStart: 5,
685
+ },
686
+ !selectedContact
687
+ ? {
688
+ backgroundColor: '#E0E3EB',
689
+ }
690
+ : {},
691
+ ]}
692
+ labelStyle={[
693
+ CommonStyles.nextButtonLabel,
694
+ { textTransform: 'capitalize' },
695
+ !selectedContact ? { color: '#A3AAC2' } : {},
696
+ ]}
697
+ disabled={!selectedContact}
698
+ mode={'contained'}
699
+ onPress={async () => {
700
+ await getPaymentStatus(true);
701
+ }}
702
+ >
703
+ Send Payment Link
704
+ </Button>
705
+ </View>
706
+ </View>
707
+ </View>
708
+ </Provider>
709
+ );
710
+ };
711
+
712
+ export default PaymentContactDetails;
713
+
714
+ const styles = StyleSheet.create({
715
+ title: {
716
+ fontFamily: Platform.OS === 'android'
717
+ ? Fonts.IBMPlexSans_400Regular
718
+ : 'IBMPlexSans-Regular',
719
+ fontWeight: '400',
720
+ fontSize: 16,
721
+ lineHeight: 24,
722
+ color: '#3D445C',
723
+ margin: 20,
724
+ },
725
+ reasonItemStyle: {
726
+ flexDirection: 'row',
727
+ paddingVertical: 5,
728
+ paddingStart: 20,
729
+ paddingEnd: 20,
730
+ backgroundColor: 'white',
731
+ marginBottom: 5,
732
+ },
733
+ reasonTextStyle: {
734
+ flex: 1,
735
+ flexWrap: 'wrap',
736
+ fontFamily: Platform.OS === 'android'
737
+ ? Fonts.IBMPlexSans_400Regular
738
+ : 'IBMPlexSans-Regular',
739
+ fontStyle: 'normal',
740
+ fontSize: 14,
741
+ lineHeight: 21,
742
+ letterSpacing: 0.25,
743
+ textAlign: 'justify',
744
+ color: '#111111',
745
+ paddingTop: 5,
746
+ },
747
+ link: {
748
+ color: '#5B80F7',
749
+ fontSize: 14,
750
+ fontWeight: '500',
751
+ lineHeight: 20,
752
+ },
753
+ inputLabel: {
754
+ fontSize: 14,
755
+ lineHeight: 20,
756
+ fontWeight: '500',
757
+ fontFamily: Platform.OS === 'android'
758
+ ? Fonts.IBMPlexSans_500Medium
759
+ : 'IBMPlexSans-Medium',
760
+ color: '#3D445C',
761
+ },
762
+ input: {
763
+ // flex: 1,
764
+ fontSize: 14,
765
+ lineHeight: 24,
766
+ fontFamily: Platform.OS === 'android'
767
+ ? Fonts.IBMPlexSans_400Regular
768
+ : 'IBMPlexSans-Regular',
769
+ borderColor: '#E0E3EB',
770
+ borderWidth: 1,
771
+ height: 22,
772
+ borderRadius: 6,
773
+ paddingHorizontal: 13,
774
+ paddingVertical: 9,
775
+ backgroundColor: '#ffffff',
776
+ },
777
+ buttonParentContainer: {
778
+ flexDirection: 'row',
779
+ padding: 10,
780
+ paddingTop: 16,
781
+ backgroundColor: 'white',
782
+ borderTopWidth: 1,
783
+ borderTopColor: '#eeeeee',
784
+ },
785
+ btnContainer: {
786
+ justifyContent: 'flex-end',
787
+ marginBottom: 10,
788
+ flexGrow: 1,
789
+ },
790
+ });