@os1-platform/dispatch-mobile 2.1.2 → 2.1.4
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/android/.gradle/6.8/fileChanges/last-build.bin +0 -0
- package/android/.gradle/6.8/fileHashes/fileHashes.lock +0 -0
- package/android/.gradle/6.8/gc.properties +0 -0
- package/android/.gradle/checksums/checksums.lock +0 -0
- package/android/.gradle/configuration-cache/gc.properties +0 -0
- package/android/.gradle/vcs-1/gc.properties +0 -0
- package/android/.idea/gradle.xml +13 -0
- package/android/.idea/misc.xml +10 -0
- package/android/.idea/vcs.xml +6 -0
- package/dispatch-mobile.podspec +35 -0
- package/ios/DispatchSdk-Bridging-Header.h +3 -0
- package/ios/DispatchSdk.m +9 -0
- package/ios/DispatchSdk.swift +8 -0
- package/ios/DispatchSdk.xcodeproj/project.pbxproj +317 -0
- package/ios/EventEmitter.swift +21 -0
- package/ios/EventsConstant.swift +13 -0
- package/ios/RNEventEmitter.m +15 -0
- package/ios/RNEventEmitter.swift +24 -0
- package/lib/commonjs/components/dispatch/DispatchExecNavigator.js +3 -4
- package/lib/commonjs/components/dispatch/DispatchExecNavigator.js.map +1 -1
- package/lib/commonjs/components/executiontasks/cancellation/CancelET.js +13 -8
- package/lib/commonjs/components/executiontasks/cancellation/CancelET.js.map +1 -1
- package/lib/commonjs/components/executiontasks/captureInput/CaptureText.js +3 -4
- package/lib/commonjs/components/executiontasks/captureInput/CaptureText.js.map +1 -1
- package/lib/commonjs/components/executiontasks/deliver/DeliverET.js +3 -4
- 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 +112 -27
- package/lib/commonjs/components/executiontasks/deliver/SLDeliverET.js.map +1 -1
- package/lib/commonjs/components/executiontasks/display/DisplayModalET.js +7 -8
- package/lib/commonjs/components/executiontasks/display/DisplayModalET.js.map +1 -1
- package/lib/commonjs/components/executiontasks/doodle/SignatureET.js +113 -48
- package/lib/commonjs/components/executiontasks/doodle/SignatureET.js.map +1 -1
- package/lib/commonjs/components/executiontasks/doodle/SignatureSchema.js.map +1 -1
- package/lib/commonjs/components/executiontasks/dropCash/DropCashET.js +3 -4
- package/lib/commonjs/components/executiontasks/dropCash/DropCashET.js.map +1 -1
- package/lib/commonjs/components/executiontasks/dropCash/DropCashSchema.js.map +1 -1
- package/lib/commonjs/components/executiontasks/dropCash/SLDropCash.js +7 -8
- package/lib/commonjs/components/executiontasks/dropCash/SLDropCash.js.map +1 -1
- package/lib/commonjs/components/executiontasks/forms/FormGenerator.js +23 -24
- package/lib/commonjs/components/executiontasks/forms/FormGenerator.js.map +1 -1
- package/lib/commonjs/components/executiontasks/forms/FormSchema.js.map +1 -1
- package/lib/commonjs/components/executiontasks/forms/widgets/DateTimeWidget.js +4 -5
- package/lib/commonjs/components/executiontasks/forms/widgets/DateTimeWidget.js.map +1 -1
- package/lib/commonjs/components/executiontasks/forms/widgets/DropdownWidget.js +3 -4
- package/lib/commonjs/components/executiontasks/forms/widgets/DropdownWidget.js.map +1 -1
- package/lib/commonjs/components/executiontasks/forms/widgets/QRBarcodeScannerWidget.js +3 -4
- package/lib/commonjs/components/executiontasks/forms/widgets/QRBarcodeScannerWidget.js.map +1 -1
- package/lib/commonjs/components/executiontasks/forms/widgets/TimeRangeSelector.js +3 -4
- package/lib/commonjs/components/executiontasks/forms/widgets/TimeRangeSelector.js.map +1 -1
- package/lib/commonjs/components/executiontasks/httpRequest/HttpRequestET.js +3 -4
- 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 +138 -25
- package/lib/commonjs/components/executiontasks/imageCapture/CaptureUtils.js.map +1 -1
- package/lib/commonjs/components/executiontasks/imageCapture/ImageCapture.js +228 -132
- package/lib/commonjs/components/executiontasks/imageCapture/ImageCapture.js.map +1 -1
- package/lib/commonjs/components/executiontasks/imageCapture/camera.svg +3 -0
- package/lib/commonjs/components/executiontasks/imageCapture/circle-xmark.svg +5 -0
- package/lib/commonjs/components/executiontasks/payments/PaymentStyles.js +6 -7
- package/lib/commonjs/components/executiontasks/payments/PaymentStyles.js.map +1 -1
- package/lib/commonjs/components/executiontasks/payments/completePayment/CompletePaymentET.js +6 -7
- package/lib/commonjs/components/executiontasks/payments/completePayment/CompletePaymentET.js.map +1 -1
- package/lib/commonjs/components/executiontasks/payments/completePayment/CompletePaymentSchema.js.map +1 -1
- package/lib/commonjs/components/executiontasks/payments/init/InitPaymentET.js +4 -5
- package/lib/commonjs/components/executiontasks/payments/init/InitPaymentET.js.map +1 -1
- package/lib/commonjs/components/executiontasks/payments/init/InitPaymentSchema.js.map +1 -1
- package/lib/commonjs/components/executiontasks/payments/processPayment/ProcessPaymentET.js +4 -5
- package/lib/commonjs/components/executiontasks/payments/processPayment/ProcessPaymentET.js.map +1 -1
- package/lib/commonjs/components/executiontasks/payments/processPayment/ProcessPaymentSchema.js.map +1 -1
- package/lib/commonjs/components/executiontasks/pickup/PickpSchema.js.map +1 -1
- package/lib/commonjs/components/executiontasks/pickup/PickupET.js +3 -4
- package/lib/commonjs/components/executiontasks/pickup/PickupET.js.map +1 -1
- package/lib/commonjs/components/executiontasks/pickup/SLPickupET.js +89 -17
- package/lib/commonjs/components/executiontasks/pickup/SLPickupET.js.map +1 -1
- package/lib/commonjs/components/executiontasks/scan/ScanET.js +14 -15
- package/lib/commonjs/components/executiontasks/scan/ScanET.js.map +1 -1
- package/lib/commonjs/components/executiontasks/scan/ScanSchema.js +1 -2
- package/lib/commonjs/components/executiontasks/scan/ScanSchema.js.map +1 -1
- package/lib/commonjs/components/executiontasks/scan/constants.js +6 -12
- package/lib/commonjs/components/executiontasks/scan/constants.js.map +1 -1
- package/lib/commonjs/components/executiontasks/scan/interfaces.js +4 -8
- package/lib/commonjs/components/executiontasks/scan/interfaces.js.map +1 -1
- package/lib/commonjs/components/executiontasks/scan/sub_components/CScanner.js +4 -5
- package/lib/commonjs/components/executiontasks/scan/sub_components/CScanner.js.map +1 -1
- package/lib/commonjs/components/executiontasks/scan/sub_components/ERDropDown.js +5 -6
- package/lib/commonjs/components/executiontasks/scan/sub_components/ERDropDown.js.map +1 -1
- package/lib/commonjs/components/executiontasks/scan/sub_components/SummaryPage.js +8 -9
- package/lib/commonjs/components/executiontasks/scan/sub_components/SummaryPage.js.map +1 -1
- package/lib/commonjs/components/executiontasks/scan/utils.js +2 -2
- package/lib/commonjs/components/executiontasks/scan/utils.js.map +1 -1
- package/lib/commonjs/components/executiontasks/validateOTP/ValidateOTPET.js +8 -9
- package/lib/commonjs/components/executiontasks/validateOTP/ValidateOTPET.js.map +1 -1
- package/lib/commonjs/components/executiontasks/validateOTP/ValidateOTPSchema.js +1 -2
- package/lib/commonjs/components/executiontasks/validateOTP/ValidateOTPSchema.js.map +1 -1
- package/lib/commonjs/components/executiontasks/validateOTP/constants.js +6 -12
- package/lib/commonjs/components/executiontasks/validateOTP/constants.js.map +1 -1
- package/lib/commonjs/components/executiontasks/validateOTP/sub-components/OTPInput.js +5 -6
- package/lib/commonjs/components/executiontasks/validateOTP/sub-components/OTPInput.js.map +1 -1
- package/lib/commonjs/components/executiontasks/validateOTP/utils.js +2 -2
- package/lib/commonjs/components/executiontasks/validateOTP/utils.js.map +1 -1
- package/lib/commonjs/components/executiontasks/verifyLocation/GeofenceUtils.js +2 -2
- package/lib/commonjs/components/executiontasks/verifyLocation/GeofenceUtils.js.map +1 -1
- package/lib/commonjs/components/executiontasks/verifyLocation/VerifyLocationET.js +3 -4
- package/lib/commonjs/components/executiontasks/verifyLocation/VerifyLocationET.js.map +1 -1
- package/lib/commonjs/components/executiontasks/verifyOtp/VerifyOtpET.js +3 -4
- package/lib/commonjs/components/executiontasks/verifyOtp/VerifyOtpET.js.map +1 -1
- package/lib/commonjs/components/widgets/AlertDisplay.js +14 -9
- package/lib/commonjs/components/widgets/AlertDisplay.js.map +1 -1
- package/lib/commonjs/components/widgets/CancelOrderDialog.js +5 -6
- package/lib/commonjs/components/widgets/CancelOrderDialog.js.map +1 -1
- package/lib/commonjs/components/widgets/Card.js +2 -3
- package/lib/commonjs/components/widgets/Card.js.map +1 -1
- package/lib/commonjs/components/widgets/GoBackModal.js +1 -2
- package/lib/commonjs/components/widgets/GoBackModal.js.map +1 -1
- package/lib/commonjs/components/widgets/IconButton.js +1 -2
- package/lib/commonjs/components/widgets/IconButton.js.map +1 -1
- package/lib/commonjs/components/widgets/ModalWidget.js +3 -4
- package/lib/commonjs/components/widgets/ModalWidget.js.map +1 -1
- package/lib/commonjs/components/widgets/ProgressDialog.js +2 -3
- package/lib/commonjs/components/widgets/ProgressDialog.js.map +1 -1
- package/lib/commonjs/components/widgets/SearchBar.js +1 -2
- package/lib/commonjs/components/widgets/SearchBar.js.map +1 -1
- package/lib/commonjs/components/widgets/SnackBarCustom.js +3 -5
- package/lib/commonjs/components/widgets/SnackBarCustom.js.map +1 -1
- package/lib/commonjs/components/widgets/SplitTextInput.js +3 -4
- package/lib/commonjs/components/widgets/SplitTextInput.js.map +1 -1
- package/lib/commonjs/components/widgets/TabsComponent.js +3 -4
- package/lib/commonjs/components/widgets/TabsComponent.js.map +1 -1
- package/lib/commonjs/config/DispatchSDKConfig.js +1 -2
- package/lib/commonjs/config/DispatchSDKConfig.js.map +1 -1
- package/lib/commonjs/constants/apiConstants.js +2 -4
- package/lib/commonjs/constants/apiConstants.js.map +1 -1
- package/lib/commonjs/constants/constants.js +11 -22
- package/lib/commonjs/constants/constants.js.map +1 -1
- package/lib/commonjs/constants/statuscode.js +1 -2
- package/lib/commonjs/constants/statuscode.js.map +1 -1
- package/lib/commonjs/errors/ErrorCodes.js +7 -14
- package/lib/commonjs/errors/ErrorCodes.js.map +1 -1
- package/lib/commonjs/events/EventDispatcher.js +5 -3
- package/lib/commonjs/events/EventDispatcher.js.map +1 -1
- package/lib/commonjs/events/EventListener.js +1 -2
- package/lib/commonjs/events/EventListener.js.map +1 -1
- package/lib/commonjs/events/constants.js +1 -2
- package/lib/commonjs/events/constants.js.map +1 -1
- package/lib/commonjs/events/index.js +1 -2
- package/lib/commonjs/events/index.js.map +1 -1
- package/lib/commonjs/icons/ScanIcon.js +1 -2
- package/lib/commonjs/icons/ScanIcon.js.map +1 -1
- package/lib/commonjs/icons/circleMark.svg +3 -0
- package/lib/commonjs/icons/file.js +1 -2
- package/lib/commonjs/icons/file.js.map +1 -1
- package/lib/commonjs/index.js +15 -2
- package/lib/commonjs/index.js.map +1 -1
- package/lib/commonjs/locale/Str.js +21 -0
- package/lib/commonjs/locale/Str.js.map +1 -0
- package/lib/commonjs/locale/en.json +7 -0
- package/lib/commonjs/locale/i18n.js +32 -0
- package/lib/commonjs/locale/i18n.js.map +1 -0
- package/lib/commonjs/locale/util.js +27 -0
- package/lib/commonjs/locale/util.js.map +1 -0
- package/lib/commonjs/manager/dispatch/DispatchStateContainer.js +5 -3
- package/lib/commonjs/manager/dispatch/DispatchStateContainer.js.map +1 -1
- package/lib/commonjs/manager/dispatchCodes/EventCodeContainer.js +2 -0
- package/lib/commonjs/manager/dispatchCodes/EventCodeContainer.js.map +1 -1
- package/lib/commonjs/manager/dispatchCodes/EventCodeRepo.js +4 -2
- package/lib/commonjs/manager/dispatchCodes/EventCodeRepo.js.map +1 -1
- package/lib/commonjs/manager/dispatchCodes/ReasonCodeContainer.js +4 -2
- package/lib/commonjs/manager/dispatchCodes/ReasonCodeContainer.js.map +1 -1
- package/lib/commonjs/manager/dispatchCodes/ReasonCodeRepo.js +4 -2
- package/lib/commonjs/manager/dispatchCodes/ReasonCodeRepo.js.map +1 -1
- package/lib/commonjs/manager/location/LocationManager.js +7 -4
- package/lib/commonjs/manager/location/LocationManager.js.map +1 -1
- package/lib/commonjs/manager/sdk/DispatchSDKManager.js +4 -2
- package/lib/commonjs/manager/sdk/DispatchSDKManager.js.map +1 -1
- package/lib/commonjs/manager/sdk/DispatchSdkCache.js +2 -0
- package/lib/commonjs/manager/sdk/DispatchSdkCache.js.map +1 -1
- package/lib/commonjs/manager/sdk/callbacksHandler.js +1 -2
- package/lib/commonjs/manager/sdk/callbacksHandler.js.map +1 -1
- package/lib/commonjs/manager/syncmanager/AppSyncManager.js +4 -2
- package/lib/commonjs/manager/syncmanager/AppSyncManager.js.map +1 -1
- package/lib/commonjs/manager/syncmanager/DBConfig.js +15 -26
- package/lib/commonjs/manager/syncmanager/DBConfig.js.map +1 -1
- package/lib/commonjs/manager/syncmanager/NativeSyncManager.js +1 -2
- package/lib/commonjs/manager/syncmanager/NativeSyncManager.js.map +1 -1
- package/lib/commonjs/manager/syncmanager/constants.js +5 -10
- package/lib/commonjs/manager/syncmanager/constants.js.map +1 -1
- package/lib/commonjs/manager/syncmanager/database.js +2 -2
- package/lib/commonjs/manager/syncmanager/database.js.map +1 -1
- package/lib/commonjs/manager/syncmanager/document/DocumentHttpClient.js +5 -4
- package/lib/commonjs/manager/syncmanager/document/DocumentHttpClient.js.map +1 -1
- package/lib/commonjs/manager/syncmanager/document/DocumentManager.js +4 -2
- package/lib/commonjs/manager/syncmanager/document/DocumentManager.js.map +1 -1
- package/lib/commonjs/manager/syncmanager/document/DocumentSyncManager.js +4 -2
- package/lib/commonjs/manager/syncmanager/document/DocumentSyncManager.js.map +1 -1
- package/lib/commonjs/manager/syncmanager/events/ETEventsManager.js +15 -3
- package/lib/commonjs/manager/syncmanager/events/ETEventsManager.js.map +1 -1
- package/lib/commonjs/manager/syncmanager/events/EventsSyncManager.js +4 -2
- package/lib/commonjs/manager/syncmanager/events/EventsSyncManager.js.map +1 -1
- package/lib/commonjs/models/DispatchModels.js +1 -2
- package/lib/commonjs/models/DispatchModels.js.map +1 -1
- package/lib/commonjs/models/execTasks/ETConfig.js +6 -12
- package/lib/commonjs/models/execTasks/ETConfig.js.map +1 -1
- package/lib/commonjs/models/fcm.js.map +1 -1
- package/lib/commonjs/models/sdk.js +1 -2
- package/lib/commonjs/models/sdk.js.map +1 -1
- package/lib/commonjs/native/signature/SignatureCapture.js +1 -2
- package/lib/commonjs/native/signature/SignatureCapture.js.map +1 -1
- package/lib/commonjs/network/GraphQLClient.js +48 -4
- package/lib/commonjs/network/GraphQLClient.js.map +1 -1
- package/lib/commonjs/network/Queries.js +5 -10
- package/lib/commonjs/network/Queries.js.map +1 -1
- package/lib/commonjs/res/strings.js +1 -2
- package/lib/commonjs/res/strings.js.map +1 -1
- package/lib/commonjs/resources/Login.js +1 -2
- package/lib/commonjs/resources/Login.js.map +1 -1
- package/lib/commonjs/resources/network.js +1 -2
- package/lib/commonjs/resources/network.js.map +1 -1
- package/lib/commonjs/styles/SdkColors.js +2 -4
- package/lib/commonjs/styles/SdkColors.js.map +1 -1
- package/lib/commonjs/styles/executionTasks/CommonStyles.js +8 -11
- package/lib/commonjs/styles/executionTasks/CommonStyles.js.map +1 -1
- package/lib/commonjs/ui/screens/CancellationScreen.js +3 -4
- package/lib/commonjs/ui/screens/CancellationScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/CaptureInputScreen.js +5 -5
- package/lib/commonjs/ui/screens/CaptureInputScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/CompleteObjectiveScreen.js +3 -4
- package/lib/commonjs/ui/screens/CompleteObjectiveScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/DeliverScreen.js +36 -10
- package/lib/commonjs/ui/screens/DeliverScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/DisplayScreen.js +3 -4
- package/lib/commonjs/ui/screens/DisplayScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/DoodleScreen.js +27 -6
- package/lib/commonjs/ui/screens/DoodleScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/DropCashScreen.js +29 -10
- package/lib/commonjs/ui/screens/DropCashScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/FormsScreen.js +25 -5
- package/lib/commonjs/ui/screens/FormsScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/GeofenceScreen.js +3 -4
- package/lib/commonjs/ui/screens/GeofenceScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/HttpRequestScreen.js +1 -2
- package/lib/commonjs/ui/screens/HttpRequestScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/ImageCaptureScreen.js +27 -9
- package/lib/commonjs/ui/screens/ImageCaptureScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/PaymentScreen.js +31 -10
- package/lib/commonjs/ui/screens/PaymentScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/PickupScreen.js +38 -10
- package/lib/commonjs/ui/screens/PickupScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/ScanScreen.js +3 -4
- package/lib/commonjs/ui/screens/ScanScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/StartWorkFlowScreen.js +8 -7
- package/lib/commonjs/ui/screens/StartWorkFlowScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/ValidateOTPScreen.js +3 -4
- package/lib/commonjs/ui/screens/ValidateOTPScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/WithBaseDispatchScreen.js +4 -4
- package/lib/commonjs/ui/screens/WithBaseDispatchScreen.js.map +1 -1
- package/lib/commonjs/ui/uiConfig/RouteParams.js +1 -2
- package/lib/commonjs/ui/uiConfig/RouteParams.js.map +1 -1
- package/lib/commonjs/utils/ApiUtils.js +2 -4
- package/lib/commonjs/utils/ApiUtils.js.map +1 -1
- package/lib/commonjs/utils/Logger.js +10 -9
- package/lib/commonjs/utils/Logger.js.map +1 -1
- package/lib/commonjs/utils/NetworkUtil.js +1 -2
- package/lib/commonjs/utils/NetworkUtil.js.map +1 -1
- package/lib/commonjs/utils/SdkUtils.js +12 -8
- package/lib/commonjs/utils/SdkUtils.js.map +1 -1
- package/lib/commonjs/utils/SyncManagerUtils.js +2 -2
- package/lib/commonjs/utils/SyncManagerUtils.js.map +1 -1
- package/lib/commonjs/utils/fcm/FCM.js +3 -4
- package/lib/commonjs/utils/fcm/FCM.js.map +1 -1
- package/lib/commonjs/utils/fcm/FcmUtils.js +14 -2
- package/lib/commonjs/utils/fcm/FcmUtils.js.map +1 -1
- package/lib/commonjs/utils/helper.js +46 -4
- package/lib/commonjs/utils/helper.js.map +1 -1
- package/lib/commonjs/utils/hooks/useModal.js +3 -4
- package/lib/commonjs/utils/hooks/useModal.js.map +1 -1
- package/lib/commonjs/utils/hooks/useTimer.js +1 -2
- package/lib/commonjs/utils/hooks/useTimer.js.map +1 -1
- package/lib/commonjs/utils/loginHelper.js +1 -2
- package/lib/commonjs/utils/loginHelper.js.map +1 -1
- package/lib/commonjs/utils/storage.js +71 -13
- package/lib/commonjs/utils/storage.js.map +1 -1
- package/lib/module/components/dispatch/DispatchExecNavigator.js.map +1 -1
- package/lib/module/components/executiontasks/cancellation/CancelET.js +11 -5
- package/lib/module/components/executiontasks/cancellation/CancelET.js.map +1 -1
- package/lib/module/components/executiontasks/deliver/DeliverETInput.js.map +1 -1
- package/lib/module/components/executiontasks/deliver/SLDeliverET.js +112 -25
- package/lib/module/components/executiontasks/deliver/SLDeliverET.js.map +1 -1
- package/lib/module/components/executiontasks/display/DisplayModalET.js +5 -5
- package/lib/module/components/executiontasks/display/DisplayModalET.js.map +1 -1
- package/lib/module/components/executiontasks/doodle/SignatureET.js +111 -45
- package/lib/module/components/executiontasks/doodle/SignatureET.js.map +1 -1
- package/lib/module/components/executiontasks/doodle/SignatureSchema.js.map +1 -1
- package/lib/module/components/executiontasks/dropCash/DropCashSchema.js.map +1 -1
- package/lib/module/components/executiontasks/dropCash/SLDropCash.js +5 -5
- package/lib/module/components/executiontasks/dropCash/SLDropCash.js.map +1 -1
- package/lib/module/components/executiontasks/forms/FormGenerator.js +21 -21
- package/lib/module/components/executiontasks/forms/FormGenerator.js.map +1 -1
- package/lib/module/components/executiontasks/forms/FormSchema.js.map +1 -1
- package/lib/module/components/executiontasks/forms/widgets/DateTimeWidget.js +1 -1
- package/lib/module/components/executiontasks/forms/widgets/DateTimeWidget.js.map +1 -1
- package/lib/module/components/executiontasks/imageCapture/CaptureSchema.js.map +1 -1
- package/lib/module/components/executiontasks/imageCapture/CaptureUtils.js +133 -21
- package/lib/module/components/executiontasks/imageCapture/CaptureUtils.js.map +1 -1
- package/lib/module/components/executiontasks/imageCapture/ImageCapture.js +226 -130
- package/lib/module/components/executiontasks/imageCapture/ImageCapture.js.map +1 -1
- package/lib/module/components/executiontasks/imageCapture/camera.svg +3 -0
- package/lib/module/components/executiontasks/imageCapture/circle-xmark.svg +5 -0
- package/lib/module/components/executiontasks/payments/PaymentStyles.js +6 -6
- package/lib/module/components/executiontasks/payments/PaymentStyles.js.map +1 -1
- package/lib/module/components/executiontasks/payments/completePayment/CompletePaymentET.js +4 -4
- package/lib/module/components/executiontasks/payments/completePayment/CompletePaymentET.js.map +1 -1
- package/lib/module/components/executiontasks/payments/completePayment/CompletePaymentSchema.js.map +1 -1
- package/lib/module/components/executiontasks/payments/init/InitPaymentET.js +1 -1
- package/lib/module/components/executiontasks/payments/init/InitPaymentET.js.map +1 -1
- package/lib/module/components/executiontasks/payments/init/InitPaymentSchema.js.map +1 -1
- package/lib/module/components/executiontasks/payments/processPayment/ProcessPaymentET.js +1 -1
- package/lib/module/components/executiontasks/payments/processPayment/ProcessPaymentET.js.map +1 -1
- package/lib/module/components/executiontasks/payments/processPayment/ProcessPaymentSchema.js.map +1 -1
- package/lib/module/components/executiontasks/pickup/PickpSchema.js.map +1 -1
- package/lib/module/components/executiontasks/pickup/SLPickupET.js +89 -16
- package/lib/module/components/executiontasks/pickup/SLPickupET.js.map +1 -1
- package/lib/module/components/executiontasks/scan/ScanET.js +12 -12
- package/lib/module/components/executiontasks/scan/ScanET.js.map +1 -1
- package/lib/module/components/executiontasks/scan/sub_components/CScanner.js +2 -2
- package/lib/module/components/executiontasks/scan/sub_components/CScanner.js.map +1 -1
- package/lib/module/components/executiontasks/scan/sub_components/ERDropDown.js +3 -3
- package/lib/module/components/executiontasks/scan/sub_components/ERDropDown.js.map +1 -1
- package/lib/module/components/executiontasks/scan/sub_components/SummaryPage.js +6 -6
- package/lib/module/components/executiontasks/scan/sub_components/SummaryPage.js.map +1 -1
- package/lib/module/components/executiontasks/scan/utils.js.map +1 -1
- package/lib/module/components/executiontasks/validateOTP/ValidateOTPET.js +6 -6
- package/lib/module/components/executiontasks/validateOTP/ValidateOTPET.js.map +1 -1
- package/lib/module/components/executiontasks/validateOTP/sub-components/OTPInput.js +3 -3
- package/lib/module/components/executiontasks/validateOTP/sub-components/OTPInput.js.map +1 -1
- package/lib/module/components/widgets/AlertDisplay.js +12 -7
- package/lib/module/components/widgets/AlertDisplay.js.map +1 -1
- package/lib/module/components/widgets/CancelOrderDialog.js +3 -3
- package/lib/module/components/widgets/CancelOrderDialog.js.map +1 -1
- package/lib/module/components/widgets/Card.js +1 -1
- package/lib/module/components/widgets/Card.js.map +1 -1
- package/lib/module/components/widgets/ModalWidget.js +3 -3
- package/lib/module/components/widgets/ModalWidget.js.map +1 -1
- package/lib/module/components/widgets/ProgressDialog.js +2 -2
- package/lib/module/components/widgets/ProgressDialog.js.map +1 -1
- package/lib/module/components/widgets/SnackBarCustom.js +2 -2
- package/lib/module/components/widgets/SnackBarCustom.js.map +1 -1
- package/lib/module/constants/constants.js +1 -1
- package/lib/module/constants/constants.js.map +1 -1
- package/lib/module/events/EventDispatcher.js +5 -2
- package/lib/module/events/EventDispatcher.js.map +1 -1
- package/lib/module/icons/circleMark.svg +3 -0
- package/lib/module/index.js +4 -2
- package/lib/module/index.js.map +1 -1
- package/lib/module/locale/Str.js +15 -0
- package/lib/module/locale/Str.js.map +1 -0
- package/lib/module/locale/en.json +7 -0
- package/lib/module/locale/i18n.js +25 -0
- package/lib/module/locale/i18n.js.map +1 -0
- package/lib/module/locale/util.js +18 -0
- package/lib/module/locale/util.js.map +1 -0
- package/lib/module/manager/dispatch/DispatchStateContainer.js +3 -1
- package/lib/module/manager/dispatch/DispatchStateContainer.js.map +1 -1
- package/lib/module/manager/dispatchCodes/EventCodeContainer.js +2 -0
- package/lib/module/manager/dispatchCodes/EventCodeContainer.js.map +1 -1
- package/lib/module/manager/dispatchCodes/EventCodeRepo.js +2 -0
- package/lib/module/manager/dispatchCodes/EventCodeRepo.js.map +1 -1
- package/lib/module/manager/dispatchCodes/ReasonCodeContainer.js +2 -0
- package/lib/module/manager/dispatchCodes/ReasonCodeContainer.js.map +1 -1
- package/lib/module/manager/dispatchCodes/ReasonCodeRepo.js +2 -0
- package/lib/module/manager/dispatchCodes/ReasonCodeRepo.js.map +1 -1
- package/lib/module/manager/location/LocationManager.js +2 -0
- package/lib/module/manager/location/LocationManager.js.map +1 -1
- package/lib/module/manager/sdk/DispatchSDKManager.js +2 -0
- package/lib/module/manager/sdk/DispatchSDKManager.js.map +1 -1
- package/lib/module/manager/sdk/DispatchSdkCache.js +2 -0
- package/lib/module/manager/sdk/DispatchSdkCache.js.map +1 -1
- package/lib/module/manager/syncmanager/AppSyncManager.js +2 -0
- package/lib/module/manager/syncmanager/AppSyncManager.js.map +1 -1
- package/lib/module/manager/syncmanager/DBConfig.js +1 -0
- package/lib/module/manager/syncmanager/DBConfig.js.map +1 -1
- package/lib/module/manager/syncmanager/document/DocumentManager.js +2 -0
- package/lib/module/manager/syncmanager/document/DocumentManager.js.map +1 -1
- package/lib/module/manager/syncmanager/document/DocumentSyncManager.js +2 -0
- package/lib/module/manager/syncmanager/document/DocumentSyncManager.js.map +1 -1
- package/lib/module/manager/syncmanager/events/ETEventsManager.js +13 -1
- package/lib/module/manager/syncmanager/events/ETEventsManager.js.map +1 -1
- package/lib/module/manager/syncmanager/events/EventsSyncManager.js +2 -0
- package/lib/module/manager/syncmanager/events/EventsSyncManager.js.map +1 -1
- package/lib/module/models/fcm.js.map +1 -1
- package/lib/module/network/GraphQLClient.js +48 -3
- package/lib/module/network/GraphQLClient.js.map +1 -1
- package/lib/module/styles/executionTasks/CommonStyles.js +2 -1
- package/lib/module/styles/executionTasks/CommonStyles.js.map +1 -1
- package/lib/module/ui/screens/CaptureInputScreen.js +2 -1
- package/lib/module/ui/screens/CaptureInputScreen.js.map +1 -1
- package/lib/module/ui/screens/DeliverScreen.js +33 -6
- package/lib/module/ui/screens/DeliverScreen.js.map +1 -1
- package/lib/module/ui/screens/DoodleScreen.js +24 -2
- package/lib/module/ui/screens/DoodleScreen.js.map +1 -1
- package/lib/module/ui/screens/DropCashScreen.js +26 -6
- package/lib/module/ui/screens/DropCashScreen.js.map +1 -1
- package/lib/module/ui/screens/FormsScreen.js +22 -1
- package/lib/module/ui/screens/FormsScreen.js.map +1 -1
- package/lib/module/ui/screens/ImageCaptureScreen.js +24 -5
- package/lib/module/ui/screens/ImageCaptureScreen.js.map +1 -1
- package/lib/module/ui/screens/PaymentScreen.js +28 -6
- package/lib/module/ui/screens/PaymentScreen.js.map +1 -1
- package/lib/module/ui/screens/PickupScreen.js +35 -6
- package/lib/module/ui/screens/PickupScreen.js.map +1 -1
- package/lib/module/ui/screens/StartWorkFlowScreen.js +6 -4
- package/lib/module/ui/screens/StartWorkFlowScreen.js.map +1 -1
- package/lib/module/ui/screens/WithBaseDispatchScreen.js +1 -0
- package/lib/module/ui/screens/WithBaseDispatchScreen.js.map +1 -1
- package/lib/module/utils/Logger.js +2 -0
- package/lib/module/utils/Logger.js.map +1 -1
- package/lib/module/utils/SdkUtils.js +11 -7
- package/lib/module/utils/SdkUtils.js.map +1 -1
- package/lib/module/utils/fcm/FcmUtils.js +11 -0
- package/lib/module/utils/fcm/FcmUtils.js.map +1 -1
- package/lib/module/utils/helper.js +46 -4
- package/lib/module/utils/helper.js.map +1 -1
- package/lib/module/utils/storage.js +69 -10
- package/lib/module/utils/storage.js.map +1 -1
- package/lib/typescript/components/executiontasks/deliver/DeliverETInput.d.ts +5 -0
- package/lib/typescript/components/executiontasks/doodle/SignatureSchema.d.ts +1 -0
- package/lib/typescript/components/executiontasks/dropCash/DropCashSchema.d.ts +1 -0
- package/lib/typescript/components/executiontasks/forms/FormSchema.d.ts +1 -0
- package/lib/typescript/components/executiontasks/imageCapture/CaptureSchema.d.ts +1 -0
- package/lib/typescript/components/executiontasks/imageCapture/CaptureUtils.d.ts +6 -1
- package/lib/typescript/components/executiontasks/imageCapture/ImageCapture.d.ts +1 -2
- package/lib/typescript/components/executiontasks/payments/PaymentStyles.d.ts +4 -5
- package/lib/typescript/components/executiontasks/payments/completePayment/CompletePaymentSchema.d.ts +1 -0
- package/lib/typescript/components/executiontasks/payments/init/InitPaymentSchema.d.ts +1 -0
- package/lib/typescript/components/executiontasks/payments/processPayment/ProcessPaymentSchema.d.ts +1 -0
- package/lib/typescript/components/executiontasks/pickup/PickpSchema.d.ts +2 -0
- package/lib/typescript/components/widgets/SnackBarCustom.d.ts +1 -1
- package/lib/typescript/constants/constants.d.ts +1 -1
- package/lib/typescript/index.d.ts +4 -2
- package/lib/typescript/locale/Str.d.ts +13 -0
- package/lib/typescript/locale/i18n.d.ts +3 -0
- package/lib/typescript/locale/util.d.ts +2 -0
- package/lib/typescript/manager/syncmanager/DBConfig.d.ts +2 -1
- package/lib/typescript/models/fcm.d.ts +3 -0
- package/lib/typescript/styles/executionTasks/CommonStyles.d.ts +1 -0
- package/lib/typescript/utils/fcm/FcmUtils.d.ts +2 -1
- package/lib/typescript/utils/helper.d.ts +4 -3
- package/lib/typescript/utils/storage.d.ts +3 -2
- package/package.json +22 -7
- package/src/@types/assets/index.d.ts +6 -0
- package/src/components/dispatch/DispatchExecNavigator.tsx +273 -0
- package/src/components/executiontasks/CompletedWFSchema.ts +24 -0
- package/src/components/executiontasks/ExecutionTasksIndex.ts +137 -0
- package/src/components/executiontasks/cancellation/CancelET.tsx +281 -0
- package/src/components/executiontasks/cancellation/CancellationSchema.ts +30 -0
- package/src/components/executiontasks/captureInput/CaptureInputSchema.ts +52 -0
- package/src/components/executiontasks/captureInput/CaptureText.tsx +172 -0
- package/src/components/executiontasks/captureInput/utils.ts +9 -0
- package/src/components/executiontasks/deliver/DeliverET.tsx +124 -0
- package/src/components/executiontasks/deliver/DeliverETInput.ts +52 -0
- package/src/components/executiontasks/deliver/SLDeliverET.tsx +522 -0
- package/src/components/executiontasks/display/DisplayModalET.tsx +174 -0
- package/src/components/executiontasks/display/DisplaySchema.ts +29 -0
- package/src/components/executiontasks/doodle/SignatureET.tsx +325 -0
- package/src/components/executiontasks/doodle/SignatureSchema.ts +52 -0
- package/src/components/executiontasks/dropCash/DropCashET.tsx +145 -0
- package/src/components/executiontasks/dropCash/DropCashSchema.ts +23 -0
- package/src/components/executiontasks/dropCash/SLDropCash.tsx +286 -0
- package/src/components/executiontasks/forms/FormGenerator.tsx +277 -0
- package/src/components/executiontasks/forms/FormSchema.ts +30 -0
- package/src/components/executiontasks/forms/widgets/DateTimeWidget.tsx +144 -0
- package/src/components/executiontasks/forms/widgets/DropdownWidget.tsx +52 -0
- package/src/components/executiontasks/forms/widgets/QRBarcodeScannerWidget.tsx +158 -0
- package/src/components/executiontasks/forms/widgets/TimeRangeSelector.tsx +38 -0
- package/src/components/executiontasks/httpRequest/HttpEtUtils.ts +49 -0
- package/src/components/executiontasks/httpRequest/HttpRequestET.tsx +59 -0
- package/src/components/executiontasks/httpRequest/HttpRequestETSchema.ts +42 -0
- package/src/components/executiontasks/imageCapture/CaptureSchema.ts +94 -0
- package/src/components/executiontasks/imageCapture/CaptureUtils.ts +321 -0
- package/src/components/executiontasks/imageCapture/ImageCapture.tsx +457 -0
- package/src/components/executiontasks/imageCapture/camera.svg +3 -0
- package/src/components/executiontasks/imageCapture/circle-xmark.svg +5 -0
- package/src/components/executiontasks/payments/PaymentStyles.ts +93 -0
- package/src/components/executiontasks/payments/PaymentUtils.ts +7 -0
- package/src/components/executiontasks/payments/completePayment/CompletePaymentET.tsx +238 -0
- package/src/components/executiontasks/payments/completePayment/CompletePaymentSchema.ts +24 -0
- package/src/components/executiontasks/payments/init/InitPaymentET.tsx +246 -0
- package/src/components/executiontasks/payments/init/InitPaymentSchema.ts +38 -0
- package/src/components/executiontasks/payments/processPayment/ProcessPaymentET.tsx +273 -0
- package/src/components/executiontasks/payments/processPayment/ProcessPaymentSchema.ts +39 -0
- package/src/components/executiontasks/pickup/PickpSchema.ts +30 -0
- package/src/components/executiontasks/pickup/PickupET.tsx +126 -0
- package/src/components/executiontasks/pickup/SLPickupET.tsx +372 -0
- package/src/components/executiontasks/scan/ScanET.tsx +1059 -0
- package/src/components/executiontasks/scan/ScanSchema.ts +121 -0
- package/src/components/executiontasks/scan/constants.ts +6 -0
- package/src/components/executiontasks/scan/interfaces.ts +109 -0
- package/src/components/executiontasks/scan/modalConstant.ts +120 -0
- package/src/components/executiontasks/scan/sub_components/CScanner.tsx +107 -0
- package/src/components/executiontasks/scan/sub_components/DropDownUtils.ts +119 -0
- package/src/components/executiontasks/scan/sub_components/ERDropDown.tsx +134 -0
- package/src/components/executiontasks/scan/sub_components/SummaryPage.tsx +1296 -0
- package/src/components/executiontasks/scan/utils.ts +1108 -0
- package/src/components/executiontasks/validateOTP/ValidateOTPET.tsx +436 -0
- package/src/components/executiontasks/validateOTP/ValidateOTPSchema.ts +68 -0
- package/src/components/executiontasks/validateOTP/constants.ts +24 -0
- package/src/components/executiontasks/validateOTP/sub-components/OTPInput.tsx +83 -0
- package/src/components/executiontasks/validateOTP/utils.ts +180 -0
- package/src/components/executiontasks/verifyInput/VerifyInputSchema.ts +49 -0
- package/src/components/executiontasks/verifyLocation/GeofenceUtils.ts +55 -0
- package/src/components/executiontasks/verifyLocation/VerifyLocSchema.ts +56 -0
- package/src/components/executiontasks/verifyLocation/VerifyLocationET.tsx +69 -0
- package/src/components/executiontasks/verifyOtp/VerifyOtpET.tsx +96 -0
- package/src/components/executiontasks/verifyOtp/VerifyOtpSchema.ts +27 -0
- package/src/components/utils/index.ts +18 -0
- package/src/components/widgets/AlertDisplay.tsx +38 -0
- package/src/components/widgets/CancelOrderDialog.tsx +112 -0
- package/src/components/widgets/Card.tsx +99 -0
- package/src/components/widgets/GoBackModal.tsx +49 -0
- package/src/components/widgets/IconButton.tsx +32 -0
- package/src/components/widgets/ModalWidget.tsx +157 -0
- package/src/components/widgets/ProgressDialog.tsx +54 -0
- package/src/components/widgets/SearchBar.tsx +71 -0
- package/src/components/widgets/SnackBarCustom.tsx +212 -0
- package/src/components/widgets/SplitTextInput.tsx +116 -0
- package/src/components/widgets/TabsComponent.tsx +84 -0
- package/src/components/widgets/Toaster.ts +8 -0
- package/src/config/DispatchSDKConfig.ts +4 -0
- package/src/constants/apiConstants.ts +11 -0
- package/src/constants/constants.ts +12 -0
- package/src/constants/statuscode.ts +8 -0
- package/src/errors/BaseError.ts +16 -0
- package/src/errors/ErrorCodes.ts +38 -0
- package/src/events/EventDispatcher.ts +22 -0
- package/src/events/EventListener.ts +14 -0
- package/src/events/constants.ts +7 -0
- package/src/events/index.ts +3 -0
- package/src/events/interface.ts +1 -0
- package/src/icons/ScanIcon.tsx +24 -0
- package/src/icons/circleMark.svg +3 -0
- package/src/icons/file.tsx +24 -0
- package/src/icons/interface.ts +5 -0
- package/src/index.tsx +82 -0
- package/src/locale/Str.ts +15 -0
- package/src/locale/en.json +7 -0
- package/src/locale/i18n.ts +26 -0
- package/src/locale/util.ts +20 -0
- package/src/manager/dispatch/DispatchStateContainer.tsx +842 -0
- package/src/manager/dispatchCodes/EventCodeContainer.ts +75 -0
- package/src/manager/dispatchCodes/EventCodeRepo.ts +82 -0
- package/src/manager/dispatchCodes/ReasonCodeContainer.ts +121 -0
- package/src/manager/dispatchCodes/ReasonCodeRepo.ts +90 -0
- package/src/manager/dispatchCodes/reasonCodes.json +137 -0
- package/src/manager/jobRemoval/JobRemovalManager.ts +21 -0
- package/src/manager/location/LocationManager.ts +77 -0
- package/src/manager/sdk/DispatchSDKManager.ts +99 -0
- package/src/manager/sdk/DispatchSdkCache.ts +47 -0
- package/src/manager/sdk/callbacksHandler.ts +25 -0
- package/src/manager/syncmanager/AppSyncManager.ts +187 -0
- package/src/manager/syncmanager/DBConfig.ts +181 -0
- package/src/manager/syncmanager/NativeSyncManager.ts +14 -0
- package/src/manager/syncmanager/constants.ts +5 -0
- package/src/manager/syncmanager/database.ts +93 -0
- package/src/manager/syncmanager/document/DocumentHttpClient.ts +111 -0
- package/src/manager/syncmanager/document/DocumentManager.ts +143 -0
- package/src/manager/syncmanager/document/DocumentSyncManager.ts +233 -0
- package/src/manager/syncmanager/document/models.ts +4 -0
- package/src/manager/syncmanager/events/ETEventsManager.ts +647 -0
- package/src/manager/syncmanager/events/EventsGraphQLClient.ts +0 -0
- package/src/manager/syncmanager/events/EventsSyncManager.ts +490 -0
- package/src/manager/syncmanager/events/SyncHttpClient.ts +202 -0
- package/src/models/DispatchModels.ts +97 -0
- package/src/models/ReasonCodes.ts +12 -0
- package/src/models/auth.ts +43 -0
- package/src/models/execTasks/ETBaseModels.ts +113 -0
- package/src/models/execTasks/ETConfig.ts +94 -0
- package/src/models/execution.ts +9 -0
- package/src/models/fcm.ts +6 -0
- package/src/models/sdk.ts +35 -0
- package/src/native/signature/SignatureCapture.tsx +110 -0
- package/src/network/GraphQLClient.ts +147 -0
- package/src/network/NetworkClient.ts +58 -0
- package/src/network/NetworkUtils.ts +41 -0
- package/src/network/Queries.ts +46 -0
- package/src/network/client.ts +61 -0
- package/src/res/strings.ts +1 -0
- package/src/resources/Login.ts +36 -0
- package/src/resources/network.ts +13 -0
- package/src/styles/SdkColors.ts +24 -0
- package/src/styles/executionTasks/CommonStyles.ts +189 -0
- package/src/ui/screens/CancellationScreen.tsx +144 -0
- package/src/ui/screens/CaptureInputScreen.tsx +79 -0
- package/src/ui/screens/CompleteObjectiveScreen.tsx +72 -0
- package/src/ui/screens/DeliverScreen.tsx +136 -0
- package/src/ui/screens/DisplayScreen.tsx +52 -0
- package/src/ui/screens/DoodleScreen.tsx +107 -0
- package/src/ui/screens/DropCashScreen.tsx +132 -0
- package/src/ui/screens/ETScreensIndex.ts +35 -0
- package/src/ui/screens/FormsScreen.tsx +186 -0
- package/src/ui/screens/GeofenceScreen.tsx +54 -0
- package/src/ui/screens/HttpRequestScreen.tsx +47 -0
- package/src/ui/screens/ImageCaptureScreen.tsx +95 -0
- package/src/ui/screens/PaymentScreen.tsx +213 -0
- package/src/ui/screens/PickupScreen.tsx +112 -0
- package/src/ui/screens/ScanScreen.tsx +159 -0
- package/src/ui/screens/StartWorkFlowScreen.tsx +233 -0
- package/src/ui/screens/ValidateOTPScreen.tsx +62 -0
- package/src/ui/screens/WithBaseDispatchScreen.tsx +33 -0
- package/src/ui/uiConfig/RouteParams.ts +28 -0
- package/src/utils/ApiUtils.ts +157 -0
- package/src/utils/ExecTaskUtils.ts +214 -0
- package/src/utils/Logger.ts +110 -0
- package/src/utils/NetworkUtil.ts +50 -0
- package/src/utils/SdkUtils.ts +155 -0
- package/src/utils/SyncManagerUtils.ts +223 -0
- package/src/utils/fcm/FCM.ts +118 -0
- package/src/utils/fcm/FcmUtils.ts +130 -0
- package/src/utils/helper.ts +67 -0
- package/src/utils/hooks/useModal.tsx +67 -0
- package/src/utils/hooks/useTimer.ts +44 -0
- package/src/utils/loginHelper.ts +51 -0
- package/src/utils/storage.ts +292 -0
- package/src/utils/test.json +17 -0
- package/src/utils/utils.ts +30 -0
- package/android/gradle/wrapper/gradle-wrapper.jar +0 -0
- package/android/gradle/wrapper/gradle-wrapper.properties +0 -5
- package/android/gradlew +0 -185
- package/android/gradlew.bat +0 -89
|
@@ -0,0 +1,116 @@
|
|
|
1
|
+
import {
|
|
2
|
+
View,
|
|
3
|
+
Text,
|
|
4
|
+
Pressable,
|
|
5
|
+
StyleSheet,
|
|
6
|
+
TextInput,
|
|
7
|
+
KeyboardTypeOptions,
|
|
8
|
+
} from 'react-native';
|
|
9
|
+
import React, { useRef, useState } from 'react';
|
|
10
|
+
|
|
11
|
+
export interface SplitTextInputProps {
|
|
12
|
+
styles: any;
|
|
13
|
+
value: string;
|
|
14
|
+
onChange: (text: string) => void;
|
|
15
|
+
maxLength: number;
|
|
16
|
+
keyboardType: KeyboardTypeOptions;
|
|
17
|
+
hasError: boolean;
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
const SplitTextInput = ({
|
|
21
|
+
styles,
|
|
22
|
+
value,
|
|
23
|
+
onChange,
|
|
24
|
+
maxLength,
|
|
25
|
+
keyboardType,
|
|
26
|
+
hasError,
|
|
27
|
+
}: SplitTextInputProps) => {
|
|
28
|
+
const inputRef: any = useRef();
|
|
29
|
+
const boxArray = new Array(maxLength).fill(0);
|
|
30
|
+
const [isInputBoxFocused, setIsInputBoxFocused] = useState(false);
|
|
31
|
+
|
|
32
|
+
const handleOnPress = () => {
|
|
33
|
+
setIsInputBoxFocused(true);
|
|
34
|
+
inputRef.current.focus();
|
|
35
|
+
};
|
|
36
|
+
|
|
37
|
+
const handleOnBlur = () => {
|
|
38
|
+
setIsInputBoxFocused(false);
|
|
39
|
+
};
|
|
40
|
+
|
|
41
|
+
const boxDigit = (_: number, index: number) => {
|
|
42
|
+
const digit = value[index] || '';
|
|
43
|
+
|
|
44
|
+
const isCurrentValue = index === value.length;
|
|
45
|
+
const isLastValue = index === maxLength - 1;
|
|
46
|
+
const isCodeComplete = value.length === maxLength;
|
|
47
|
+
|
|
48
|
+
const isValueFocused = isCurrentValue || (isLastValue && isCodeComplete);
|
|
49
|
+
|
|
50
|
+
const splitBoxesStyle = Boolean(hasError)
|
|
51
|
+
? widgetStyles.errorSplitBoxes
|
|
52
|
+
: (isInputBoxFocused && isValueFocused) || value[index]
|
|
53
|
+
? widgetStyles.focusedSplitBoxes
|
|
54
|
+
: widgetStyles.splitBoxes;
|
|
55
|
+
|
|
56
|
+
return (
|
|
57
|
+
<View style={splitBoxesStyle} key={index}>
|
|
58
|
+
<Text style={styles}>{digit}</Text>
|
|
59
|
+
</View>
|
|
60
|
+
);
|
|
61
|
+
};
|
|
62
|
+
|
|
63
|
+
return (
|
|
64
|
+
<>
|
|
65
|
+
<Pressable onPress={handleOnPress} style={widgetStyles.splitContainer}>
|
|
66
|
+
{boxArray.map(boxDigit)}
|
|
67
|
+
</Pressable>
|
|
68
|
+
<TextInput
|
|
69
|
+
style={widgetStyles.textInputHidden}
|
|
70
|
+
value={value}
|
|
71
|
+
onChangeText={onChange}
|
|
72
|
+
maxLength={maxLength}
|
|
73
|
+
ref={inputRef}
|
|
74
|
+
onBlur={handleOnBlur}
|
|
75
|
+
keyboardType={keyboardType}
|
|
76
|
+
/>
|
|
77
|
+
</>
|
|
78
|
+
);
|
|
79
|
+
};
|
|
80
|
+
|
|
81
|
+
export default SplitTextInput;
|
|
82
|
+
|
|
83
|
+
const widgetStyles = StyleSheet.create({
|
|
84
|
+
splitContainer: {
|
|
85
|
+
width: '100%',
|
|
86
|
+
flexDirection: 'row',
|
|
87
|
+
justifyContent: 'space-evenly',
|
|
88
|
+
},
|
|
89
|
+
splitBoxes: {
|
|
90
|
+
borderColor: '#dddddd',
|
|
91
|
+
borderWidth: 2,
|
|
92
|
+
borderRadius: 5,
|
|
93
|
+
padding: 12,
|
|
94
|
+
minWidth: 50,
|
|
95
|
+
},
|
|
96
|
+
focusedSplitBoxes: {
|
|
97
|
+
borderColor: '#666666',
|
|
98
|
+
borderWidth: 2,
|
|
99
|
+
borderRadius: 5,
|
|
100
|
+
padding: 12,
|
|
101
|
+
minWidth: 50,
|
|
102
|
+
},
|
|
103
|
+
errorSplitBoxes: {
|
|
104
|
+
borderColor: '#DC2626',
|
|
105
|
+
borderWidth: 2,
|
|
106
|
+
borderRadius: 5,
|
|
107
|
+
padding: 12,
|
|
108
|
+
minWidth: 50,
|
|
109
|
+
},
|
|
110
|
+
textInputHidden: {
|
|
111
|
+
height: 30,
|
|
112
|
+
width: 300,
|
|
113
|
+
position: 'absolute',
|
|
114
|
+
opacity: 0,
|
|
115
|
+
},
|
|
116
|
+
});
|
|
@@ -0,0 +1,84 @@
|
|
|
1
|
+
import React, { useState } from 'react';
|
|
2
|
+
import { View, TouchableOpacity, StyleSheet, ScrollView } from 'react-native';
|
|
3
|
+
|
|
4
|
+
export interface Tab {
|
|
5
|
+
title: string;
|
|
6
|
+
count: number;
|
|
7
|
+
titleStyle?: any;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
interface TabsComponentProps {
|
|
11
|
+
tabs: Array<Tab>;
|
|
12
|
+
initialTab: Tab;
|
|
13
|
+
onTabChange: (currentTab: string) => void;
|
|
14
|
+
renderTabItem: (tab: Tab) => JSX.Element;
|
|
15
|
+
renderBody: (currentTab: string) => JSX.Element | null;
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
const TabsComponent = (props: TabsComponentProps) => {
|
|
19
|
+
const [activeTab, setActiveTab] = useState(props.initialTab.title);
|
|
20
|
+
|
|
21
|
+
const handleTabPress = (tabName: string) => {
|
|
22
|
+
setActiveTab(tabName);
|
|
23
|
+
props.onTabChange(tabName);
|
|
24
|
+
};
|
|
25
|
+
|
|
26
|
+
return (
|
|
27
|
+
<View style={styles.container}>
|
|
28
|
+
<View style={{ flexDirection: 'row' }}>
|
|
29
|
+
<ScrollView
|
|
30
|
+
horizontal
|
|
31
|
+
showsHorizontalScrollIndicator={false}
|
|
32
|
+
contentContainerStyle={styles.tabsContainer}
|
|
33
|
+
>
|
|
34
|
+
{props.tabs.map((tab: Tab) => {
|
|
35
|
+
return (
|
|
36
|
+
<TouchableOpacity
|
|
37
|
+
key={tab.title}
|
|
38
|
+
style={[
|
|
39
|
+
styles.tabItem,
|
|
40
|
+
activeTab === tab.title && styles.activeTab,
|
|
41
|
+
tab.titleStyle ? tab.titleStyle : {},
|
|
42
|
+
]}
|
|
43
|
+
onPress={() => handleTabPress(tab.title)}
|
|
44
|
+
>
|
|
45
|
+
{props.renderTabItem(tab)}
|
|
46
|
+
</TouchableOpacity>
|
|
47
|
+
);
|
|
48
|
+
})}
|
|
49
|
+
</ScrollView>
|
|
50
|
+
</View>
|
|
51
|
+
|
|
52
|
+
{/* Render content based on the active tab */}
|
|
53
|
+
<View style={styles.contentContainer}>{props.renderBody(activeTab)}</View>
|
|
54
|
+
</View>
|
|
55
|
+
);
|
|
56
|
+
};
|
|
57
|
+
|
|
58
|
+
const styles = StyleSheet.create({
|
|
59
|
+
container: {
|
|
60
|
+
flex: 1,
|
|
61
|
+
},
|
|
62
|
+
tabsContainer: {
|
|
63
|
+
flexDirection: 'row',
|
|
64
|
+
justifyContent: 'space-around',
|
|
65
|
+
backgroundColor: '#f0f0f0',
|
|
66
|
+
flexGrow: 1,
|
|
67
|
+
paddingHorizontal: 20,
|
|
68
|
+
},
|
|
69
|
+
tabItem: {
|
|
70
|
+
// width: 200,
|
|
71
|
+
alignItems: 'center',
|
|
72
|
+
paddingVertical: 10,
|
|
73
|
+
marginHorizontal: 10,
|
|
74
|
+
},
|
|
75
|
+
activeTab: {
|
|
76
|
+
borderBottomWidth: 2,
|
|
77
|
+
borderBottomColor: 'blue',
|
|
78
|
+
},
|
|
79
|
+
contentContainer: {
|
|
80
|
+
flex: 1,
|
|
81
|
+
},
|
|
82
|
+
});
|
|
83
|
+
|
|
84
|
+
export default TabsComponent;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
export const ENDPOINTS = {
|
|
2
|
+
JOB_REMOVAL: (dispatchId: string) =>
|
|
3
|
+
`/dispatches/${dispatchId}/multiple-jobs`,
|
|
4
|
+
// NEW CODE
|
|
5
|
+
BULK_JOB_UPDATE: (dispatchId: string) =>
|
|
6
|
+
`/api/v2/produce/${dispatchId}/job-bulk-update`,
|
|
7
|
+
};
|
|
8
|
+
|
|
9
|
+
export const API_CONFIG = {
|
|
10
|
+
timeout: 15000, // timeout in millis i.e 15s
|
|
11
|
+
};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
export const LOCAL_STORAGE_KEY_PREFIX = '@dispatch-sdk:';
|
|
2
|
+
export const DEFAULT_NOTIFICATION_TITLE = 'Dispatch Sync Manager';
|
|
3
|
+
export const DEFAULT_NOTIFICATION_DESCRIPTION = 'Syncing Events & Files';
|
|
4
|
+
export const DEFAULT_INTERVAL = 10000;
|
|
5
|
+
export const DEFAULT_PICKUP_TITLE = 'Pickup Order';
|
|
6
|
+
export const DEFAULT_PICKUP_MESSAGE = 'Confirm Pickup of $ orders';
|
|
7
|
+
export const DEFAULT_DELIVER_TITLE = 'Drop Order';
|
|
8
|
+
export const DEFAULT_DELIVER_MESSAGE = 'Confirm Drop of $ orders';
|
|
9
|
+
export const DEFAULT_SIGN_ET_MESSAGE =
|
|
10
|
+
'Please sign here';
|
|
11
|
+
export const REASON_NOT_USED = 'NOT_TO_BE_USED';
|
|
12
|
+
export const GO_BACK_EVENT_CODE = 'E-099';
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* A general error class that should be used for all errors in Expo modules.
|
|
3
|
+
* Guarantees a `code` field that can be used to differentiate between different
|
|
4
|
+
* types of errors without further subclassing Error.
|
|
5
|
+
*/
|
|
6
|
+
export class BaseError extends Error {
|
|
7
|
+
code: string;
|
|
8
|
+
info?: any;
|
|
9
|
+
|
|
10
|
+
constructor(code: string, message: string, info?: string) {
|
|
11
|
+
super(message);
|
|
12
|
+
this.code = code;
|
|
13
|
+
if (info) this.info = info;
|
|
14
|
+
else this.info = message;
|
|
15
|
+
}
|
|
16
|
+
}
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
const enum BaseErrorCodes {
|
|
2
|
+
InvalidArgumentError = '100100',
|
|
3
|
+
InvalidBaseURL = '100101',
|
|
4
|
+
SyncManagerNotInitialized = '100102',
|
|
5
|
+
MissingOrInvalidProps = '100103',
|
|
6
|
+
SQLiteDBIssue = '100104',
|
|
7
|
+
AppSyncNotInitialized = '100105',
|
|
8
|
+
FMS_FOLDER_CREATION_ERROR = '100106',
|
|
9
|
+
REASON_CODE_API_ERROR = '100107',
|
|
10
|
+
MERGING_ERROR = '100108',
|
|
11
|
+
LOCATION_PERMISSION_DENIED = '100109',
|
|
12
|
+
CAMERA_PERMISSION_DENIED = '100110',
|
|
13
|
+
STORAGE_PERMISSION_DENIED = '100111',
|
|
14
|
+
GRAPHQL_CLIENT_NOT_INITIALIZED = '100112',
|
|
15
|
+
FMS_GRAPHQL_API_ERROR = '100113',
|
|
16
|
+
INTERNET_NOT_ENABLED = '100114',
|
|
17
|
+
LOCATION_OR_GPS_NOT_ENABLED = '100115',
|
|
18
|
+
EXECUTION_ENGINE_ERROR = '100116',
|
|
19
|
+
UNEXPECTED_ERROR = '100117',
|
|
20
|
+
SYSTEM_TIME_CHECK_FAILED = '100118',
|
|
21
|
+
ACCESS_TOKEN_EXPIRED = '100119',
|
|
22
|
+
MULTI_OBJECTIVE_ERROR = '100119',
|
|
23
|
+
}
|
|
24
|
+
export const InvalidArgumentsError = 'Missing or invalid arguments';
|
|
25
|
+
export const InvalidBaseURL = 'URL is invalid';
|
|
26
|
+
export const SyncManagerNotInitialized =
|
|
27
|
+
'Sync Manager is not initialized.Please call init method first';
|
|
28
|
+
|
|
29
|
+
export const AppSyncInitError =
|
|
30
|
+
"App sync Manager not initialized.Please call initSyncManager() with valid BASE URLs from your app's index file";
|
|
31
|
+
|
|
32
|
+
export const MissingOrInvalidProps =
|
|
33
|
+
'One or more prop(s) is missing or invalid';
|
|
34
|
+
|
|
35
|
+
export const MultiObjectiveError =
|
|
36
|
+
'Multiple objective not allowed as enableMultiObjectiveFlow is false.';
|
|
37
|
+
|
|
38
|
+
export default BaseErrorCodes;
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { NativeEventEmitter, NativeModules } from 'react-native';
|
|
2
|
+
import { BaseEvents } from './constants';
|
|
3
|
+
import type { eventType } from './interface';
|
|
4
|
+
import Logger, { LOG_TYPE } from '../utils/Logger';
|
|
5
|
+
|
|
6
|
+
const { RNEventEmitter } = NativeModules;
|
|
7
|
+
const eventEmitter = new NativeEventEmitter(RNEventEmitter);
|
|
8
|
+
|
|
9
|
+
const events = (type: eventType, customEtName: string) => {
|
|
10
|
+
return `${BaseEvents[type]}:${customEtName}`;
|
|
11
|
+
};
|
|
12
|
+
|
|
13
|
+
const dispatchEvent = (type: eventType, customEtName: string, data: any) => {
|
|
14
|
+
/* Logger.getInstance().logEvent(
|
|
15
|
+
'eventOutputData: ',
|
|
16
|
+
JSON.stringify({ type, customEtName, data }),
|
|
17
|
+
LOG_TYPE.SDK_INFO
|
|
18
|
+
); */
|
|
19
|
+
eventEmitter.emit(events(type, customEtName), data);
|
|
20
|
+
};
|
|
21
|
+
|
|
22
|
+
export default dispatchEvent;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { DeviceEventEmitter } from 'react-native';
|
|
2
|
+
|
|
3
|
+
const eventListener = {
|
|
4
|
+
on(event: string, callback: Function) {
|
|
5
|
+
DeviceEventEmitter.addListener(event, (e: any) => {
|
|
6
|
+
callback(e);
|
|
7
|
+
});
|
|
8
|
+
},
|
|
9
|
+
remove(event: string) {
|
|
10
|
+
DeviceEventEmitter.removeAllListeners(event);
|
|
11
|
+
},
|
|
12
|
+
};
|
|
13
|
+
|
|
14
|
+
export default eventListener;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export type eventType = 'START' | 'END' | 'BACK' | 'ON_SCAN' | 'ON_SCAN_REMOVE';
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { IconProps } from './interface';
|
|
3
|
+
import { Path, Svg } from 'react-native-svg';
|
|
4
|
+
import { View } from 'react-native';
|
|
5
|
+
|
|
6
|
+
const ScanIcon = (props: IconProps) => {
|
|
7
|
+
return (
|
|
8
|
+
<View>
|
|
9
|
+
<Svg
|
|
10
|
+
width={props.width || '80'}
|
|
11
|
+
height={props.height || '80'}
|
|
12
|
+
viewBox="0 0 80 80"
|
|
13
|
+
fill="none"
|
|
14
|
+
>
|
|
15
|
+
<Path
|
|
16
|
+
d="M30.8889 25.2222C29.9417 25.2222 29.1667 25.9972 29.1667 26.9445V51.0556C29.1667 52.0028 29.9417 52.7778 30.8889 52.7778C31.8361 52.7778 32.6111 52.0028 32.6111 51.0556V26.9445C32.6111 25.9972 31.8361 25.2222 30.8889 25.2222ZM55 52.7778C55.952 52.7778 56.7222 52.0076 56.7222 51.1524V27.0413C56.7222 25.9972 55.9472 25.2222 55 25.2222C54.0528 25.2222 53.2778 25.9972 53.2778 26.9445V51.0556C53.2778 52.0028 54.0528 52.7778 55 52.7778ZM37.7778 25.2222C36.8306 25.2222 36.0556 25.9972 36.0556 26.9445V51.0556C36.0556 52.0028 36.8306 52.7778 37.7778 52.7778C38.725 52.7778 39.5 52.0075 39.5 51.0556V26.9445C39.5 25.9972 38.725 25.2222 37.7778 25.2222ZM46.3889 25.2222C45.4369 25.2222 44.6667 25.9925 44.6667 26.9445V51.0556C44.6667 52.0075 45.4369 52.7778 46.3889 52.7778C47.3408 52.7778 48.1111 52.0075 48.1111 51.0556V26.9445C48.1111 25.9972 47.3361 25.2222 46.3889 25.2222ZM24 25.2222C23.0528 25.2222 22.2778 25.9972 22.2778 26.9445V51.0556C22.2778 52.0028 23.0528 52.7778 24 52.7778C24.9472 52.7778 25.7222 52.0028 25.7222 51.0556V26.9445C25.7222 25.9972 24.9472 25.2222 24 25.2222ZM24 11.4445H10.2222C9.27026 11.4445 8.5 12.2147 8.5 13.1667V26.9445C8.5 27.8917 9.27026 28.6667 10.2222 28.6667C11.1742 28.6667 11.9444 27.8917 11.9444 26.9445V14.8889H24C24.9472 14.8889 25.7222 14.1182 25.7222 13.1667C25.7222 12.2152 24.9472 11.4445 24 11.4445ZM68.7778 11.4445H55C54.0528 11.4445 53.2778 12.2147 53.2778 13.1667C53.2778 14.1186 54.0528 14.8889 55 14.8889H67.0556V26.9445C67.0556 27.8917 67.8306 28.6667 68.7778 28.6667C69.725 28.6667 70.5 27.8917 70.5 26.9445V13.1667C70.5 12.2147 69.725 11.4445 68.7778 11.4445ZM68.7778 49.3334C67.8258 49.3334 67.0556 50.1036 67.0556 51.0556V63.1111H55C54.048 63.1111 53.2778 63.8814 53.2778 64.8334C53.2778 65.7853 54.048 66.5556 55 66.5556H68.7778C69.7297 66.5556 70.5 65.7853 70.5 64.8334V51.0556C70.5 50.1083 69.725 49.3334 68.7778 49.3334ZM24 63.1111H11.9444V51.0556C11.9444 50.1083 11.1737 49.3334 10.2222 49.3334C9.27069 49.3334 8.5 50.1083 8.5 51.0556V64.8334C8.5 65.7806 9.27026 66.5556 10.2222 66.5556H24C24.9472 66.5556 25.7222 65.7806 25.7222 64.8334C25.7222 63.8861 24.9472 63.1111 24 63.1111Z"
|
|
17
|
+
fill={props.fill || '#5B80F7'}
|
|
18
|
+
/>
|
|
19
|
+
</Svg>
|
|
20
|
+
</View>
|
|
21
|
+
);
|
|
22
|
+
};
|
|
23
|
+
|
|
24
|
+
export default ScanIcon;
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
<svg width="20" height="20" viewBox="0 0 20 20" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2
|
+
<path d="M12.9414 7.06434C12.6973 6.82067 12.3016 6.82067 12.0578 7.06434L10 9.11891L7.94141 7.06434C7.69727 6.82067 7.30156 6.82067 7.05781 7.06434C6.81406 7.308 6.81367 7.70293 7.05781 7.94621L9.11719 10L7.05859 12.0546C6.81445 12.2982 6.81445 12.6932 7.05859 12.9364C7.30258 13.1799 7.69805 13.1803 7.94219 12.9364L10 10.8811L12.0582 12.9353C12.3022 13.1788 12.6977 13.1791 12.9418 12.9353C13.1859 12.6916 13.1859 12.2967 12.9418 12.0534L10.8828 10L12.941 7.94582C13.1875 7.70371 13.1875 7.30605 12.9414 7.06434ZM10 0.0195312C4.47656 0.0195312 0 4.48735 0 10C0 15.5126 4.47656 19.9805 10 19.9805C15.5234 19.9805 20 15.5126 20 10C20 4.48735 15.5234 0.0195312 10 0.0195312ZM10 18.7329C5.17578 18.7329 1.25 14.8148 1.25 10C1.25 5.1852 5.17578 1.26709 10 1.26709C14.8242 1.26709 18.75 5.1852 18.75 10C18.75 14.8148 14.8242 18.7329 10 18.7329Z" fill="#A3AAC2"/>
|
|
3
|
+
</svg>
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { Path, Svg } from 'react-native-svg';
|
|
3
|
+
import { IconProps } from './interface';
|
|
4
|
+
import { View } from 'react-native';
|
|
5
|
+
|
|
6
|
+
const FileIcon = (props: IconProps) => {
|
|
7
|
+
return (
|
|
8
|
+
<View>
|
|
9
|
+
<Svg
|
|
10
|
+
width={props.width || '80'}
|
|
11
|
+
height={props.height || '80'}
|
|
12
|
+
viewBox="0 0 80 80"
|
|
13
|
+
fill="none"
|
|
14
|
+
>
|
|
15
|
+
<Path
|
|
16
|
+
d="M21.5 55.4375C19.5332 55.4375 17.9375 57.0317 17.9375 59C17.9375 60.9668 19.5332 62.5625 21.5 62.5625C23.4683 62.5625 25.0625 60.9668 25.0625 59C25.0625 57.0258 23.4742 55.4375 21.5 55.4375ZM59.5 56.625H33.375C32.0688 56.625 31 57.6937 31 59C31 60.3063 32.0622 61.375 33.375 61.375H59.5C60.8128 61.375 61.875 60.3128 61.875 59C61.875 57.6872 60.8063 56.625 59.5 56.625ZM22.2867 44.75C22.8944 44.75 23.5021 44.5181 23.9655 44.0541L32.6744 35.3453C33.6021 34.4176 33.6021 32.9139 32.6744 31.9876C31.7466 31.0614 30.243 31.0599 29.3167 31.9876L22.2867 39.0203L19.6163 36.3484C18.6886 35.4207 17.1849 35.4207 16.2587 36.3484C15.3324 37.2762 15.3309 38.7798 16.2587 39.7061L20.6123 44.0598C21.0755 44.5125 21.6826 44.75 22.2867 44.75ZM21.5 24.5625C23.4683 24.5625 25.0625 22.9668 25.0625 21C25.0625 19.0317 23.4683 17.4375 21.5 17.4375C19.5332 17.4375 17.9375 19.0258 17.9375 21C17.9375 22.9742 19.5332 24.5625 21.5 24.5625ZM59.5 37.625H38.125C36.8188 37.625 35.75 38.6937 35.75 40C35.75 41.3063 36.8122 42.375 38.125 42.375H59.5C60.8128 42.375 61.875 41.3128 61.875 40C61.875 38.6872 60.8063 37.625 59.5 37.625ZM64.25 2H16.75C11.5027 2 7.25 6.25273 7.25 11.5V68.5C7.25 73.7473 11.5027 78 16.75 78H64.25C69.4973 78 73.75 73.7473 73.75 68.5V11.5C73.75 6.25273 69.4898 2 64.25 2ZM69 68.5C69 71.1184 66.8684 73.25 64.25 73.25H16.75C14.1316 73.25 12 71.1184 12 68.5V11.5C12 8.88156 14.1316 6.75 16.75 6.75H64.25C66.8684 6.75 69 8.88156 69 11.5V68.5ZM59.5 18.625H33.375C32.0688 18.625 31 19.6938 31 21C31 22.3062 32.0622 23.375 33.375 23.375H59.5C60.8128 23.375 61.875 22.3128 61.875 21C61.875 19.6872 60.8063 18.625 59.5 18.625Z"
|
|
17
|
+
fill={props.fill || '#E0E3EB'}
|
|
18
|
+
/>
|
|
19
|
+
</Svg>
|
|
20
|
+
</View>
|
|
21
|
+
);
|
|
22
|
+
};
|
|
23
|
+
|
|
24
|
+
export default FileIcon;
|
package/src/index.tsx
ADDED
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
import Storage from './utils/storage';
|
|
2
|
+
import type * as ETaskSchema from './components/executiontasks/ExecutionTasksIndex';
|
|
3
|
+
import * as ExecutionTask from './components/executiontasks/ExecutionTasksIndex';
|
|
4
|
+
import type {
|
|
5
|
+
MTSInitRequest,
|
|
6
|
+
MTSStartRequest,
|
|
7
|
+
} from '@foxtrotplatform/platform-coreos-mts-sdk';
|
|
8
|
+
import * as MtsSdk from '@foxtrotplatform/platform-coreos-mts-sdk';
|
|
9
|
+
import NativeSyncManager from './manager/syncmanager/NativeSyncManager';
|
|
10
|
+
import type { DocumentRow, EventRow } from './manager/syncmanager/DBConfig';
|
|
11
|
+
import { SyncMethod, DispatchSyncType } from './manager/syncmanager/DBConfig';
|
|
12
|
+
import CancelOrderDialog from './components/widgets/CancelOrderDialog';
|
|
13
|
+
import useFCMMessage, {
|
|
14
|
+
getFCMToken,
|
|
15
|
+
registerBackgroundHandler,
|
|
16
|
+
requestFirebasePermissions,
|
|
17
|
+
onNotificationOpenedApp,
|
|
18
|
+
onTokenRefresh,
|
|
19
|
+
getInitialNotification,
|
|
20
|
+
} from './utils/fcm/FcmUtils';
|
|
21
|
+
import FCM from './utils/fcm/FCM';
|
|
22
|
+
import DispatchExecNavigator from './components/dispatch/DispatchExecNavigator';
|
|
23
|
+
import DispatchStateContainer from './manager/dispatch/DispatchStateContainer';
|
|
24
|
+
import { DispatchSDKManager } from './manager/sdk/DispatchSDKManager';
|
|
25
|
+
import Logger, { LOG_TYPE } from './utils/Logger';
|
|
26
|
+
import type {
|
|
27
|
+
ETSummary,
|
|
28
|
+
CompleteSummary,
|
|
29
|
+
ObjectiveSummary,
|
|
30
|
+
} from './models/execTasks/ETBaseModels';
|
|
31
|
+
import SdkUtils from './utils/SdkUtils';
|
|
32
|
+
import AppSyncManager from './manager/syncmanager/AppSyncManager';
|
|
33
|
+
import type {
|
|
34
|
+
JobObjectiveType,
|
|
35
|
+
endEvent,
|
|
36
|
+
startEvent,
|
|
37
|
+
onScanRemoveEvent,
|
|
38
|
+
onScanEvent,
|
|
39
|
+
} from './models/DispatchModels';
|
|
40
|
+
import { SdkSyncType } from './models/DispatchModels';
|
|
41
|
+
import EventListener from './events';
|
|
42
|
+
import { BaseEvents } from './events/constants';
|
|
43
|
+
import {
|
|
44
|
+
DispatchExecutor,
|
|
45
|
+
IDispatch,
|
|
46
|
+
IDispatchExecutor,
|
|
47
|
+
} from '@os1-platform/platform-coreos-execution-engine-sdk';
|
|
48
|
+
import Helper from './utils/helper';
|
|
49
|
+
|
|
50
|
+
export { DispatchExecutor, IDispatch, IDispatchExecutor };
|
|
51
|
+
export { Storage, DispatchExecNavigator };
|
|
52
|
+
export { ETSummary, CompleteSummary, ObjectiveSummary, DispatchSyncType };
|
|
53
|
+
export { BaseEvents, endEvent, startEvent, onScanRemoveEvent, onScanEvent };
|
|
54
|
+
export {
|
|
55
|
+
NativeSyncManager,
|
|
56
|
+
AppSyncManager,
|
|
57
|
+
SdkSyncType,
|
|
58
|
+
EventRow,
|
|
59
|
+
DocumentRow,
|
|
60
|
+
useFCMMessage,
|
|
61
|
+
getFCMToken,
|
|
62
|
+
requestFirebasePermissions,
|
|
63
|
+
FCM,
|
|
64
|
+
registerBackgroundHandler,
|
|
65
|
+
onNotificationOpenedApp,
|
|
66
|
+
onTokenRefresh,
|
|
67
|
+
getInitialNotification,
|
|
68
|
+
DispatchStateContainer,
|
|
69
|
+
SdkUtils,
|
|
70
|
+
Logger,
|
|
71
|
+
LOG_TYPE,
|
|
72
|
+
EventListener,
|
|
73
|
+
};
|
|
74
|
+
|
|
75
|
+
export { SyncMethod, JobObjectiveType };
|
|
76
|
+
export type { ETaskSchema };
|
|
77
|
+
export { ExecutionTask, CancelOrderDialog };
|
|
78
|
+
export { DispatchSDKManager };
|
|
79
|
+
|
|
80
|
+
export type { MTSStartRequest, MTSInitRequest };
|
|
81
|
+
export { MtsSdk };
|
|
82
|
+
export { Helper };
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
export default {
|
|
2
|
+
//value variable constants
|
|
3
|
+
count: 'count',
|
|
4
|
+
|
|
5
|
+
//string constants
|
|
6
|
+
DEFAULT_PICKUP_MESSAGE: 'DEFAULT_PICKUP_MESSAGE',
|
|
7
|
+
DEFAULT_DELIVER_MESSAGE: 'DEFAULT_DELIVER_MESSAGE',
|
|
8
|
+
DEFAULT_RETURN_MESSAGE: 'DEFAULT_RETURN_MESSAGE',
|
|
9
|
+
Expected_Shipments: 'Expected_Shipments',
|
|
10
|
+
Expected_Shipment: 'Expected_Shipment',
|
|
11
|
+
Shipment_handed_over: 'Shipment_handed_over',
|
|
12
|
+
Shipments_handed_over: 'Shipments_handed_over',
|
|
13
|
+
shipments: 'shipments',
|
|
14
|
+
skip: 'skip'
|
|
15
|
+
}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { I18n } from "i18n-js";
|
|
2
|
+
import en from './en.json';
|
|
3
|
+
|
|
4
|
+
const i18n = new I18n({
|
|
5
|
+
en: {
|
|
6
|
+
...en,
|
|
7
|
+
DEFAULT_PICKUP_MESSAGE: {
|
|
8
|
+
one: "Confirm Pickup of 1 order",
|
|
9
|
+
other: "Confirm Pickup of %{count} orders",
|
|
10
|
+
},
|
|
11
|
+
DEFAULT_DELIVER_MESSAGE: {
|
|
12
|
+
one: "Confirm Drop of 1 order",
|
|
13
|
+
other: "Confirm Drop of %{count} orders"
|
|
14
|
+
},
|
|
15
|
+
DEFAULT_RETURN_MESSAGE: {
|
|
16
|
+
one: "Confirm Return of 1 order",
|
|
17
|
+
other: "Confirm Return of %{count} orders"
|
|
18
|
+
},
|
|
19
|
+
shipments: {
|
|
20
|
+
one: "(%{count} shipment)?",
|
|
21
|
+
other: "(%{count} shipments)?"
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
});
|
|
25
|
+
|
|
26
|
+
export default i18n;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import i18n from "./i18n";
|
|
2
|
+
|
|
3
|
+
export const getStr = (str: string) => {
|
|
4
|
+
try {
|
|
5
|
+
return i18n.t(str);
|
|
6
|
+
} catch (error) {
|
|
7
|
+
|
|
8
|
+
return str;
|
|
9
|
+
}
|
|
10
|
+
};
|
|
11
|
+
|
|
12
|
+
export const getStrVal = (str: string, varName: string, varVal: any) => {
|
|
13
|
+
try {
|
|
14
|
+
let dataObj: { [k: string]: any } = {};
|
|
15
|
+
dataObj[varName] = varVal;
|
|
16
|
+
return i18n.t(str, dataObj);
|
|
17
|
+
} catch (error) {
|
|
18
|
+
return str;
|
|
19
|
+
}
|
|
20
|
+
};
|