@os1-platform/dispatch-mobile 1.0.7 → 1.3.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +90 -26
- package/android/.gradle/6.8/fileChanges/last-build.bin +0 -0
- package/android/.gradle/6.8/fileHashes/fileHashes.lock +0 -0
- package/android/.gradle/6.8/gc.properties +0 -0
- package/android/.gradle/buildOutputCleanup/buildOutputCleanup.lock +0 -0
- package/android/.gradle/buildOutputCleanup/cache.properties +2 -0
- package/android/.gradle/checksums/checksums.lock +0 -0
- package/android/.gradle/configuration-cache/gc.properties +0 -0
- package/android/.gradle/vcs-1/gc.properties +0 -0
- package/android/.idea/gradle.xml +13 -0
- package/android/.idea/misc.xml +4 -0
- package/android/.idea/vcs.xml +6 -0
- package/android/.idea/workspace.xml +131 -0
- package/android/gradle.properties +1 -1
- package/android/local.properties +8 -0
- package/android/src/main/AndroidManifest.xml +0 -1
- package/lib/commonjs/components/dispatch/DispatchExecNavigator.js +46 -39
- package/lib/commonjs/components/dispatch/DispatchExecNavigator.js.map +1 -1
- package/lib/commonjs/components/executiontasks/ExecutionTasksIndex.js +14 -24
- package/lib/commonjs/components/executiontasks/ExecutionTasksIndex.js.map +1 -1
- package/lib/commonjs/components/executiontasks/cancellation/CancelET.js +142 -23
- package/lib/commonjs/components/executiontasks/cancellation/CancelET.js.map +1 -1
- package/lib/commonjs/components/executiontasks/cancellation/CancellationSchema.js.map +1 -1
- package/lib/commonjs/components/executiontasks/captureInput/CaptureText.js +64 -16
- package/lib/commonjs/components/executiontasks/captureInput/CaptureText.js.map +1 -1
- package/lib/commonjs/components/executiontasks/deliver/DeliverET.js +6 -16
- package/lib/commonjs/components/executiontasks/deliver/DeliverET.js.map +1 -1
- package/lib/commonjs/components/executiontasks/deliver/SLDeliverET.js +68 -26
- package/lib/commonjs/components/executiontasks/deliver/SLDeliverET.js.map +1 -1
- package/lib/commonjs/components/executiontasks/display/DisplayModalET.js +4 -13
- package/lib/commonjs/components/executiontasks/display/DisplayModalET.js.map +1 -1
- package/lib/commonjs/components/executiontasks/doodle/DoodleUtils.js +0 -2
- package/lib/commonjs/components/executiontasks/doodle/DoodleUtils.js.map +1 -1
- package/lib/commonjs/components/executiontasks/doodle/SignatureET.js +61 -28
- package/lib/commonjs/components/executiontasks/doodle/SignatureET.js.map +1 -1
- package/lib/commonjs/components/executiontasks/dropCash/DropCashET.js +5 -19
- package/lib/commonjs/components/executiontasks/dropCash/DropCashET.js.map +1 -1
- package/lib/commonjs/components/executiontasks/dropCash/SLDropCash.js +62 -18
- package/lib/commonjs/components/executiontasks/dropCash/SLDropCash.js.map +1 -1
- package/lib/commonjs/components/executiontasks/forms/FormGenerator.js +112 -28
- package/lib/commonjs/components/executiontasks/forms/FormGenerator.js.map +1 -1
- package/lib/commonjs/components/executiontasks/forms/widgets/DateTimeWidget.js +3 -26
- package/lib/commonjs/components/executiontasks/forms/widgets/DateTimeWidget.js.map +1 -1
- package/lib/commonjs/components/executiontasks/forms/widgets/DropdownWidget.js +49 -0
- package/lib/commonjs/components/executiontasks/forms/widgets/DropdownWidget.js.map +1 -0
- package/lib/commonjs/components/executiontasks/forms/widgets/QRBarcodeScannerWidget.js +1 -16
- package/lib/commonjs/components/executiontasks/forms/widgets/QRBarcodeScannerWidget.js.map +1 -1
- package/lib/commonjs/components/executiontasks/forms/widgets/TimeRangeSelector.js +0 -10
- package/lib/commonjs/components/executiontasks/forms/widgets/TimeRangeSelector.js.map +1 -1
- package/lib/commonjs/components/executiontasks/httpRequest/HttpEtUtils.js +4 -13
- package/lib/commonjs/components/executiontasks/httpRequest/HttpEtUtils.js.map +1 -1
- package/lib/commonjs/components/executiontasks/httpRequest/HttpRequestET.js +0 -12
- package/lib/commonjs/components/executiontasks/httpRequest/HttpRequestET.js.map +1 -1
- package/lib/commonjs/components/executiontasks/imageCapture/CaptureSchema.js.map +1 -1
- package/lib/commonjs/components/executiontasks/imageCapture/CaptureUtils.js +7 -35
- package/lib/commonjs/components/executiontasks/imageCapture/CaptureUtils.js.map +1 -1
- package/lib/commonjs/components/executiontasks/imageCapture/ImageCapture.js +74 -49
- package/lib/commonjs/components/executiontasks/imageCapture/ImageCapture.js.map +1 -1
- package/lib/commonjs/components/executiontasks/payments/PaymentStyles.js +0 -4
- package/lib/commonjs/components/executiontasks/payments/PaymentStyles.js.map +1 -1
- package/lib/commonjs/components/executiontasks/payments/PaymentUtils.js +0 -2
- package/lib/commonjs/components/executiontasks/payments/PaymentUtils.js.map +1 -1
- package/lib/commonjs/components/executiontasks/payments/completePayment/CompletePaymentET.js +64 -17
- package/lib/commonjs/components/executiontasks/payments/completePayment/CompletePaymentET.js.map +1 -1
- package/lib/commonjs/components/executiontasks/payments/init/InitPaymentET.js +63 -24
- package/lib/commonjs/components/executiontasks/payments/init/InitPaymentET.js.map +1 -1
- package/lib/commonjs/components/executiontasks/payments/processPayment/ProcessPaymentET.js +71 -22
- package/lib/commonjs/components/executiontasks/payments/processPayment/ProcessPaymentET.js.map +1 -1
- package/lib/commonjs/components/executiontasks/pickup/PickupET.js +5 -15
- package/lib/commonjs/components/executiontasks/pickup/PickupET.js.map +1 -1
- package/lib/commonjs/components/executiontasks/pickup/SLPickupET.js +60 -19
- package/lib/commonjs/components/executiontasks/pickup/SLPickupET.js.map +1 -1
- package/lib/commonjs/components/executiontasks/scan/ScanET.js +843 -0
- package/lib/commonjs/components/executiontasks/scan/ScanET.js.map +1 -0
- package/lib/commonjs/components/executiontasks/scan/ScanSchema.js +6 -0
- package/lib/commonjs/components/executiontasks/scan/ScanSchema.js.map +1 -0
- package/lib/commonjs/components/executiontasks/scan/constants.js +19 -0
- package/lib/commonjs/components/executiontasks/scan/constants.js.map +1 -0
- package/lib/commonjs/components/executiontasks/scan/interfaces.js +29 -0
- package/lib/commonjs/components/executiontasks/scan/interfaces.js.map +1 -0
- package/lib/commonjs/components/executiontasks/scan/sub_components/CScanner.js +103 -0
- package/lib/commonjs/components/executiontasks/scan/sub_components/CScanner.js.map +1 -0
- package/lib/commonjs/components/executiontasks/scan/sub_components/DropDownUtils.js +74 -0
- package/lib/commonjs/components/executiontasks/scan/sub_components/DropDownUtils.js.map +1 -0
- package/lib/commonjs/components/executiontasks/scan/sub_components/ERDropDown.js +115 -0
- package/lib/commonjs/components/executiontasks/scan/sub_components/ERDropDown.js.map +1 -0
- package/lib/commonjs/components/executiontasks/scan/sub_components/ScanList.js +134 -0
- package/lib/commonjs/components/executiontasks/scan/sub_components/ScanList.js.map +1 -0
- package/lib/commonjs/components/executiontasks/scan/utils.js +373 -0
- package/lib/commonjs/components/executiontasks/scan/utils.js.map +1 -0
- package/lib/commonjs/components/executiontasks/scanner/CScanner.js +3 -21
- package/lib/commonjs/components/executiontasks/scanner/CScanner.js.map +1 -1
- package/lib/commonjs/components/executiontasks/scanner/ScannerSchema.js +4 -9
- package/lib/commonjs/components/executiontasks/scanner/ScannerSchema.js.map +1 -1
- package/lib/commonjs/components/executiontasks/scanner/ScannerUtils.js +7 -36
- package/lib/commonjs/components/executiontasks/scanner/ScannerUtils.js.map +1 -1
- package/lib/commonjs/components/executiontasks/scanner/returns/DropDownSelector.js +0 -5
- package/lib/commonjs/components/executiontasks/scanner/returns/DropDownSelector.js.map +1 -1
- package/lib/commonjs/components/executiontasks/scanner/returns/DropDownUtils.js +0 -9
- package/lib/commonjs/components/executiontasks/scanner/returns/DropDownUtils.js.map +1 -1
- package/lib/commonjs/components/executiontasks/scanner/returns/RTReasonSelection.js +0 -14
- package/lib/commonjs/components/executiontasks/scanner/returns/RTReasonSelection.js.map +1 -1
- package/lib/commonjs/components/executiontasks/scanner/returns/RTScan.js +1 -40
- package/lib/commonjs/components/executiontasks/scanner/returns/RTScan.js.map +1 -1
- package/lib/commonjs/components/executiontasks/scanner/returns/ReasonDropDown.js +0 -17
- package/lib/commonjs/components/executiontasks/scanner/returns/ReasonDropDown.js.map +1 -1
- package/lib/commonjs/components/executiontasks/scanner/returns/ScanList.js +0 -28
- package/lib/commonjs/components/executiontasks/scanner/returns/ScanList.js.map +1 -1
- package/lib/commonjs/components/executiontasks/validateOTP/ValidateOTPET.js +334 -0
- package/lib/commonjs/components/executiontasks/validateOTP/ValidateOTPET.js.map +1 -0
- package/lib/commonjs/components/executiontasks/validateOTP/ValidateOTPSchema.js +14 -0
- package/lib/commonjs/components/executiontasks/validateOTP/ValidateOTPSchema.js.map +1 -0
- package/lib/commonjs/components/executiontasks/validateOTP/constants.js +37 -0
- package/lib/commonjs/components/executiontasks/validateOTP/constants.js.map +1 -0
- package/lib/commonjs/components/executiontasks/validateOTP/sub-components/OTPInput.js +59 -0
- package/lib/commonjs/components/executiontasks/validateOTP/sub-components/OTPInput.js.map +1 -0
- package/lib/commonjs/components/executiontasks/validateOTP/utils.js +147 -0
- package/lib/commonjs/components/executiontasks/validateOTP/utils.js.map +1 -0
- package/lib/commonjs/components/executiontasks/verifyLocation/GeofenceUtils.js +0 -13
- package/lib/commonjs/components/executiontasks/verifyLocation/GeofenceUtils.js.map +1 -1
- package/lib/commonjs/components/executiontasks/verifyLocation/VerifyLocationET.js +4 -17
- package/lib/commonjs/components/executiontasks/verifyLocation/VerifyLocationET.js.map +1 -1
- package/lib/commonjs/components/executiontasks/verifyOtp/VerifyOtpET.js +3 -18
- package/lib/commonjs/components/executiontasks/verifyOtp/VerifyOtpET.js.map +1 -1
- package/lib/commonjs/components/widgets/AlertDisplay.js +0 -5
- package/lib/commonjs/components/widgets/AlertDisplay.js.map +1 -1
- package/lib/commonjs/components/widgets/CancelOrderDialog.js +0 -12
- package/lib/commonjs/components/widgets/CancelOrderDialog.js.map +1 -1
- package/lib/commonjs/components/widgets/IconButton.js +34 -0
- package/lib/commonjs/components/widgets/IconButton.js.map +1 -0
- package/lib/commonjs/components/widgets/ProgressDialog.js +0 -7
- package/lib/commonjs/components/widgets/ProgressDialog.js.map +1 -1
- package/lib/commonjs/components/widgets/SnackBarCustom.js +38 -38
- package/lib/commonjs/components/widgets/SnackBarCustom.js.map +1 -1
- package/lib/commonjs/components/widgets/SplitTextInput.js +93 -0
- package/lib/commonjs/components/widgets/SplitTextInput.js.map +1 -0
- package/lib/commonjs/components/widgets/Toaster.js +0 -2
- package/lib/commonjs/components/widgets/Toaster.js.map +1 -1
- package/lib/commonjs/config/DispatchSDKConfig.js +4 -5
- package/lib/commonjs/config/DispatchSDKConfig.js.map +1 -1
- package/lib/commonjs/constants/apiConstants.js +15 -0
- package/lib/commonjs/constants/apiConstants.js.map +1 -0
- package/lib/commonjs/constants/constants.js +7 -3
- package/lib/commonjs/constants/constants.js.map +1 -1
- package/lib/commonjs/constants/statuscode.js +3 -5
- package/lib/commonjs/constants/statuscode.js.map +1 -1
- package/lib/commonjs/errors/BaseError.js +3 -8
- package/lib/commonjs/errors/BaseError.js.map +1 -1
- package/lib/commonjs/errors/ErrorCodes.js +7 -6
- package/lib/commonjs/errors/ErrorCodes.js.map +1 -1
- package/lib/commonjs/events/EventDispatcher.js +27 -0
- package/lib/commonjs/events/EventDispatcher.js.map +1 -0
- package/lib/commonjs/events/EventListener.js +20 -0
- package/lib/commonjs/events/EventListener.js.map +1 -0
- package/lib/commonjs/events/constants.js +13 -0
- package/lib/commonjs/events/constants.js.map +1 -0
- package/lib/commonjs/events/index.js +11 -0
- package/lib/commonjs/events/index.js.map +1 -0
- package/lib/commonjs/events/interface.js +2 -0
- package/lib/commonjs/events/interface.js.map +1 -0
- package/lib/commonjs/index.js +9 -23
- package/lib/commonjs/index.js.map +1 -1
- package/lib/commonjs/manager/dispatch/DispatchStateContainer.js +527 -177
- package/lib/commonjs/manager/dispatch/DispatchStateContainer.js.map +1 -1
- package/lib/commonjs/manager/dispatchCodes/EventCodeContainer.js +55 -4
- package/lib/commonjs/manager/dispatchCodes/EventCodeContainer.js.map +1 -1
- package/lib/commonjs/manager/dispatchCodes/EventCodeRepo.js +70 -0
- package/lib/commonjs/manager/dispatchCodes/EventCodeRepo.js.map +1 -0
- package/lib/commonjs/manager/dispatchCodes/ReasonCodeContainer.js +3 -29
- package/lib/commonjs/manager/dispatchCodes/ReasonCodeContainer.js.map +1 -1
- package/lib/commonjs/manager/dispatchCodes/ReasonCodeRepo.js +6 -20
- package/lib/commonjs/manager/dispatchCodes/ReasonCodeRepo.js.map +1 -1
- package/lib/commonjs/manager/jobRemoval/JobRemovalManager.js +27 -0
- package/lib/commonjs/manager/jobRemoval/JobRemovalManager.js.map +1 -0
- package/lib/commonjs/manager/location/LocationManager.js +3 -20
- package/lib/commonjs/manager/location/LocationManager.js.map +1 -1
- package/lib/commonjs/manager/sdk/DispatchSDKManager.js +8 -36
- package/lib/commonjs/manager/sdk/DispatchSDKManager.js.map +1 -1
- package/lib/commonjs/manager/sdk/DispatchSdkCache.js +6 -17
- package/lib/commonjs/manager/sdk/DispatchSdkCache.js.map +1 -1
- package/lib/commonjs/manager/syncmanager/AppSyncManager.js +12 -46
- package/lib/commonjs/manager/syncmanager/AppSyncManager.js.map +1 -1
- package/lib/commonjs/manager/syncmanager/DBConfig.js +13 -7
- package/lib/commonjs/manager/syncmanager/DBConfig.js.map +1 -1
- package/lib/commonjs/manager/syncmanager/NativeSyncManager.js +0 -2
- package/lib/commonjs/manager/syncmanager/NativeSyncManager.js.map +1 -1
- package/lib/commonjs/manager/syncmanager/database.js +28 -12
- package/lib/commonjs/manager/syncmanager/database.js.map +1 -1
- package/lib/commonjs/manager/syncmanager/document/DocumentHttpClient.js +0 -19
- package/lib/commonjs/manager/syncmanager/document/DocumentHttpClient.js.map +1 -1
- package/lib/commonjs/manager/syncmanager/document/DocumentManager.js +3 -20
- package/lib/commonjs/manager/syncmanager/document/DocumentManager.js.map +1 -1
- package/lib/commonjs/manager/syncmanager/document/DocumentSyncManager.js +3 -52
- package/lib/commonjs/manager/syncmanager/document/DocumentSyncManager.js.map +1 -1
- package/lib/commonjs/manager/syncmanager/events/ETEventsManager.js +59 -25
- package/lib/commonjs/manager/syncmanager/events/ETEventsManager.js.map +1 -1
- package/lib/commonjs/manager/syncmanager/events/EventsSyncManager.js +77 -90
- package/lib/commonjs/manager/syncmanager/events/EventsSyncManager.js.map +1 -1
- package/lib/commonjs/manager/syncmanager/events/SyncHttpClient.js +27 -19
- package/lib/commonjs/manager/syncmanager/events/SyncHttpClient.js.map +1 -1
- package/lib/commonjs/models/DispatchModels.js +4 -5
- package/lib/commonjs/models/DispatchModels.js.map +1 -1
- package/lib/commonjs/models/ReasonCodes.js.map +1 -1
- package/lib/commonjs/models/execTasks/ETBaseModels.js.map +1 -1
- package/lib/commonjs/models/execTasks/ETConfig.js +28 -35
- package/lib/commonjs/models/execTasks/ETConfig.js.map +1 -1
- package/lib/commonjs/models/sdk.js +4 -5
- package/lib/commonjs/models/sdk.js.map +1 -1
- package/lib/commonjs/native/signature/SignatureCapture.js +3 -24
- package/lib/commonjs/native/signature/SignatureCapture.js.map +1 -1
- package/lib/commonjs/network/GraphQLClient.js +7 -35
- package/lib/commonjs/network/GraphQLClient.js.map +1 -1
- package/lib/commonjs/network/NetworkClient.js +2 -13
- package/lib/commonjs/network/NetworkClient.js.map +1 -1
- package/lib/commonjs/network/NetworkUtils.js +10 -8
- package/lib/commonjs/network/NetworkUtils.js.map +1 -1
- package/lib/commonjs/network/Queries.js +0 -2
- package/lib/commonjs/network/Queries.js.map +1 -1
- package/lib/commonjs/network/client.js +6 -21
- package/lib/commonjs/network/client.js.map +1 -1
- package/lib/commonjs/res/strings.js.map +1 -1
- package/lib/commonjs/resources/Login.js +4 -15
- package/lib/commonjs/resources/Login.js.map +1 -1
- package/lib/commonjs/resources/network.js +3 -8
- package/lib/commonjs/resources/network.js.map +1 -1
- package/lib/commonjs/styles/SdkColors.js +7 -7
- package/lib/commonjs/styles/SdkColors.js.map +1 -1
- package/lib/commonjs/styles/executionTasks/CommonStyles.js +42 -18
- package/lib/commonjs/styles/executionTasks/CommonStyles.js.map +1 -1
- package/lib/commonjs/ui/screens/CancellationScreen.js +36 -27
- package/lib/commonjs/ui/screens/CancellationScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/CaptureInputScreen.js +6 -15
- package/lib/commonjs/ui/screens/CaptureInputScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/CompleteObjectiveScreen.js +0 -19
- package/lib/commonjs/ui/screens/CompleteObjectiveScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/DeliverScreen.js +6 -15
- package/lib/commonjs/ui/screens/DeliverScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/DisplayScreen.js +7 -12
- package/lib/commonjs/ui/screens/DisplayScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/DoodleScreen.js +6 -16
- package/lib/commonjs/ui/screens/DoodleScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/DropCashScreen.js +6 -18
- package/lib/commonjs/ui/screens/DropCashScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/ETScreensIndex.js +14 -16
- package/lib/commonjs/ui/screens/ETScreensIndex.js.map +1 -1
- package/lib/commonjs/ui/screens/FormsScreen.js +36 -15
- package/lib/commonjs/ui/screens/FormsScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/GeofenceScreen.js +7 -13
- package/lib/commonjs/ui/screens/GeofenceScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/HttpRequestScreen.js +5 -10
- package/lib/commonjs/ui/screens/HttpRequestScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/ImageCaptureScreen.js +27 -14
- package/lib/commonjs/ui/screens/ImageCaptureScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/PaymentScreen.js +11 -23
- package/lib/commonjs/ui/screens/PaymentScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/PickupScreen.js +9 -13
- package/lib/commonjs/ui/screens/PickupScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/RTScanScreen.js +8 -27
- package/lib/commonjs/ui/screens/RTScanScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/ScanScreen.js +268 -0
- package/lib/commonjs/ui/screens/ScanScreen.js.map +1 -0
- package/lib/commonjs/ui/screens/StartWorkFlowScreen.js +21 -30
- package/lib/commonjs/ui/screens/StartWorkFlowScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/ValidateOTPScreen.js +49 -0
- package/lib/commonjs/ui/screens/ValidateOTPScreen.js.map +1 -0
- package/lib/commonjs/ui/screens/WithBaseDispatchScreen.js +0 -10
- package/lib/commonjs/ui/screens/WithBaseDispatchScreen.js.map +1 -1
- package/lib/commonjs/ui/uiConfig/RouteParams.js +9 -1
- package/lib/commonjs/ui/uiConfig/RouteParams.js.map +1 -1
- package/lib/commonjs/utils/ApiUtils.js +115 -0
- package/lib/commonjs/utils/ApiUtils.js.map +1 -0
- package/lib/commonjs/utils/ExecTaskUtils.js +93 -31
- package/lib/commonjs/utils/ExecTaskUtils.js.map +1 -1
- package/lib/commonjs/utils/Logger.js +10 -29
- package/lib/commonjs/utils/Logger.js.map +1 -1
- package/lib/commonjs/utils/NetworkUtil.js +3 -19
- package/lib/commonjs/utils/NetworkUtil.js.map +1 -1
- package/lib/commonjs/utils/SdkUtils.js +2 -31
- package/lib/commonjs/utils/SdkUtils.js.map +1 -1
- package/lib/commonjs/utils/SyncManagerUtils.js +25 -40
- package/lib/commonjs/utils/SyncManagerUtils.js.map +1 -1
- package/lib/commonjs/utils/fcm/FCM.js +35 -16
- package/lib/commonjs/utils/fcm/FCM.js.map +1 -1
- package/lib/commonjs/utils/fcm/FcmUtils.js +50 -25
- package/lib/commonjs/utils/fcm/FcmUtils.js.map +1 -1
- package/lib/commonjs/utils/helper.js +0 -5
- package/lib/commonjs/utils/helper.js.map +1 -1
- package/lib/commonjs/utils/hooks/useTimer.js +44 -0
- package/lib/commonjs/utils/hooks/useTimer.js.map +1 -0
- package/lib/commonjs/utils/loginHelper.js +6 -18
- package/lib/commonjs/utils/loginHelper.js.map +1 -1
- package/lib/commonjs/utils/storage.js +53 -32
- package/lib/commonjs/utils/storage.js.map +1 -1
- package/lib/commonjs/utils/utils.js +8 -11
- package/lib/commonjs/utils/utils.js.map +1 -1
- package/lib/module/components/dispatch/DispatchExecNavigator.js +46 -28
- package/lib/module/components/dispatch/DispatchExecNavigator.js.map +1 -1
- package/lib/module/components/executiontasks/ExecutionTasksIndex.js +3 -1
- package/lib/module/components/executiontasks/ExecutionTasksIndex.js.map +1 -1
- package/lib/module/components/executiontasks/cancellation/CancelET.js +145 -19
- package/lib/module/components/executiontasks/cancellation/CancelET.js.map +1 -1
- package/lib/module/components/executiontasks/cancellation/CancellationSchema.js.map +1 -1
- package/lib/module/components/executiontasks/captureInput/CaptureText.js +66 -9
- package/lib/module/components/executiontasks/captureInput/CaptureText.js.map +1 -1
- package/lib/module/components/executiontasks/deliver/DeliverET.js +6 -7
- package/lib/module/components/executiontasks/deliver/DeliverET.js.map +1 -1
- package/lib/module/components/executiontasks/deliver/SLDeliverET.js +69 -16
- package/lib/module/components/executiontasks/deliver/SLDeliverET.js.map +1 -1
- package/lib/module/components/executiontasks/display/DisplayModalET.js +4 -3
- package/lib/module/components/executiontasks/display/DisplayModalET.js.map +1 -1
- package/lib/module/components/executiontasks/doodle/DoodleUtils.js.map +1 -1
- package/lib/module/components/executiontasks/doodle/SignatureET.js +64 -14
- package/lib/module/components/executiontasks/doodle/SignatureET.js.map +1 -1
- package/lib/module/components/executiontasks/dropCash/DropCashET.js +5 -6
- package/lib/module/components/executiontasks/dropCash/DropCashET.js.map +1 -1
- package/lib/module/components/executiontasks/dropCash/SLDropCash.js +62 -8
- package/lib/module/components/executiontasks/dropCash/SLDropCash.js.map +1 -1
- package/lib/module/components/executiontasks/forms/FormGenerator.js +114 -14
- package/lib/module/components/executiontasks/forms/FormGenerator.js.map +1 -1
- package/lib/module/components/executiontasks/forms/widgets/DateTimeWidget.js +3 -15
- package/lib/module/components/executiontasks/forms/widgets/DateTimeWidget.js.map +1 -1
- package/lib/module/components/executiontasks/forms/widgets/DropdownWidget.js +39 -0
- package/lib/module/components/executiontasks/forms/widgets/DropdownWidget.js.map +1 -0
- package/lib/module/components/executiontasks/forms/widgets/QRBarcodeScannerWidget.js +1 -5
- package/lib/module/components/executiontasks/forms/widgets/QRBarcodeScannerWidget.js.map +1 -1
- package/lib/module/components/executiontasks/forms/widgets/TimeRangeSelector.js +0 -3
- package/lib/module/components/executiontasks/forms/widgets/TimeRangeSelector.js.map +1 -1
- package/lib/module/components/executiontasks/httpRequest/HttpEtUtils.js +4 -2
- package/lib/module/components/executiontasks/httpRequest/HttpEtUtils.js.map +1 -1
- package/lib/module/components/executiontasks/httpRequest/HttpRequestET.js +0 -3
- package/lib/module/components/executiontasks/httpRequest/HttpRequestET.js.map +1 -1
- package/lib/module/components/executiontasks/imageCapture/CaptureSchema.js.map +1 -1
- package/lib/module/components/executiontasks/imageCapture/CaptureUtils.js +7 -10
- package/lib/module/components/executiontasks/imageCapture/CaptureUtils.js.map +1 -1
- package/lib/module/components/executiontasks/imageCapture/ImageCapture.js +75 -35
- package/lib/module/components/executiontasks/imageCapture/ImageCapture.js.map +1 -1
- package/lib/module/components/executiontasks/payments/PaymentStyles.js.map +1 -1
- package/lib/module/components/executiontasks/payments/PaymentUtils.js.map +1 -1
- package/lib/module/components/executiontasks/payments/completePayment/CompletePaymentET.js +64 -6
- package/lib/module/components/executiontasks/payments/completePayment/CompletePaymentET.js.map +1 -1
- package/lib/module/components/executiontasks/payments/init/InitPaymentET.js +63 -11
- package/lib/module/components/executiontasks/payments/init/InitPaymentET.js.map +1 -1
- package/lib/module/components/executiontasks/payments/processPayment/ProcessPaymentET.js +71 -10
- package/lib/module/components/executiontasks/payments/processPayment/ProcessPaymentET.js.map +1 -1
- package/lib/module/components/executiontasks/pickup/PickupET.js +5 -6
- package/lib/module/components/executiontasks/pickup/PickupET.js.map +1 -1
- package/lib/module/components/executiontasks/pickup/SLPickupET.js +61 -10
- package/lib/module/components/executiontasks/pickup/SLPickupET.js.map +1 -1
- package/lib/module/components/executiontasks/scan/ScanET.js +833 -0
- package/lib/module/components/executiontasks/scan/ScanET.js.map +1 -0
- package/lib/module/components/executiontasks/scan/ScanSchema.js +2 -0
- package/lib/module/components/executiontasks/scan/ScanSchema.js.map +1 -0
- package/lib/module/components/executiontasks/scan/constants.js +7 -0
- package/lib/module/components/executiontasks/scan/constants.js.map +1 -0
- package/lib/module/components/executiontasks/scan/interfaces.js +21 -0
- package/lib/module/components/executiontasks/scan/interfaces.js.map +1 -0
- package/lib/module/components/executiontasks/scan/sub_components/CScanner.js +94 -0
- package/lib/module/components/executiontasks/scan/sub_components/CScanner.js.map +1 -0
- package/lib/module/components/executiontasks/scan/sub_components/DropDownUtils.js +66 -0
- package/lib/module/components/executiontasks/scan/sub_components/DropDownUtils.js.map +1 -0
- package/lib/module/components/executiontasks/scan/sub_components/ERDropDown.js +105 -0
- package/lib/module/components/executiontasks/scan/sub_components/ERDropDown.js.map +1 -0
- package/lib/module/components/executiontasks/scan/sub_components/ScanList.js +124 -0
- package/lib/module/components/executiontasks/scan/sub_components/ScanList.js.map +1 -0
- package/lib/module/components/executiontasks/scan/utils.js +358 -0
- package/lib/module/components/executiontasks/scan/utils.js.map +1 -0
- package/lib/module/components/executiontasks/scanner/CScanner.js +3 -8
- package/lib/module/components/executiontasks/scanner/CScanner.js.map +1 -1
- package/lib/module/components/executiontasks/scanner/ScannerSchema.js +3 -3
- package/lib/module/components/executiontasks/scanner/ScannerSchema.js.map +1 -1
- package/lib/module/components/executiontasks/scanner/ScannerUtils.js +6 -18
- package/lib/module/components/executiontasks/scanner/ScannerUtils.js.map +1 -1
- package/lib/module/components/executiontasks/scanner/returns/DropDownSelector.js +0 -2
- package/lib/module/components/executiontasks/scanner/returns/DropDownSelector.js.map +1 -1
- package/lib/module/components/executiontasks/scanner/returns/DropDownUtils.js +0 -5
- package/lib/module/components/executiontasks/scanner/returns/DropDownUtils.js.map +1 -1
- package/lib/module/components/executiontasks/scanner/returns/RTReasonSelection.js +0 -3
- package/lib/module/components/executiontasks/scanner/returns/RTReasonSelection.js.map +1 -1
- package/lib/module/components/executiontasks/scanner/returns/RTScan.js +1 -19
- package/lib/module/components/executiontasks/scanner/returns/RTScan.js.map +1 -1
- package/lib/module/components/executiontasks/scanner/returns/ReasonDropDown.js +0 -7
- package/lib/module/components/executiontasks/scanner/returns/ReasonDropDown.js.map +1 -1
- package/lib/module/components/executiontasks/scanner/returns/ScanList.js +0 -15
- package/lib/module/components/executiontasks/scanner/returns/ScanList.js.map +1 -1
- package/lib/module/components/executiontasks/validateOTP/ValidateOTPET.js +325 -0
- package/lib/module/components/executiontasks/validateOTP/ValidateOTPET.js.map +1 -0
- package/lib/module/components/executiontasks/validateOTP/ValidateOTPSchema.js +8 -0
- package/lib/module/components/executiontasks/validateOTP/ValidateOTPSchema.js.map +1 -0
- package/lib/module/components/executiontasks/validateOTP/constants.js +25 -0
- package/lib/module/components/executiontasks/validateOTP/constants.js.map +1 -0
- package/lib/module/components/executiontasks/validateOTP/sub-components/OTPInput.js +49 -0
- package/lib/module/components/executiontasks/validateOTP/sub-components/OTPInput.js.map +1 -0
- package/lib/module/components/executiontasks/validateOTP/utils.js +133 -0
- package/lib/module/components/executiontasks/validateOTP/utils.js.map +1 -0
- package/lib/module/components/executiontasks/verifyLocation/GeofenceUtils.js +0 -6
- package/lib/module/components/executiontasks/verifyLocation/GeofenceUtils.js.map +1 -1
- package/lib/module/components/executiontasks/verifyLocation/VerifyLocationET.js +4 -3
- package/lib/module/components/executiontasks/verifyLocation/VerifyLocationET.js.map +1 -1
- package/lib/module/components/executiontasks/verifyOtp/VerifyOtpET.js +4 -8
- package/lib/module/components/executiontasks/verifyOtp/VerifyOtpET.js.map +1 -1
- package/lib/module/components/widgets/AlertDisplay.js.map +1 -1
- package/lib/module/components/widgets/CancelOrderDialog.js +0 -2
- package/lib/module/components/widgets/CancelOrderDialog.js.map +1 -1
- package/lib/module/components/widgets/IconButton.js +26 -0
- package/lib/module/components/widgets/IconButton.js.map +1 -0
- package/lib/module/components/widgets/ProgressDialog.js +0 -2
- package/lib/module/components/widgets/ProgressDialog.js.map +1 -1
- package/lib/module/components/widgets/SnackBarCustom.js +36 -18
- package/lib/module/components/widgets/SnackBarCustom.js.map +1 -1
- package/lib/module/components/widgets/SplitTextInput.js +84 -0
- package/lib/module/components/widgets/SplitTextInput.js.map +1 -0
- package/lib/module/components/widgets/Toaster.js.map +1 -1
- package/lib/module/config/DispatchSDKConfig.js +3 -4
- package/lib/module/config/DispatchSDKConfig.js.map +1 -1
- package/lib/module/constants/apiConstants.js +7 -0
- package/lib/module/constants/apiConstants.js.map +1 -0
- package/lib/module/constants/constants.js +4 -2
- package/lib/module/constants/constants.js.map +1 -1
- package/lib/module/constants/statuscode.js +3 -5
- package/lib/module/constants/statuscode.js.map +1 -1
- package/lib/module/errors/BaseError.js +3 -6
- package/lib/module/errors/BaseError.js.map +1 -1
- package/lib/module/errors/ErrorCodes.js +5 -5
- package/lib/module/errors/ErrorCodes.js.map +1 -1
- package/lib/module/events/EventDispatcher.js +19 -0
- package/lib/module/events/EventDispatcher.js.map +1 -0
- package/lib/module/events/EventListener.js +13 -0
- package/lib/module/events/EventListener.js.map +1 -0
- package/lib/module/events/constants.js +6 -0
- package/lib/module/events/constants.js.map +1 -0
- package/lib/module/events/index.js +3 -0
- package/lib/module/events/index.js.map +1 -0
- package/lib/module/events/interface.js +2 -0
- package/lib/module/events/interface.js.map +1 -0
- package/lib/module/index.js +4 -3
- package/lib/module/index.js.map +1 -1
- package/lib/module/manager/dispatch/DispatchStateContainer.js +529 -151
- package/lib/module/manager/dispatch/DispatchStateContainer.js.map +1 -1
- package/lib/module/manager/dispatchCodes/EventCodeContainer.js +52 -2
- package/lib/module/manager/dispatchCodes/EventCodeContainer.js.map +1 -1
- package/lib/module/manager/dispatchCodes/EventCodeRepo.js +61 -0
- package/lib/module/manager/dispatchCodes/EventCodeRepo.js.map +1 -0
- package/lib/module/manager/dispatchCodes/ReasonCodeContainer.js +3 -16
- package/lib/module/manager/dispatchCodes/ReasonCodeContainer.js.map +1 -1
- package/lib/module/manager/dispatchCodes/ReasonCodeRepo.js +6 -14
- package/lib/module/manager/dispatchCodes/ReasonCodeRepo.js.map +1 -1
- package/lib/module/manager/jobRemoval/JobRemovalManager.js +20 -0
- package/lib/module/manager/jobRemoval/JobRemovalManager.js.map +1 -0
- package/lib/module/manager/location/LocationManager.js +3 -14
- package/lib/module/manager/location/LocationManager.js.map +1 -1
- package/lib/module/manager/sdk/DispatchSDKManager.js +8 -14
- package/lib/module/manager/sdk/DispatchSDKManager.js.map +1 -1
- package/lib/module/manager/sdk/DispatchSdkCache.js +6 -13
- package/lib/module/manager/sdk/DispatchSdkCache.js.map +1 -1
- package/lib/module/manager/syncmanager/AppSyncManager.js +12 -26
- package/lib/module/manager/syncmanager/AppSyncManager.js.map +1 -1
- package/lib/module/manager/syncmanager/DBConfig.js +9 -5
- package/lib/module/manager/syncmanager/DBConfig.js.map +1 -1
- package/lib/module/manager/syncmanager/NativeSyncManager.js.map +1 -1
- package/lib/module/manager/syncmanager/database.js +27 -3
- package/lib/module/manager/syncmanager/database.js.map +1 -1
- package/lib/module/manager/syncmanager/document/DocumentHttpClient.js +0 -7
- package/lib/module/manager/syncmanager/document/DocumentHttpClient.js.map +1 -1
- package/lib/module/manager/syncmanager/document/DocumentManager.js +3 -14
- package/lib/module/manager/syncmanager/document/DocumentManager.js.map +1 -1
- package/lib/module/manager/syncmanager/document/DocumentSyncManager.js +3 -35
- package/lib/module/manager/syncmanager/document/DocumentSyncManager.js.map +1 -1
- package/lib/module/manager/syncmanager/events/ETEventsManager.js +59 -18
- package/lib/module/manager/syncmanager/events/ETEventsManager.js.map +1 -1
- package/lib/module/manager/syncmanager/events/EventsSyncManager.js +77 -68
- package/lib/module/manager/syncmanager/events/EventsSyncManager.js.map +1 -1
- package/lib/module/manager/syncmanager/events/SyncHttpClient.js +26 -11
- package/lib/module/manager/syncmanager/events/SyncHttpClient.js.map +1 -1
- package/lib/module/models/DispatchModels.js +3 -4
- package/lib/module/models/DispatchModels.js.map +1 -1
- package/lib/module/models/ReasonCodes.js.map +1 -1
- package/lib/module/models/execTasks/ETBaseModels.js.map +1 -1
- package/lib/module/models/execTasks/ETConfig.js +22 -29
- package/lib/module/models/execTasks/ETConfig.js.map +1 -1
- package/lib/module/models/sdk.js +3 -4
- package/lib/module/models/sdk.js.map +1 -1
- package/lib/module/native/signature/SignatureCapture.js +3 -18
- package/lib/module/native/signature/SignatureCapture.js.map +1 -1
- package/lib/module/network/GraphQLClient.js +6 -26
- package/lib/module/network/GraphQLClient.js.map +1 -1
- package/lib/module/network/NetworkClient.js +2 -6
- package/lib/module/network/NetworkClient.js.map +1 -1
- package/lib/module/network/NetworkUtils.js +10 -3
- package/lib/module/network/NetworkUtils.js.map +1 -1
- package/lib/module/network/Queries.js.map +1 -1
- package/lib/module/network/client.js +7 -17
- package/lib/module/network/client.js.map +1 -1
- package/lib/module/res/strings.js.map +1 -1
- package/lib/module/resources/Login.js +4 -13
- package/lib/module/resources/Login.js.map +1 -1
- package/lib/module/resources/network.js +3 -6
- package/lib/module/resources/network.js.map +1 -1
- package/lib/module/styles/SdkColors.js +6 -6
- package/lib/module/styles/SdkColors.js.map +1 -1
- package/lib/module/styles/executionTasks/CommonStyles.js +41 -7
- package/lib/module/styles/executionTasks/CommonStyles.js.map +1 -1
- package/lib/module/ui/screens/CancellationScreen.js +36 -14
- package/lib/module/ui/screens/CancellationScreen.js.map +1 -1
- package/lib/module/ui/screens/CaptureInputScreen.js +7 -4
- package/lib/module/ui/screens/CaptureInputScreen.js.map +1 -1
- package/lib/module/ui/screens/CompleteObjectiveScreen.js +0 -3
- package/lib/module/ui/screens/CompleteObjectiveScreen.js.map +1 -1
- package/lib/module/ui/screens/DeliverScreen.js +7 -4
- package/lib/module/ui/screens/DeliverScreen.js.map +1 -1
- package/lib/module/ui/screens/DisplayScreen.js +5 -4
- package/lib/module/ui/screens/DisplayScreen.js.map +1 -1
- package/lib/module/ui/screens/DoodleScreen.js +7 -4
- package/lib/module/ui/screens/DoodleScreen.js.map +1 -1
- package/lib/module/ui/screens/DropCashScreen.js +7 -7
- package/lib/module/ui/screens/DropCashScreen.js.map +1 -1
- package/lib/module/ui/screens/ETScreensIndex.js +3 -1
- package/lib/module/ui/screens/ETScreensIndex.js.map +1 -1
- package/lib/module/ui/screens/FormsScreen.js +34 -6
- package/lib/module/ui/screens/FormsScreen.js.map +1 -1
- package/lib/module/ui/screens/GeofenceScreen.js +5 -4
- package/lib/module/ui/screens/GeofenceScreen.js.map +1 -1
- package/lib/module/ui/screens/HttpRequestScreen.js +5 -3
- package/lib/module/ui/screens/HttpRequestScreen.js.map +1 -1
- package/lib/module/ui/screens/ImageCaptureScreen.js +25 -5
- package/lib/module/ui/screens/ImageCaptureScreen.js.map +1 -1
- package/lib/module/ui/screens/PaymentScreen.js +12 -10
- package/lib/module/ui/screens/PaymentScreen.js.map +1 -1
- package/lib/module/ui/screens/PickupScreen.js +7 -5
- package/lib/module/ui/screens/PickupScreen.js.map +1 -1
- package/lib/module/ui/screens/RTScanScreen.js +9 -13
- package/lib/module/ui/screens/RTScanScreen.js.map +1 -1
- package/lib/module/ui/screens/ScanScreen.js +259 -0
- package/lib/module/ui/screens/ScanScreen.js.map +1 -0
- package/lib/module/ui/screens/StartWorkFlowScreen.js +22 -9
- package/lib/module/ui/screens/StartWorkFlowScreen.js.map +1 -1
- package/lib/module/ui/screens/ValidateOTPScreen.js +39 -0
- package/lib/module/ui/screens/ValidateOTPScreen.js.map +1 -0
- package/lib/module/ui/screens/WithBaseDispatchScreen.js +0 -3
- package/lib/module/ui/screens/WithBaseDispatchScreen.js.map +1 -1
- package/lib/module/ui/uiConfig/RouteParams.js +9 -1
- package/lib/module/ui/uiConfig/RouteParams.js.map +1 -1
- package/lib/module/utils/ApiUtils.js +101 -0
- package/lib/module/utils/ApiUtils.js.map +1 -0
- package/lib/module/utils/ExecTaskUtils.js +92 -21
- package/lib/module/utils/ExecTaskUtils.js.map +1 -1
- package/lib/module/utils/Logger.js +9 -21
- package/lib/module/utils/Logger.js.map +1 -1
- package/lib/module/utils/NetworkUtil.js +3 -15
- package/lib/module/utils/NetworkUtil.js.map +1 -1
- package/lib/module/utils/SdkUtils.js +2 -15
- package/lib/module/utils/SdkUtils.js.map +1 -1
- package/lib/module/utils/SyncManagerUtils.js +25 -10
- package/lib/module/utils/SyncManagerUtils.js.map +1 -1
- package/lib/module/utils/fcm/FCM.js +35 -4
- package/lib/module/utils/fcm/FCM.js.map +1 -1
- package/lib/module/utils/fcm/FcmUtils.js +50 -7
- package/lib/module/utils/fcm/FcmUtils.js.map +1 -1
- package/lib/module/utils/helper.js +0 -3
- package/lib/module/utils/helper.js.map +1 -1
- package/lib/module/utils/hooks/useTimer.js +37 -0
- package/lib/module/utils/hooks/useTimer.js.map +1 -0
- package/lib/module/utils/loginHelper.js +6 -16
- package/lib/module/utils/loginHelper.js.map +1 -1
- package/lib/module/utils/storage.js +51 -29
- package/lib/module/utils/storage.js.map +1 -1
- package/lib/module/utils/utils.js +8 -6
- package/lib/module/utils/utils.js.map +1 -1
- package/lib/typescript/components/executiontasks/CompletedWFSchema.d.ts +2 -2
- package/lib/typescript/components/executiontasks/ExecutionTasksIndex.d.ts +6 -2
- package/lib/typescript/components/executiontasks/cancellation/CancellationSchema.d.ts +10 -5
- package/lib/typescript/components/executiontasks/captureInput/CaptureInputSchema.d.ts +7 -7
- package/lib/typescript/components/executiontasks/deliver/DeliverETInput.d.ts +7 -7
- package/lib/typescript/components/executiontasks/display/DisplaySchema.d.ts +5 -5
- package/lib/typescript/components/executiontasks/doodle/SignatureSchema.d.ts +7 -7
- package/lib/typescript/components/executiontasks/dropCash/DropCashSchema.d.ts +2 -2
- package/lib/typescript/components/executiontasks/forms/FormSchema.d.ts +2 -2
- package/lib/typescript/components/executiontasks/forms/widgets/DateTimeWidget.d.ts +1 -1
- package/lib/typescript/components/executiontasks/forms/widgets/DropdownWidget.d.ts +9 -0
- package/lib/typescript/components/executiontasks/httpRequest/HttpRequestETSchema.d.ts +6 -6
- package/lib/typescript/components/executiontasks/imageCapture/CaptureSchema.d.ts +16 -11
- package/lib/typescript/components/executiontasks/payments/completePayment/CompletePaymentSchema.d.ts +2 -2
- package/lib/typescript/components/executiontasks/payments/init/InitPaymentSchema.d.ts +3 -3
- package/lib/typescript/components/executiontasks/payments/processPayment/ProcessPaymentSchema.d.ts +2 -2
- package/lib/typescript/components/executiontasks/pickup/PickpSchema.d.ts +3 -3
- package/lib/typescript/components/executiontasks/scan/ScanET.d.ts +16 -0
- package/lib/typescript/components/executiontasks/scan/ScanSchema.d.ts +70 -0
- package/lib/typescript/components/executiontasks/scan/constants.d.ts +6 -0
- package/lib/typescript/components/executiontasks/scan/interfaces.d.ts +41 -0
- package/lib/typescript/components/executiontasks/scan/sub_components/CScanner.d.ts +7 -0
- package/lib/typescript/components/executiontasks/scan/sub_components/DropDownUtils.d.ts +7 -0
- package/lib/typescript/components/executiontasks/scan/sub_components/ERDropDown.d.ts +17 -0
- package/lib/typescript/components/executiontasks/scan/sub_components/ScanList.d.ts +8 -0
- package/lib/typescript/components/executiontasks/scan/utils.d.ts +21 -0
- package/lib/typescript/components/executiontasks/scanner/ScannerSchema.d.ts +6 -6
- package/lib/typescript/components/executiontasks/scanner/returns/DropDownUtils.d.ts +1 -2
- package/lib/typescript/components/executiontasks/scanner/returns/RTReasonSelection.d.ts +1 -1
- package/lib/typescript/components/executiontasks/scanner/returns/ScanList.d.ts +1 -1
- package/lib/typescript/components/executiontasks/validateOTP/ValidateOTPET.d.ts +4 -0
- package/lib/typescript/components/executiontasks/validateOTP/ValidateOTPSchema.d.ts +54 -0
- package/lib/typescript/components/executiontasks/validateOTP/constants.d.ts +10 -0
- package/lib/typescript/components/executiontasks/validateOTP/sub-components/OTPInput.d.ts +12 -0
- package/lib/typescript/components/executiontasks/validateOTP/utils.d.ts +7 -0
- package/lib/typescript/components/executiontasks/verifyInput/VerifyInputSchema.d.ts +8 -8
- package/lib/typescript/components/executiontasks/verifyLocation/VerifyLocSchema.d.ts +9 -9
- package/lib/typescript/components/executiontasks/verifyOtp/VerifyOtpSchema.d.ts +3 -3
- package/lib/typescript/components/widgets/IconButton.d.ts +9 -0
- package/lib/typescript/components/widgets/SnackBarCustom.d.ts +9 -5
- package/lib/typescript/components/widgets/SplitTextInput.d.ts +12 -0
- package/lib/typescript/constants/apiConstants.d.ts +6 -0
- package/lib/typescript/constants/constants.d.ts +4 -2
- package/lib/typescript/errors/ErrorCodes.d.ts +3 -1
- package/lib/typescript/events/EventDispatcher.d.ts +5 -0
- package/lib/typescript/events/EventListener.d.ts +5 -0
- package/lib/typescript/events/constants.d.ts +5 -0
- package/lib/typescript/events/index.d.ts +2 -0
- package/lib/typescript/events/interface.d.ts +1 -0
- package/lib/typescript/index.d.ts +5 -4
- package/lib/typescript/manager/dispatch/DispatchStateContainer.d.ts +21 -8
- package/lib/typescript/manager/dispatchCodes/EventCodeContainer.d.ts +12 -1
- package/lib/typescript/manager/dispatchCodes/EventCodeRepo.d.ts +13 -0
- package/lib/typescript/manager/jobRemoval/JobRemovalManager.d.ts +6 -0
- package/lib/typescript/manager/sdk/DispatchSdkCache.d.ts +2 -0
- package/lib/typescript/manager/syncmanager/AppSyncManager.d.ts +1 -0
- package/lib/typescript/manager/syncmanager/DBConfig.d.ts +22 -2
- package/lib/typescript/manager/syncmanager/database.d.ts +5 -0
- package/lib/typescript/manager/syncmanager/document/models.d.ts +1 -1
- package/lib/typescript/manager/syncmanager/events/ETEventsManager.d.ts +5 -1
- package/lib/typescript/manager/syncmanager/events/EventsSyncManager.d.ts +5 -1
- package/lib/typescript/manager/syncmanager/events/SyncHttpClient.d.ts +3 -1
- package/lib/typescript/models/DispatchModels.d.ts +56 -1
- package/lib/typescript/models/ReasonCodes.d.ts +5 -0
- package/lib/typescript/models/auth.d.ts +1 -1
- package/lib/typescript/models/execTasks/ETBaseModels.d.ts +27 -8
- package/lib/typescript/models/execTasks/ETConfig.d.ts +8 -4
- package/lib/typescript/models/sdk.d.ts +5 -0
- package/lib/typescript/native/signature/SignatureCapture.d.ts +1 -1
- package/lib/typescript/network/NetworkUtils.d.ts +1 -5
- package/lib/typescript/styles/SdkColors.d.ts +1 -0
- package/lib/typescript/styles/executionTasks/CommonStyles.d.ts +36 -0
- package/lib/typescript/ui/screens/ETScreensIndex.d.ts +3 -1
- package/lib/typescript/ui/screens/ScanScreen.d.ts +3 -0
- package/lib/typescript/ui/screens/ValidateOTPScreen.d.ts +3 -0
- package/lib/typescript/ui/uiConfig/RouteParams.d.ts +8 -0
- package/lib/typescript/utils/ApiUtils.d.ts +61 -0
- package/lib/typescript/utils/ExecTaskUtils.d.ts +7 -2
- package/lib/typescript/utils/NetworkUtil.d.ts +1 -1
- package/lib/typescript/utils/SyncManagerUtils.d.ts +3 -1
- package/lib/typescript/utils/hooks/useTimer.d.ts +5 -0
- package/lib/typescript/utils/storage.d.ts +17 -0
- package/package.json +23 -24
- package/tsconfig.json +9 -8
- package/file_unzip.js +0 -5
- package/mobile-execution-lib-0.6.4.tgz +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["StyleSheet","SdkColors","ColorTheme","Fonts","deliverETStyles","create","item","padding","marginTop","title","fontSize","footerButtonStyles","flexDirection","width","input","marginBottom","footerComponent","flex","marginStart","marginEnd","marginRight","position","bottom","errorText","color","fontStyle","CommonStyles","alignCenter","alignItems","flexRow","mainContainer","backgroundColor","nextButton","LIGHT","primaryButton","nextButtonLabel","fontFamily","lineHeight","letterSpacing","textAlign","fontWeight","cancelButton","borderWidth","borderColor","cancelButtonLabel","IBMPlexSans_600SemiBold","justifyContent","
|
|
1
|
+
{"version":3,"names":["StyleSheet","SdkColors","ColorTheme","Fonts","deliverETStyles","create","item","padding","marginTop","title","fontSize","footerButtonStyles","flexDirection","width","input","marginBottom","footerComponent","flex","marginStart","marginEnd","marginRight","position","bottom","errorText","color","fontStyle","CommonStyles","alignCenter","alignItems","flexRow","mainContainer","backgroundColor","nextButton","LIGHT","primaryButton","nextButtonLabel","fontFamily","lineHeight","letterSpacing","textAlign","fontWeight","cancelButton","borderWidth","borderColor","cancelButtonLabel","IBMPlexSans_600SemiBold","exitButton","exitButtonLabel","justifyContent","modalContent","modalView","borderRadius","subText","DeliverPickupStyles","itemTextStyle","IBMPlexSans_400Regular","flatList","titleText","messageText"],"sources":["CommonStyles.ts"],"sourcesContent":["import { StyleSheet } from 'react-native';\nimport SdkColors, { ColorTheme } from '../SdkColors';\n\nexport enum Fonts {\n IBMPlexSans_400Regular = 'IBMPlexSans_400Regular',\n IBMPlexSans_600SemiBold = 'IBMPlexSans_600SemiBold',\n IBMPlexSans_300Light = 'IBMPlexSans_300Light',\n IBMPlexSans_700Bold = 'IBMPlexSans_700Bold',\n IBMPlexSans_100Thin = 'IBMPlexSans_100Thin',\n IBMPlexSans_100Thin_Italic = 'IBMPlexSans_100Thin_Italic',\n IBMPlexSans_200ExtraLight = 'IBMPlexSans_200ExtraLight',\n IBMPlexSans_200ExtraLight_Italic = 'IBMPlexSans_200ExtraLight_Italic',\n IBMPlexSans_300Light_Italic = 'IBMPlexSans_300Light_Italic',\n IBMPlexSans_400Regular_Italic = 'IBMPlexSans_400Regular_Italic',\n IBMPlexSans_500Medium = 'IBMPlexSans_500Medium',\n IBMPlexSans_500Medium_Italic = 'IBMPlexSans_500Medium_Italic',\n IBMPlexSans_600SemiBold_Italic = 'IBMPlexSans_600SemiBold_Italic',\n IBMPlexSans_700Bold_Italic = 'IBMPlexSans_700Bold_Italic',\n}\nexport const deliverETStyles = StyleSheet.create({\n item: {\n padding: 2,\n marginTop: 8,\n },\n title: {\n fontSize: 16,\n },\n footerButtonStyles: {\n flexDirection: 'row',\n width: '100%',\n },\n input: {\n marginTop: 12,\n marginBottom: 10,\n },\n footerComponent: {\n flex: 1,\n marginStart: 8,\n marginEnd: 8,\n marginRight: 8,\n width: '100%',\n position: 'absolute',\n bottom: 10,\n },\n errorText: {\n color: 'red',\n fontSize: 16,\n fontStyle: 'normal',\n },\n});\nexport const CommonStyles = StyleSheet.create({\n alignCenter: {\n flex: 1,\n alignItems: 'center',\n },\n flexRow: {\n flex: 1,\n flexDirection: 'row',\n },\n mainContainer: {\n flex: 1,\n backgroundColor: '#f9f9f9',\n },\n nextButton: {\n backgroundColor: SdkColors[ColorTheme.LIGHT].primaryButton,\n },\n nextButtonLabel: {\n color: '#ffffff',\n fontFamily: 'IBMPlexSans_600SemiBold',\n fontSize: 14,\n lineHeight: 20,\n letterSpacing: 1.56,\n textAlign: 'center',\n fontStyle: 'normal',\n fontWeight: '600',\n },\n cancelButton: {\n borderWidth: 1,\n borderColor: SdkColors[ColorTheme.LIGHT].primaryButton,\n },\n cancelButtonLabel: {\n color: SdkColors[ColorTheme.LIGHT].primaryButton,\n fontFamily: Fonts.IBMPlexSans_600SemiBold,\n fontSize: 14,\n fontWeight: '600',\n lineHeight: 20,\n letterSpacing: 1.56,\n textAlign: 'center',\n fontStyle: 'normal',\n },\n exitButton: {\n borderWidth: 1,\n borderColor: SdkColors[ColorTheme.LIGHT].exitButton,\n },\n exitButtonLabel: {\n color: SdkColors[ColorTheme.LIGHT].exitButton,\n fontFamily: Fonts.IBMPlexSans_600SemiBold,\n fontSize: 14,\n fontWeight: '600',\n lineHeight: 20,\n letterSpacing: 1.56,\n textAlign: 'center',\n fontStyle: 'normal',\n },\n bottom: {\n flex: 1,\n justifyContent: 'flex-end',\n marginBottom: 10,\n },\n modalContent: {\n marginStart: 60,\n marginEnd: 60,\n flex: 1,\n marginBottom: 60,\n },\n modalView: {\n backgroundColor: 'white',\n padding: 15,\n borderRadius: 9,\n },\n subText: {\n justifyContent: 'center',\n fontFamily: 'IBMPlexSans_400Regular',\n fontStyle: 'normal',\n fontSize: 14,\n letterSpacing: 0.25,\n lineHeight: 20,\n textAlign: 'center',\n color: '#000000',\n marginBottom: 10,\n },\n});\nexport const DeliverPickupStyles = StyleSheet.create({\n itemTextStyle: {\n fontFamily: Fonts.IBMPlexSans_400Regular,\n color: '#111111',\n textAlign: 'center',\n alignItems: 'center',\n justifyContent: 'center',\n },\n mainContainer: {\n flex: 1,\n backgroundColor: 'rgba(61, 68, 92, 0.7)',\n },\n modalContent: {\n marginStart: 60,\n marginEnd: 60,\n flex: 1,\n marginBottom: 60,\n },\n flatList: {\n marginTop: 7,\n },\n modalView: {\n backgroundColor: 'white',\n padding: 15,\n borderRadius: 9,\n },\n titleText: {\n justifyContent: 'center',\n fontFamily: Fonts.IBMPlexSans_600SemiBold,\n fontStyle: 'normal',\n fontSize: 14,\n lineHeight: 20,\n textAlign: 'center',\n color: '#111111',\n },\n messageText: {\n marginTop: 10,\n justifyContent: 'center',\n fontFamily: Fonts.IBMPlexSans_400Regular,\n fontStyle: 'normal',\n fontWeight: '400',\n fontSize: 14,\n lineHeight: 20,\n textAlign: 'center',\n color: '#000000',\n },\n});\n"],"mappings":"AAAA,SAASA,UAAU,QAAQ,cAAc;AACzC,OAAOC,SAAS,IAAIC,UAAU,QAAQ,cAAc;AAEpD,WAAYC,KAAK,0BAALA,KAAK;EAALA,KAAK;EAALA,KAAK;EAALA,KAAK;EAALA,KAAK;EAALA,KAAK;EAALA,KAAK;EAALA,KAAK;EAALA,KAAK;EAALA,KAAK;EAALA,KAAK;EAALA,KAAK;EAALA,KAAK;EAALA,KAAK;EAALA,KAAK;EAAA,OAALA,KAAK;AAAA;AAgBjB,OAAO,MAAMC,eAAe,GAAGJ,UAAU,CAACK,MAAM,CAAC;EAC/CC,IAAI,EAAE;IACJC,OAAO,EAAE,CAAC;IACVC,SAAS,EAAE;EACb,CAAC;EACDC,KAAK,EAAE;IACLC,QAAQ,EAAE;EACZ,CAAC;EACDC,kBAAkB,EAAE;IAClBC,aAAa,EAAE,KAAK;IACpBC,KAAK,EAAE;EACT,CAAC;EACDC,KAAK,EAAE;IACLN,SAAS,EAAE,EAAE;IACbO,YAAY,EAAE;EAChB,CAAC;EACDC,eAAe,EAAE;IACfC,IAAI,EAAE,CAAC;IACPC,WAAW,EAAE,CAAC;IACdC,SAAS,EAAE,CAAC;IACZC,WAAW,EAAE,CAAC;IACdP,KAAK,EAAE,MAAM;IACbQ,QAAQ,EAAE,UAAU;IACpBC,M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;EACnB,CAAC;EACDkB,YAAY,EAAE;IACZ/B,WAAW,EAAE,EAAE;IACfC,SAAS,EAAE,EAAE;IACbF,IAAI,EAAE,CAAC;IACPF,YAAY,EAAE;EAChB,CAAC;EACDyC,QAAQ,EAAE;IACRhD,SAAS,EAAE;EACb,CAAC;EACD0C,SAAS,EAAE;IACTnB,eAAe,EAAE,OAAO;IACxBxB,OAAO,EAAE,EAAE;IACX4C,YAAY,EAAE;EAChB,CAAC;EACDM,SAAS,EAAE;IACTT,cAAc,EAAE,QAAQ;IACxBZ,UAAU,EAAEjC,KAAK,CAAC0C,uBAAuB;IACzCpB,SAAS,EAAE,QAAQ;IACnBf,QAAQ,EAAE,EAAE;IACZ2B,UAAU,EAAE,EAAE;IACdE,SAAS,EAAE,QAAQ;IACnBf,KAAK,EAAE;EACT,CAAC;EACDkC,WAAW,EAAE;IACXlD,SAAS,EAAE,EAAE;IACbwC,cAAc,EAAE,QAAQ;IACxBZ,UAAU,EAAEjC,KAAK,CAACoD,sBAAsB;IACxC9B,SAAS,EAAE,QAAQ;IACnBe,UAAU,EAAE,KAAK;IACjB9B,QAAQ,EAAE,EAAE;IACZ2B,UAAU,EAAE,EAAE;IACdE,SAAS,EAAE,QAAQ;IACnBf,KAAK,EAAE;EACT;AACF,CAAC,CAAC"}
|
|
@@ -7,7 +7,6 @@ import ReasonCodeContainer from '../../manager/dispatchCodes/ReasonCodeContainer
|
|
|
7
7
|
import { RouteParams } from '../uiConfig/RouteParams';
|
|
8
8
|
import DispatchStateContainer from '../../manager/dispatch/DispatchStateContainer';
|
|
9
9
|
const instance = DispatchStateContainer.getInstance();
|
|
10
|
-
|
|
11
10
|
const CancellationScreen = _ref => {
|
|
12
11
|
let {
|
|
13
12
|
route,
|
|
@@ -15,27 +14,50 @@ const CancellationScreen = _ref => {
|
|
|
15
14
|
baseETProps
|
|
16
15
|
} = _ref;
|
|
17
16
|
const [reasons, setReasons] = useState([]);
|
|
17
|
+
const [events, setEvents] = useState([]);
|
|
18
18
|
useEffect(() => {
|
|
19
|
-
const
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
19
|
+
const reasonCodes = route.params[RouteParams.REASONS];
|
|
20
|
+
if (reasonCodes && reasonCodes.length) {
|
|
21
|
+
const values = [];
|
|
22
|
+
for (let reasonCode of reasonCodes) {
|
|
23
|
+
values.push(reasonCode.description);
|
|
24
|
+
}
|
|
25
|
+
setReasons(values);
|
|
26
|
+
}
|
|
27
|
+
const eventCodes = route.params[RouteParams.EVENT_CODES];
|
|
28
|
+
if (eventCodes && eventCodes.length) {
|
|
29
|
+
const e_values = [];
|
|
30
|
+
for (let eventCode of route.params[RouteParams.EVENT_CODES]) {
|
|
31
|
+
e_values.push(eventCode.description);
|
|
32
|
+
}
|
|
33
|
+
setEvents(e_values);
|
|
23
34
|
}
|
|
24
|
-
|
|
25
|
-
setReasons(values);
|
|
26
35
|
}, [route.params]);
|
|
27
|
-
return /*#__PURE__*/React.createElement(CancelET, {
|
|
36
|
+
return events.length || reasons.length ? /*#__PURE__*/React.createElement(CancelET, {
|
|
37
|
+
cancelEvent: route.params[RouteParams.CANCEL_EVENT] || '',
|
|
38
|
+
cancellationEvents: events,
|
|
28
39
|
cancellationReasons: reasons,
|
|
29
|
-
|
|
40
|
+
applicableCodes: route.params[RouteParams.APPLICABLE_CODES],
|
|
41
|
+
eventRows: route.params[RouteParams.EVENT_CODES],
|
|
42
|
+
onSubmitET: async (reason, eventCode, reasonsRow) => {
|
|
43
|
+
const isJobBasedOutput = route.params[RouteParams.IS_JOB_BASED_OUTPUT];
|
|
30
44
|
if (route.params[RouteParams.ET_SUCCESS]) {
|
|
31
|
-
route.params[RouteParams.
|
|
32
|
-
|
|
45
|
+
if (route.params[RouteParams.EVENT_CODES] && eventCode) {
|
|
46
|
+
if (isJobBasedOutput) route.params[RouteParams.ET_SUCCESS_RESPONSE].baseResponse.eventCode = eventCode;else route.params[RouteParams.ET_SUCCESS_RESPONSE].eventCode = eventCode;
|
|
47
|
+
} else if (eventCode) {
|
|
48
|
+
if (isJobBasedOutput) route.params[RouteParams.ET_SUCCESS_RESPONSE].baseResponse.eventCode = eventCode;else route.params[RouteParams.ET_SUCCESS_RESPONSE].eventCode = eventCode;
|
|
49
|
+
}
|
|
50
|
+
if (isJobBasedOutput) route.params[RouteParams.ET_SUCCESS_RESPONSE].baseResponse.reasonCode = ReasonCodeContainer.getReasonCodeFromText(reason, route.params[RouteParams.REASONS] ? route.params[RouteParams.REASONS] : reasonsRow);else route.params[RouteParams.ET_SUCCESS_RESPONSE].reasonCode = ReasonCodeContainer.getReasonCodeFromText(reason, route.params[RouteParams.REASONS] ? route.params[RouteParams.REASONS] : reasonsRow);
|
|
51
|
+
await instance.saveAndProceed(baseETProps, route.params[RouteParams.ET_SUCCESS_RESPONSE], route.params, navigation, route.params[RouteParams.IS_LAST_ET], isJobBasedOutput);
|
|
33
52
|
} else {
|
|
34
|
-
|
|
53
|
+
let _eventCodeOutput = '';
|
|
54
|
+
if (route.params[RouteParams.EVENT_CODES] && eventCode) {
|
|
55
|
+
_eventCodeOutput = eventCode;
|
|
56
|
+
} else if (eventCode) _eventCodeOutput = eventCode;
|
|
57
|
+
await instance.saveAndProceed(baseETProps, await getBaseETResponse(getEntityCodeByET(route.params[RouteParams.CURRENT_ET_NAME]), false, _eventCodeOutput ? _eventCodeOutput : getEventCodeByET(route.params[RouteParams.CURRENT_ET_NAME], false, route.params[RouteParams.EVENT_CODES] || []), ReasonCodeContainer.getReasonCodeFromText(reason, route.params[RouteParams.REASONS] ? route.params[RouteParams.REASONS] : reasonsRow)), route.params, navigation, route.params[RouteParams.IS_LAST_ET], isJobBasedOutput);
|
|
35
58
|
}
|
|
36
59
|
}
|
|
37
|
-
});
|
|
60
|
+
}) : null;
|
|
38
61
|
};
|
|
39
|
-
|
|
40
62
|
export default withBaseDispatchScreen(CancellationScreen);
|
|
41
63
|
//# sourceMappingURL=CancellationScreen.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["CancelET","React","useEffect","useState","getEventCodeByET","withBaseDispatchScreen","getBaseETResponse","getEntityCodeByET","ReasonCodeContainer","RouteParams","DispatchStateContainer","instance","getInstance","CancellationScreen","route","navigation","baseETProps","reasons","setReasons","
|
|
1
|
+
{"version":3,"names":["CancelET","React","useEffect","useState","getEventCodeByET","withBaseDispatchScreen","getBaseETResponse","getEntityCodeByET","ReasonCodeContainer","RouteParams","DispatchStateContainer","instance","getInstance","CancellationScreen","_ref","route","navigation","baseETProps","reasons","setReasons","events","setEvents","reasonCodes","params","REASONS","length","values","reasonCode","push","description","eventCodes","EVENT_CODES","e_values","eventCode","createElement","cancelEvent","CANCEL_EVENT","cancellationEvents","cancellationReasons","applicableCodes","APPLICABLE_CODES","eventRows","onSubmitET","reason","reasonsRow","isJobBasedOutput","IS_JOB_BASED_OUTPUT","ET_SUCCESS","ET_SUCCESS_RESPONSE","baseResponse","getReasonCodeFromText","saveAndProceed","IS_LAST_ET","_eventCodeOutput","CURRENT_ET_NAME"],"sources":["CancellationScreen.tsx"],"sourcesContent":["import CancelET from '../../components/executiontasks/cancellation/CancelET';\nimport React, { useEffect, useState } from 'react';\nimport { getEventCodeByET } from '../../manager/dispatchCodes/EventCodeContainer';\nimport withBaseDispatchScreen from './WithBaseDispatchScreen';\nimport type { BaseETProps } from '../../models/DispatchModels';\nimport {\n getBaseETResponse,\n getEntityCodeByET,\n} from '../../utils/ExecTaskUtils';\nimport ReasonCodeContainer from '../../manager/dispatchCodes/ReasonCodeContainer';\nimport type { EventsRow, ReasonsRow } from '../../manager/syncmanager/DBConfig';\nimport { RouteParams } from '../uiConfig/RouteParams';\nimport DispatchStateContainer from '../../manager/dispatch/DispatchStateContainer';\n\nconst instance = DispatchStateContainer.getInstance();\nconst CancellationScreen = ({\n route,\n navigation,\n baseETProps,\n}: {\n route: any;\n navigation: any;\n baseETProps: BaseETProps;\n}) => {\n const [reasons, setReasons] = useState<string[]>([]);\n const [events, setEvents] = useState<string[]>([]);\n useEffect(() => {\n const reasonCodes = route.params[RouteParams.REASONS];\n if (reasonCodes && reasonCodes.length) {\n const values: string[] = [];\n for (let reasonCode of reasonCodes as ReasonsRow[]) {\n values.push(reasonCode.description);\n }\n setReasons(values);\n }\n const eventCodes = route.params[RouteParams.EVENT_CODES];\n\n if (eventCodes && eventCodes.length) {\n const e_values: string[] = [];\n for (let eventCode of route.params[\n RouteParams.EVENT_CODES\n ] as EventsRow[]) {\n e_values.push(eventCode.description);\n }\n setEvents(e_values);\n }\n }, [route.params]);\n\n return events.length || reasons.length ? (\n <CancelET\n cancelEvent={route.params[RouteParams.CANCEL_EVENT] || ''}\n cancellationEvents={events}\n cancellationReasons={reasons}\n applicableCodes={route.params[RouteParams.APPLICABLE_CODES]}\n eventRows={route.params[RouteParams.EVENT_CODES]}\n onSubmitET={async (reason, eventCode, reasonsRow) => {\n const isJobBasedOutput = route.params[RouteParams.IS_JOB_BASED_OUTPUT];\n if (route.params[RouteParams.ET_SUCCESS]) {\n if (route.params[RouteParams.EVENT_CODES] && eventCode) {\n if (isJobBasedOutput)\n route.params[\n RouteParams.ET_SUCCESS_RESPONSE\n ].baseResponse.eventCode = eventCode;\n else\n route.params[RouteParams.ET_SUCCESS_RESPONSE].eventCode =\n eventCode;\n } else if (eventCode) {\n if (isJobBasedOutput)\n route.params[\n RouteParams.ET_SUCCESS_RESPONSE\n ].baseResponse.eventCode = eventCode;\n else\n route.params[RouteParams.ET_SUCCESS_RESPONSE].eventCode =\n eventCode;\n }\n\n if (isJobBasedOutput)\n route.params[\n RouteParams.ET_SUCCESS_RESPONSE\n ].baseResponse.reasonCode =\n ReasonCodeContainer.getReasonCodeFromText(\n reason,\n route.params[RouteParams.REASONS]\n ? route.params[RouteParams.REASONS]\n : reasonsRow\n );\n else\n route.params[RouteParams.ET_SUCCESS_RESPONSE].reasonCode =\n ReasonCodeContainer.getReasonCodeFromText(\n reason,\n route.params[RouteParams.REASONS]\n ? route.params[RouteParams.REASONS]\n : reasonsRow\n );\n\n await instance.saveAndProceed(\n baseETProps,\n route.params[RouteParams.ET_SUCCESS_RESPONSE],\n route.params,\n navigation,\n route.params[RouteParams.IS_LAST_ET],\n isJobBasedOutput\n );\n } else {\n let _eventCodeOutput = '';\n if (route.params[RouteParams.EVENT_CODES] && eventCode) {\n _eventCodeOutput = eventCode;\n } else if (eventCode) _eventCodeOutput = eventCode;\n\n await instance.saveAndProceed(\n baseETProps,\n await getBaseETResponse(\n getEntityCodeByET(route.params[RouteParams.CURRENT_ET_NAME]),\n false,\n _eventCodeOutput\n ? _eventCodeOutput\n : getEventCodeByET(\n route.params[RouteParams.CURRENT_ET_NAME],\n false,\n route.params[RouteParams.EVENT_CODES] || []\n ),\n ReasonCodeContainer.getReasonCodeFromText(\n reason,\n route.params[RouteParams.REASONS]\n ? route.params[RouteParams.REASONS]\n : reasonsRow\n )\n ),\n route.params,\n navigation,\n route.params[RouteParams.IS_LAST_ET],\n isJobBasedOutput\n );\n }\n }}\n />\n ) : null;\n};\nexport default withBaseDispatchScreen(CancellationScreen);\n"],"mappings":"AAAA,OAAOA,QAAQ,MAAM,uDAAuD;AAC5E,OAAOC,KAAK,IAAIC,SAAS,EAAEC,QAAQ,QAAQ,OAAO;AAClD,SAASC,gBAAgB,QAAQ,gDAAgD;AACjF,OAAOC,sBAAsB,MAAM,0BAA0B;AAE7D,SACEC,iBAAiB,EACjBC,iBAAiB,QACZ,2BAA2B;AAClC,OAAOC,mBAAmB,MAAM,iDAAiD;AAEjF,SAASC,WAAW,QAAQ,yBAAyB;AACrD,OAAOC,sBAAsB,MAAM,+CAA+C;AAElF,MAAMC,QAAQ,GAAGD,sBAAsB,CAACE,WAAW,EAAE;AACrD,MAAMC,kBAAkB,GAAGC,IAAA,IAQrB;EAAA,IARsB;IAC1BC,KAAK;IACLC,UAAU;IACVC;EAKF,CAAC,GAAAH,IAAA;EACC,MAAM,CAACI,OAAO,EAAEC,UAAU,CAAC,GAAGhB,QAAQ,CAAW,EAAE,CAAC;EACpD,MAA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AACD,eAAexC,sBAAsB,CAACQ,kBAAkB,CAAC"}
|
|
@@ -1,20 +1,22 @@
|
|
|
1
1
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
2
|
-
|
|
3
2
|
import { CaptureText } from '../../components/executiontasks/ExecutionTasksIndex';
|
|
4
|
-
import React, { useCallback, useState } from 'react';
|
|
3
|
+
import React, { useCallback, useEffect, useState } from 'react';
|
|
5
4
|
import withBaseDispatchScreen from './WithBaseDispatchScreen';
|
|
6
5
|
import { EntityCode, ExecutionTaskID } from '../../models/execTasks/ETConfig';
|
|
7
6
|
import DispatchStateContainer from '../../manager/dispatch/DispatchStateContainer';
|
|
8
7
|
import { RouteParams } from '../uiConfig/RouteParams';
|
|
9
8
|
import { View } from 'react-native';
|
|
10
9
|
import CancelOrderDialog from '../../components/widgets/CancelOrderDialog';
|
|
11
|
-
|
|
10
|
+
import { onTaskStart } from '../../utils/ExecTaskUtils';
|
|
12
11
|
const CaptureInputScreen = _ref => {
|
|
13
12
|
let {
|
|
14
13
|
route,
|
|
15
14
|
navigation,
|
|
16
15
|
baseETProps
|
|
17
16
|
} = _ref;
|
|
17
|
+
useEffect(() => {
|
|
18
|
+
onTaskStart(route.params[RouteParams.NEXT_STATES]);
|
|
19
|
+
}, []);
|
|
18
20
|
const [showAlert, setShowAlert] = useState(false);
|
|
19
21
|
const [sResponse, setResponse] = useState();
|
|
20
22
|
const submitOutput = useCallback(async response => {
|
|
@@ -25,6 +27,8 @@ const CaptureInputScreen = _ref => {
|
|
|
25
27
|
flex: 1
|
|
26
28
|
}
|
|
27
29
|
}, /*#__PURE__*/React.createElement(CaptureText, _extends({}, route.params[RouteParams.NEXT_STATES][0].nextState.data.input, {
|
|
30
|
+
navigation: navigation,
|
|
31
|
+
taskMeta: JSON.parse(route.params[RouteParams.NEXT_STATES][0].nextState.data.taskMeta || '{}'),
|
|
28
32
|
onSubmitET: async etResponse => {
|
|
29
33
|
if (etResponse.success) {
|
|
30
34
|
await submitOutput(etResponse);
|
|
@@ -47,6 +51,5 @@ const CaptureInputScreen = _ref => {
|
|
|
47
51
|
}
|
|
48
52
|
}));
|
|
49
53
|
};
|
|
50
|
-
|
|
51
54
|
export default withBaseDispatchScreen(CaptureInputScreen);
|
|
52
55
|
//# sourceMappingURL=CaptureInputScreen.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["CaptureText","React","useCallback","useState","withBaseDispatchScreen","EntityCode","ExecutionTaskID","DispatchStateContainer","RouteParams","View","CancelOrderDialog","CaptureInputScreen","route","navigation","baseETProps","showAlert","setShowAlert","sResponse","setResponse","submitOutput","response","getInstance","navigateToNextTask","success","CAPTURE_INPUT","
|
|
1
|
+
{"version":3,"names":["CaptureText","React","useCallback","useEffect","useState","withBaseDispatchScreen","EntityCode","ExecutionTaskID","DispatchStateContainer","RouteParams","View","CancelOrderDialog","onTaskStart","CaptureInputScreen","_ref","route","navigation","baseETProps","params","NEXT_STATES","showAlert","setShowAlert","sResponse","setResponse","submitOutput","response","getInstance","navigateToNextTask","success","CAPTURE_INPUT","createElement","style","flex","_extends","nextState","data","input","taskMeta","JSON","parse","onSubmitET","etResponse","_prevState","visible","onSubmit","value"],"sources":["CaptureInputScreen.tsx"],"sourcesContent":["import { CaptureText } from '../../components/executiontasks/ExecutionTasksIndex';\nimport React, { useCallback, useEffect, useState } from 'react';\nimport withBaseDispatchScreen from './WithBaseDispatchScreen';\nimport type { BaseETProps } from '../../models/DispatchModels';\nimport { EntityCode, ExecutionTaskID } from '../../models/execTasks/ETConfig';\nimport DispatchStateContainer from '../../manager/dispatch/DispatchStateContainer';\nimport { RouteParams } from '../uiConfig/RouteParams';\nimport { View } from 'react-native';\nimport CancelOrderDialog from '../../components/widgets/CancelOrderDialog';\nimport { onTaskStart } from '../../utils/ExecTaskUtils';\n\nconst CaptureInputScreen = ({\n route,\n navigation,\n baseETProps,\n}: {\n route: any;\n navigation: any;\n baseETProps: BaseETProps;\n}) => {\n useEffect(() => {\n onTaskStart(route.params[RouteParams.NEXT_STATES]);\n }, []);\n const [showAlert, setShowAlert] = useState(false);\n const [sResponse, setResponse] = useState<any>();\n const submitOutput = useCallback(\n async (response: any) => {\n await DispatchStateContainer.getInstance().navigateToNextTask(\n navigation,\n route,\n response,\n response.success,\n EntityCode.CAPTURE_INPUT,\n ExecutionTaskID.CAPTURE_INPUT,\n baseETProps,\n false\n );\n },\n [baseETProps, navigation, route]\n );\n return (\n <View style={{ flex: 1 }}>\n <CaptureText\n {...route.params[RouteParams.NEXT_STATES][0].nextState.data.input}\n navigation={navigation}\n taskMeta={JSON.parse(\n route.params[RouteParams.NEXT_STATES][0].nextState.data.taskMeta ||\n '{}'\n )}\n onSubmitET={async (etResponse) => {\n if (etResponse.success) {\n await submitOutput(etResponse);\n } else {\n setResponse((_prevState: any) => {\n setShowAlert(true);\n return etResponse;\n });\n }\n }}\n />\n <CancelOrderDialog\n visible={showAlert}\n onSubmit={async (value) => {\n if (value) {\n setShowAlert(false);\n await submitOutput(sResponse);\n } else {\n setShowAlert(false);\n }\n }}\n />\n </View>\n );\n};\nexport default withBaseDispatchScreen(CaptureInputScreen);\n"],"mappings":";AAAA,SAASA,WAAW,QAAQ,qDAAqD;AACjF,OAAOC,KAAK,IAAIC,WAAW,EAAEC,SAAS,EAAEC,QAAQ,QAAQ,OAAO;AAC/D,OAAOC,sBAAsB,MAAM,0BAA0B;AAE7D,SAASC,UAAU,EAAEC,eAAe,QAAQ,iCAAiC;AAC7E,OAAOC,sBAAsB,MAAM,+CAA+C;AAClF,SAASC,WAAW,QAAQ,yBAAyB;AACrD,SAASC,IAAI,QAAQ,cAAc;AACnC,OAAOC,iBAAiB,MAAM,4CAA4C;AAC1E,SAASC,WAAW,QAAQ,2BAA2B;AAEvD,MAAMC,kBAAkB,GAAGC,I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MJ,YAAY,CAACiB,UAAU,CAAC;MAChC,CAAC,MAAM;QACLlB,WAAW,CAAEmB,UAAe,IAAK;UAC/BrB,YAAY,CAAC,IAAI,CAAC;UAClB,OAAOoB,UAAU;QACnB,CAAC,CAAC;MACJ;IACF;EAAE,GACF,eACFxC,KAAA,CAAA6B,aAAA,CAACnB,iBAAiB;IAChBgC,OAAO,EAAEvB,SAAU;IACnBwB,QAAQ,EAAE,MAAOC,KAAK,IAAK;MACzB,IAAIA,KAAK,EAAE;QACTxB,YAAY,CAAC,KAAK,CAAC;QACnB,MAAMG,YAAY,CAACF,SAAS,CAAC;MAC/B,CAAC,MAAM;QACLD,YAAY,CAAC,KAAK,CAAC;MACrB;IACF;EAAE,EACF,CACG;AAEX,CAAC;AACD,eAAehB,sBAAsB,CAACQ,kBAAkB,CAAC"}
|
|
@@ -8,7 +8,6 @@ import withBaseDispatchScreen from './WithBaseDispatchScreen';
|
|
|
8
8
|
import Logger, { LOG_TYPE } from '../../utils/Logger';
|
|
9
9
|
import { showToast } from '../../components/widgets/Toaster';
|
|
10
10
|
import { RouteParams } from '../uiConfig/RouteParams';
|
|
11
|
-
|
|
12
11
|
const CompleteObjectiveScreen = _ref => {
|
|
13
12
|
let {
|
|
14
13
|
navigation,
|
|
@@ -30,13 +29,11 @@ const CompleteObjectiveScreen = _ref => {
|
|
|
30
29
|
showToast(error.message);
|
|
31
30
|
}
|
|
32
31
|
})();
|
|
33
|
-
|
|
34
32
|
return () => {
|
|
35
33
|
baseETProps.showProgress(false);
|
|
36
34
|
};
|
|
37
35
|
}, []);
|
|
38
36
|
return /*#__PURE__*/React.createElement(View, null);
|
|
39
37
|
};
|
|
40
|
-
|
|
41
38
|
export default withBaseDispatchScreen(CompleteObjectiveScreen);
|
|
42
39
|
//# sourceMappingURL=CompleteObjectiveScreen.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["View","React","useEffect","DispatchStateContainer","getObjectiveCompleteResp","getEventCodeByET","EntityCode","ExecutionTaskID","withBaseDispatchScreen","Logger","LOG_TYPE","showToast","RouteParams","CompleteObjectiveScreen","navigation","route","baseETProps","showProgress","etResponse","nextState","params","NEXT_STATES","entityCode","taskId","COMPLETED_SUCCESS","COMPLETED_FAILURE","getInstance","navigateToNextTask","success","error","logEvent","message","SDK_ERROR"],"sources":["CompleteObjectiveScreen.tsx"],"sourcesContent":["import { View } from 'react-native';\nimport React, { useEffect } from 'react';\nimport type { BaseETProps, stateWithObjRef } from '../../models/DispatchModels';\nimport DispatchStateContainer from '../../manager/dispatch/DispatchStateContainer';\nimport { getObjectiveCompleteResp } from '../../utils/ExecTaskUtils';\nimport { getEventCodeByET } from '../../manager/dispatchCodes/EventCodeContainer';\nimport { EntityCode, ExecutionTaskID } from '../../models/execTasks/ETConfig';\nimport withBaseDispatchScreen from './WithBaseDispatchScreen';\nimport Logger, { LOG_TYPE } from '../../utils/Logger';\nimport { showToast } from '../../components/widgets/Toaster';\nimport { RouteParams } from '../uiConfig/RouteParams';\n\nconst CompleteObjectiveScreen = ({\n navigation,\n route,\n baseETProps,\n}: {\n route: any;\n navigation: any;\n baseETProps: BaseETProps;\n}) => {\n useEffect(() => {\n (async () => {\n try {\n baseETProps.showProgress(true);\n let etResponse;\n let nextState: stateWithObjRef = route.params[\n RouteParams.NEXT_STATES\n ][0] as stateWithObjRef;\n const entityCode =\n nextState.nextState.taskId === ExecutionTaskID.COMPLETED_SUCCESS\n ? EntityCode.COMPLETED_SUCCESS\n : EntityCode.COMPLETED_FAILURE;\n etResponse = await getObjectiveCompleteResp(\n entityCode,\n true,\n getEventCodeByET(nextState.nextState.taskId, true),\n ''\n );\n await DispatchStateContainer.getInstance().navigateToNextTask(\n navigation,\n route,\n etResponse,\n etResponse.success,\n entityCode,\n nextState.nextState.taskId === ExecutionTaskID.COMPLETED_SUCCESS\n ? ExecutionTaskID.COMPLETED_SUCCESS\n : ExecutionTaskID.COMPLETED_FAILURE,\n baseETProps,\n true\n );\n } catch (error: any) {\n baseETProps.showProgress(false);\n Logger.getInstance().logEvent(\n 'COMPLETE_OBJECTIVE',\n error.message,\n LOG_TYPE.SDK_ERROR\n );\n showToast(error.message);\n }\n })();\n\n return () => {\n baseETProps.showProgress(false);\n };\n }, []);\n return <View />;\n};\nexport default withBaseDispatchScreen(CompleteObjectiveScreen);\n"],"mappings":"AAAA,SAASA,
|
|
1
|
+
{"version":3,"names":["View","React","useEffect","DispatchStateContainer","getObjectiveCompleteResp","getEventCodeByET","EntityCode","ExecutionTaskID","withBaseDispatchScreen","Logger","LOG_TYPE","showToast","RouteParams","CompleteObjectiveScreen","_ref","navigation","route","baseETProps","showProgress","etResponse","nextState","params","NEXT_STATES","entityCode","taskId","COMPLETED_SUCCESS","COMPLETED_FAILURE","getInstance","navigateToNextTask","success","error","logEvent","message","SDK_ERROR","createElement"],"sources":["CompleteObjectiveScreen.tsx"],"sourcesContent":["import { View } from 'react-native';\nimport React, { useEffect } from 'react';\nimport type { BaseETProps, stateWithObjRef } from '../../models/DispatchModels';\nimport DispatchStateContainer from '../../manager/dispatch/DispatchStateContainer';\nimport { getObjectiveCompleteResp } from '../../utils/ExecTaskUtils';\nimport { getEventCodeByET } from '../../manager/dispatchCodes/EventCodeContainer';\nimport { EntityCode, ExecutionTaskID } from '../../models/execTasks/ETConfig';\nimport withBaseDispatchScreen from './WithBaseDispatchScreen';\nimport Logger, { LOG_TYPE } from '../../utils/Logger';\nimport { showToast } from '../../components/widgets/Toaster';\nimport { RouteParams } from '../uiConfig/RouteParams';\n\nconst CompleteObjectiveScreen = ({\n navigation,\n route,\n baseETProps,\n}: {\n route: any;\n navigation: any;\n baseETProps: BaseETProps;\n}) => {\n useEffect(() => {\n (async () => {\n try {\n baseETProps.showProgress(true);\n let etResponse;\n let nextState: stateWithObjRef = route.params[\n RouteParams.NEXT_STATES\n ][0] as stateWithObjRef;\n const entityCode =\n nextState.nextState.taskId === ExecutionTaskID.COMPLETED_SUCCESS\n ? EntityCode.COMPLETED_SUCCESS\n : EntityCode.COMPLETED_FAILURE;\n etResponse = await getObjectiveCompleteResp(\n entityCode,\n true,\n getEventCodeByET(nextState.nextState.taskId, true),\n ''\n );\n await DispatchStateContainer.getInstance().navigateToNextTask(\n navigation,\n route,\n etResponse,\n etResponse.success,\n entityCode,\n nextState.nextState.taskId === ExecutionTaskID.COMPLETED_SUCCESS\n ? ExecutionTaskID.COMPLETED_SUCCESS\n : ExecutionTaskID.COMPLETED_FAILURE,\n baseETProps,\n true\n );\n } catch (error: any) {\n baseETProps.showProgress(false);\n Logger.getInstance().logEvent(\n 'COMPLETE_OBJECTIVE',\n error.message,\n LOG_TYPE.SDK_ERROR\n );\n showToast(error.message);\n }\n })();\n\n return () => {\n baseETProps.showProgress(false);\n };\n }, []);\n return <View />;\n};\nexport default withBaseDispatchScreen(CompleteObjectiveScreen);\n"],"mappings":"AAAA,SAASA,IAAI,QAAQ,cAAc;AACnC,OAAOC,KAAK,IAAIC,SAAS,QAAQ,OAAO;AAExC,OAAOC,sBAAsB,MAAM,+CAA+C;AAClF,SAASC,wBAAwB,QAAQ,2BAA2B;AACpE,SAASC,gBAAgB,QAAQ,gDAAgD;AACjF,SAASC,UAAU,EAAEC,eAAe,QAAQ,iCAAiC;AAC7E,OAAOC,sBAAsB,MAAM,0BAA0B;AAC7D,OAAOC,MAAM,IAAIC,QAAQ,QAAQ,oBAAoB;AACrD,SAASC,SAAS,QAAQ,kCAAkC;AAC5D,SAASC,WAAW,QAAQ,yBAAyB;AAErD,MAAMC,uBAAuB,GAAGC,IAAA,IAQ1B;EAAA,IAR2B;IAC/BC,UAAU;IACVC,KAAK;IACLC;EAKF,CAAC,GAAAH,IAAA;EACCZ,SAAS,CAAC,MAAM;IACd,CAAC,YAAY;MACX,IAAI;QACFe,WAAW,CAACC,YAAY,CAAC,IAAI,CAAC;QAC9B,IAAIC,UAAU;QACd,IAAIC,SAA0B,GAAGJ,KAAK,CAACK,MAAM,CAC3CT,WAAW,CAACU,WAAW,CACxB,CAAC,CAAC,CAAoB;QACvB,MAAMC,UAAU,GACdH,SAAS,CAACA,SAAS,CAACI,MAAM,KAAKjB,eAAe,CAACkB,iBAAiB,GAC5DnB,UAAU,CAACmB,iBAAiB,GAC5BnB,UAAU,CAACoB,iBAAiB;QAClCP,UAAU,GAAG,MAAMf,wBAAwB,CACzCmB,UAAU,EACV,IAAI,EACJlB,gBAAgB,CAACe,SAAS,CAACA,SAAS,CAACI,MAAM,EAAE,IAAI,CAAC,EAClD,EAAE,CACH;QACD,MAAMrB,sBAAsB,CAACwB,WAAW,EAAE,CAACC,kBAAkB,CAC3Db,UAAU,EACVC,KAAK,EACLG,UAAU,EACVA,UAAU,CAACU,OAAO,EAClBN,UAAU,EACVH,SAAS,CAACA,SAAS,CAACI,MAAM,KAAKjB,eAAe,CAACkB,iBAAiB,GAC5DlB,eAAe,CAACkB,iBAAiB,GACjClB,eAAe,CAACmB,iBAAiB,EACrCT,WAAW,EACX,IAAI,CACL;MACH,CAAC,CAAC,OAAOa,KAAU,EAAE;QACnBb,WAAW,CAACC,YAAY,CAAC,KAAK,CAAC;QAC/BT,MAAM,CAACkB,WAAW,EAAE,CAACI,QAAQ,CAC3B,oBAAoB,EACpBD,KAAK,CAACE,OAAO,EACbtB,QAAQ,CAACuB,SAAS,CACnB;QACDtB,SAAS,CAACmB,KAAK,CAACE,OAAO,CAAC;MAC1B;IACF,CAAC,GAAG;IAEJ,OAAO,MAAM;MACXf,WAAW,CAACC,YAAY,CAAC,KAAK,CAAC;IACjC,CAAC;EACH,CAAC,EAAE,EAAE,CAAC;EACN,oBAAOjB,KAAA,CAAAiC,aAAA,CAAClC,IAAI,OAAG;AACjB,CAAC;AACD,eAAeQ,sBAAsB,CAACK,uBAAuB,CAAC"}
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
2
|
-
|
|
3
|
-
import React, { useCallback, useState } from 'react';
|
|
2
|
+
import React, { useCallback, useEffect, useState } from 'react';
|
|
4
3
|
import withBaseDispatchScreen from './WithBaseDispatchScreen';
|
|
5
4
|
import { EntityCode, ExecutionTaskID } from '../../models/execTasks/ETConfig';
|
|
6
5
|
import DispatchStateContainer from '../../manager/dispatch/DispatchStateContainer';
|
|
@@ -8,13 +7,16 @@ import SLDeliverET from '../../components/executiontasks/deliver/SLDeliverET';
|
|
|
8
7
|
import { RouteParams } from '../uiConfig/RouteParams';
|
|
9
8
|
import { View } from 'react-native';
|
|
10
9
|
import CancelOrderDialog from '../../components/widgets/CancelOrderDialog';
|
|
11
|
-
|
|
10
|
+
import { onTaskStart } from '../../utils/ExecTaskUtils';
|
|
12
11
|
const DeliverScreen = _ref => {
|
|
13
12
|
let {
|
|
14
13
|
navigation,
|
|
15
14
|
route,
|
|
16
15
|
baseETProps
|
|
17
16
|
} = _ref;
|
|
17
|
+
useEffect(() => {
|
|
18
|
+
onTaskStart(route.params[RouteParams.NEXT_STATES]);
|
|
19
|
+
}, []);
|
|
18
20
|
const [showAlert, setShowAlert] = useState(false);
|
|
19
21
|
const [sResponse, setResponse] = useState();
|
|
20
22
|
const submitOutput = useCallback(async deliverOutput => {
|
|
@@ -25,6 +27,8 @@ const DeliverScreen = _ref => {
|
|
|
25
27
|
flex: 1
|
|
26
28
|
}
|
|
27
29
|
}, /*#__PURE__*/React.createElement(SLDeliverET, _extends({}, route.params[RouteParams.NEXT_STATES][0].nextState.data.input, {
|
|
30
|
+
navigation: navigation,
|
|
31
|
+
taskMeta: JSON.parse(route.params[RouteParams.NEXT_STATES][0].nextState.data.taskMeta || '{}'),
|
|
28
32
|
returnPackageCount: route.params[RouteParams.NEXT_STATES].length,
|
|
29
33
|
onSubmitET: async deliverOutput => {
|
|
30
34
|
if (deliverOutput.success) {
|
|
@@ -48,6 +52,5 @@ const DeliverScreen = _ref => {
|
|
|
48
52
|
}
|
|
49
53
|
}));
|
|
50
54
|
};
|
|
51
|
-
|
|
52
55
|
export default withBaseDispatchScreen(DeliverScreen);
|
|
53
56
|
//# sourceMappingURL=DeliverScreen.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","useCallback","useState","withBaseDispatchScreen","EntityCode","ExecutionTaskID","DispatchStateContainer","SLDeliverET","RouteParams","View","CancelOrderDialog","DeliverScreen","navigation","route","baseETProps","showAlert","setShowAlert","sResponse","setResponse","submitOutput","deliverOutput","getInstance","navigateToNextTask","success","DELIVER","
|
|
1
|
+
{"version":3,"names":["React","useCallback","useEffect","useState","withBaseDispatchScreen","EntityCode","ExecutionTaskID","DispatchStateContainer","SLDeliverET","RouteParams","View","CancelOrderDialog","onTaskStart","DeliverScreen","_ref","navigation","route","baseETProps","params","NEXT_STATES","showAlert","setShowAlert","sResponse","setResponse","submitOutput","deliverOutput","getInstance","navigateToNextTask","success","DELIVER","createElement","style","flex","_extends","nextState","data","input","taskMeta","JSON","parse","returnPackageCount","length","onSubmitET","_prevState","visible","onSubmit","value"],"sources":["DeliverScreen.tsx"],"sourcesContent":["import React, { useCallback, useEffect, useState } from 'react';\nimport withBaseDispatchScreen from './WithBaseDispatchScreen';\nimport type { BaseETProps } from '../../models/DispatchModels';\nimport { EntityCode, ExecutionTaskID } from '../../models/execTasks/ETConfig';\nimport DispatchStateContainer from '../../manager/dispatch/DispatchStateContainer';\nimport SLDeliverET from '../../components/executiontasks/deliver/SLDeliverET';\nimport { RouteParams } from '../uiConfig/RouteParams';\nimport { View } from 'react-native';\nimport CancelOrderDialog from '../../components/widgets/CancelOrderDialog';\nimport { onTaskStart } from '../../utils/ExecTaskUtils';\n\nconst DeliverScreen = ({\n navigation,\n route,\n baseETProps,\n}: {\n route: any;\n navigation: any;\n baseETProps: BaseETProps;\n}) => {\n useEffect(() => {\n onTaskStart(route.params[RouteParams.NEXT_STATES]);\n }, []);\n const [showAlert, setShowAlert] = useState(false);\n const [sResponse, setResponse] = useState<any>();\n const submitOutput = useCallback(\n async (deliverOutput: any) => {\n await DispatchStateContainer.getInstance().navigateToNextTask(\n navigation,\n route,\n deliverOutput,\n deliverOutput.success,\n EntityCode.DELIVER,\n ExecutionTaskID.DELIVER,\n baseETProps,\n false\n );\n },\n [baseETProps, navigation, route]\n );\n return (\n <View style={{ flex: 1 }}>\n <SLDeliverET\n {...route.params[RouteParams.NEXT_STATES][0].nextState.data.input}\n navigation={navigation}\n taskMeta={JSON.parse(\n route.params[RouteParams.NEXT_STATES][0].nextState.data.taskMeta ||\n '{}'\n )}\n returnPackageCount={route.params[RouteParams.NEXT_STATES].length}\n onSubmitET={async (deliverOutput) => {\n if (deliverOutput.success) {\n await submitOutput(deliverOutput);\n } else {\n setResponse((_prevState: any) => {\n setShowAlert(true);\n return deliverOutput;\n });\n }\n }}\n />\n <CancelOrderDialog\n visible={showAlert}\n onSubmit={async (value) => {\n if (value) {\n setShowAlert(false);\n await submitOutput(sResponse);\n } else {\n setShowAlert(false);\n }\n }}\n />\n </View>\n );\n};\nexport default withBaseDispatchScreen(DeliverScreen);\n"],"mappings":";AAAA,OAAOA,KAAK,IAAIC,WAAW,EAAEC,SAAS,EAAEC,QAAQ,QAAQ,OAAO;AAC/D,OAAOC,sBAAsB,MAAM,0BAA0B;AAE7D,SAASC,UAAU,EAAEC,eAAe,QAAQ,iCAAiC;AAC7E,OAAOC,sBAAsB,MAAM,+CAA+C;AAClF,OAAOC,WAAW,MAAM,qDAAqD;AAC7E,SAASC,WAAW,QAAQ,yBAAyB;AACrD,SAASC,IAAI,QAAQ,cAAc;AACnC,OAAOC,iBAAiB,MAAM,4CAA4C;AAC1E,SAASC,WAAW,QAAQ,2BAA2B;AAEvD,MAAMC,aAAa,GAAGC,IAAA,IAQhB;EAAA,IARiB;IACrBC,UAAU;IACVC,KAAK;IACLC;EAKF,CAAC,GAAAH,IAAA;EACCZ,SAAS,CAAC,MAAM;IACdU,WAAW,CA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,CAAC,MAAM;QACLF,WAAW,CAAEoB,UAAe,IAAK;UAC/BtB,YAAY,CAAC,IAAI,CAAC;UAClB,OAAOI,aAAa;QACtB,CAAC,CAAC;MACJ;IACF;EAAE,GACF,eACFzB,KAAA,CAAA8B,aAAA,CAACnB,iBAAiB;IAChBiC,OAAO,EAAExB,SAAU;IACnByB,QAAQ,EAAE,MAAOC,KAAK,IAAK;MACzB,IAAIA,KAAK,EAAE;QACTzB,YAAY,CAAC,KAAK,CAAC;QACnB,MAAMG,YAAY,CAACF,SAAS,CAAC;MAC/B,CAAC,MAAM;QACLD,YAAY,CAAC,KAAK,CAAC;MACrB;IACF;EAAE,EACF,CACG;AAEX,CAAC;AACD,eAAejB,sBAAsB,CAACS,aAAa,CAAC"}
|
|
@@ -1,18 +1,20 @@
|
|
|
1
1
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
2
|
-
|
|
3
|
-
import React from 'react';
|
|
2
|
+
import React, { useEffect } from 'react';
|
|
4
3
|
import withBaseDispatchScreen from './WithBaseDispatchScreen';
|
|
5
4
|
import { DisplayModalET } from '../../components/executiontasks/ExecutionTasksIndex';
|
|
6
5
|
import { EntityCode, ExecutionTaskID } from '../../models/execTasks/ETConfig';
|
|
7
6
|
import DispatchStateContainer from '../../manager/dispatch/DispatchStateContainer';
|
|
8
7
|
import { RouteParams } from '../uiConfig/RouteParams';
|
|
9
|
-
|
|
8
|
+
import { onTaskStart } from '../../utils/ExecTaskUtils';
|
|
10
9
|
const DisplayScreen = _ref => {
|
|
11
10
|
let {
|
|
12
11
|
route,
|
|
13
12
|
navigation,
|
|
14
13
|
baseETProps
|
|
15
14
|
} = _ref;
|
|
15
|
+
useEffect(() => {
|
|
16
|
+
onTaskStart(route.params[RouteParams.NEXT_STATES]);
|
|
17
|
+
}, []);
|
|
16
18
|
return /*#__PURE__*/React.createElement(DisplayModalET, _extends({}, route.params[RouteParams.NEXT_STATES][0].nextState.data.input, {
|
|
17
19
|
positiveBtn: 'Submit',
|
|
18
20
|
showDialog: true,
|
|
@@ -22,6 +24,5 @@ const DisplayScreen = _ref => {
|
|
|
22
24
|
}
|
|
23
25
|
}));
|
|
24
26
|
};
|
|
25
|
-
|
|
26
27
|
export default withBaseDispatchScreen(DisplayScreen);
|
|
27
28
|
//# sourceMappingURL=DisplayScreen.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","withBaseDispatchScreen","DisplayModalET","EntityCode","ExecutionTaskID","DispatchStateContainer","RouteParams","DisplayScreen","route","navigation","baseETProps","params","NEXT_STATES","nextState","data","input","displayOutput","getInstance","navigateToNextTask","success","DISPLAY"],"sources":["DisplayScreen.tsx"],"sourcesContent":["import React from 'react';\nimport withBaseDispatchScreen from './WithBaseDispatchScreen';\nimport { DisplayModalET } from '../../components/executiontasks/ExecutionTasksIndex';\nimport type { BaseETProps } from '../../models/DispatchModels';\nimport { EntityCode, ExecutionTaskID } from '../../models/execTasks/ETConfig';\nimport DispatchStateContainer from '../../manager/dispatch/DispatchStateContainer';\nimport { RouteParams } from '../uiConfig/RouteParams';\n\nconst DisplayScreen = ({\n route,\n navigation,\n baseETProps,\n}: {\n route: any;\n navigation: any;\n baseETProps: BaseETProps;\n}) => {\n return (\n <DisplayModalET\n {...route.params[RouteParams.NEXT_STATES][0].nextState.data.input}\n positiveBtn={'Submit'}\n showDialog={true}\n negativeBtn={'Cancel'}\n onSubmit={async (displayOutput) => {\n await DispatchStateContainer.getInstance().navigateToNextTask(\n navigation,\n route,\n displayOutput,\n displayOutput.success,\n EntityCode.DISPLAY,\n ExecutionTaskID.DISPLAY,\n baseETProps,\n false\n );\n }}\n />\n );\n};\n\nexport default withBaseDispatchScreen(DisplayScreen);\n"],"mappings":"
|
|
1
|
+
{"version":3,"names":["React","useEffect","withBaseDispatchScreen","DisplayModalET","EntityCode","ExecutionTaskID","DispatchStateContainer","RouteParams","onTaskStart","DisplayScreen","_ref","route","navigation","baseETProps","params","NEXT_STATES","createElement","_extends","nextState","data","input","positiveBtn","showDialog","negativeBtn","onSubmit","displayOutput","getInstance","navigateToNextTask","success","DISPLAY"],"sources":["DisplayScreen.tsx"],"sourcesContent":["import React, { useEffect } from 'react';\nimport withBaseDispatchScreen from './WithBaseDispatchScreen';\nimport { DisplayModalET } from '../../components/executiontasks/ExecutionTasksIndex';\nimport type { BaseETProps } from '../../models/DispatchModels';\nimport { EntityCode, ExecutionTaskID } from '../../models/execTasks/ETConfig';\nimport DispatchStateContainer from '../../manager/dispatch/DispatchStateContainer';\nimport { RouteParams } from '../uiConfig/RouteParams';\nimport { onTaskStart } from '../../utils/ExecTaskUtils';\n\nconst DisplayScreen = ({\n route,\n navigation,\n baseETProps,\n}: {\n route: any;\n navigation: any;\n baseETProps: BaseETProps;\n}) => {\n useEffect(() => {\n onTaskStart(route.params[RouteParams.NEXT_STATES]);\n }, []);\n return (\n <DisplayModalET\n {...route.params[RouteParams.NEXT_STATES][0].nextState.data.input}\n positiveBtn={'Submit'}\n showDialog={true}\n negativeBtn={'Cancel'}\n onSubmit={async (displayOutput) => {\n await DispatchStateContainer.getInstance().navigateToNextTask(\n navigation,\n route,\n displayOutput,\n displayOutput.success,\n EntityCode.DISPLAY,\n ExecutionTaskID.DISPLAY,\n baseETProps,\n false\n );\n }}\n />\n );\n};\n\nexport default withBaseDispatchScreen(DisplayScreen);\n"],"mappings":";AAAA,OAAOA,KAAK,IAAIC,SAAS,QAAQ,OAAO;AACxC,OAAOC,sBAAsB,MAAM,0BAA0B;AAC7D,SAASC,cAAc,QAAQ,qDAAqD;AAEpF,SAASC,UAAU,EAAEC,eAAe,QAAQ,iCAAiC;AAC7E,OAAOC,sBAAsB,MAAM,+CAA+C;AAClF,SAASC,WAAW,QAAQ,yBAAyB;AACrD,SAASC,WAAW,QAAQ,2BAA2B;AAEvD,MAAMC,aAAa,GAAGC,IAAA,IAQhB;EAAA,IARiB;IACrBC,KAAK;IACLC,UAAU;IACVC;EAKF,CAAC,GAAAH,IAAA;EACCT,SAAS,CAAC,MAAM;IACdO,WAAW,CAACG,KAAK,CAACG,MAAM,CAACP,WAAW,CAACQ,WAAW,CAAC,CAAC;EACpD,CAAC,EAAE,EAAE,CAAC;EACN,oBACEf,KAAA,CAAAgB,aAAA,CAACb,cAAc,EAAAc,QAAA,KACTN,KAAK,CAACG,MAAM,CAACP,WAAW,CAACQ,WAAW,CAAC,CAAC,CAAC,CAAC,CAACG,SAAS,CAACC,IAAI,CAACC,KAAK;IACjEC,WAAW,EAAE,QAAS;IACtBC,UAAU,EAAE,IAAK;IACjBC,WAAW,EAAE,QAAS;IACtBC,QAAQ,EAAE,MAAOC,aAAa,IAAK;MACjC,MAAMnB,sBAAsB,CAACoB,WAAW,EAAE,CAACC,kBAAkB,CAC3Df,UAAU,EACVD,KAAK,EACLc,aAAa,EACbA,aAAa,CAACG,OAAO,EACrBxB,UAAU,CAACyB,OAAO,EAClBxB,eAAe,CAACwB,OAAO,EACvBhB,WAAW,EACX,KAAK,CACN;IACH;EAAE,GACF;AAEN,CAAC;AAED,eAAeX,sBAAsB,CAACO,aAAa,CAAC"}
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
2
|
-
|
|
3
2
|
import SignatureET from '../../components/executiontasks/doodle/SignatureET';
|
|
4
|
-
import React, { useCallback, useState } from 'react';
|
|
3
|
+
import React, { useCallback, useEffect, useState } from 'react';
|
|
5
4
|
import withBaseDispatchScreen from './WithBaseDispatchScreen';
|
|
6
5
|
import { EntityCode, ExecutionTaskID } from '../../models/execTasks/ETConfig';
|
|
7
6
|
import DispatchStateContainer from '../../manager/dispatch/DispatchStateContainer';
|
|
@@ -9,13 +8,16 @@ import { RouteParams } from '../uiConfig/RouteParams';
|
|
|
9
8
|
import { View } from 'react-native';
|
|
10
9
|
import CancelOrderDialog from '../../components/widgets/CancelOrderDialog';
|
|
11
10
|
import { getJobIDs, getObjectiveRefs } from '../../components/executiontasks/doodle/DoodleUtils';
|
|
12
|
-
|
|
11
|
+
import { onTaskStart } from '../../utils/ExecTaskUtils';
|
|
13
12
|
const DoodleScreen = _ref => {
|
|
14
13
|
let {
|
|
15
14
|
route,
|
|
16
15
|
navigation,
|
|
17
16
|
baseETProps
|
|
18
17
|
} = _ref;
|
|
18
|
+
useEffect(() => {
|
|
19
|
+
onTaskStart(route.params[RouteParams.NEXT_STATES]);
|
|
20
|
+
}, []);
|
|
19
21
|
const [showAlert, setShowAlert] = useState(false);
|
|
20
22
|
const [sResponse, setResponse] = useState();
|
|
21
23
|
const submitOutput = useCallback(async base64Data => {
|
|
@@ -28,6 +30,8 @@ const DoodleScreen = _ref => {
|
|
|
28
30
|
}, /*#__PURE__*/React.createElement(SignatureET, _extends({}, route.params[RouteParams.NEXT_STATES][0].nextState.data.input, {
|
|
29
31
|
jobIDs: getJobIDs(route.params[RouteParams.NEXT_STATES]),
|
|
30
32
|
objRefs: getObjectiveRefs(route.params[RouteParams.NEXT_STATES]),
|
|
33
|
+
navigation: navigation,
|
|
34
|
+
taskMeta: JSON.parse(route.params[RouteParams.NEXT_STATES][0].nextState.data.taskMeta || '{}'),
|
|
31
35
|
onSubmitET: async base64Data => {
|
|
32
36
|
if (base64Data.success) {
|
|
33
37
|
await submitOutput(base64Data);
|
|
@@ -51,6 +55,5 @@ const DoodleScreen = _ref => {
|
|
|
51
55
|
}
|
|
52
56
|
}));
|
|
53
57
|
};
|
|
54
|
-
|
|
55
58
|
export default withBaseDispatchScreen(DoodleScreen);
|
|
56
59
|
//# sourceMappingURL=DoodleScreen.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["SignatureET","React","useCallback","useState","withBaseDispatchScreen","EntityCode","ExecutionTaskID","DispatchStateContainer","RouteParams","View","CancelOrderDialog","getJobIDs","getObjectiveRefs","DoodleScreen","route","navigation","baseETProps","showAlert","setShowAlert","sResponse","setResponse","submitOutput","base64Data","getInstance","navigateToNextTask","success","DOODLE","
|
|
1
|
+
{"version":3,"names":["SignatureET","React","useCallback","useEffect","useState","withBaseDispatchScreen","EntityCode","ExecutionTaskID","DispatchStateContainer","RouteParams","View","CancelOrderDialog","getJobIDs","getObjectiveRefs","onTaskStart","DoodleScreen","_ref","route","navigation","baseETProps","params","NEXT_STATES","showAlert","setShowAlert","sResponse","setResponse","submitOutput","base64Data","getInstance","navigateToNextTask","success","DOODLE","createElement","style","flex","_extends","nextState","data","input","jobIDs","objRefs","taskMeta","JSON","parse","onSubmitET","_prevState","label","visible","onSubmit","value"],"sources":["DoodleScreen.tsx"],"sourcesContent":["import SignatureET from '../../components/executiontasks/doodle/SignatureET';\nimport React, { useCallback, useEffect, useState } from 'react';\nimport withBaseDispatchScreen from './WithBaseDispatchScreen';\nimport type { BaseETProps } from '../../models/DispatchModels';\nimport { EntityCode, ExecutionTaskID } from '../../models/execTasks/ETConfig';\nimport DispatchStateContainer from '../../manager/dispatch/DispatchStateContainer';\nimport { RouteParams } from '../uiConfig/RouteParams';\nimport { View } from 'react-native';\nimport CancelOrderDialog from '../../components/widgets/CancelOrderDialog';\nimport {\n getJobIDs,\n getObjectiveRefs,\n} from '../../components/executiontasks/doodle/DoodleUtils';\nimport { onTaskStart } from '../../utils/ExecTaskUtils';\n\nconst DoodleScreen = ({\n route,\n navigation,\n baseETProps,\n}: {\n route: any;\n navigation: any;\n baseETProps: BaseETProps;\n}) => {\n useEffect(() => {\n onTaskStart(route.params[RouteParams.NEXT_STATES]);\n }, []);\n const [showAlert, setShowAlert] = useState(false);\n const [sResponse, setResponse] = useState<any>();\n const submitOutput = useCallback(\n async (base64Data: any) => {\n await DispatchStateContainer.getInstance().navigateToNextTask(\n navigation,\n route,\n base64Data,\n base64Data.success,\n EntityCode.DOODLE,\n ExecutionTaskID.DOODLE,\n baseETProps,\n false\n );\n },\n [baseETProps, navigation, route]\n );\n return (\n <View style={{ flex: 1 }}>\n <SignatureET\n {...route.params[RouteParams.NEXT_STATES][0].nextState.data.input}\n jobIDs={getJobIDs(route.params[RouteParams.NEXT_STATES])}\n objRefs={getObjectiveRefs(route.params[RouteParams.NEXT_STATES])}\n navigation={navigation}\n taskMeta={JSON.parse(\n route.params[RouteParams.NEXT_STATES][0].nextState.data.taskMeta ||\n '{}'\n )}\n onSubmitET={async (base64Data) => {\n if (base64Data.success) {\n await submitOutput(base64Data);\n } else {\n setResponse((_prevState: any) => {\n setShowAlert(true);\n return base64Data;\n });\n }\n }}\n />\n <CancelOrderDialog\n label={'Cancel Signature'}\n visible={showAlert}\n onSubmit={async (value) => {\n if (value) {\n setShowAlert(false);\n await submitOutput(sResponse);\n } else {\n setShowAlert(false);\n }\n }}\n />\n </View>\n );\n};\n\nexport default withBaseDispatchScreen(DoodleScreen);\n"],"mappings":";AAAA,OAAOA,WAAW,MAAM,oDAAoD;AAC5E,OAAOC,KAAK,IAAIC,WAAW,EAAEC,SAAS,EAAEC,QAAQ,QAAQ,OAAO;AAC/D,OAAOC,sBAAsB,MAAM,0BAA0B;AAE7D,SAASC,UAAU,EAAEC,eAAe,QAAQ,iCAAiC;AAC7E,OAAOC,sBAAsB,MAAM,+CAA+C;AAClF,SAASC,WAAW,QAAQ,yBAAyB;AACrD,SAASC,IAAI,QAAQ,cAAc;AACnC,OAAOC,iBAAiB,MAAM,4CAA4C;AAC1E,SACEC,SAAS,EACTC,gBAAgB,QACX,oDAAoD;AAC3D,SAASC,WAAW,QAAQ,2BAA2B;AAEvD,MAAMC,YAAY,GAAGC,IAAA,IAQf;EAAA,IARgB;IACpBC,KAAK;IACLC,UAAU;IACVC;EAKF,CAAC,GAAAH,IAAA;EACCb,SAAS,CAAC,MAAM;IACd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AAOjB,UAAU,IAAK;MAChC,IAAIA,UAAU,CAACG,OAAO,EAAE;QACtB,MAAMJ,YAAY,CAACC,UAAU,CAAC;MAChC,CAAC,MAAM;QACLF,WAAW,CAAEoB,UAAe,IAAK;UAC/BtB,YAAY,CAAC,IAAI,CAAC;UAClB,OAAOI,UAAU;QACnB,CAAC,CAAC;MACJ;IACF;EAAE,GACF,eACF1B,KAAA,CAAA+B,aAAA,CAACrB,iBAAiB;IAChBmC,KAAK,EAAE,kBAAmB;IAC1BC,OAAO,EAAEzB,SAAU;IACnB0B,QAAQ,EAAE,MAAOC,KAAK,IAAK;MACzB,IAAIA,KAAK,EAAE;QACT1B,YAAY,CAAC,KAAK,CAAC;QACnB,MAAMG,YAAY,CAACF,SAAS,CAAC;MAC/B,CAAC,MAAM;QACLD,YAAY,CAAC,KAAK,CAAC;MACrB;IACF;EAAE,EACF,CACG;AAEX,CAAC;AAED,eAAelB,sBAAsB,CAACU,YAAY,CAAC"}
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
2
|
-
|
|
3
|
-
import React, { useCallback, useState } from 'react';
|
|
2
|
+
import React, { useCallback, useEffect, useState } from 'react';
|
|
4
3
|
import withBaseDispatchScreen from './WithBaseDispatchScreen';
|
|
5
4
|
import { SLDropCash } from '../../components/executiontasks/ExecutionTasksIndex';
|
|
6
5
|
import { EntityCode, ExecutionTaskID } from '../../models/execTasks/ETConfig';
|
|
@@ -8,27 +7,27 @@ import DispatchStateContainer from '../../manager/dispatch/DispatchStateContaine
|
|
|
8
7
|
import { RouteParams } from '../uiConfig/RouteParams';
|
|
9
8
|
import { View } from 'react-native';
|
|
10
9
|
import CancelOrderDialog from '../../components/widgets/CancelOrderDialog';
|
|
11
|
-
|
|
10
|
+
import { onTaskStart } from '../../utils/ExecTaskUtils';
|
|
12
11
|
function getTotalExpected(nextStates) {
|
|
13
12
|
let totalAmount = 0;
|
|
14
|
-
|
|
15
13
|
for (const s of nextStates) {
|
|
16
14
|
totalAmount += s.nextState.data.input.expectedAmount.value;
|
|
17
15
|
}
|
|
18
|
-
|
|
19
16
|
return {
|
|
20
17
|
value: totalAmount,
|
|
21
18
|
minorUnit: nextStates[0].nextState.data.input.expectedAmount.minorUnit,
|
|
22
19
|
currencyCode: nextStates[0].nextState.data.input.expectedAmount.currencyCode
|
|
23
20
|
};
|
|
24
21
|
}
|
|
25
|
-
|
|
26
22
|
const DropCashScreen = _ref => {
|
|
27
23
|
let {
|
|
28
24
|
route,
|
|
29
25
|
navigation,
|
|
30
26
|
baseETProps
|
|
31
27
|
} = _ref;
|
|
28
|
+
useEffect(() => {
|
|
29
|
+
onTaskStart(route.params[RouteParams.NEXT_STATES]);
|
|
30
|
+
}, []);
|
|
32
31
|
const [showAlert, setShowAlert] = useState(false);
|
|
33
32
|
const [sResponse, setResponse] = useState();
|
|
34
33
|
const submitOutput = useCallback(async etOutput => {
|
|
@@ -40,6 +39,8 @@ const DropCashScreen = _ref => {
|
|
|
40
39
|
}
|
|
41
40
|
}, /*#__PURE__*/React.createElement(SLDropCash, _extends({}, route.params[RouteParams.NEXT_STATES][0].nextState.data.input, {
|
|
42
41
|
expectedAmount: getTotalExpected(route.params[RouteParams.NEXT_STATES]),
|
|
42
|
+
navigation: navigation,
|
|
43
|
+
taskMeta: JSON.parse(route.params[RouteParams.NEXT_STATES][0].nextState.data.taskMeta || '{}'),
|
|
43
44
|
onSubmitET: async etOutput => {
|
|
44
45
|
if (etOutput.success) {
|
|
45
46
|
await submitOutput(etOutput);
|
|
@@ -62,6 +63,5 @@ const DropCashScreen = _ref => {
|
|
|
62
63
|
}
|
|
63
64
|
}));
|
|
64
65
|
};
|
|
65
|
-
|
|
66
66
|
export default withBaseDispatchScreen(DropCashScreen);
|
|
67
67
|
//# sourceMappingURL=DropCashScreen.js.map
|