@os1-platform/dispatch-mobile 1.0.8 → 2.0.0
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 +310 -74
- package/android/.gradle/7.0.2/fileChanges/last-build.bin +0 -0
- package/android/.gradle/7.0.2/fileHashes/fileHashes.lock +0 -0
- package/android/.gradle/7.0.2/gc.properties +0 -0
- package/android/.gradle/7.2/dependencies-accessors/dependencies-accessors.lock +0 -0
- package/android/.gradle/7.2/dependencies-accessors/gc.properties +0 -0
- package/android/.gradle/7.2/executionHistory/executionHistory.bin +0 -0
- package/android/.gradle/7.2/executionHistory/executionHistory.lock +0 -0
- package/android/.gradle/7.2/fileChanges/last-build.bin +0 -0
- package/android/.gradle/7.2/fileHashes/fileHashes.bin +0 -0
- package/android/.gradle/7.2/fileHashes/fileHashes.lock +0 -0
- package/android/.gradle/7.2/fileHashes/resourceHashesCache.bin +0 -0
- package/android/.gradle/7.2/gc.properties +0 -0
- package/android/.gradle/buildOutputCleanup/buildOutputCleanup.lock +0 -0
- package/android/.gradle/buildOutputCleanup/cache.properties +2 -0
- package/android/.gradle/buildOutputCleanup/outputFiles.bin +0 -0
- package/android/.gradle/checksums/checksums.lock +0 -0
- package/android/.gradle/checksums/md5-checksums.bin +0 -0
- package/android/.gradle/checksums/sha1-checksums.bin +0 -0
- package/android/.gradle/vcs-1/gc.properties +0 -0
- package/android/.idea/compiler.xml +6 -0
- package/android/.idea/gradle.xml +18 -0
- package/android/.idea/jarRepositories.xml +35 -0
- package/android/.idea/kotlinc.xml +6 -0
- package/android/.idea/misc.xml +9 -0
- package/android/.idea/vcs.xml +6 -0
- package/android/gradle.properties +1 -1
- package/android/local.properties +8 -0
- package/android/src/main/AndroidManifest.xml +0 -1
- package/android/src/main/java/com/dispatchsdk/DispatchSdkPackage.kt +3 -1
- package/android/src/main/java/com/dispatchsdk/sharedPref/SharedPreferenceModule.kt +166 -0
- package/lib/commonjs/@types/assets/index.d.js +2 -0
- package/lib/commonjs/@types/assets/index.d.js.map +1 -0
- package/lib/commonjs/components/dispatch/DispatchExecNavigator.js +50 -43
- package/lib/commonjs/components/dispatch/DispatchExecNavigator.js.map +1 -1
- package/lib/commonjs/components/executiontasks/ExecutionTasksIndex.js +10 -48
- 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 +66 -18
- package/lib/commonjs/components/executiontasks/captureInput/CaptureText.js.map +1 -1
- package/lib/commonjs/components/executiontasks/captureInput/utils.js +13 -0
- package/lib/commonjs/components/executiontasks/captureInput/utils.js.map +1 -0
- 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/DeliverETInput.js.map +1 -1
- package/lib/commonjs/components/executiontasks/deliver/SLDeliverET.js +212 -95
- package/lib/commonjs/components/executiontasks/deliver/SLDeliverET.js.map +1 -1
- package/lib/commonjs/components/executiontasks/display/DisplayModalET.js +16 -25
- package/lib/commonjs/components/executiontasks/display/DisplayModalET.js.map +1 -1
- package/lib/commonjs/components/executiontasks/doodle/SignatureET.js +65 -29
- 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 +74 -30
- package/lib/commonjs/components/executiontasks/dropCash/SLDropCash.js.map +1 -1
- package/lib/commonjs/components/executiontasks/forms/FormGenerator.js +139 -50
- 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 +2 -17
- 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 +5 -14
- package/lib/commonjs/components/executiontasks/httpRequest/HttpEtUtils.js.map +1 -1
- package/lib/commonjs/components/executiontasks/httpRequest/HttpRequestET.js +3 -15
- 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 +11 -36
- package/lib/commonjs/components/executiontasks/imageCapture/CaptureUtils.js.map +1 -1
- package/lib/commonjs/components/executiontasks/imageCapture/ImageCapture.js +73 -48
- 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 +76 -29
- 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 +138 -32
- package/lib/commonjs/components/executiontasks/pickup/SLPickupET.js.map +1 -1
- package/lib/commonjs/components/executiontasks/scan/ScanET.js +741 -0
- package/lib/commonjs/components/executiontasks/scan/ScanET.js.map +1 -0
- package/lib/commonjs/components/executiontasks/scan/ScanSchema.js +19 -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 +43 -0
- package/lib/commonjs/components/executiontasks/scan/interfaces.js.map +1 -0
- package/lib/commonjs/components/executiontasks/scan/modalConstant.js +104 -0
- package/lib/commonjs/components/executiontasks/scan/modalConstant.js.map +1 -0
- package/lib/commonjs/components/executiontasks/{scanner → scan/sub_components}/CScanner.js +9 -29
- package/lib/commonjs/components/executiontasks/scan/sub_components/CScanner.js.map +1 -0
- package/lib/commonjs/components/executiontasks/scan/sub_components/DropDownUtils.js +109 -0
- package/lib/commonjs/components/executiontasks/scan/sub_components/DropDownUtils.js.map +1 -0
- package/lib/commonjs/components/executiontasks/{scanner/returns/ReasonDropDown.js → scan/sub_components/ERDropDown.js} +72 -55
- package/lib/commonjs/components/executiontasks/scan/sub_components/ERDropDown.js.map +1 -0
- package/lib/commonjs/components/executiontasks/scan/sub_components/SummaryPage.js +1099 -0
- package/lib/commonjs/components/executiontasks/scan/sub_components/SummaryPage.js.map +1 -0
- package/lib/commonjs/components/executiontasks/scan/utils.js +762 -0
- package/lib/commonjs/components/executiontasks/scan/utils.js.map +1 -0
- package/lib/commonjs/components/executiontasks/validateOTP/ValidateOTPET.js +333 -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 +63 -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/executiontasks/verifyOtp/VerifyOtpSchema.js.map +1 -1
- package/lib/commonjs/components/utils/index.js +14 -0
- package/lib/commonjs/components/utils/index.js.map +1 -0
- 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/Card.js +88 -0
- package/lib/commonjs/components/widgets/Card.js.map +1 -0
- package/lib/commonjs/components/widgets/GoBackModal.js +48 -0
- package/lib/commonjs/components/widgets/GoBackModal.js.map +1 -0
- package/lib/commonjs/components/widgets/IconButton.js +34 -0
- package/lib/commonjs/components/widgets/IconButton.js.map +1 -0
- package/lib/commonjs/components/widgets/ModalWidget.js +99 -0
- package/lib/commonjs/components/widgets/ModalWidget.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/SearchBar.js +74 -0
- package/lib/commonjs/components/widgets/SearchBar.js.map +1 -0
- package/lib/commonjs/components/widgets/SnackBarCustom.js +48 -40
- 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/TabsComponent.js +64 -0
- package/lib/commonjs/components/widgets/TabsComponent.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 +17 -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 +23 -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 +15 -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 +40 -35
- package/lib/commonjs/index.js.map +1 -1
- package/lib/commonjs/manager/dispatch/DispatchStateContainer.js +328 -272
- 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 +23 -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 +23 -37
- 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/sdk/callbacksHandler.js +26 -0
- package/lib/commonjs/manager/sdk/callbacksHandler.js.map +1 -0
- package/lib/commonjs/manager/syncmanager/AppSyncManager.js +26 -46
- package/lib/commonjs/manager/syncmanager/AppSyncManager.js.map +1 -1
- package/lib/commonjs/manager/syncmanager/DBConfig.js +48 -9
- 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/constants.js +17 -0
- package/lib/commonjs/manager/syncmanager/constants.js.map +1 -0
- 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 +11 -36
- package/lib/commonjs/manager/syncmanager/document/DocumentHttpClient.js.map +1 -1
- package/lib/commonjs/manager/syncmanager/document/DocumentManager.js +8 -26
- package/lib/commonjs/manager/syncmanager/document/DocumentManager.js.map +1 -1
- package/lib/commonjs/manager/syncmanager/document/DocumentSyncManager.js +19 -58
- package/lib/commonjs/manager/syncmanager/document/DocumentSyncManager.js.map +1 -1
- package/lib/commonjs/manager/syncmanager/events/ETEventsManager.js +414 -29
- package/lib/commonjs/manager/syncmanager/events/ETEventsManager.js.map +1 -1
- package/lib/commonjs/manager/syncmanager/events/EventsSyncManager.js +208 -103
- package/lib/commonjs/manager/syncmanager/events/EventsSyncManager.js.map +1 -1
- package/lib/commonjs/manager/syncmanager/events/SyncHttpClient.js +157 -36
- 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 +4 -0
- 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 +10 -8
- package/lib/commonjs/styles/SdkColors.js.map +1 -1
- package/lib/commonjs/styles/executionTasks/CommonStyles.js +58 -25
- package/lib/commonjs/styles/executionTasks/CommonStyles.js.map +1 -1
- package/lib/commonjs/ui/screens/CancellationScreen.js +67 -27
- package/lib/commonjs/ui/screens/CancellationScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/CaptureInputScreen.js +15 -16
- package/lib/commonjs/ui/screens/CaptureInputScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/CompleteObjectiveScreen.js +11 -23
- package/lib/commonjs/ui/screens/CompleteObjectiveScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/DeliverScreen.js +30 -17
- package/lib/commonjs/ui/screens/DeliverScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/DisplayScreen.js +17 -13
- package/lib/commonjs/ui/screens/DisplayScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/DoodleScreen.js +17 -20
- package/lib/commonjs/ui/screens/DoodleScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/DropCashScreen.js +43 -31
- package/lib/commonjs/ui/screens/DropCashScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/ETScreensIndex.js +10 -19
- package/lib/commonjs/ui/screens/ETScreensIndex.js.map +1 -1
- package/lib/commonjs/ui/screens/FormsScreen.js +105 -17
- package/lib/commonjs/ui/screens/FormsScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/GeofenceScreen.js +16 -14
- package/lib/commonjs/ui/screens/GeofenceScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/HttpRequestScreen.js +14 -11
- package/lib/commonjs/ui/screens/HttpRequestScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/ImageCaptureScreen.js +38 -17
- package/lib/commonjs/ui/screens/ImageCaptureScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/PaymentScreen.js +28 -29
- package/lib/commonjs/ui/screens/PaymentScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/PickupScreen.js +41 -19
- package/lib/commonjs/ui/screens/PickupScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/ScanScreen.js +121 -0
- package/lib/commonjs/ui/screens/ScanScreen.js.map +1 -0
- package/lib/commonjs/ui/screens/StartWorkFlowScreen.js +64 -38
- package/lib/commonjs/ui/screens/StartWorkFlowScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/ValidateOTPScreen.js +55 -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 +24 -1
- package/lib/commonjs/ui/uiConfig/RouteParams.js.map +1 -1
- package/lib/commonjs/utils/ApiUtils.js +129 -0
- package/lib/commonjs/utils/ApiUtils.js.map +1 -0
- package/lib/commonjs/utils/ExecTaskUtils.js +111 -41
- 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 +61 -43
- package/lib/commonjs/utils/SyncManagerUtils.js.map +1 -1
- package/lib/commonjs/utils/fcm/FCM.js +59 -11
- package/lib/commonjs/utils/fcm/FCM.js.map +1 -1
- package/lib/commonjs/utils/fcm/FcmUtils.js +82 -21
- 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/useModal.js +53 -0
- package/lib/commonjs/utils/hooks/useModal.js.map +1 -0
- 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 +87 -31
- 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/@types/assets/index.d.js +2 -0
- package/lib/module/@types/assets/index.d.js.map +1 -0
- package/lib/module/components/dispatch/DispatchExecNavigator.js +50 -32
- package/lib/module/components/dispatch/DispatchExecNavigator.js.map +1 -1
- package/lib/module/components/executiontasks/ExecutionTasksIndex.js +3 -5
- 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 +68 -10
- package/lib/module/components/executiontasks/captureInput/CaptureText.js.map +1 -1
- package/lib/module/components/executiontasks/captureInput/utils.js +7 -0
- package/lib/module/components/executiontasks/captureInput/utils.js.map +1 -0
- 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/DeliverETInput.js.map +1 -1
- package/lib/module/components/executiontasks/deliver/SLDeliverET.js +214 -86
- package/lib/module/components/executiontasks/deliver/SLDeliverET.js.map +1 -1
- package/lib/module/components/executiontasks/display/DisplayModalET.js +16 -15
- package/lib/module/components/executiontasks/display/DisplayModalET.js.map +1 -1
- package/lib/module/components/executiontasks/doodle/SignatureET.js +68 -15
- 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 +75 -20
- package/lib/module/components/executiontasks/dropCash/SLDropCash.js.map +1 -1
- package/lib/module/components/executiontasks/forms/FormGenerator.js +142 -37
- 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 +2 -6
- 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 +6 -4
- package/lib/module/components/executiontasks/httpRequest/HttpEtUtils.js.map +1 -1
- package/lib/module/components/executiontasks/httpRequest/HttpRequestET.js +3 -6
- 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 +11 -11
- 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 +77 -18
- package/lib/module/components/executiontasks/payments/completePayment/CompletePaymentET.js.map +1 -1
- package/lib/module/components/executiontasks/payments/init/InitPaymentET.js +64 -11
- package/lib/module/components/executiontasks/payments/init/InitPaymentET.js.map +1 -1
- package/lib/module/components/executiontasks/payments/processPayment/ProcessPaymentET.js +72 -11
- 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 +141 -25
- package/lib/module/components/executiontasks/pickup/SLPickupET.js.map +1 -1
- package/lib/module/components/executiontasks/scan/ScanET.js +732 -0
- package/lib/module/components/executiontasks/scan/ScanET.js.map +1 -0
- package/lib/module/components/executiontasks/scan/ScanSchema.js +17 -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 +33 -0
- package/lib/module/components/executiontasks/scan/interfaces.js.map +1 -0
- package/lib/module/components/executiontasks/scan/modalConstant.js +94 -0
- package/lib/module/components/executiontasks/scan/modalConstant.js.map +1 -0
- package/lib/module/components/executiontasks/{scanner → scan/sub_components}/CScanner.js +9 -16
- package/lib/module/components/executiontasks/scan/sub_components/CScanner.js.map +1 -0
- package/lib/module/components/executiontasks/scan/sub_components/DropDownUtils.js +101 -0
- package/lib/module/components/executiontasks/scan/sub_components/DropDownUtils.js.map +1 -0
- package/lib/module/components/executiontasks/scan/sub_components/ERDropDown.js +107 -0
- package/lib/module/components/executiontasks/scan/sub_components/ERDropDown.js.map +1 -0
- package/lib/module/components/executiontasks/scan/sub_components/SummaryPage.js +1092 -0
- package/lib/module/components/executiontasks/scan/sub_components/SummaryPage.js.map +1 -0
- package/lib/module/components/executiontasks/scan/utils.js +726 -0
- package/lib/module/components/executiontasks/scan/utils.js.map +1 -0
- package/lib/module/components/executiontasks/validateOTP/ValidateOTPET.js +324 -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 +53 -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 +5 -9
- package/lib/module/components/executiontasks/verifyOtp/VerifyOtpET.js.map +1 -1
- package/lib/module/components/executiontasks/verifyOtp/VerifyOtpSchema.js.map +1 -1
- package/lib/module/components/utils/index.js +8 -0
- package/lib/module/components/utils/index.js.map +1 -0
- 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/Card.js +80 -0
- package/lib/module/components/widgets/Card.js.map +1 -0
- package/lib/module/components/widgets/GoBackModal.js +40 -0
- package/lib/module/components/widgets/GoBackModal.js.map +1 -0
- package/lib/module/components/widgets/IconButton.js +26 -0
- package/lib/module/components/widgets/IconButton.js.map +1 -0
- package/lib/module/components/widgets/ModalWidget.js +92 -0
- package/lib/module/components/widgets/ModalWidget.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/SearchBar.js +66 -0
- package/lib/module/components/widgets/SearchBar.js.map +1 -0
- package/lib/module/components/widgets/SnackBarCustom.js +46 -20
- 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/TabsComponent.js +55 -0
- package/lib/module/components/widgets/TabsComponent.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 +9 -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 +16 -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 +8 -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 +9 -5
- package/lib/module/index.js.map +1 -1
- package/lib/module/manager/dispatch/DispatchStateContainer.js +334 -247
- 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 +22 -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 +23 -15
- 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/sdk/callbacksHandler.js +19 -0
- package/lib/module/manager/sdk/callbacksHandler.js.map +1 -0
- package/lib/module/manager/syncmanager/AppSyncManager.js +26 -26
- package/lib/module/manager/syncmanager/AppSyncManager.js.map +1 -1
- package/lib/module/manager/syncmanager/DBConfig.js +41 -7
- 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/constants.js +6 -0
- package/lib/module/manager/syncmanager/constants.js.map +1 -0
- 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 +11 -24
- package/lib/module/manager/syncmanager/document/DocumentHttpClient.js.map +1 -1
- package/lib/module/manager/syncmanager/document/DocumentManager.js +8 -20
- package/lib/module/manager/syncmanager/document/DocumentManager.js.map +1 -1
- package/lib/module/manager/syncmanager/document/DocumentSyncManager.js +19 -41
- package/lib/module/manager/syncmanager/document/DocumentSyncManager.js.map +1 -1
- package/lib/module/manager/syncmanager/events/ETEventsManager.js +415 -22
- package/lib/module/manager/syncmanager/events/ETEventsManager.js.map +1 -1
- package/lib/module/manager/syncmanager/events/EventsSyncManager.js +209 -82
- package/lib/module/manager/syncmanager/events/EventsSyncManager.js.map +1 -1
- package/lib/module/manager/syncmanager/events/SyncHttpClient.js +152 -24
- 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 +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 +9 -7
- package/lib/module/styles/SdkColors.js.map +1 -1
- package/lib/module/styles/executionTasks/CommonStyles.js +57 -14
- package/lib/module/styles/executionTasks/CommonStyles.js.map +1 -1
- package/lib/module/ui/screens/CancellationScreen.js +68 -15
- package/lib/module/ui/screens/CancellationScreen.js.map +1 -1
- package/lib/module/ui/screens/CaptureInputScreen.js +17 -6
- package/lib/module/ui/screens/CaptureInputScreen.js.map +1 -1
- package/lib/module/ui/screens/CompleteObjectiveScreen.js +12 -8
- package/lib/module/ui/screens/CompleteObjectiveScreen.js.map +1 -1
- package/lib/module/ui/screens/DeliverScreen.js +32 -7
- package/lib/module/ui/screens/DeliverScreen.js.map +1 -1
- package/lib/module/ui/screens/DisplayScreen.js +16 -6
- package/lib/module/ui/screens/DisplayScreen.js.map +1 -1
- package/lib/module/ui/screens/DoodleScreen.js +19 -9
- package/lib/module/ui/screens/DoodleScreen.js.map +1 -1
- package/lib/module/ui/screens/DropCashScreen.js +45 -19
- package/lib/module/ui/screens/DropCashScreen.js.map +1 -1
- package/lib/module/ui/screens/ETScreensIndex.js +3 -2
- package/lib/module/ui/screens/ETScreensIndex.js.map +1 -1
- package/lib/module/ui/screens/FormsScreen.js +104 -9
- package/lib/module/ui/screens/FormsScreen.js.map +1 -1
- package/lib/module/ui/screens/GeofenceScreen.js +15 -6
- package/lib/module/ui/screens/GeofenceScreen.js.map +1 -1
- package/lib/module/ui/screens/HttpRequestScreen.js +15 -5
- package/lib/module/ui/screens/HttpRequestScreen.js.map +1 -1
- package/lib/module/ui/screens/ImageCaptureScreen.js +37 -9
- package/lib/module/ui/screens/ImageCaptureScreen.js.map +1 -1
- package/lib/module/ui/screens/PaymentScreen.js +30 -17
- package/lib/module/ui/screens/PaymentScreen.js.map +1 -1
- package/lib/module/ui/screens/PickupScreen.js +40 -12
- package/lib/module/ui/screens/PickupScreen.js.map +1 -1
- package/lib/module/ui/screens/ScanScreen.js +111 -0
- package/lib/module/ui/screens/ScanScreen.js.map +1 -0
- package/lib/module/ui/screens/StartWorkFlowScreen.js +64 -16
- package/lib/module/ui/screens/StartWorkFlowScreen.js.map +1 -1
- package/lib/module/ui/screens/ValidateOTPScreen.js +45 -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 +23 -1
- package/lib/module/ui/uiConfig/RouteParams.js.map +1 -1
- package/lib/module/utils/ApiUtils.js +116 -0
- package/lib/module/utils/ApiUtils.js.map +1 -0
- package/lib/module/utils/ExecTaskUtils.js +110 -31
- 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 +62 -14
- package/lib/module/utils/SyncManagerUtils.js.map +1 -1
- package/lib/module/utils/fcm/FCM.js +63 -3
- package/lib/module/utils/fcm/FCM.js.map +1 -1
- package/lib/module/utils/fcm/FcmUtils.js +86 -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/useModal.js +43 -0
- package/lib/module/utils/hooks/useModal.js.map +1 -0
- 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 +86 -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/dispatch/DispatchExecNavigator.d.ts +2 -2
- package/lib/typescript/components/executiontasks/CompletedWFSchema.d.ts +2 -2
- package/lib/typescript/components/executiontasks/ExecutionTasksIndex.d.ts +6 -7
- package/lib/typescript/components/executiontasks/cancellation/CancelET.d.ts +2 -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/captureInput/CaptureText.d.ts +2 -2
- package/lib/typescript/components/executiontasks/captureInput/utils.d.ts +1 -0
- package/lib/typescript/components/executiontasks/deliver/DeliverET.d.ts +2 -2
- package/lib/typescript/components/executiontasks/deliver/DeliverETInput.d.ts +8 -7
- package/lib/typescript/components/executiontasks/deliver/SLDeliverET.d.ts +3 -3
- package/lib/typescript/components/executiontasks/display/DisplayModalET.d.ts +2 -2
- package/lib/typescript/components/executiontasks/display/DisplaySchema.d.ts +5 -5
- package/lib/typescript/components/executiontasks/doodle/SignatureET.d.ts +2 -2
- package/lib/typescript/components/executiontasks/doodle/SignatureSchema.d.ts +7 -7
- package/lib/typescript/components/executiontasks/dropCash/DropCashET.d.ts +2 -2
- package/lib/typescript/components/executiontasks/dropCash/DropCashSchema.d.ts +2 -2
- package/lib/typescript/components/executiontasks/dropCash/SLDropCash.d.ts +2 -2
- package/lib/typescript/components/executiontasks/forms/FormGenerator.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 +3 -3
- package/lib/typescript/components/executiontasks/forms/widgets/DropdownWidget.d.ts +9 -0
- package/lib/typescript/components/executiontasks/forms/widgets/QRBarcodeScannerWidget.d.ts +2 -2
- package/lib/typescript/components/executiontasks/forms/widgets/TimeRangeSelector.d.ts +2 -2
- package/lib/typescript/components/executiontasks/httpRequest/HttpEtUtils.d.ts +1 -1
- package/lib/typescript/components/executiontasks/httpRequest/HttpRequestET.d.ts +2 -2
- package/lib/typescript/components/executiontasks/httpRequest/HttpRequestETSchema.d.ts +6 -6
- package/lib/typescript/components/executiontasks/imageCapture/CaptureSchema.d.ts +17 -11
- package/lib/typescript/components/executiontasks/imageCapture/ImageCapture.d.ts +2 -2
- package/lib/typescript/components/executiontasks/payments/completePayment/CompletePaymentET.d.ts +2 -2
- package/lib/typescript/components/executiontasks/payments/completePayment/CompletePaymentSchema.d.ts +2 -2
- package/lib/typescript/components/executiontasks/payments/init/InitPaymentET.d.ts +2 -2
- package/lib/typescript/components/executiontasks/payments/init/InitPaymentSchema.d.ts +3 -3
- package/lib/typescript/components/executiontasks/payments/processPayment/ProcessPaymentET.d.ts +2 -2
- 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/pickup/PickupET.d.ts +2 -2
- package/lib/typescript/components/executiontasks/pickup/SLPickupET.d.ts +3 -3
- package/lib/typescript/components/executiontasks/scan/ScanET.d.ts +16 -0
- package/lib/typescript/components/executiontasks/scan/ScanSchema.d.ts +86 -0
- package/lib/typescript/components/executiontasks/scan/constants.d.ts +6 -0
- package/lib/typescript/components/executiontasks/scan/interfaces.d.ts +94 -0
- package/lib/typescript/components/executiontasks/scan/modalConstant.d.ts +37 -0
- package/lib/typescript/components/executiontasks/{scanner → scan/sub_components}/CScanner.d.ts +1 -1
- 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/SummaryPage.d.ts +21 -0
- package/lib/typescript/components/executiontasks/scan/utils.d.ts +37 -0
- 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/verifyLocation/VerifyLocationET.d.ts +2 -2
- package/lib/typescript/components/executiontasks/verifyOtp/VerifyOtpET.d.ts +2 -2
- package/lib/typescript/components/executiontasks/verifyOtp/VerifyOtpSchema.d.ts +6 -6
- package/lib/typescript/components/utils/index.d.ts +2 -0
- package/lib/typescript/components/widgets/CancelOrderDialog.d.ts +2 -2
- package/lib/typescript/components/widgets/Card.d.ts +17 -0
- package/lib/typescript/components/widgets/GoBackModal.d.ts +9 -0
- package/lib/typescript/components/widgets/IconButton.d.ts +9 -0
- package/lib/typescript/components/widgets/ModalWidget.d.ts +30 -0
- package/lib/typescript/components/widgets/ProgressDialog.d.ts +2 -2
- package/lib/typescript/components/widgets/SearchBar.d.ts +10 -0
- package/lib/typescript/components/widgets/SnackBarCustom.d.ts +10 -5
- package/lib/typescript/components/widgets/SplitTextInput.d.ts +12 -0
- package/lib/typescript/components/widgets/TabsComponent.d.ts +15 -0
- package/lib/typescript/constants/apiConstants.d.ts +7 -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 +3 -0
- package/lib/typescript/events/EventListener.d.ts +5 -0
- package/lib/typescript/events/constants.d.ts +7 -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 +12 -9
- package/lib/typescript/manager/dispatch/DispatchStateContainer.d.ts +38 -17
- 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 +0 -0
- package/lib/typescript/manager/sdk/DispatchSdkCache.d.ts +1 -0
- package/lib/typescript/manager/sdk/callbacksHandler.d.ts +13 -0
- package/lib/typescript/manager/syncmanager/AppSyncManager.d.ts +3 -1
- package/lib/typescript/manager/syncmanager/DBConfig.d.ts +80 -4
- package/lib/typescript/manager/syncmanager/constants.d.ts +5 -0
- package/lib/typescript/manager/syncmanager/database.d.ts +5 -0
- package/lib/typescript/manager/syncmanager/document/DocumentManager.d.ts +1 -1
- package/lib/typescript/manager/syncmanager/document/DocumentSyncManager.d.ts +1 -1
- package/lib/typescript/manager/syncmanager/document/models.d.ts +1 -1
- package/lib/typescript/manager/syncmanager/events/ETEventsManager.d.ts +15 -2
- package/lib/typescript/manager/syncmanager/events/EventsSyncManager.d.ts +4 -2
- package/lib/typescript/manager/syncmanager/events/SyncHttpClient.d.ts +6 -3
- package/lib/typescript/models/DispatchModels.d.ts +59 -5
- 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 +44 -20
- package/lib/typescript/models/execTasks/ETConfig.d.ts +8 -4
- package/lib/typescript/models/sdk.d.ts +12 -0
- package/lib/typescript/native/signature/SignatureCapture.d.ts +2 -2
- package/lib/typescript/network/NetworkUtils.d.ts +1 -5
- package/lib/typescript/styles/SdkColors.d.ts +2 -0
- package/lib/typescript/styles/executionTasks/CommonStyles.d.ts +50 -5
- package/lib/typescript/ui/screens/CancellationScreen.d.ts +2 -2
- package/lib/typescript/ui/screens/CaptureInputScreen.d.ts +2 -2
- package/lib/typescript/ui/screens/CompleteObjectiveScreen.d.ts +2 -2
- package/lib/typescript/ui/screens/DeliverScreen.d.ts +2 -2
- package/lib/typescript/ui/screens/DisplayScreen.d.ts +2 -2
- package/lib/typescript/ui/screens/DoodleScreen.d.ts +2 -2
- package/lib/typescript/ui/screens/DropCashScreen.d.ts +2 -2
- package/lib/typescript/ui/screens/ETScreensIndex.d.ts +3 -2
- package/lib/typescript/ui/screens/FormsScreen.d.ts +2 -2
- package/lib/typescript/ui/screens/GeofenceScreen.d.ts +2 -2
- package/lib/typescript/ui/screens/HttpRequestScreen.d.ts +1 -1
- package/lib/typescript/ui/screens/ImageCaptureScreen.d.ts +2 -2
- package/lib/typescript/ui/screens/PaymentScreen.d.ts +2 -2
- package/lib/typescript/ui/screens/PickupScreen.d.ts +2 -2
- package/lib/typescript/ui/screens/ScanScreen.d.ts +3 -0
- package/lib/typescript/ui/screens/StartWorkFlowScreen.d.ts +2 -2
- package/lib/typescript/ui/screens/ValidateOTPScreen.d.ts +3 -0
- package/lib/typescript/ui/screens/WithBaseDispatchScreen.d.ts +2 -2
- package/lib/typescript/ui/uiConfig/RouteParams.d.ts +14 -0
- package/lib/typescript/utils/ApiUtils.d.ts +61 -0
- package/lib/typescript/utils/ExecTaskUtils.d.ts +10 -4
- package/lib/typescript/utils/NetworkUtil.d.ts +1 -1
- package/lib/typescript/utils/SyncManagerUtils.d.ts +4 -3
- package/lib/typescript/utils/hooks/useModal.d.ts +6 -0
- package/lib/typescript/utils/hooks/useTimer.d.ts +5 -0
- package/lib/typescript/utils/storage.d.ts +32 -0
- package/package.json +26 -26
- package/tsconfig.json +9 -9
- package/file_unzip.js +0 -5
- package/lib/commonjs/components/executiontasks/doodle/DoodleUtils.js +0 -28
- package/lib/commonjs/components/executiontasks/doodle/DoodleUtils.js.map +0 -1
- package/lib/commonjs/components/executiontasks/scanner/CScanner.js.map +0 -1
- package/lib/commonjs/components/executiontasks/scanner/ScannerSchema.js +0 -32
- package/lib/commonjs/components/executiontasks/scanner/ScannerSchema.js.map +0 -1
- package/lib/commonjs/components/executiontasks/scanner/ScannerUtils.js +0 -193
- package/lib/commonjs/components/executiontasks/scanner/ScannerUtils.js.map +0 -1
- package/lib/commonjs/components/executiontasks/scanner/returns/DropDownSelector.js +0 -20
- package/lib/commonjs/components/executiontasks/scanner/returns/DropDownSelector.js.map +0 -1
- package/lib/commonjs/components/executiontasks/scanner/returns/DropDownUtils.js +0 -49
- package/lib/commonjs/components/executiontasks/scanner/returns/DropDownUtils.js.map +0 -1
- package/lib/commonjs/components/executiontasks/scanner/returns/RTReasonSelection.js +0 -107
- package/lib/commonjs/components/executiontasks/scanner/returns/RTReasonSelection.js.map +0 -1
- package/lib/commonjs/components/executiontasks/scanner/returns/RTScan.js +0 -317
- package/lib/commonjs/components/executiontasks/scanner/returns/RTScan.js.map +0 -1
- package/lib/commonjs/components/executiontasks/scanner/returns/ReasonDropDown.js.map +0 -1
- package/lib/commonjs/components/executiontasks/scanner/returns/ScanList.js +0 -276
- package/lib/commonjs/components/executiontasks/scanner/returns/ScanList.js.map +0 -1
- package/lib/commonjs/ui/screens/RTScanScreen.js +0 -118
- package/lib/commonjs/ui/screens/RTScanScreen.js.map +0 -1
- package/lib/module/components/executiontasks/doodle/DoodleUtils.js +0 -19
- package/lib/module/components/executiontasks/doodle/DoodleUtils.js.map +0 -1
- package/lib/module/components/executiontasks/scanner/CScanner.js.map +0 -1
- package/lib/module/components/executiontasks/scanner/ScannerSchema.js +0 -24
- package/lib/module/components/executiontasks/scanner/ScannerSchema.js.map +0 -1
- package/lib/module/components/executiontasks/scanner/ScannerUtils.js +0 -158
- package/lib/module/components/executiontasks/scanner/ScannerUtils.js.map +0 -1
- package/lib/module/components/executiontasks/scanner/returns/DropDownSelector.js +0 -9
- package/lib/module/components/executiontasks/scanner/returns/DropDownSelector.js.map +0 -1
- package/lib/module/components/executiontasks/scanner/returns/DropDownUtils.js +0 -38
- package/lib/module/components/executiontasks/scanner/returns/DropDownUtils.js.map +0 -1
- package/lib/module/components/executiontasks/scanner/returns/RTReasonSelection.js +0 -86
- package/lib/module/components/executiontasks/scanner/returns/RTReasonSelection.js.map +0 -1
- package/lib/module/components/executiontasks/scanner/returns/RTScan.js +0 -287
- package/lib/module/components/executiontasks/scanner/returns/RTScan.js.map +0 -1
- package/lib/module/components/executiontasks/scanner/returns/ReasonDropDown.js +0 -80
- package/lib/module/components/executiontasks/scanner/returns/ReasonDropDown.js.map +0 -1
- package/lib/module/components/executiontasks/scanner/returns/ScanList.js +0 -253
- package/lib/module/components/executiontasks/scanner/returns/ScanList.js.map +0 -1
- package/lib/module/ui/screens/RTScanScreen.js +0 -93
- package/lib/module/ui/screens/RTScanScreen.js.map +0 -1
- package/lib/typescript/components/executiontasks/doodle/DoodleUtils.d.ts +0 -3
- package/lib/typescript/components/executiontasks/scanner/ScannerSchema.d.ts +0 -75
- package/lib/typescript/components/executiontasks/scanner/ScannerUtils.d.ts +0 -15
- package/lib/typescript/components/executiontasks/scanner/returns/DropDownSelector.d.ts +0 -3
- package/lib/typescript/components/executiontasks/scanner/returns/DropDownUtils.d.ts +0 -3
- package/lib/typescript/components/executiontasks/scanner/returns/RTReasonSelection.d.ts +0 -7
- package/lib/typescript/components/executiontasks/scanner/returns/RTScan.d.ts +0 -4
- package/lib/typescript/components/executiontasks/scanner/returns/ReasonDropDown.d.ts +0 -14
- package/lib/typescript/components/executiontasks/scanner/returns/ScanList.d.ts +0 -17
- package/lib/typescript/ui/screens/RTScanScreen.d.ts +0 -3
- package/mobile-execution-lib-0.6.4.tgz +0 -0
|
@@ -1,56 +1,184 @@
|
|
|
1
|
+
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
2
|
+
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return typeof key === "symbol" ? key : String(key); }
|
|
3
|
+
function _toPrimitive(input, hint) { if (typeof input !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (typeof res !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
1
4
|
import HttpClient from '../../../network/client';
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
import {
|
|
5
|
+
import { DispatchSyncType } from '../DBConfig';
|
|
6
|
+
import NetworkClient from '../../../network/NetworkClient';
|
|
7
|
+
import { ENDPOINTS } from '../../../constants/apiConstants';
|
|
8
|
+
import { IDispatch } from '@os1-platform/platform-coreos-execution-engine-sdk';
|
|
9
|
+
const SyncType = IDispatch.SyncType;
|
|
5
10
|
export default class SyncHttpClient extends HttpClient {
|
|
6
11
|
constructor(baseURL) {
|
|
7
12
|
super(baseURL);
|
|
13
|
+
_defineProperty(this, "networkInstance", void 0);
|
|
14
|
+
this.networkInstance = new NetworkClient(baseURL);
|
|
8
15
|
}
|
|
9
|
-
|
|
10
16
|
async syncEvent(eventRow, syncType) {
|
|
11
17
|
if (eventRow.length < 1) return null;
|
|
12
18
|
return new Promise(async (resolve, reject) => {
|
|
13
19
|
setTimeout(async () => {
|
|
14
|
-
var _response$data, _response$data$custod, _custodyOutResponse$d, _custodyOutResponse$d2;
|
|
15
|
-
|
|
16
20
|
try {
|
|
17
21
|
switch (syncType) {
|
|
18
22
|
case SyncType.CUSTODY_IN_SCAN:
|
|
19
|
-
|
|
23
|
+
{
|
|
24
|
+
// NEW CODE
|
|
25
|
+
const requestBody = JSON.parse(eventRow[0].payload);
|
|
26
|
+
const custodyInResponse = await this.networkInstance.requestPost(ENDPOINTS.BULK_JOB_UPDATE(eventRow[0].dispatch_id), requestBody, {
|
|
27
|
+
requestId: 'custodyIn: ' + eventRow[0].dispatch_id
|
|
28
|
+
});
|
|
29
|
+
if (custodyInResponse.data.error) {
|
|
30
|
+
resolve(false);
|
|
31
|
+
} else {
|
|
32
|
+
resolve(true);
|
|
33
|
+
}
|
|
34
|
+
break;
|
|
20
35
|
|
|
21
|
-
|
|
22
|
-
custodyInScans
|
|
36
|
+
// OLD CODE
|
|
37
|
+
// const custodyInScans = [];
|
|
38
|
+
// for (const ev of eventRow) {
|
|
39
|
+
// custodyInScans.push(JSON.parse(ev.payload));
|
|
40
|
+
// }
|
|
41
|
+
// const response = await GraphQLClient.getInstance().postCustodyIn(
|
|
42
|
+
// custodyInScans,
|
|
43
|
+
// eventRow[0].dispatch_id
|
|
44
|
+
// );
|
|
45
|
+
// resolve(response?.data?.custodyInBatch?.success === true);
|
|
46
|
+
// break;
|
|
23
47
|
}
|
|
24
48
|
|
|
25
|
-
const response = await GraphQLClient.getInstance().postCustodyIn(custodyInScans, eventRow[0].dispatch_id);
|
|
26
|
-
resolve((response === null || response === void 0 ? void 0 : (_response$data = response.data) === null || _response$data === void 0 ? void 0 : (_response$data$custod = _response$data.custodyInBatch) === null || _response$data$custod === void 0 ? void 0 : _response$data$custod.success) === true);
|
|
27
|
-
break;
|
|
28
|
-
|
|
29
49
|
case SyncType.CUSTODY_OUT_SCAN:
|
|
30
|
-
|
|
50
|
+
{
|
|
51
|
+
// NEW CODE
|
|
52
|
+
const requestBody = JSON.parse(eventRow[0].payload);
|
|
53
|
+
const custodyInResponse = await this.networkInstance.requestPost(ENDPOINTS.BULK_JOB_UPDATE(eventRow[0].dispatch_id), requestBody, {
|
|
54
|
+
requestId: 'custodyIn: ' + eventRow[0].dispatch_id
|
|
55
|
+
});
|
|
56
|
+
if (custodyInResponse.data.error) {
|
|
57
|
+
resolve(false);
|
|
58
|
+
} else {
|
|
59
|
+
resolve(true);
|
|
60
|
+
}
|
|
61
|
+
break;
|
|
31
62
|
|
|
32
|
-
|
|
33
|
-
custodyOutScans
|
|
63
|
+
// OLD CODE
|
|
64
|
+
// const custodyOutScans = [];
|
|
65
|
+
// for (const ev of eventRow) {
|
|
66
|
+
// custodyOutScans.push(JSON.parse(ev.payload));
|
|
67
|
+
// }
|
|
68
|
+
// const custodyOutResponse =
|
|
69
|
+
// await GraphQLClient.getInstance().postCustodyOut(
|
|
70
|
+
// custodyOutScans,
|
|
71
|
+
// eventRow[0].dispatch_id
|
|
72
|
+
// );
|
|
73
|
+
// resolve(
|
|
74
|
+
// custodyOutResponse?.data?.custodyOutBatch?.success === true
|
|
75
|
+
// );
|
|
76
|
+
// break;
|
|
34
77
|
}
|
|
35
78
|
|
|
36
|
-
const custodyOutResponse = await GraphQLClient.getInstance().postCustodyOut(custodyOutScans, eventRow[0].dispatch_id);
|
|
37
|
-
resolve((custodyOutResponse === null || custodyOutResponse === void 0 ? void 0 : (_custodyOutResponse$d = custodyOutResponse.data) === null || _custodyOutResponse$d === void 0 ? void 0 : (_custodyOutResponse$d2 = _custodyOutResponse$d.custodyOutBatch) === null || _custodyOutResponse$d2 === void 0 ? void 0 : _custodyOutResponse$d2.success) === true);
|
|
38
|
-
break;
|
|
39
|
-
|
|
40
79
|
case SyncType.WORKFLOW:
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
80
|
+
{
|
|
81
|
+
// NEW CODE
|
|
82
|
+
const requestBody = JSON.parse(eventRow[0].payload);
|
|
83
|
+
const wfiUpdateResponse = await this.networkInstance.requestPost(ENDPOINTS.BULK_JOB_UPDATE(eventRow[0].dispatch_id), requestBody, {
|
|
84
|
+
requestId: 'wfiUpdate: ' + eventRow[0].dispatch_id
|
|
85
|
+
});
|
|
86
|
+
if (wfiUpdateResponse.data.error) {
|
|
87
|
+
resolve(false);
|
|
88
|
+
} else {
|
|
89
|
+
resolve(true);
|
|
90
|
+
}
|
|
91
|
+
break;
|
|
44
92
|
|
|
93
|
+
// OLD CODE
|
|
94
|
+
// const workflowResp =
|
|
95
|
+
// await GraphQLClient.getInstance().postWorkflowUpdate(
|
|
96
|
+
// JSON.parse(eventRow[0].payload),
|
|
97
|
+
// JSON.parse(eventRow[0].config).params.workflowInstanceId
|
|
98
|
+
// );
|
|
99
|
+
// resolve(
|
|
100
|
+
// !isEmptyOrBlank(workflowResp?.data.updateWorkflowStatus.id)
|
|
101
|
+
// );
|
|
102
|
+
// break;
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
case SyncType.JOB_REMOVAL:
|
|
106
|
+
{
|
|
107
|
+
// NEW CODE
|
|
108
|
+
const requestBody = JSON.parse(eventRow[0].payload);
|
|
109
|
+
const jobResponse = await this.networkInstance.requestPut(ENDPOINTS.BULK_JOB_UPDATE(eventRow[0].dispatch_id), requestBody, {
|
|
110
|
+
requestId: 'jobRemoval: ' + eventRow[0].dispatch_id
|
|
111
|
+
});
|
|
112
|
+
if (jobResponse.data.error) {
|
|
113
|
+
resolve(false);
|
|
114
|
+
} else {
|
|
115
|
+
resolve(true);
|
|
116
|
+
}
|
|
117
|
+
break;
|
|
118
|
+
// OLD CODE
|
|
119
|
+
// const requestBody = JSON.parse(eventRow[0].payload);
|
|
120
|
+
// /* Logger.getInstance().logEvent(
|
|
121
|
+
// 'REQUEST BODY: ',
|
|
122
|
+
// JSON.stringify(requestBody),
|
|
123
|
+
// LOG_TYPE.SDK_DEBUG
|
|
124
|
+
// ); */
|
|
125
|
+
// const jobResponse = await this.networkInstance.requestPut(
|
|
126
|
+
// ENDPOINTS.JOB_REMOVAL(requestBody.dispatchId),
|
|
127
|
+
// requestBody.jobs,
|
|
128
|
+
// { requestId: 'jobRemoval:' + requestBody.dispatchId }
|
|
129
|
+
// );
|
|
130
|
+
// if (jobResponse.data.error) {
|
|
131
|
+
// resolve(false);
|
|
132
|
+
// } else {
|
|
133
|
+
// resolve(true);
|
|
134
|
+
// }
|
|
135
|
+
// break;
|
|
136
|
+
}
|
|
137
|
+
// NEW CODE
|
|
138
|
+
case DispatchSyncType.DISPATCH_UPDATE:
|
|
139
|
+
{
|
|
140
|
+
const requestBody = JSON.parse(eventRow[0].payload);
|
|
141
|
+
const dispatchUpdateResponse = await this.networkInstance.requestPost(ENDPOINTS.BULK_JOB_UPDATE(eventRow[0].dispatch_id), requestBody, {
|
|
142
|
+
requestId: 'dispatchUpdate: ' + eventRow[0].dispatch_id
|
|
143
|
+
});
|
|
144
|
+
if (dispatchUpdateResponse.data.error) {
|
|
145
|
+
resolve(false);
|
|
146
|
+
} else {
|
|
147
|
+
resolve(true);
|
|
148
|
+
}
|
|
149
|
+
break;
|
|
150
|
+
}
|
|
45
151
|
default:
|
|
46
152
|
resolve(null);
|
|
47
153
|
}
|
|
48
154
|
} catch (error) {
|
|
49
155
|
reject(error);
|
|
50
156
|
}
|
|
51
|
-
},
|
|
157
|
+
}, 0); //1000
|
|
52
158
|
});
|
|
53
159
|
}
|
|
54
160
|
|
|
161
|
+
async syncBulkEvent(eventRow) {
|
|
162
|
+
if (eventRow.length < 1) return null;
|
|
163
|
+
return new Promise(async (resolve, reject) => {
|
|
164
|
+
setTimeout(async () => {
|
|
165
|
+
try {
|
|
166
|
+
const requestBody = eventRow.map(event => {
|
|
167
|
+
return JSON.parse(event.payload);
|
|
168
|
+
});
|
|
169
|
+
const response = await this.networkInstance.requestPost(ENDPOINTS.BULK_JOB_UPDATE(eventRow[0].dispatch_id), requestBody, {
|
|
170
|
+
requestId: 'dispatchBulkUpdate: ' + eventRow[0].dispatch_id
|
|
171
|
+
});
|
|
172
|
+
if (response.data.error) {
|
|
173
|
+
resolve(false);
|
|
174
|
+
} else {
|
|
175
|
+
resolve(true);
|
|
176
|
+
}
|
|
177
|
+
} catch (error) {
|
|
178
|
+
reject(error);
|
|
179
|
+
}
|
|
180
|
+
}, 0); //1000
|
|
181
|
+
});
|
|
182
|
+
}
|
|
55
183
|
}
|
|
56
184
|
//# sourceMappingURL=SyncHttpClient.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["HttpClient","GraphQLClient","SyncType","isEmptyOrBlank","SyncHttpClient","constructor","baseURL","syncEvent","eventRow","syncType","length","Promise","resolve","reject","setTimeout","CUSTODY_IN_SCAN","custodyInScans","ev","push","JSON","parse","payload","response","getInstance","postCustodyIn","dispatch_id","data","custodyInBatch","success","CUSTODY_OUT_SCAN","custodyOutScans","custodyOutResponse","postCustodyOut","custodyOutBatch","WORKFLOW","workflowResp","postWorkflowUpdate","config","params","workflowInstanceId","updateWorkflowStatus","id","error"],"sources":["SyncHttpClient.ts"],"sourcesContent":["import HttpClient from '../../../network/client';\nimport type { EventRow } from '../DBConfig';\nimport GraphQLClient from '../../../network/GraphQLClient';\nimport { SyncType } from 'mobile-execution-lib';\nimport { isEmptyOrBlank } from '../../../utils/utils';\n\nexport default class SyncHttpClient extends HttpClient {\n constructor(baseURL: string) {\n super(baseURL);\n }\n\n public async syncEvent(\n eventRow: EventRow[],\n syncType: SyncType\n ): Promise<boolean | null> {\n if (eventRow.length < 1) return null;\n return new Promise(async (resolve, reject) => {\n setTimeout(async () => {\n try {\n switch (syncType) {\n case SyncType.CUSTODY_IN_SCAN:\n const custodyInScans = [];\n for (const ev of eventRow) {\n custodyInScans.push(JSON.parse(ev.payload));\n }\n const response = await GraphQLClient.getInstance().postCustodyIn(\n custodyInScans,\n eventRow[0].dispatch_id\n );\n resolve(response?.data?.custodyInBatch?.success === true);\n break;\n case SyncType.CUSTODY_OUT_SCAN:\n const custodyOutScans = [];\n for (const ev of eventRow) {\n custodyOutScans.push(JSON.parse(ev.payload));\n }\n const custodyOutResponse =\n await GraphQLClient.getInstance().postCustodyOut(\n custodyOutScans,\n eventRow[0].dispatch_id\n );\n resolve(\n custodyOutResponse?.data?.custodyOutBatch?.success === true\n );\n break;\n case SyncType.WORKFLOW:\n const workflowResp =\n await GraphQLClient.getInstance().postWorkflowUpdate(\n JSON.parse(eventRow[0].payload),\n JSON.parse(eventRow[0].config).params.workflowInstanceId\n );\n resolve(\n !isEmptyOrBlank(workflowResp?.data.updateWorkflowStatus.id)\n );\n break;\n default:\n resolve(null);\n }\n } catch (error: any) {\n reject(error);\n }\n }, 1000);\n });\n }\n}\n"],"mappings":"AAAA,OAAOA,UAAP,MAAuB,yBAAvB;AAEA,OAAOC,aAAP,MAA0B,gCAA1B;AACA,SAASC,QAAT,QAAyB,sBAAzB;AACA,SAASC,cAAT,QAA+B,sBAA/B;AAEA,eAAe,MAAMC,cAAN,SAA6BJ,UAA7B,CAAwC;EACrDK,WAAW,CAACC,OAAD,EAAkB;IAC3B,MAAMA,OA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,CAAP;cAGA;;YACF,KAAK1B,QAAQ,CAACgC,QAAd;cACE,MAAMC,YAAY,GAChB,MAAMlC,aAAa,CAACsB,WAAd,GAA4Ba,kBAA5B,CACJjB,IAAI,CAACC,KAAL,CAAWZ,QAAQ,CAAC,CAAD,CAAR,CAAYa,OAAvB,CADI,EAEJF,IAAI,CAACC,KAAL,CAAWZ,QAAQ,CAAC,CAAD,CAAR,CAAY6B,MAAvB,EAA+BC,MAA/B,CAAsCC,kBAFlC,CADR;cAKA3B,OAAO,CACL,CAACT,cAAc,CAACgC,YAAD,aAACA,YAAD,uBAACA,YAAY,CAAET,IAAd,CAAmBc,oBAAnB,CAAwCC,EAAzC,CADV,CAAP;cAGA;;YACF;cACE7B,OAAO,CAAC,IAAD,CAAP;UArCJ;QAuCD,CAxCD,CAwCE,OAAO8B,KAAP,EAAmB;UACnB7B,MAAM,CAAC6B,KAAD,CAAN;QACD;MACF,CA5CS,EA4CP,IA5CO,CAAV;IA6CD,CA9CM,CAAP;EA+CD;;AAzDoD"}
|
|
1
|
+
{"version":3,"names":["HttpClient","DispatchSyncType","NetworkClient","ENDPOINTS","IDispatch","SyncType","SyncHttpClient","constructor","baseURL","_defineProperty","networkInstance","syncEvent","eventRow","syncType","length","Promise","resolve","reject","setTimeout","CUSTODY_IN_SCAN","requestBody","JSON","parse","payload","custodyInResponse","requestPost","BULK_JOB_UPDATE","dispatch_id","requestId","data","error","CUSTODY_OUT_SCAN","WORKFLOW","wfiUpdateResponse","JOB_REMOVAL","jobResponse","requestPut","DISPATCH_UPDATE","dispatchUpdateResponse","syncBulkEvent","map","event","response"],"sources":["SyncHttpClient.ts"],"sourcesContent":["import HttpClient from '../../../network/client';\nimport { DispatchSyncType, EventRow } from '../DBConfig';\nimport GraphQLClient from '../../../network/GraphQLClient';\nimport NetworkClient from '../../../network/NetworkClient';\nimport { ExecEngineSyncType } from '../DBConfig';\n\nimport { isEmptyOrBlank } from '../../../utils/utils';\nimport { ENDPOINTS } from '../../../constants/apiConstants';\nimport Logger, { LOG_TYPE } from '../../../utils/Logger';\n\nimport { IDispatch } from '@os1-platform/platform-coreos-execution-engine-sdk';\nconst SyncType = IDispatch.SyncType;\n\nexport default class SyncHttpClient extends HttpClient {\n protected readonly networkInstance: NetworkClient;\n constructor(baseURL: string) {\n super(baseURL);\n this.networkInstance = new NetworkClient(baseURL);\n }\n\n public async syncEvent(\n eventRow: EventRow[],\n syncType: ExecEngineSyncType | DispatchSyncType\n ): Promise<boolean | null> {\n if (eventRow.length < 1) return null;\n return new Promise(async (resolve, reject) => {\n setTimeout(async () => {\n try {\n switch (syncType) {\n case SyncType.CUSTODY_IN_SCAN: {\n // NEW CODE\n const requestBody = JSON.parse(eventRow[0].payload);\n const custodyInResponse = await this.networkInstance.requestPost(\n ENDPOINTS.BULK_JOB_UPDATE(eventRow[0].dispatch_id),\n requestBody,\n { requestId: 'custodyIn: ' + eventRow[0].dispatch_id }\n );\n\n if (custodyInResponse.data.error) {\n resolve(false);\n } else {\n resolve(true);\n }\n break;\n\n // OLD CODE\n // const custodyInScans = [];\n // for (const ev of eventRow) {\n // custodyInScans.push(JSON.parse(ev.payload));\n // }\n // const response = await GraphQLClient.getInstance().postCustodyIn(\n // custodyInScans,\n // eventRow[0].dispatch_id\n // );\n // resolve(response?.data?.custodyInBatch?.success === true);\n // break;\n }\n case SyncType.CUSTODY_OUT_SCAN: {\n // NEW CODE\n const requestBody = JSON.parse(eventRow[0].payload);\n const custodyInResponse = await this.networkInstance.requestPost(\n ENDPOINTS.BULK_JOB_UPDATE(eventRow[0].dispatch_id),\n requestBody,\n { requestId: 'custodyIn: ' + eventRow[0].dispatch_id }\n );\n\n if (custodyInResponse.data.error) {\n resolve(false);\n } else {\n resolve(true);\n }\n break;\n\n // OLD CODE\n // const custodyOutScans = [];\n // for (const ev of eventRow) {\n // custodyOutScans.push(JSON.parse(ev.payload));\n // }\n // const custodyOutResponse =\n // await GraphQLClient.getInstance().postCustodyOut(\n // custodyOutScans,\n // eventRow[0].dispatch_id\n // );\n // resolve(\n // custodyOutResponse?.data?.custodyOutBatch?.success === true\n // );\n // break;\n }\n case SyncType.WORKFLOW: {\n // NEW CODE\n const requestBody = JSON.parse(eventRow[0].payload);\n const wfiUpdateResponse = await this.networkInstance.requestPost(\n ENDPOINTS.BULK_JOB_UPDATE(eventRow[0].dispatch_id),\n requestBody,\n { requestId: 'wfiUpdate: ' + eventRow[0].dispatch_id }\n );\n\n if (wfiUpdateResponse.data.error) {\n resolve(false);\n } else {\n resolve(true);\n }\n break;\n\n // OLD CODE\n // const workflowResp =\n // await GraphQLClient.getInstance().postWorkflowUpdate(\n // JSON.parse(eventRow[0].payload),\n // JSON.parse(eventRow[0].config).params.workflowInstanceId\n // );\n // resolve(\n // !isEmptyOrBlank(workflowResp?.data.updateWorkflowStatus.id)\n // );\n // break;\n }\n case SyncType.JOB_REMOVAL: {\n // NEW CODE\n const requestBody = JSON.parse(eventRow[0].payload);\n const jobResponse = await this.networkInstance.requestPut(\n ENDPOINTS.BULK_JOB_UPDATE(eventRow[0].dispatch_id),\n requestBody,\n { requestId: 'jobRemoval: ' + eventRow[0].dispatch_id }\n );\n\n if (jobResponse.data.error) {\n resolve(false);\n } else {\n resolve(true);\n }\n break;\n // OLD CODE\n // const requestBody = JSON.parse(eventRow[0].payload);\n // /* Logger.getInstance().logEvent(\n // 'REQUEST BODY: ',\n // JSON.stringify(requestBody),\n // LOG_TYPE.SDK_DEBUG\n // ); */\n // const jobResponse = await this.networkInstance.requestPut(\n // ENDPOINTS.JOB_REMOVAL(requestBody.dispatchId),\n // requestBody.jobs,\n // { requestId: 'jobRemoval:' + requestBody.dispatchId }\n // );\n // if (jobResponse.data.error) {\n // resolve(false);\n // } else {\n // resolve(true);\n // }\n // break;\n }\n // NEW CODE\n case DispatchSyncType.DISPATCH_UPDATE: {\n const requestBody = JSON.parse(eventRow[0].payload);\n const dispatchUpdateResponse =\n await this.networkInstance.requestPost(\n ENDPOINTS.BULK_JOB_UPDATE(eventRow[0].dispatch_id),\n requestBody,\n { requestId: 'dispatchUpdate: ' + eventRow[0].dispatch_id }\n );\n\n if (dispatchUpdateResponse.data.error) {\n resolve(false);\n } else {\n resolve(true);\n }\n break;\n }\n default:\n resolve(null);\n }\n } catch (error: any) {\n reject(error);\n }\n }, 0); //1000\n });\n }\n\n public async syncBulkEvent(eventRow: EventRow[]): Promise<boolean | null> {\n if (eventRow.length < 1) return null;\n return new Promise(async (resolve, reject) => {\n setTimeout(async () => {\n try {\n const requestBody = eventRow.map((event) => {\n return JSON.parse(event.payload);\n });\n const response = await this.networkInstance.requestPost(\n ENDPOINTS.BULK_JOB_UPDATE(eventRow[0].dispatch_id),\n requestBody,\n { requestId: 'dispatchBulkUpdate: ' + eventRow[0].dispatch_id }\n );\n\n if (response.data.error) {\n resolve(false);\n } else {\n resolve(true);\n }\n } catch (error: any) {\n reject(error);\n }\n }, 0); //1000\n });\n }\n}\n"],"mappings":";;;AAAA,OAAOA,UAAU,MAAM,yBAAyB;AAChD,SAASC,gBAAgB,QAAkB,aAAa;AAExD,OAAOC,aAAa,MAAM,gCAAgC;AAI1D,SAASC,SAAS,QAAQ,iCAAiC;AAG3D,SAASC,SAAS,QAAQ,oDAAoD;AAC9E,MAAMC,QAAQ,GAAGD,SAAS,CAACC,QAAQ;AAEnC,eAAe,MAAMC,cAAc,SAASN,UAAU,CAAC;EAErDO,WAAWA,CAACC,OAAe,EAAE;IAC3B,KAAK,CAACA,OAAO,CAAC;IAACC,eAAA;IACf,IAAI,CAACC,eAAe,GAAG,IAAIR,aAAa,CAACM,OAAO,CAAC;EACnD;EAEA,MAAaG,SAASA,CACpBC,QAAoB,EACpBC,QAA+C,EACtB;IACzB,IAAID,QAAQ,CAACE,MAAM,GAAG,CAAC,EAAE,OAAO,IAAI;IACpC,OAAO,IAAIC,OAAO,CAAC,OAAOC,OAAO,EAAEC,MAAM,KAAK;MAC5CC,UAAU,CAAC,YAAY;QACrB,IAAI;UACF,QAAQL,QAAQ;YACd,KAA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CAACe,WAAW,CAAC,EAClDP,WAAW,EACX;YAAEQ,SAAS,EAAE,sBAAsB,GAAGhB,QAAQ,CAAC,CAAC,CAAC,CAACe;UAAY,CAChE,CAAC;UAED,IAAIe,QAAQ,CAACb,IAAI,CAACC,KAAK,EAAE;YACvBd,OAAO,CAAC,KAAK,CAAC;UAChB,CAAC,MAAM;YACLA,OAAO,CAAC,IAAI,CAAC;UACf;QACF,CAAC,CAAC,OAAOc,KAAU,EAAE;UACnBb,MAAM,CAACa,KAAK,CAAC;QACf;MACF,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC;IACT,CAAC,CAAC;EACJ;AACF"}
|
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
export let SdkSyncType
|
|
2
|
-
|
|
3
|
-
(function (SdkSyncType) {
|
|
1
|
+
export let SdkSyncType = /*#__PURE__*/function (SdkSyncType) {
|
|
4
2
|
SdkSyncType[SdkSyncType["EVENTS_SYNC"] = 0] = "EVENTS_SYNC";
|
|
5
3
|
SdkSyncType[SdkSyncType["DOCUMENT_SYNC"] = 1] = "DOCUMENT_SYNC";
|
|
6
|
-
|
|
4
|
+
return SdkSyncType;
|
|
5
|
+
}({});
|
|
7
6
|
//# sourceMappingURL=DispatchModels.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["SdkSyncType"],"sources":["DispatchModels.ts"],"sourcesContent":["import
|
|
1
|
+
{"version":3,"names":["SdkSyncType"],"sources":["DispatchModels.ts"],"sourcesContent":["import {\n IDispatch,\n IDispatchExecutor,\n} from '@os1-platform/platform-coreos-execution-engine-sdk';\n\nexport interface BaseETProps {\n showProgress: (loading: boolean) => void;\n}\n\nexport enum SdkSyncType {\n EVENTS_SYNC,\n DOCUMENT_SYNC,\n}\n\nexport interface JobObjectiveType {\n objectiveId: string;\n jobId: string;\n groupId?: string;\n additionalData?: any;\n}\n\nexport interface endEvent {\n taskId: string;\n nextTaskId: string;\n timestamp: number;\n // groupId?: string;\n customData?: any;\n etData: {\n [key: string]: any;\n /* [key: string]: {\n workflowInstanceId: string;\n additionalData?: any;\n success?: boolean;\n eventCode?: string;\n reasonCode?: string;\n [key: string]: any;\n }; */\n };\n meta?: any;\n}\n\nexport interface onScanEvent {\n taskId: string;\n timestamp: number;\n customData?: any;\n etData: {\n eventCode: string;\n reasonCode: string;\n success: boolean;\n endTime: number;\n scannedData: {\n jobId: string;\n scanValue: string;\n shipmentFlow: string; //displayinfo\n groupId: string; //displayinfo\n }[];\n };\n meta?: any;\n}\n\nexport interface onScanRemoveEvent {\n taskId: string;\n timestamp: number;\n customData?: any;\n etData: {\n scannedData: {\n scanValue: string;\n }[];\n };\n meta?: any;\n}\n\nexport interface startEvent {\n timestamp: number;\n taskId: string;\n // groupId?: string;\n customData?: any;\n etData: {\n [key: string]: any;\n // [key: string]: {\n // workflowInstanceId: string;\n // additionalData?: any;\n // [key: string]: any;\n // };\n };\n}\n\nexport interface stateParams {\n next_states: IDispatch.IExecutionTaskQueryResponse;\n rootMetaData: {\n meta: any;\n customEventsData?: any;\n statusFilter: IDispatchExecutor.ExecutionStatus[];\n prefixedMergedObjectiveId: string;\n };\n has_multiple_ets?: boolean;\n}\n"],"mappings":"AASA,WAAYA,WAAW,0BAAXA,WAAW;EAAXA,WAAW,CAAXA,WAAW;EAAXA,WAAW,CAAXA,WAAW;EAAA,OAAXA,WAAW;AAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":[],"sources":["ReasonCodes.ts"],"sourcesContent":["export interface ReasonCodes {\n description: string;\n isEnabled: boolean;\n reasonCode: string;\n isSystemDefined: boolean;\n}\n"],"mappings":""}
|
|
1
|
+
{"version":3,"names":[],"sources":["ReasonCodes.ts"],"sourcesContent":["export interface ReasonCodes {\n description: string;\n isEnabled: boolean;\n reasonCode: string;\n isSystemDefined: boolean;\n}\n\nexport interface EventCodes {\n description: string;\n eventCode: string;\n successEvent: boolean;\n}\n"],"mappings":""}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
|
|
1
|
+
export {};
|
|
2
2
|
//# sourceMappingURL=ETBaseModels.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":[],"sources":["ETBaseModels.ts"],"sourcesContent":["
|
|
1
|
+
{"version":3,"names":[],"sources":["ETBaseModels.ts"],"sourcesContent":["import { ExecutionTaskID } from './ETConfig';\n\nexport type BaseETResponse = {\n id: ExecutionTaskID;\n mergedObjectiveIds: Array<string>;\n /**\n * Success flag for the operation performed by user\n */\n entityCode: string;\n success: boolean;\n /**\n * Event code\n */\n eventCode: string;\n /**\n * Reason code\n */\n reasonCode: string;\n /**\n * Meta data related to execution of task\n */\n meta?: {\n /**\n * Epoch timestamp for the start of task\n */\n // startTime?: number;\n /**\n * Epoch timestamp for the end of task\n */\n // endTime?: number;\n /**\n * Location at start of task\n */\n // location?: {\n /**\n * Latitude\n */\n // latitude?: string;\n /**\n * Longitude\n */\n // longitude?: string;\n // };\n /**\n * Unique identifier of user performing the action\n */\n userDetails: UserData;\n /**\n * Check if ETs are executed in merged form\n */\n // isMerged?: boolean;\n };\n};\nexport interface UserData {\n id: string;\n name: string;\n}\n\n/**\n * Title of instruction\n */\nexport type Title = string;\n/**\n * Message of instruction\n */\nexport type Message = string;\n/**\n * Can go back\n */\nexport type CanGoBack = boolean;\n\nexport type BaseETRequest = {\n title: Title;\n message?: Message;\n canGoBack?: CanGoBack;\n applicableReasons?: ApplicableReasons | NewApplicableReasons;\n taskMeta?: { [k: string]: any };\n wfMeta?: { [k: string]: any };\n navigation?: any;\n route?: any;\n taskName: string;\n mergedObjectiveId: Array<string>;\n};\n\nexport type ApplicableReasons = {\n [k: string]: string[];\n};\n\nexport type NewApplicableReasons = {\n success: { [k: string]: string[] };\n failure: { [k: string]: string[] };\n goBack?: { [k: string]: string[] };\n};\n\nexport interface ETSummary {\n name: string;\n eventCode: string;\n reasonCode: string;\n reasonCodeDesc: string | null | undefined;\n}\n\nexport interface CompleteSummary {\n jobId: string;\n objectiveRef: string;\n jobObjectiveSummary: ETSummary[];\n}\n\nexport interface ObjectiveSummary {\n entityCode: string;\n eventCode: string;\n reasonCode: string;\n reasonCodeDesc?: string;\n}\n"],"mappings":""}
|
|
@@ -1,6 +1,4 @@
|
|
|
1
|
-
export let ExecutionTaskID
|
|
2
|
-
|
|
3
|
-
(function (ExecutionTaskID) {
|
|
1
|
+
export let ExecutionTaskID = /*#__PURE__*/function (ExecutionTaskID) {
|
|
4
2
|
ExecutionTaskID["DELIVER"] = "etask:dcac5d49-c54c-5c38-a780-ad2e9ba5e2e2";
|
|
5
3
|
ExecutionTaskID["DOODLE"] = "etask:cea7c9a7-3ee7-52e9-ab3e-82849675d745";
|
|
6
4
|
ExecutionTaskID["COMPLETED_FAILURE"] = "etask:e04ab83d-2a02-5970-ade9-e2a8a879b200";
|
|
@@ -19,11 +17,10 @@ export let ExecutionTaskID;
|
|
|
19
17
|
ExecutionTaskID["VERIFY_INPUT"] = "etask:6fc10a60-a144-5798-97f3-1f12e77f56e2";
|
|
20
18
|
ExecutionTaskID["DELIVER_CASH"] = "etask:2fffdf62-62b3-5e70-bd9e-d4d2644ee2fe";
|
|
21
19
|
ExecutionTaskID["HTTP_REQUEST_ET"] = "etask:e148b862-8368-5586-b29d-1eda95ffc8c4";
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
(function (ExecutionTaskName) {
|
|
20
|
+
ExecutionTaskID["VALIDATE_OTP_ET"] = "etask:8d5b96f3-7342-5e25-a57f-30004f53de17";
|
|
21
|
+
return ExecutionTaskID;
|
|
22
|
+
}({});
|
|
23
|
+
export let ExecutionTaskName = /*#__PURE__*/function (ExecutionTaskName) {
|
|
27
24
|
ExecutionTaskName["DELIVER"] = "Deliver";
|
|
28
25
|
ExecutionTaskName["DOODLE"] = "Signature";
|
|
29
26
|
ExecutionTaskName["COMPLETED_FAILURE"] = "Please wait...";
|
|
@@ -42,17 +39,14 @@ export let ExecutionTaskName;
|
|
|
42
39
|
ExecutionTaskName["VERIFY_INPUT"] = "Verifying Input";
|
|
43
40
|
ExecutionTaskName["DELIVER_CASH"] = "Drop Cash";
|
|
44
41
|
ExecutionTaskName["HTTP_REQUEST_ET"] = "Network Request";
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
(function (CustomScreens) {
|
|
42
|
+
ExecutionTaskName["VALIDATE_OTP_ET"] = "Validate OTP";
|
|
43
|
+
return ExecutionTaskName;
|
|
44
|
+
}({});
|
|
45
|
+
export let CustomScreens = /*#__PURE__*/function (CustomScreens) {
|
|
50
46
|
CustomScreens["REMARK_SCREEN"] = "REMARKS_SCREEN";
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
export let EntityCode
|
|
54
|
-
|
|
55
|
-
(function (EntityCode) {
|
|
47
|
+
return CustomScreens;
|
|
48
|
+
}({});
|
|
49
|
+
export let EntityCode = /*#__PURE__*/function (EntityCode) {
|
|
56
50
|
EntityCode["DELIVER"] = "0010";
|
|
57
51
|
EntityCode["DOODLE"] = "0014";
|
|
58
52
|
EntityCode["COMPLETED_FAILURE"] = "0008";
|
|
@@ -71,18 +65,15 @@ export let EntityCode;
|
|
|
71
65
|
EntityCode["VERIFY_INPUT"] = "0020";
|
|
72
66
|
EntityCode["DELIVER_CASH"] = "0022";
|
|
73
67
|
EntityCode["HTTP_REQUEST_ET"] = "0023";
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
(function (BaseEventCodes) {
|
|
68
|
+
EntityCode["VALIDATE_OTP_ET"] = "0052";
|
|
69
|
+
return EntityCode;
|
|
70
|
+
}({});
|
|
71
|
+
export let BaseEventCodes = /*#__PURE__*/function (BaseEventCodes) {
|
|
79
72
|
BaseEventCodes["ENTITY_SUCCESS"] = "E-010";
|
|
80
73
|
BaseEventCodes["ENTITY_FAILURE"] = "E-011";
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
export let FinalETName
|
|
84
|
-
|
|
85
|
-
(function (FinalETName) {
|
|
74
|
+
return BaseEventCodes;
|
|
75
|
+
}({});
|
|
76
|
+
export let FinalETName = /*#__PURE__*/function (FinalETName) {
|
|
86
77
|
FinalETName["DELIVER"] = "Deliver";
|
|
87
78
|
FinalETName["DOODLE"] = "Doodle";
|
|
88
79
|
FinalETName["COMPLETED_FAILURE"] = "Completed-Failure";
|
|
@@ -100,5 +91,7 @@ export let FinalETName;
|
|
|
100
91
|
FinalETName["DISPLAY"] = "etask:574ff9b0-c49c-5eb5-b550-8548ae0cab44";
|
|
101
92
|
FinalETName["VERIFY_INPUT"] = "etask:6fc10a60-a144-5798-97f3-1f12e77f56e2";
|
|
102
93
|
FinalETName["DELIVER_CASH"] = "etask:2fffdf62-62b3-5e70-bd9e-d4d2644ee2fe";
|
|
103
|
-
|
|
94
|
+
FinalETName["VALIDATE_OTP_ET"] = "Validate OTP";
|
|
95
|
+
return FinalETName;
|
|
96
|
+
}({});
|
|
104
97
|
//# sourceMappingURL=ETConfig.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["ExecutionTaskID","ExecutionTaskName","CustomScreens","EntityCode","BaseEventCodes","FinalETName"],"sources":["ETConfig.ts"],"sourcesContent":["export enum ExecutionTaskID {\n DELIVER = 'etask:dcac5d49-c54c-5c38-a780-ad2e9ba5e2e2',\n DOODLE = 'etask:cea7c9a7-3ee7-52e9-ab3e-82849675d745',\n COMPLETED_FAILURE = 'etask:e04ab83d-2a02-5970-ade9-e2a8a879b200',\n COMPLETED_SUCCESS = 'etask:134e93b4-49a8-59b9-bc6c-7bd9045728ff',\n CAPTURE_INPUT = 'etask:7b5637cc-570e-5c9d-b184-ecfbbd7c198d',\n START_WORKFLOW = 'etask:952f3754-12e8-5ff2-93a8-aca383d18e56',\n FORMS = 'etask:80446347-ede5-5cf9-8e56-b3d59fda4b5c',\n IMAGE_CAPTURE = 'etask:9370d00a-8d84-5bf9-94bb-cd8cc73eeeec',\n INIT_PAYMENT = 'etask:4eb8d36b-6762-5c53-aca6-95b1f4e3aa3f',\n PROCESS_PAYMENT = 'etask:9a559375-02a5-50fe-9ce4-0a36df6f324e',\n COMPLETE_PAYMENT = 'etask:0e6c7bd7-c9ab-5b82-85b2-a054249bc1f1',\n PICKUP = 'etask:04d2414c-ddc1-552e-af02-78073dbb8ff7',\n SCAN = 'etask:28cba55d-2aad-5568-863a-9e7e645f8c7b',\n VERIFY_LOCATION = 'etask:7f3897da-3a1f-5736-b8e5-5d9f131b13cd',\n DISPLAY = 'etask:574ff9b0-c49c-5eb5-b550-8548ae0cab44',\n VERIFY_INPUT = 'etask:6fc10a60-a144-5798-97f3-1f12e77f56e2',\n DELIVER_CASH = 'etask:2fffdf62-62b3-5e70-bd9e-d4d2644ee2fe',\n HTTP_REQUEST_ET = 'etask:e148b862-8368-5586-b29d-1eda95ffc8c4',\n}\n\nexport enum ExecutionTaskName {\n DELIVER = 'Deliver',\n DOODLE = 'Signature',\n COMPLETED_FAILURE = 'Please wait...',\n COMPLETED_SUCCESS = 'Please wait...',\n CAPTURE_INPUT = 'Form',\n START_WORKFLOW = 'Please wait...',\n FORMS = 'Form',\n IMAGE_CAPTURE = 'Capture Image',\n INIT_PAYMENT = 'Payment',\n PROCESS_PAYMENT = 'Processing Payment',\n COMPLETE_PAYMENT = 'Completing Payment',\n PICKUP = 'Pickup',\n SCAN = 'Scan',\n VERIFY_LOCATION = 'Verify Location',\n DISPLAY = 'Display',\n VERIFY_INPUT = 'Verifying Input',\n DELIVER_CASH = 'Drop Cash',\n HTTP_REQUEST_ET = 'Network Request',\n}\n\nexport enum CustomScreens {\n REMARK_SCREEN = 'REMARKS_SCREEN',\n}\nexport enum EntityCode {\n DELIVER = '0010',\n DOODLE = '0014',\n COMPLETED_FAILURE = '0008',\n COMPLETED_SUCCESS = '0007',\n CAPTURE_INPUT = '0012',\n START_WORKFLOW = '0006',\n FORMS = '0015',\n IMAGE_CAPTURE = '0011',\n INIT_PAYMENT = '0017',\n PROCESS_PAYMENT = '0018',\n COMPLETE_PAYMENT = '0019',\n PICKUP = '0009',\n SCAN = '0016',\n VERIFY_LOCATION = '0021',\n DISPLAY = '0013',\n VERIFY_INPUT = '0020',\n DELIVER_CASH = '0022',\n HTTP_REQUEST_ET = '0023', //todo change Entity ID here\n}\n\nexport enum BaseEventCodes {\n ENTITY_SUCCESS = 'E-010',\n ENTITY_FAILURE = 'E-011',\n}\n\nexport enum FinalETName {\n DELIVER = 'Deliver',\n DOODLE = 'Doodle',\n COMPLETED_FAILURE = 'Completed-Failure',\n COMPLETED_SUCCESS = 'Completed-Success',\n CAPTURE_INPUT = 'etask:7b5637cc-570e-5c9d-b184-ecfbbd7c198d',\n START_WORKFLOW = 'Start',\n FORMS = 'Form',\n IMAGE_CAPTURE = 'etask:9370d00a-8d84-5bf9-94bb-cd8cc73eeeec',\n INIT_PAYMENT = 'etask:4eb8d36b-6762-5c53-aca6-95b1f4e3aa3f',\n PROCESS_PAYMENT = 'etask:9a559375-02a5-50fe-9ce4-0a36df6f324e',\n COMPLETE_PAYMENT = 'etask:0e6c7bd7-c9ab-5b82-85b2-a054249bc1f1',\n PICKUP = 'Pickup',\n SCAN = 'Scan',\n VERIFY_LOCATION = 'etask:7f3897da-3a1f-5736-b8e5-5d9f131b13cd',\n DISPLAY = 'etask:574ff9b0-c49c-5eb5-b550-8548ae0cab44',\n VERIFY_INPUT = 'etask:6fc10a60-a144-5798-97f3-1f12e77f56e2',\n DELIVER_CASH = 'etask:2fffdf62-62b3-5e70-bd9e-d4d2644ee2fe',\n}\n"],"mappings":"AAAA,WAAYA,
|
|
1
|
+
{"version":3,"names":["ExecutionTaskID","ExecutionTaskName","CustomScreens","EntityCode","BaseEventCodes","FinalETName"],"sources":["ETConfig.ts"],"sourcesContent":["export enum ExecutionTaskID {\n DELIVER = 'etask:dcac5d49-c54c-5c38-a780-ad2e9ba5e2e2',\n DOODLE = 'etask:cea7c9a7-3ee7-52e9-ab3e-82849675d745',\n COMPLETED_FAILURE = 'etask:e04ab83d-2a02-5970-ade9-e2a8a879b200',\n COMPLETED_SUCCESS = 'etask:134e93b4-49a8-59b9-bc6c-7bd9045728ff',\n CAPTURE_INPUT = 'etask:7b5637cc-570e-5c9d-b184-ecfbbd7c198d',\n START_WORKFLOW = 'etask:952f3754-12e8-5ff2-93a8-aca383d18e56',\n FORMS = 'etask:80446347-ede5-5cf9-8e56-b3d59fda4b5c',\n IMAGE_CAPTURE = 'etask:9370d00a-8d84-5bf9-94bb-cd8cc73eeeec',\n INIT_PAYMENT = 'etask:4eb8d36b-6762-5c53-aca6-95b1f4e3aa3f',\n PROCESS_PAYMENT = 'etask:9a559375-02a5-50fe-9ce4-0a36df6f324e',\n COMPLETE_PAYMENT = 'etask:0e6c7bd7-c9ab-5b82-85b2-a054249bc1f1',\n PICKUP = 'etask:04d2414c-ddc1-552e-af02-78073dbb8ff7',\n SCAN = 'etask:28cba55d-2aad-5568-863a-9e7e645f8c7b',\n VERIFY_LOCATION = 'etask:7f3897da-3a1f-5736-b8e5-5d9f131b13cd',\n DISPLAY = 'etask:574ff9b0-c49c-5eb5-b550-8548ae0cab44',\n VERIFY_INPUT = 'etask:6fc10a60-a144-5798-97f3-1f12e77f56e2',\n DELIVER_CASH = 'etask:2fffdf62-62b3-5e70-bd9e-d4d2644ee2fe',\n HTTP_REQUEST_ET = 'etask:e148b862-8368-5586-b29d-1eda95ffc8c4',\n VALIDATE_OTP_ET = 'etask:8d5b96f3-7342-5e25-a57f-30004f53de17',\n}\n\nexport enum ExecutionTaskName {\n DELIVER = 'Deliver',\n DOODLE = 'Signature',\n COMPLETED_FAILURE = 'Please wait...',\n COMPLETED_SUCCESS = 'Please wait...',\n CAPTURE_INPUT = 'Form',\n START_WORKFLOW = 'Please wait...',\n FORMS = 'Form',\n IMAGE_CAPTURE = 'Capture Image',\n INIT_PAYMENT = 'Payment',\n PROCESS_PAYMENT = 'Processing Payment',\n COMPLETE_PAYMENT = 'Completing Payment',\n PICKUP = 'Pickup',\n SCAN = 'Scan',\n VERIFY_LOCATION = 'Verify Location',\n DISPLAY = 'Display',\n VERIFY_INPUT = 'Verifying Input',\n DELIVER_CASH = 'Drop Cash',\n HTTP_REQUEST_ET = 'Network Request',\n VALIDATE_OTP_ET = 'Validate OTP',\n}\n\nexport enum CustomScreens {\n REMARK_SCREEN = 'REMARKS_SCREEN',\n}\nexport enum EntityCode {\n DELIVER = '0010',\n DOODLE = '0014',\n COMPLETED_FAILURE = '0008',\n COMPLETED_SUCCESS = '0007',\n CAPTURE_INPUT = '0012',\n START_WORKFLOW = '0006',\n FORMS = '0015',\n IMAGE_CAPTURE = '0011',\n INIT_PAYMENT = '0017',\n PROCESS_PAYMENT = '0018',\n COMPLETE_PAYMENT = '0019',\n PICKUP = '0009',\n SCAN = '0016',\n VERIFY_LOCATION = '0021',\n DISPLAY = '0013',\n VERIFY_INPUT = '0020',\n DELIVER_CASH = '0022',\n HTTP_REQUEST_ET = '0023', //todo change Entity ID here\n VALIDATE_OTP_ET = '0052',\n}\n\nexport enum BaseEventCodes {\n ENTITY_SUCCESS = 'E-010',\n ENTITY_FAILURE = 'E-011',\n}\n\nexport enum FinalETName {\n DELIVER = 'Deliver',\n DOODLE = 'Doodle',\n COMPLETED_FAILURE = 'Completed-Failure',\n COMPLETED_SUCCESS = 'Completed-Success',\n CAPTURE_INPUT = 'etask:7b5637cc-570e-5c9d-b184-ecfbbd7c198d',\n START_WORKFLOW = 'Start',\n FORMS = 'Form',\n IMAGE_CAPTURE = 'etask:9370d00a-8d84-5bf9-94bb-cd8cc73eeeec',\n INIT_PAYMENT = 'etask:4eb8d36b-6762-5c53-aca6-95b1f4e3aa3f',\n PROCESS_PAYMENT = 'etask:9a559375-02a5-50fe-9ce4-0a36df6f324e',\n COMPLETE_PAYMENT = 'etask:0e6c7bd7-c9ab-5b82-85b2-a054249bc1f1',\n PICKUP = 'Pickup',\n SCAN = 'Scan',\n VERIFY_LOCATION = 'etask:7f3897da-3a1f-5736-b8e5-5d9f131b13cd',\n DISPL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AAU;EAAVA,UAAU;EAAVA,UAAU;EAAA,OAAVA,UAAU;AAAA;AAsBtB,WAAYC,cAAc,0BAAdA,cAAc;EAAdA,cAAc;EAAdA,cAAc;EAAA,OAAdA,cAAc;AAAA;AAK1B,WAAYC,WAAW,0BAAXA,WAAW;EAAXA,WAAW;EAAXA,WAAW;EAAXA,WAAW;EAAXA,WAAW;EAAXA,WAAW;EAAXA,WAAW;EAAXA,WAAW;EAAXA,WAAW;EAAXA,WAAW;EAAXA,WAAW;EAAXA,WAAW;EAAXA,WAAW;EAAXA,WAAW;EAAXA,WAAW;EAAXA,WAAW;EAAXA,WAAW;EAAXA,WAAW;EAAXA,WAAW;EAAA,OAAXA,WAAW;AAAA"}
|
package/lib/module/models/sdk.js
CHANGED
|
@@ -1,8 +1,7 @@
|
|
|
1
|
-
export let ENVIRONMENT
|
|
2
|
-
|
|
3
|
-
(function (ENVIRONMENT) {
|
|
1
|
+
export let ENVIRONMENT = /*#__PURE__*/function (ENVIRONMENT) {
|
|
4
2
|
ENVIRONMENT["DEV"] = "dev";
|
|
5
3
|
ENVIRONMENT["PRE_PROD"] = "preprod";
|
|
6
4
|
ENVIRONMENT["PROD"] = "prod";
|
|
7
|
-
|
|
5
|
+
return ENVIRONMENT;
|
|
6
|
+
}({});
|
|
8
7
|
//# sourceMappingURL=sdk.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["ENVIRONMENT"],"sources":["sdk.ts"],"sourcesContent":["
|
|
1
|
+
{"version":3,"names":["ENVIRONMENT"],"sources":["sdk.ts"],"sourcesContent":["import type { EventCodes } from './ReasonCodes';\n\nexport interface DispatchSDKConfig {\n tenantID: string;\n userID: string;\n userName: string;\n tenantBaseURL: string;\n headers?: { [key: string]: any };\n enableLogging?: boolean;\n syncRetryCount?: number;\n accessToken: string;\n sentry?: {\n env: ENVIRONMENT;\n enabled: boolean;\n dsn?: string;\n };\n notificationConfig?: {\n title: string;\n description: string;\n interval: number;\n };\n eventMapping?: EventCodes[];\n debugLevelLog?: Boolean;\n callbacks?: {\n fetchPhoneNumbersCallback?: (\n sdsIds: string[]\n ) => Promise<{ key: string; value: string[] }>;\n };\n}\n\nexport enum ENVIRONMENT {\n DEV = 'dev',\n PRE_PROD = 'preprod',\n PROD = 'prod',\n}\n"],"mappings":"AA8BA,WAAYA,WAAW,0BAAXA,WAAW;EAAXA,WAAW;EAAXA,WAAW;EAAXA,WAAW;EAAA,OAAXA,WAAW;AAAA"}
|
|
@@ -1,60 +1,49 @@
|
|
|
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
|
-
function
|
|
4
|
-
|
|
2
|
+
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
3
|
+
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return typeof key === "symbol" ? key : String(key); }
|
|
4
|
+
function _toPrimitive(input, hint) { if (typeof input !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (typeof res !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
5
5
|
import React from 'react';
|
|
6
6
|
import { DeviceEventEmitter, findNodeHandle, requireNativeComponent, UIManager } from 'react-native';
|
|
7
7
|
const RSSignatureView = requireNativeComponent('RSSignatureView');
|
|
8
|
-
|
|
9
8
|
class SignatureCapture extends React.Component {
|
|
10
9
|
constructor(props) {
|
|
11
10
|
super(props);
|
|
12
|
-
|
|
13
11
|
_defineProperty(this, "subscriptions", void 0);
|
|
14
|
-
|
|
15
12
|
this.onChange = this.onChange.bind(this);
|
|
16
13
|
this.subscriptions = [];
|
|
17
14
|
}
|
|
18
|
-
|
|
19
15
|
onChange(event) {
|
|
20
16
|
if (event.nativeEvent.encoded) {
|
|
21
17
|
if (!this.props.onSaveEvent) {
|
|
22
18
|
return;
|
|
23
19
|
}
|
|
24
|
-
|
|
25
20
|
this.props.onSaveEvent({
|
|
26
21
|
encoded: event.nativeEvent.encoded
|
|
27
22
|
});
|
|
28
23
|
}
|
|
29
|
-
|
|
30
24
|
if (event.nativeEvent.dragged) {
|
|
31
25
|
if (!this.props.onDragEvent) {
|
|
32
26
|
return;
|
|
33
27
|
}
|
|
34
|
-
|
|
35
28
|
this.props.onDragEvent({
|
|
36
29
|
dragged: event.nativeEvent.dragged
|
|
37
30
|
});
|
|
38
31
|
}
|
|
39
32
|
}
|
|
40
|
-
|
|
41
33
|
componentDidMount() {
|
|
42
34
|
if (this.props.onSaveEvent) {
|
|
43
35
|
let sub = DeviceEventEmitter.addListener('onSaveEvent', this.props.onSaveEvent);
|
|
44
36
|
this.subscriptions.push(sub);
|
|
45
37
|
}
|
|
46
|
-
|
|
47
38
|
if (this.props.onDragEvent) {
|
|
48
39
|
let sub = DeviceEventEmitter.addListener('onDragEvent', this.props.onDragEvent);
|
|
49
40
|
this.subscriptions.push(sub);
|
|
50
41
|
}
|
|
51
42
|
}
|
|
52
|
-
|
|
53
43
|
componentWillUnmount() {
|
|
54
44
|
this.subscriptions.forEach(sub => sub.remove());
|
|
55
45
|
this.subscriptions = [];
|
|
56
46
|
}
|
|
57
|
-
|
|
58
47
|
render() {
|
|
59
48
|
return /*#__PURE__*/React.createElement(RSSignatureView, _extends({
|
|
60
49
|
style: {
|
|
@@ -65,16 +54,12 @@ class SignatureCapture extends React.Component {
|
|
|
65
54
|
onChange: this.onChange
|
|
66
55
|
}));
|
|
67
56
|
}
|
|
68
|
-
|
|
69
57
|
saveImage() {
|
|
70
58
|
UIManager.dispatchViewManagerCommand(findNodeHandle(this), UIManager.getViewManagerConfig('RSSignatureView').Commands.saveImage, []);
|
|
71
59
|
}
|
|
72
|
-
|
|
73
60
|
resetImage() {
|
|
74
61
|
UIManager.dispatchViewManagerCommand(findNodeHandle(this), UIManager.getViewManagerConfig('RSSignatureView').Commands.resetImage, []);
|
|
75
62
|
}
|
|
76
|
-
|
|
77
63
|
}
|
|
78
|
-
|
|
79
64
|
export default SignatureCapture;
|
|
80
65
|
//# sourceMappingURL=SignatureCapture.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","DeviceEventEmitter","findNodeHandle","requireNativeComponent","UIManager","RSSignatureView","SignatureCapture","Component","constructor","props","onChange","bind","subscriptions","event","nativeEvent","encoded","onSaveEvent","dragged","onDragEvent","componentDidMount","sub","addListener","push","componentWillUnmount","forEach","remove","render","flex","saveImage","dispatchViewManagerCommand","getViewManagerConfig","Commands","resetImage"],"sources":["SignatureCapture.tsx"],"sourcesContent":["import React from 'react';\nimport {\n DeviceEventEmitter,\n findNodeHandle,\n requireNativeComponent,\n UIManager,\n ViewProps,\n} from 'react-native';\n\nconst RSSignatureView = requireNativeComponent('RSSignatureView');\n\nclass SignatureCapture extends React.Component<SignatureProps, any> {\n subscriptions: any[];\n constructor(props: SignatureProps) {\n super(props);\n this.onChange = this.onChange.bind(this);\n this.subscriptions = [];\n }\n\n onChange(event: any) {\n if (event.nativeEvent.encoded) {\n if (!this.props.onSaveEvent) {\n return;\n }\n this.props.onSaveEvent({\n encoded: event.nativeEvent.encoded,\n });\n }\n\n if (event.nativeEvent.dragged) {\n if (!this.props.onDragEvent) {\n return;\n }\n this.props.onDragEvent({\n dragged: event.nativeEvent.dragged,\n });\n }\n }\n\n componentDidMount() {\n if (this.props.onSaveEvent) {\n let sub = DeviceEventEmitter.addListener(\n 'onSaveEvent',\n this.props.onSaveEvent\n );\n this.subscriptions.push(sub);\n }\n\n if (this.props.onDragEvent) {\n let sub = DeviceEventEmitter.addListener(\n 'onDragEvent',\n this.props.onDragEvent\n );\n this.subscriptions.push(sub);\n }\n }\n\n componentWillUnmount() {\n this.subscriptions.forEach((sub) => sub.remove());\n this.subscriptions = [];\n }\n\n render() {\n return (\n <RSSignatureView\n style={{ flex: 1 }}\n {...this.props} // @ts-ignore\n onChange={this.onChange}\n />\n );\n }\n\n saveImage() {\n UIManager.dispatchViewManagerCommand(\n findNodeHandle(this),\n UIManager.getViewManagerConfig('RSSignatureView').Commands.saveImage,\n []\n );\n }\n\n resetImage() {\n UIManager.dispatchViewManagerCommand(\n findNodeHandle(this),\n UIManager.getViewManagerConfig('RSSignatureView').Commands.resetImage,\n []\n );\n }\n}\n\nexport type SignatureProps = ViewProps & {\n rotateClockwise: boolean;\n square: boolean;\n viewMode: string;\n showBorder: boolean;\n showNativeButtons: boolean;\n showTitleLabel: boolean;\n maxSize: number;\n minStrokeWidth: number;\n maxStrokeWidth: number;\n strokeColor: string;\n backgroundColor: string;\n onSaveEvent: (result: SignatureResponse) => void;\n onDragEvent: ({ dragged }: { dragged: boolean }) => void;\n};\n\nexport interface SignatureResponse {\n encoded: string;\n}\n\nexport default SignatureCapture;\n"],"mappings":";;;;AAAA,OAAOA,
|
|
1
|
+
{"version":3,"names":["React","DeviceEventEmitter","findNodeHandle","requireNativeComponent","UIManager","RSSignatureView","SignatureCapture","Component","constructor","props","_defineProperty","onChange","bind","subscriptions","event","nativeEvent","encoded","onSaveEvent","dragged","onDragEvent","componentDidMount","sub","addListener","push","componentWillUnmount","forEach","remove","render","createElement","_extends","style","flex","saveImage","dispatchViewManagerCommand","getViewManagerConfig","Commands","resetImage"],"sources":["SignatureCapture.tsx"],"sourcesContent":["import React from 'react';\nimport {\n DeviceEventEmitter,\n findNodeHandle,\n requireNativeComponent,\n UIManager,\n ViewProps,\n} from 'react-native';\n\nconst RSSignatureView = requireNativeComponent('RSSignatureView');\n\nclass SignatureCapture extends React.Component<SignatureProps, any> {\n subscriptions: any[];\n constructor(props: SignatureProps) {\n super(props);\n this.onChange = this.onChange.bind(this);\n this.subscriptions = [];\n }\n\n onChange(event: any) {\n if (event.nativeEvent.encoded) {\n if (!this.props.onSaveEvent) {\n return;\n }\n this.props.onSaveEvent({\n encoded: event.nativeEvent.encoded,\n });\n }\n\n if (event.nativeEvent.dragged) {\n if (!this.props.onDragEvent) {\n return;\n }\n this.props.onDragEvent({\n dragged: event.nativeEvent.dragged,\n });\n }\n }\n\n componentDidMount() {\n if (this.props.onSaveEvent) {\n let sub = DeviceEventEmitter.addListener(\n 'onSaveEvent',\n this.props.onSaveEvent\n );\n this.subscriptions.push(sub);\n }\n\n if (this.props.onDragEvent) {\n let sub = DeviceEventEmitter.addListener(\n 'onDragEvent',\n this.props.onDragEvent\n );\n this.subscriptions.push(sub);\n }\n }\n\n componentWillUnmount() {\n this.subscriptions.forEach((sub) => sub.remove());\n this.subscriptions = [];\n }\n\n render() {\n return (\n <RSSignatureView\n style={{ flex: 1 }}\n {...this.props} // @ts-ignore\n onChange={this.onChange}\n />\n );\n }\n\n saveImage() {\n UIManager.dispatchViewManagerCommand(\n findNodeHandle(this),\n UIManager.getViewManagerConfig('RSSignatureView').Commands.saveImage,\n []\n );\n }\n\n resetImage() {\n UIManager.dispatchViewManagerCommand(\n findNodeHandle(this),\n UIManager.getViewManagerConfig('RSSignatureView').Commands.resetImage,\n []\n );\n }\n}\n\nexport type SignatureProps = ViewProps & {\n rotateClockwise: boolean;\n square: boolean;\n viewMode: string;\n showBorder: boolean;\n showNativeButtons: boolean;\n showTitleLabel: boolean;\n maxSize: number;\n minStrokeWidth: number;\n maxStrokeWidth: number;\n strokeColor: string;\n backgroundColor: string;\n onSaveEvent: (result: SignatureResponse) => void;\n onDragEvent: ({ dragged }: { dragged: boolean }) => void;\n};\n\nexport interface SignatureResponse {\n encoded: string;\n}\n\nexport default SignatureCapture;\n"],"mappings":";;;;AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SACEC,kBAAkB,EAClBC,cAAc,EACdC,sBAAsB,EACtBC,SAAS,QAEJ,cAAc;AAErB,MAAMC,eAAe,GAAGF,sBAAsB,CAAC,i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