@trusted-solutions/sdit.models 0.24.2 → 0.24.3
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/base-data.d.ts +15 -15
- package/base-data.js +2 -2
- package/constants/client-endpoints.d.ts +7 -7
- package/constants/client-endpoints.js +10 -10
- package/constants/district-zip.taiwan.d.ts +7 -7
- package/constants/district-zip.taiwan.js +499 -499
- package/constants/index.d.ts +3 -3
- package/constants/index.js +6 -6
- package/constants/industry.d.ts +4 -4
- package/constants/industry.js +27 -27
- package/data-service/config.d.ts +62 -62
- package/data-service/config.js +895 -895
- package/data-service/enum.d.ts +82 -82
- package/data-service/enum.js +101 -101
- package/data-service/index.d.ts +4 -4
- package/data-service/index.js +7 -7
- package/data-service/lambda.d.ts +92 -92
- package/data-service/lambda.js +3 -3
- package/data-service/model.d.ts +79 -79
- package/data-service/model.js +190 -190
- package/enums/analysis.d.ts +201 -201
- package/enums/analysis.js +213 -213
- package/enums/block-storage.d.ts +4 -4
- package/enums/block-storage.js +8 -8
- package/enums/close-type.d.ts +4 -4
- package/enums/close-type.js +8 -8
- package/enums/cognito-filter-key.d.ts +14 -14
- package/enums/cognito-filter-key.js +19 -19
- package/enums/cognito-operator.d.ts +4 -4
- package/enums/cognito-operator.js +8 -8
- package/enums/company.d.ts +4 -4
- package/enums/company.js +8 -8
- package/enums/customer.d.ts +23 -23
- package/enums/customer.js +29 -29
- package/enums/discount-module.d.ts +18 -18
- package/enums/discount-module.js +27 -27
- package/enums/dynamodb-operator.d.ts +66 -66
- package/enums/dynamodb-operator.js +77 -77
- package/enums/error-type.d.ts +109 -109
- package/enums/error-type.js +145 -145
- package/enums/event.d.ts +29 -29
- package/enums/event.js +36 -36
- package/enums/external.d.ts +3 -3
- package/enums/external.js +7 -7
- package/enums/filter-keys.d.ts +9 -9
- package/enums/filter-keys.js +15 -15
- package/enums/import-data.d.ts +3 -3
- package/enums/import-data.js +7 -7
- package/enums/index.d.ts +41 -41
- package/enums/index.js +44 -44
- package/enums/inventory.d.ts +7 -7
- package/enums/inventory.js +11 -11
- package/enums/invoice-carrier-type.d.ts +5 -5
- package/enums/invoice-carrier-type.js +9 -9
- package/enums/invoice-error-name.d.ts +4 -4
- package/enums/invoice-error-name.js +8 -8
- package/enums/invoice-provider.d.ts +5 -5
- package/enums/invoice-provider.js +9 -9
- package/enums/invoice-status-type.d.ts +4 -4
- package/enums/invoice-status-type.js +8 -8
- package/enums/invoice-type.d.ts +6 -6
- package/enums/invoice-type.js +10 -10
- package/enums/language.d.ts +4 -4
- package/enums/language.js +8 -8
- package/enums/number-of-customers-group-type.d.ts +12 -12
- package/enums/number-of-customers-group-type.js +16 -16
- package/enums/offline-sync-type.d.ts +7 -7
- package/enums/offline-sync-type.js +11 -11
- package/enums/order-action-name.d.ts +4 -4
- package/enums/order-action-name.js +8 -8
- package/enums/order-item.d.ts +13 -13
- package/enums/order-item.js +18 -18
- package/enums/order-source-type.d.ts +5 -5
- package/enums/order-source-type.js +9 -9
- package/enums/order-status.d.ts +18 -18
- package/enums/order-status.js +22 -22
- package/enums/payment-parameters.d.ts +18 -18
- package/enums/payment-parameters.js +25 -25
- package/enums/payment-service-provider.d.ts +28 -28
- package/enums/payment-service-provider.js +32 -32
- package/enums/payment-type.d.ts +35 -35
- package/enums/payment-type.js +39 -39
- package/enums/permission-name.d.ts +30 -30
- package/enums/permission-name.js +34 -34
- package/enums/printer.d.ts +57 -57
- package/enums/printer.js +68 -68
- package/enums/real-time-switch-type.d.ts +8 -8
- package/enums/real-time-switch-type.js +12 -12
- package/enums/receipt.d.ts +4 -4
- package/enums/receipt.js +8 -8
- package/enums/serve-type.d.ts +6 -6
- package/enums/serve-type.js +10 -10
- package/enums/server-error.d.ts +4 -4
- package/enums/server-error.js +8 -8
- package/enums/store.d.ts +15 -15
- package/enums/store.js +21 -21
- package/enums/table-index.d.ts +25 -24
- package/enums/table-index.js +32 -31
- package/enums/table-index.js.map +1 -1
- package/enums/table.d.ts +6 -6
- package/enums/table.js +10 -10
- package/enums/tax-type.d.ts +5 -5
- package/enums/tax-type.js +9 -9
- package/enums/user.d.ts +8 -8
- package/enums/user.js +13 -13
- package/lambda/contract.d.ts +87 -97
- package/lambda/contract.js +2 -2
- package/lambda/error/create-order-when-item-sold-out.d.ts +6 -6
- package/lambda/error/create-order-when-item-sold-out.js +2 -2
- package/lambda/error/index.d.ts +1 -1
- package/lambda/error/index.js +4 -4
- package/lambda/index.d.ts +9 -9
- package/lambda/index.js +12 -12
- package/lambda/line-notify.d.ts +8 -8
- package/lambda/line-notify.js +4 -4
- package/lambda/online-integration.d.ts +110 -110
- package/lambda/online-integration.js +2 -2
- package/lambda/online-ordering.d.ts +230 -230
- package/lambda/online-ordering.js +2 -2
- package/lambda/override.d.ts +23 -23
- package/lambda/override.js +2 -2
- package/lambda/pos-integration.d.ts +19 -19
- package/lambda/pos-integration.js +2 -2
- package/lambda/request/analysis.d.ts +4 -4
- package/lambda/request/analysis.js +2 -2
- package/lambda/request/chain.d.ts +30 -30
- package/lambda/request/chain.js +2 -2
- package/lambda/request/closing.d.ts +64 -64
- package/lambda/request/closing.js +2 -2
- package/lambda/request/common.d.ts +19 -19
- package/lambda/request/common.js +2 -2
- package/lambda/request/custom-analysis-group.d.ts +19 -19
- package/lambda/request/custom-analysis-group.js +2 -2
- package/lambda/request/customer.d.ts +19 -19
- package/lambda/request/customer.js +2 -2
- package/lambda/request/discount-module.d.ts +50 -50
- package/lambda/request/discount-module.js +2 -2
- package/lambda/request/event.d.ts +9 -9
- package/lambda/request/event.js +2 -2
- package/lambda/request/import-data.d.ts +15 -15
- package/lambda/request/import-data.js +2 -2
- package/lambda/request/index.d.ts +20 -20
- package/lambda/request/index.js +23 -23
- package/lambda/request/invoice.d.ts +93 -93
- package/lambda/request/invoice.js +2 -2
- package/lambda/request/kiosk.d.ts +15 -15
- package/lambda/request/kiosk.js +2 -2
- package/lambda/request/menu.d.ts +88 -88
- package/lambda/request/menu.js +2 -2
- package/lambda/request/offline-sync.d.ts +33 -33
- package/lambda/request/offline-sync.js +2 -2
- package/lambda/request/order.d.ts +49 -49
- package/lambda/request/order.js +2 -2
- package/lambda/request/payment.d.ts +19 -19
- package/lambda/request/payment.js +2 -2
- package/lambda/request/printer.d.ts +42 -42
- package/lambda/request/printer.js +2 -2
- package/lambda/request/real-time-switch.d.ts +33 -33
- package/lambda/request/real-time-switch.js +2 -2
- package/lambda/request/receipt.d.ts +5 -5
- package/lambda/request/receipt.js +2 -2
- package/lambda/request/store.d.ts +77 -77
- package/lambda/request/store.js +2 -2
- package/lambda/request/user.d.ts +29 -29
- package/lambda/request/user.js +2 -2
- package/lambda/response/analysis.d.ts +4 -4
- package/lambda/response/analysis.js +2 -2
- package/lambda/response/chain.d.ts +14 -14
- package/lambda/response/chain.js +2 -2
- package/lambda/response/closing.d.ts +14 -14
- package/lambda/response/closing.js +3 -3
- package/lambda/response/common.d.ts +15 -15
- package/lambda/response/common.js +2 -2
- package/lambda/response/custom-analysis-group.d.ts +14 -14
- package/lambda/response/custom-analysis-group.js +7 -7
- package/lambda/response/customer.d.ts +12 -12
- package/lambda/response/customer.js +2 -2
- package/lambda/response/discount-module.d.ts +28 -28
- package/lambda/response/discount-module.js +2 -2
- package/lambda/response/event.d.ts +4 -4
- package/lambda/response/event.js +2 -2
- package/lambda/response/index.d.ts +17 -17
- package/lambda/response/index.js +20 -20
- package/lambda/response/invoice.d.ts +34 -34
- package/lambda/response/invoice.js +2 -2
- package/lambda/response/kiosk.d.ts +12 -12
- package/lambda/response/kiosk.js +2 -2
- package/lambda/response/menu.d.ts +54 -54
- package/lambda/response/menu.js +2 -2
- package/lambda/response/order.d.ts +20 -20
- package/lambda/response/order.js +2 -2
- package/lambda/response/payment.d.ts +199 -199
- package/lambda/response/payment.js +2 -2
- package/lambda/response/printer.d.ts +22 -22
- package/lambda/response/printer.js +2 -2
- package/lambda/response/receipt.d.ts +4 -4
- package/lambda/response/receipt.js +2 -2
- package/lambda/response/store.d.ts +38 -38
- package/lambda/response/store.js +2 -2
- package/lambda/response/user.d.ts +17 -17
- package/lambda/response/user.js +2 -2
- package/lambda/subscription.d.ts +111 -111
- package/lambda/subscription.js +8 -8
- package/models/analysis-summary.d.ts +23 -23
- package/models/analysis-summary.js +2 -2
- package/models/analysis.d.ts +56 -56
- package/models/analysis.js +2 -2
- package/models/appointment.d.ts +18 -18
- package/models/appointment.js +2 -2
- package/models/array-mutations.d.ts +8 -8
- package/models/array-mutations.js +2 -2
- package/models/chain.d.ts +5 -5
- package/models/chain.js +2 -2
- package/models/cognito-filters.d.ts +21 -21
- package/models/cognito-filters.js +2 -2
- package/models/contract.d.ts +32 -32
- package/models/contract.js +2 -2
- package/models/csv/customer.d.ts +18 -18
- package/models/csv/customer.js +2 -2
- package/models/csv/index.d.ts +1 -1
- package/models/csv/index.js +4 -4
- package/models/custom-analysis-group.d.ts +5 -5
- package/models/custom-analysis-group.js +2 -2
- package/models/customer.d.ts +32 -32
- package/models/customer.js +2 -2
- package/models/discount-module/bundle-discount-module.d.ts +9 -9
- package/models/discount-module/bundle-discount-module.js +2 -2
- package/models/discount-module/discount-module.d.ts +92 -92
- package/models/discount-module/discount-module.js +2 -2
- package/models/discount-module/entire-order-discount-module.d.ts +6 -6
- package/models/discount-module/entire-order-discount-module.js +2 -2
- package/models/discount-module/index.d.ts +3 -3
- package/models/discount-module/index.js +6 -6
- package/models/discount-module/selected-item-discount-module.d.ts +9 -9
- package/models/discount-module/selected-item-discount-module.js +2 -2
- package/models/dynamodb-filters.d.ts +37 -37
- package/models/dynamodb-filters.js +2 -2
- package/models/dynamodb-index.d.ts +19 -19
- package/models/dynamodb-index.js +2 -2
- package/models/error/index.d.ts +11 -11
- package/models/error/index.js +6 -6
- package/models/error/invoice.d.ts +3 -3
- package/models/error/invoice.js +11 -11
- package/models/error/order.d.ts +17 -17
- package/models/error/order.js +42 -42
- package/models/error/store.d.ts +6 -6
- package/models/error/store.js +18 -18
- package/models/event.d.ts +13 -13
- package/models/event.js +2 -2
- package/models/external-config.d.ts +10 -10
- package/models/external-config.js +2 -2
- package/models/filter-request.d.ts +13 -13
- package/models/filter-request.js +2 -2
- package/models/index.d.ts +40 -40
- package/models/index.js +43 -43
- package/models/inventory/index.d.ts +5 -5
- package/models/inventory/index.js +8 -8
- package/models/inventory/inventory-item-record.d.ts +52 -52
- package/models/inventory/inventory-item-record.js +2 -2
- package/models/inventory/inventory-item.d.ts +38 -38
- package/models/inventory/inventory-item.js +2 -2
- package/models/inventory/inventory-record.d.ts +40 -40
- package/models/inventory/inventory-record.js +2 -2
- package/models/inventory/inventory.d.ts +23 -23
- package/models/inventory/inventory.js +2 -2
- package/models/inventory/relation.d.ts +17 -17
- package/models/inventory/relation.js +2 -2
- package/models/invoice-config.d.ts +14 -14
- package/models/invoice-config.js +2 -2
- package/models/invoice.d.ts +83 -83
- package/models/invoice.js +2 -2
- package/models/json/base-json.d.ts +3 -3
- package/models/json/base-json.js +2 -2
- package/models/json/index.d.ts +2 -2
- package/models/json/index.js +5 -5
- package/models/json/product-json.d.ts +16 -16
- package/models/json/product-json.js +2 -2
- package/models/kiosk.d.ts +4 -4
- package/models/kiosk.js +2 -2
- package/models/language.d.ts +8 -8
- package/models/language.js +2 -2
- package/models/menu.d.ts +111 -111
- package/models/menu.js +10 -10
- package/models/online-integration.d.ts +88 -88
- package/models/online-integration.js +59 -59
- package/models/online-ordering.d.ts +230 -230
- package/models/online-ordering.js +37 -37
- package/models/order-action.d.ts +11 -11
- package/models/order-action.js +2 -2
- package/models/order.d.ts +445 -445
- package/models/order.js +2 -2
- package/models/override.d.ts +28 -28
- package/models/override.js +14 -14
- package/models/payment-config.d.ts +69 -69
- package/models/payment-config.js +2 -2
- package/models/payment-parameters.d.ts +116 -116
- package/models/payment-parameters.js +3 -3
- package/models/payment.d.ts +42 -42
- package/models/payment.js +2 -2
- package/models/permission/index.d.ts +4 -4
- package/models/permission/index.js +7 -7
- package/models/permission/store-permission.d.ts +9 -9
- package/models/permission/store-permission.js +2 -2
- package/models/permission/store-role-store-permission.d.ts +5 -5
- package/models/permission/store-role-store-permission.js +2 -2
- package/models/permission/store-role-store-user.d.ts +5 -5
- package/models/permission/store-role-store-user.js +2 -2
- package/models/permission/store-role.d.ts +5 -5
- package/models/permission/store-role.js +2 -2
- package/models/plugin/index.d.ts +5 -5
- package/models/plugin/index.js +8 -8
- package/models/plugin/intent-handler/index.d.ts +2 -2
- package/models/plugin/intent-handler/index.js +5 -5
- package/models/plugin/intent-handler/intent-handler-request.d.ts +14 -14
- package/models/plugin/intent-handler/intent-handler-request.js +2 -2
- package/models/plugin/intent-handler/intent-handler-response.d.ts +7 -7
- package/models/plugin/intent-handler/intent-handler-response.js +2 -2
- package/models/plugin/payment-machine/index.d.ts +3 -3
- package/models/plugin/payment-machine/index.js +6 -6
- package/models/plugin/payment-machine/models/fixed-string.model.d.ts +14 -14
- package/models/plugin/payment-machine/models/fixed-string.model.js +52 -52
- package/models/plugin/payment-machine/models/index.d.ts +5 -5
- package/models/plugin/payment-machine/models/index.js +8 -8
- package/models/plugin/payment-machine/models/nccc/index.d.ts +3 -3
- package/models/plugin/payment-machine/models/nccc/index.js +6 -6
- package/models/plugin/payment-machine/models/nccc/payment-machine-d200.model.d.ts +41 -41
- package/models/plugin/payment-machine/models/nccc/payment-machine-d200.model.js +140 -140
- package/models/plugin/payment-machine/models/nccc/payment-machine-v3p.model.d.ts +42 -42
- package/models/plugin/payment-machine/models/nccc/payment-machine-v3p.model.js +621 -621
- package/models/plugin/payment-machine/models/nccc/payment-machine-vx520.model.d.ts +21 -21
- package/models/plugin/payment-machine/models/nccc/payment-machine-vx520.model.js +28 -28
- package/models/plugin/payment-machine/models/payment-machine-minimum.model.d.ts +38 -38
- package/models/plugin/payment-machine/models/payment-machine-minimum.model.js +27 -27
- package/models/plugin/payment-machine/models/payment-machine-union.model.d.ts +123 -123
- package/models/plugin/payment-machine/models/payment-machine-union.model.js +376 -376
- package/models/plugin/payment-machine/models/tsb/index.d.ts +1 -1
- package/models/plugin/payment-machine/models/tsb/index.js +4 -4
- package/models/plugin/payment-machine/models/tsb/payment-machine-d220.model.d.ts +20 -20
- package/models/plugin/payment-machine/models/tsb/payment-machine-d220.model.js +27 -27
- package/models/plugin/payment-machine/payment-machine-request.d.ts +8 -8
- package/models/plugin/payment-machine/payment-machine-request.js +2 -2
- package/models/plugin/payment-machine/payment-machine.d.ts +43 -43
- package/models/plugin/payment-machine/payment-machine.js +50 -50
- package/models/plugin/peripheral.model.d.ts +53 -53
- package/models/plugin/peripheral.model.js +38 -38
- package/models/plugin/printer/index.d.ts +2 -2
- package/models/plugin/printer/index.js +5 -5
- package/models/plugin/printer/printer-request.d.ts +20 -20
- package/models/plugin/printer/printer-request.js +2 -2
- package/models/plugin/printer/printer.d.ts +92 -92
- package/models/plugin/printer/printer.js +11 -11
- package/models/plugin/serial-port/index.d.ts +2 -2
- package/models/plugin/serial-port/index.js +5 -5
- package/models/plugin/serial-port/serial-port-request.d.ts +11 -11
- package/models/plugin/serial-port/serial-port-request.js +2 -2
- package/models/plugin/serial-port/serial-port.d.ts +17 -17
- package/models/plugin/serial-port/serial-port.js +22 -22
- package/models/printer.d.ts +70 -70
- package/models/printer.js +2 -2
- package/models/receipt.d.ts +61 -61
- package/models/receipt.js +2 -2
- package/models/store.d.ts +223 -223
- package/models/store.js +3 -3
- package/models/table.d.ts +34 -34
- package/models/table.js +9 -9
- package/models/template-interface/index.d.ts +1 -1
- package/models/template-interface/index.js +4 -4
- package/models/template-interface/list.d.ts +10 -10
- package/models/template-interface/list.js +2 -2
- package/models/user.d.ts +31 -31
- package/models/user.js +2 -2
- package/models/utils/index.d.ts +1 -1
- package/models/utils/index.js +4 -4
- package/models/utils/utils-data.d.ts +4 -4
- package/models/utils/utils-data.js +2 -2
- package/package.json +25 -25
- package/public-api.d.ts +5 -5
- package/public-api.js +8 -8
- package/third-party-api/uber-eats/enums/ub-menu.d.ts +24 -24
- package/third-party-api/uber-eats/enums/ub-menu.js +32 -32
- package/third-party-api/uber-eats/enums/ub-order.d.ts +55 -55
- package/third-party-api/uber-eats/enums/ub-order.js +66 -66
- package/third-party-api/uber-eats/enums/ub-utils.d.ts +34 -34
- package/third-party-api/uber-eats/enums/ub-utils.js +40 -40
- package/third-party-api/uber-eats/index.d.ts +13 -13
- package/third-party-api/uber-eats/index.js +16 -16
- package/third-party-api/uber-eats/models/ub-cancel-order.d.ts +28 -28
- package/third-party-api/uber-eats/models/ub-cancel-order.js +17 -17
- package/third-party-api/uber-eats/models/ub-cart.d.ts +84 -84
- package/third-party-api/uber-eats/models/ub-cart.js +2 -2
- package/third-party-api/uber-eats/models/ub-menu-config.d.ts +40 -40
- package/third-party-api/uber-eats/models/ub-menu-config.js +2 -2
- package/third-party-api/uber-eats/models/ub-menu-item.d.ts +112 -112
- package/third-party-api/uber-eats/models/ub-menu-item.js +2 -2
- package/third-party-api/uber-eats/models/ub-order.d.ts +59 -59
- package/third-party-api/uber-eats/models/ub-order.js +2 -2
- package/third-party-api/uber-eats/models/ub-payment.d.ts +59 -59
- package/third-party-api/uber-eats/models/ub-payment.js +2 -2
- package/third-party-api/uber-eats/models/ub-pos-accept-order.d.ts +39 -39
- package/third-party-api/uber-eats/models/ub-pos-accept-order.js +2 -2
- package/third-party-api/uber-eats/models/ub-pos-deny-order.d.ts +29 -29
- package/third-party-api/uber-eats/models/ub-pos-deny-order.js +17 -17
- package/third-party-api/uber-eats/models/ub-quantity-constraint-rules.d.ts +48 -48
- package/third-party-api/uber-eats/models/ub-quantity-constraint-rules.js +2 -2
- package/third-party-api/uber-eats/models/ub-utils.d.ts +41 -41
- package/third-party-api/uber-eats/models/ub-utils.js +2 -2
|
@@ -1,59 +1,59 @@
|
|
|
1
|
-
import { UbDeliveryType, UbOrderBrand, UbOrderState, UbOrderType } from '../enums/ub-order';
|
|
2
|
-
import { UbCart } from './ub-cart';
|
|
3
|
-
import { UbPayment } from './ub-payment';
|
|
4
|
-
import { UbLocation } from './ub-utils';
|
|
5
|
-
export interface UbOrder {
|
|
6
|
-
id: string;
|
|
7
|
-
display_id: string;
|
|
8
|
-
/** 如果POS有Call Accept API,會帶入POS的 orderID */
|
|
9
|
-
external_reference_id: string;
|
|
10
|
-
current_state: UbOrderState;
|
|
11
|
-
/** Serve type */
|
|
12
|
-
type: UbOrderType;
|
|
13
|
-
brand: UbOrderBrand;
|
|
14
|
-
store: UbStore;
|
|
15
|
-
eater: UbEater;
|
|
16
|
-
eaters: UbEater[];
|
|
17
|
-
cart: UbCart;
|
|
18
|
-
payment: UbPayment;
|
|
19
|
-
packaging: UbPackaging;
|
|
20
|
-
/** Order.createdAt; e.g. “2019-05-14T15:16:54.723-05:00” */
|
|
21
|
-
placed_at: string;
|
|
22
|
-
/** 餐點預計完成時間; e.g. “2019-05-14T15:16:54.723-05:00” */
|
|
23
|
-
estimated_ready_for_pickup_at: string;
|
|
24
|
-
}
|
|
25
|
-
export interface UbStore {
|
|
26
|
-
id: string;
|
|
27
|
-
name: string;
|
|
28
|
-
/**
|
|
29
|
-
* An optional reference ID for the store that can be used to identify the location in the partner’s systems.
|
|
30
|
-
* 1. If you are using the POS Provision platform, this data is configurable via the Set up POS Integration endpoint.
|
|
31
|
-
* 2. Otherwise, this data must be provided directly to your Uber Eats account manager
|
|
32
|
-
* to configure for each store or provided in store staging requests.
|
|
33
|
-
*/
|
|
34
|
-
external_reference_id?: string;
|
|
35
|
-
}
|
|
36
|
-
export interface UbEater {
|
|
37
|
-
first_name: string;
|
|
38
|
-
last_name: string;
|
|
39
|
-
phone: string;
|
|
40
|
-
phone_code: string;
|
|
41
|
-
id: string;
|
|
42
|
-
corporate_tax_id_taiwan?: string;
|
|
43
|
-
/**
|
|
44
|
-
* 台灣好像沒有店家外送
|
|
45
|
-
* 店家自行外送時才有的特殊指示
|
|
46
|
-
*/
|
|
47
|
-
delivery: UbDelivery;
|
|
48
|
-
}
|
|
49
|
-
export interface UbDelivery {
|
|
50
|
-
location: UbLocation;
|
|
51
|
-
type: UbDeliveryType;
|
|
52
|
-
note: string;
|
|
53
|
-
}
|
|
54
|
-
export interface UbPackaging {
|
|
55
|
-
disposable_items: UbDisposableItems;
|
|
56
|
-
}
|
|
57
|
-
export interface UbDisposableItems {
|
|
58
|
-
should_include: boolean;
|
|
59
|
-
}
|
|
1
|
+
import { UbDeliveryType, UbOrderBrand, UbOrderState, UbOrderType } from '../enums/ub-order';
|
|
2
|
+
import { UbCart } from './ub-cart';
|
|
3
|
+
import { UbPayment } from './ub-payment';
|
|
4
|
+
import { UbLocation } from './ub-utils';
|
|
5
|
+
export interface UbOrder {
|
|
6
|
+
id: string;
|
|
7
|
+
display_id: string;
|
|
8
|
+
/** 如果POS有Call Accept API,會帶入POS的 orderID */
|
|
9
|
+
external_reference_id: string;
|
|
10
|
+
current_state: UbOrderState;
|
|
11
|
+
/** Serve type */
|
|
12
|
+
type: UbOrderType;
|
|
13
|
+
brand: UbOrderBrand;
|
|
14
|
+
store: UbStore;
|
|
15
|
+
eater: UbEater;
|
|
16
|
+
eaters: UbEater[];
|
|
17
|
+
cart: UbCart;
|
|
18
|
+
payment: UbPayment;
|
|
19
|
+
packaging: UbPackaging;
|
|
20
|
+
/** Order.createdAt; e.g. “2019-05-14T15:16:54.723-05:00” */
|
|
21
|
+
placed_at: string;
|
|
22
|
+
/** 餐點預計完成時間; e.g. “2019-05-14T15:16:54.723-05:00” */
|
|
23
|
+
estimated_ready_for_pickup_at: string;
|
|
24
|
+
}
|
|
25
|
+
export interface UbStore {
|
|
26
|
+
id: string;
|
|
27
|
+
name: string;
|
|
28
|
+
/**
|
|
29
|
+
* An optional reference ID for the store that can be used to identify the location in the partner’s systems.
|
|
30
|
+
* 1. If you are using the POS Provision platform, this data is configurable via the Set up POS Integration endpoint.
|
|
31
|
+
* 2. Otherwise, this data must be provided directly to your Uber Eats account manager
|
|
32
|
+
* to configure for each store or provided in store staging requests.
|
|
33
|
+
*/
|
|
34
|
+
external_reference_id?: string;
|
|
35
|
+
}
|
|
36
|
+
export interface UbEater {
|
|
37
|
+
first_name: string;
|
|
38
|
+
last_name: string;
|
|
39
|
+
phone: string;
|
|
40
|
+
phone_code: string;
|
|
41
|
+
id: string;
|
|
42
|
+
corporate_tax_id_taiwan?: string;
|
|
43
|
+
/**
|
|
44
|
+
* 台灣好像沒有店家外送
|
|
45
|
+
* 店家自行外送時才有的特殊指示
|
|
46
|
+
*/
|
|
47
|
+
delivery: UbDelivery;
|
|
48
|
+
}
|
|
49
|
+
export interface UbDelivery {
|
|
50
|
+
location: UbLocation;
|
|
51
|
+
type: UbDeliveryType;
|
|
52
|
+
note: string;
|
|
53
|
+
}
|
|
54
|
+
export interface UbPackaging {
|
|
55
|
+
disposable_items: UbDisposableItems;
|
|
56
|
+
}
|
|
57
|
+
export interface UbDisposableItems {
|
|
58
|
+
should_include: boolean;
|
|
59
|
+
}
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
//# sourceMappingURL=ub-order.js.map
|
|
@@ -1,59 +1,59 @@
|
|
|
1
|
-
import { UbPromotionType } from '../enums/ub-order';
|
|
2
|
-
import { UbMoney } from './ub-utils';
|
|
3
|
-
export interface UbPayment {
|
|
4
|
-
/** 全品項稅率與金額 */
|
|
5
|
-
charges: UbCharges;
|
|
6
|
-
/** 整張單的會計包含稅率 */
|
|
7
|
-
accounting: UbAccounting;
|
|
8
|
-
/** 促銷數據,開發者需要而外開通才接的到 */
|
|
9
|
-
promotions?: UbPromotions;
|
|
10
|
-
}
|
|
11
|
-
export interface UbCharges {
|
|
12
|
-
/** 包含稅率的總額 */
|
|
13
|
-
total: UbMoney;
|
|
14
|
-
/** 各品項金額加總 */
|
|
15
|
-
sub_total: UbMoney;
|
|
16
|
-
/** 各品項的稅率總和 */
|
|
17
|
-
tax: UbMoney;
|
|
18
|
-
/** (部分地區適用,暫時不理他) */
|
|
19
|
-
total_fee: UbMoney;
|
|
20
|
-
/** (部分地區適用,暫時不理他) */
|
|
21
|
-
total_fee_tax: UbMoney;
|
|
22
|
-
}
|
|
23
|
-
export interface UbAccounting {
|
|
24
|
-
tax_remittance: UbTaxRemittance;
|
|
25
|
-
}
|
|
26
|
-
export interface UbTaxRemittance {
|
|
27
|
-
tax: UbRemittanceInfo;
|
|
28
|
-
total_fee_tax: UbRemittanceInfo;
|
|
29
|
-
delivery_fee_tax: UbRemittanceInfo;
|
|
30
|
-
small_order_fee_tax: UbRemittanceInfo;
|
|
31
|
-
}
|
|
32
|
-
/** Contains the Payee details this entity need to remit */
|
|
33
|
-
export interface UbRemittanceInfo {
|
|
34
|
-
uber: UbPayeeDetail[];
|
|
35
|
-
/** 店家要負責的稅 */
|
|
36
|
-
restaurant: UbPayeeDetail[];
|
|
37
|
-
courier: UbPayeeDetail[];
|
|
38
|
-
eater: UbPayeeDetail[];
|
|
39
|
-
}
|
|
40
|
-
export interface UbPayeeDetail {
|
|
41
|
-
value: UbMoney;
|
|
42
|
-
}
|
|
43
|
-
export interface UbPromotions {
|
|
44
|
-
promotions: UbPromotion[];
|
|
45
|
-
}
|
|
46
|
-
export interface UbPromotion {
|
|
47
|
-
/** the external partner’s promotion id */
|
|
48
|
-
external_promotion_id?: string;
|
|
49
|
-
promo_type: UbPromotionType;
|
|
50
|
-
promo_discount_value: number;
|
|
51
|
-
promo_discount_percentage: number;
|
|
52
|
-
promo_delivery_fee_value: number;
|
|
53
|
-
discount_items: UbDiscountItem[];
|
|
54
|
-
}
|
|
55
|
-
export interface UbDiscountItem {
|
|
56
|
-
/** the external partner’s id for an item. */
|
|
57
|
-
external_id?: string;
|
|
58
|
-
discounted_quantity: number;
|
|
59
|
-
}
|
|
1
|
+
import { UbPromotionType } from '../enums/ub-order';
|
|
2
|
+
import { UbMoney } from './ub-utils';
|
|
3
|
+
export interface UbPayment {
|
|
4
|
+
/** 全品項稅率與金額 */
|
|
5
|
+
charges: UbCharges;
|
|
6
|
+
/** 整張單的會計包含稅率 */
|
|
7
|
+
accounting: UbAccounting;
|
|
8
|
+
/** 促銷數據,開發者需要而外開通才接的到 */
|
|
9
|
+
promotions?: UbPromotions;
|
|
10
|
+
}
|
|
11
|
+
export interface UbCharges {
|
|
12
|
+
/** 包含稅率的總額 */
|
|
13
|
+
total: UbMoney;
|
|
14
|
+
/** 各品項金額加總 */
|
|
15
|
+
sub_total: UbMoney;
|
|
16
|
+
/** 各品項的稅率總和 */
|
|
17
|
+
tax: UbMoney;
|
|
18
|
+
/** (部分地區適用,暫時不理他) */
|
|
19
|
+
total_fee: UbMoney;
|
|
20
|
+
/** (部分地區適用,暫時不理他) */
|
|
21
|
+
total_fee_tax: UbMoney;
|
|
22
|
+
}
|
|
23
|
+
export interface UbAccounting {
|
|
24
|
+
tax_remittance: UbTaxRemittance;
|
|
25
|
+
}
|
|
26
|
+
export interface UbTaxRemittance {
|
|
27
|
+
tax: UbRemittanceInfo;
|
|
28
|
+
total_fee_tax: UbRemittanceInfo;
|
|
29
|
+
delivery_fee_tax: UbRemittanceInfo;
|
|
30
|
+
small_order_fee_tax: UbRemittanceInfo;
|
|
31
|
+
}
|
|
32
|
+
/** Contains the Payee details this entity need to remit */
|
|
33
|
+
export interface UbRemittanceInfo {
|
|
34
|
+
uber: UbPayeeDetail[];
|
|
35
|
+
/** 店家要負責的稅 */
|
|
36
|
+
restaurant: UbPayeeDetail[];
|
|
37
|
+
courier: UbPayeeDetail[];
|
|
38
|
+
eater: UbPayeeDetail[];
|
|
39
|
+
}
|
|
40
|
+
export interface UbPayeeDetail {
|
|
41
|
+
value: UbMoney;
|
|
42
|
+
}
|
|
43
|
+
export interface UbPromotions {
|
|
44
|
+
promotions: UbPromotion[];
|
|
45
|
+
}
|
|
46
|
+
export interface UbPromotion {
|
|
47
|
+
/** the external partner’s promotion id */
|
|
48
|
+
external_promotion_id?: string;
|
|
49
|
+
promo_type: UbPromotionType;
|
|
50
|
+
promo_discount_value: number;
|
|
51
|
+
promo_discount_percentage: number;
|
|
52
|
+
promo_delivery_fee_value: number;
|
|
53
|
+
discount_items: UbDiscountItem[];
|
|
54
|
+
}
|
|
55
|
+
export interface UbDiscountItem {
|
|
56
|
+
/** the external partner’s id for an item. */
|
|
57
|
+
external_id?: string;
|
|
58
|
+
discounted_quantity: number;
|
|
59
|
+
}
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
//# sourceMappingURL=ub-payment.js.map
|
|
@@ -1,39 +1,39 @@
|
|
|
1
|
-
export interface UbAcceptOrderRequest {
|
|
2
|
-
/**
|
|
3
|
-
* Reason or note of acceptance.
|
|
4
|
-
*/
|
|
5
|
-
reason: string;
|
|
6
|
-
/**
|
|
7
|
-
* (optional) Time when order will be ready for pick-up,
|
|
8
|
-
* specified as a Unix timestamp (seconds since Jan 1, 1970).
|
|
9
|
-
*/
|
|
10
|
-
pickup_time?: number;
|
|
11
|
-
/**
|
|
12
|
-
* (optional) Used to assign a custom/3rd-party order ID.
|
|
13
|
-
* This can be subsequently retrieved using the GET /<order_uuid> V2 endpoint.
|
|
14
|
-
*/
|
|
15
|
-
external_reference_id?: string;
|
|
16
|
-
/**
|
|
17
|
-
* (optional) Used to surface the Eats features supported by the order integration.
|
|
18
|
-
*/
|
|
19
|
-
fields_relayed?: UbFieldsRelayed;
|
|
20
|
-
}
|
|
21
|
-
export interface UbFieldsRelayed {
|
|
22
|
-
/**
|
|
23
|
-
* (optional) Set as true if the order integration supports order-level special instructions.
|
|
24
|
-
*/
|
|
25
|
-
order_special_instructions?: boolean;
|
|
26
|
-
/**
|
|
27
|
-
* (optional) Set as true if the order integration supports item-level special instructions.
|
|
28
|
-
*/
|
|
29
|
-
item_special_instructions?: boolean;
|
|
30
|
-
/**
|
|
31
|
-
* (optional) Set as true if the order integration supports special requests
|
|
32
|
-
*/
|
|
33
|
-
item_special_requests?: boolean;
|
|
34
|
-
/**
|
|
35
|
-
* (optional) Set as true if the order integration supports Eats promotions
|
|
36
|
-
*/
|
|
37
|
-
promotions?: boolean;
|
|
38
|
-
}
|
|
39
|
-
export declare type UbAcceptOrderResponse = null;
|
|
1
|
+
export interface UbAcceptOrderRequest {
|
|
2
|
+
/**
|
|
3
|
+
* Reason or note of acceptance.
|
|
4
|
+
*/
|
|
5
|
+
reason: string;
|
|
6
|
+
/**
|
|
7
|
+
* (optional) Time when order will be ready for pick-up,
|
|
8
|
+
* specified as a Unix timestamp (seconds since Jan 1, 1970).
|
|
9
|
+
*/
|
|
10
|
+
pickup_time?: number;
|
|
11
|
+
/**
|
|
12
|
+
* (optional) Used to assign a custom/3rd-party order ID.
|
|
13
|
+
* This can be subsequently retrieved using the GET /<order_uuid> V2 endpoint.
|
|
14
|
+
*/
|
|
15
|
+
external_reference_id?: string;
|
|
16
|
+
/**
|
|
17
|
+
* (optional) Used to surface the Eats features supported by the order integration.
|
|
18
|
+
*/
|
|
19
|
+
fields_relayed?: UbFieldsRelayed;
|
|
20
|
+
}
|
|
21
|
+
export interface UbFieldsRelayed {
|
|
22
|
+
/**
|
|
23
|
+
* (optional) Set as true if the order integration supports order-level special instructions.
|
|
24
|
+
*/
|
|
25
|
+
order_special_instructions?: boolean;
|
|
26
|
+
/**
|
|
27
|
+
* (optional) Set as true if the order integration supports item-level special instructions.
|
|
28
|
+
*/
|
|
29
|
+
item_special_instructions?: boolean;
|
|
30
|
+
/**
|
|
31
|
+
* (optional) Set as true if the order integration supports special requests
|
|
32
|
+
*/
|
|
33
|
+
item_special_requests?: boolean;
|
|
34
|
+
/**
|
|
35
|
+
* (optional) Set as true if the order integration supports Eats promotions
|
|
36
|
+
*/
|
|
37
|
+
promotions?: boolean;
|
|
38
|
+
}
|
|
39
|
+
export declare type UbAcceptOrderResponse = null;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
//# sourceMappingURL=ub-pos-accept-order.js.map
|
|
@@ -1,29 +1,29 @@
|
|
|
1
|
-
export declare enum UbDenyReasonCode {
|
|
2
|
-
STORE_CLOSED = "STORE_CLOSED",
|
|
3
|
-
POS_NOT_READY = "POS_NOT_READY",
|
|
4
|
-
POS_OFFLINE = "POS_OFFLINE",
|
|
5
|
-
ITEM_AVAILABILITY = "ITEM_AVAILABILITY",
|
|
6
|
-
MISSING_ITEM = "MISSING_ITEM",
|
|
7
|
-
MISSING_INFO = "MISSING_INFO",
|
|
8
|
-
PRICING = "PRICING",
|
|
9
|
-
CAPACITY = "CAPACITY",
|
|
10
|
-
ADDRESS = "ADDRESS",
|
|
11
|
-
SPECIAL_INSTRUCTIONS = "SPECIAL_INSTRUCTIONS",
|
|
12
|
-
OTHER = "OTHER"
|
|
13
|
-
}
|
|
14
|
-
export interface UbDenyOrderRequest {
|
|
15
|
-
reason: {
|
|
16
|
-
/**
|
|
17
|
-
* Reason or note for denial.
|
|
18
|
-
*/
|
|
19
|
-
explanation: string;
|
|
20
|
-
/**
|
|
21
|
-
* Reason code from set list of possible predefined values.
|
|
22
|
-
* Examples for each can be found here.
|
|
23
|
-
*/
|
|
24
|
-
code: UbDenyReasonCode;
|
|
25
|
-
out_of_stock_items?: string[];
|
|
26
|
-
invalid_items?: string[];
|
|
27
|
-
};
|
|
28
|
-
}
|
|
29
|
-
export declare type UbDenyOrderResponse = null;
|
|
1
|
+
export declare enum UbDenyReasonCode {
|
|
2
|
+
STORE_CLOSED = "STORE_CLOSED",
|
|
3
|
+
POS_NOT_READY = "POS_NOT_READY",
|
|
4
|
+
POS_OFFLINE = "POS_OFFLINE",
|
|
5
|
+
ITEM_AVAILABILITY = "ITEM_AVAILABILITY",
|
|
6
|
+
MISSING_ITEM = "MISSING_ITEM",
|
|
7
|
+
MISSING_INFO = "MISSING_INFO",
|
|
8
|
+
PRICING = "PRICING",
|
|
9
|
+
CAPACITY = "CAPACITY",
|
|
10
|
+
ADDRESS = "ADDRESS",
|
|
11
|
+
SPECIAL_INSTRUCTIONS = "SPECIAL_INSTRUCTIONS",
|
|
12
|
+
OTHER = "OTHER"
|
|
13
|
+
}
|
|
14
|
+
export interface UbDenyOrderRequest {
|
|
15
|
+
reason: {
|
|
16
|
+
/**
|
|
17
|
+
* Reason or note for denial.
|
|
18
|
+
*/
|
|
19
|
+
explanation: string;
|
|
20
|
+
/**
|
|
21
|
+
* Reason code from set list of possible predefined values.
|
|
22
|
+
* Examples for each can be found here.
|
|
23
|
+
*/
|
|
24
|
+
code: UbDenyReasonCode;
|
|
25
|
+
out_of_stock_items?: string[];
|
|
26
|
+
invalid_items?: string[];
|
|
27
|
+
};
|
|
28
|
+
}
|
|
29
|
+
export declare type UbDenyOrderResponse = null;
|
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.UbDenyReasonCode = void 0;
|
|
4
|
-
var UbDenyReasonCode;
|
|
5
|
-
(function (UbDenyReasonCode) {
|
|
6
|
-
UbDenyReasonCode["STORE_CLOSED"] = "STORE_CLOSED";
|
|
7
|
-
UbDenyReasonCode["POS_NOT_READY"] = "POS_NOT_READY";
|
|
8
|
-
UbDenyReasonCode["POS_OFFLINE"] = "POS_OFFLINE";
|
|
9
|
-
UbDenyReasonCode["ITEM_AVAILABILITY"] = "ITEM_AVAILABILITY";
|
|
10
|
-
UbDenyReasonCode["MISSING_ITEM"] = "MISSING_ITEM";
|
|
11
|
-
UbDenyReasonCode["MISSING_INFO"] = "MISSING_INFO";
|
|
12
|
-
UbDenyReasonCode["PRICING"] = "PRICING";
|
|
13
|
-
UbDenyReasonCode["CAPACITY"] = "CAPACITY";
|
|
14
|
-
UbDenyReasonCode["ADDRESS"] = "ADDRESS";
|
|
15
|
-
UbDenyReasonCode["SPECIAL_INSTRUCTIONS"] = "SPECIAL_INSTRUCTIONS";
|
|
16
|
-
UbDenyReasonCode["OTHER"] = "OTHER";
|
|
17
|
-
})(UbDenyReasonCode = exports.UbDenyReasonCode || (exports.UbDenyReasonCode = {}));
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.UbDenyReasonCode = void 0;
|
|
4
|
+
var UbDenyReasonCode;
|
|
5
|
+
(function (UbDenyReasonCode) {
|
|
6
|
+
UbDenyReasonCode["STORE_CLOSED"] = "STORE_CLOSED";
|
|
7
|
+
UbDenyReasonCode["POS_NOT_READY"] = "POS_NOT_READY";
|
|
8
|
+
UbDenyReasonCode["POS_OFFLINE"] = "POS_OFFLINE";
|
|
9
|
+
UbDenyReasonCode["ITEM_AVAILABILITY"] = "ITEM_AVAILABILITY";
|
|
10
|
+
UbDenyReasonCode["MISSING_ITEM"] = "MISSING_ITEM";
|
|
11
|
+
UbDenyReasonCode["MISSING_INFO"] = "MISSING_INFO";
|
|
12
|
+
UbDenyReasonCode["PRICING"] = "PRICING";
|
|
13
|
+
UbDenyReasonCode["CAPACITY"] = "CAPACITY";
|
|
14
|
+
UbDenyReasonCode["ADDRESS"] = "ADDRESS";
|
|
15
|
+
UbDenyReasonCode["SPECIAL_INSTRUCTIONS"] = "SPECIAL_INSTRUCTIONS";
|
|
16
|
+
UbDenyReasonCode["OTHER"] = "OTHER";
|
|
17
|
+
})(UbDenyReasonCode = exports.UbDenyReasonCode || (exports.UbDenyReasonCode = {}));
|
|
18
18
|
//# sourceMappingURL=ub-pos-deny-order.js.map
|
|
@@ -1,48 +1,48 @@
|
|
|
1
|
-
import { UbOverride } from './ub-utils';
|
|
2
|
-
export interface UbQuantityConstraintRules {
|
|
3
|
-
quantity?: UbQuantityConstraint;
|
|
4
|
-
overrides?: UbQuantityConstraintOverride[];
|
|
5
|
-
}
|
|
6
|
-
export interface UbQuantityConstraint {
|
|
7
|
-
/** Minimum quantity allowed (inclusive); Cannot be negative */
|
|
8
|
-
min_permitted?: number;
|
|
9
|
-
/** Maximum quantity allowed (inclusive); cannot be less than min_permitted */
|
|
10
|
-
max_permitted?: number;
|
|
11
|
-
/** must be between min_permitted and max_permitted (inclusive) */
|
|
12
|
-
default_quantity?: number;
|
|
13
|
-
/**
|
|
14
|
-
* When provided, the item price will only be charged per quantity unit in excess of this amount.
|
|
15
|
-
* Can either be applied to an individual item or an entire modifier group.
|
|
16
|
-
* - charge_above and refund_under must either both be null or both be non-null.
|
|
17
|
-
* - Cannot be negative.
|
|
18
|
-
* - Cannot be greater than max_permitted.
|
|
19
|
-
* - Cannot be less than default_quantity.
|
|
20
|
-
*/
|
|
21
|
-
charge_above?: number;
|
|
22
|
-
/**
|
|
23
|
-
* When provided, the item price will be refunded per quantity unit chosen below this amount.
|
|
24
|
-
* Can either be applied to an individual item or an entire modifier group.
|
|
25
|
-
* - charge_above and refund_under must either both be null or both be non-null.
|
|
26
|
-
* - Cannot be negative.
|
|
27
|
-
* - Cannot be less than max_permitted.
|
|
28
|
-
* - Cannot be greater than default_quantity.
|
|
29
|
-
*/
|
|
30
|
-
refund_under?: number;
|
|
31
|
-
/**
|
|
32
|
-
* Minimum quantity of unique customization selections allowed (inclusive).
|
|
33
|
-
* - Cannot be negative.
|
|
34
|
-
* - Can only be applied to modifier groups;
|
|
35
|
-
* - Cannot be used for individual modifier options.
|
|
36
|
-
*/
|
|
37
|
-
min_permitted_unique?: number;
|
|
38
|
-
/**
|
|
39
|
-
* Maximum quantity of unique customization selections allowed (inclusive)
|
|
40
|
-
* - Cannot be less than min_permitted_unique.
|
|
41
|
-
* - Can only be applied to modifier groups;
|
|
42
|
-
* - Cannot be used for individual modifier options.
|
|
43
|
-
*/
|
|
44
|
-
max_permitted_unique?: number;
|
|
45
|
-
}
|
|
46
|
-
export interface UbQuantityConstraintOverride extends UbOverride {
|
|
47
|
-
quantity: UbQuantityConstraint;
|
|
48
|
-
}
|
|
1
|
+
import { UbOverride } from './ub-utils';
|
|
2
|
+
export interface UbQuantityConstraintRules {
|
|
3
|
+
quantity?: UbQuantityConstraint;
|
|
4
|
+
overrides?: UbQuantityConstraintOverride[];
|
|
5
|
+
}
|
|
6
|
+
export interface UbQuantityConstraint {
|
|
7
|
+
/** Minimum quantity allowed (inclusive); Cannot be negative */
|
|
8
|
+
min_permitted?: number;
|
|
9
|
+
/** Maximum quantity allowed (inclusive); cannot be less than min_permitted */
|
|
10
|
+
max_permitted?: number;
|
|
11
|
+
/** must be between min_permitted and max_permitted (inclusive) */
|
|
12
|
+
default_quantity?: number;
|
|
13
|
+
/**
|
|
14
|
+
* When provided, the item price will only be charged per quantity unit in excess of this amount.
|
|
15
|
+
* Can either be applied to an individual item or an entire modifier group.
|
|
16
|
+
* - charge_above and refund_under must either both be null or both be non-null.
|
|
17
|
+
* - Cannot be negative.
|
|
18
|
+
* - Cannot be greater than max_permitted.
|
|
19
|
+
* - Cannot be less than default_quantity.
|
|
20
|
+
*/
|
|
21
|
+
charge_above?: number;
|
|
22
|
+
/**
|
|
23
|
+
* When provided, the item price will be refunded per quantity unit chosen below this amount.
|
|
24
|
+
* Can either be applied to an individual item or an entire modifier group.
|
|
25
|
+
* - charge_above and refund_under must either both be null or both be non-null.
|
|
26
|
+
* - Cannot be negative.
|
|
27
|
+
* - Cannot be less than max_permitted.
|
|
28
|
+
* - Cannot be greater than default_quantity.
|
|
29
|
+
*/
|
|
30
|
+
refund_under?: number;
|
|
31
|
+
/**
|
|
32
|
+
* Minimum quantity of unique customization selections allowed (inclusive).
|
|
33
|
+
* - Cannot be negative.
|
|
34
|
+
* - Can only be applied to modifier groups;
|
|
35
|
+
* - Cannot be used for individual modifier options.
|
|
36
|
+
*/
|
|
37
|
+
min_permitted_unique?: number;
|
|
38
|
+
/**
|
|
39
|
+
* Maximum quantity of unique customization selections allowed (inclusive)
|
|
40
|
+
* - Cannot be less than min_permitted_unique.
|
|
41
|
+
* - Can only be applied to modifier groups;
|
|
42
|
+
* - Cannot be used for individual modifier options.
|
|
43
|
+
*/
|
|
44
|
+
max_permitted_unique?: number;
|
|
45
|
+
}
|
|
46
|
+
export interface UbQuantityConstraintOverride extends UbOverride {
|
|
47
|
+
quantity: UbQuantityConstraint;
|
|
48
|
+
}
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
//# sourceMappingURL=ub-quantity-constraint-rules.js.map
|
|
@@ -1,41 +1,41 @@
|
|
|
1
|
-
import { UbContextType } from '../enums/ub-menu';
|
|
2
|
-
import { UbDayOfWeek, UbLocationType } from '../enums/ub-utils';
|
|
3
|
-
export interface UbMultiLanguageText {
|
|
4
|
-
/** key: 'en_us' (locale codes) */
|
|
5
|
-
translations: {
|
|
6
|
-
[key: string]: string;
|
|
7
|
-
};
|
|
8
|
-
}
|
|
9
|
-
export interface UbServiceAvailability {
|
|
10
|
-
day_of_week: UbDayOfWeek;
|
|
11
|
-
time_periods: UbTimePeriod[];
|
|
12
|
-
}
|
|
13
|
-
export interface UbTimePeriod {
|
|
14
|
-
/** HH:MM '00:00' - '23:59' */
|
|
15
|
-
start_time: string;
|
|
16
|
-
/** HH:MM '00:00' - '23:59' */
|
|
17
|
-
end_time: string;
|
|
18
|
-
}
|
|
19
|
-
export interface UbOverride {
|
|
20
|
-
context_type: UbContextType;
|
|
21
|
-
/** context ID */
|
|
22
|
-
context_value: string;
|
|
23
|
-
}
|
|
24
|
-
export interface UbHoursOfWeek {
|
|
25
|
-
day_of_week: UbDayOfWeek;
|
|
26
|
-
time_periods: UbTimePeriod;
|
|
27
|
-
}
|
|
28
|
-
export interface UbLocation {
|
|
29
|
-
type: UbLocationType;
|
|
30
|
-
street_address?: string;
|
|
31
|
-
latitude?: number;
|
|
32
|
-
longitude?: number;
|
|
33
|
-
google_place_id?: string;
|
|
34
|
-
unit_number?: string;
|
|
35
|
-
}
|
|
36
|
-
export interface UbMoney {
|
|
37
|
-
amount: number;
|
|
38
|
-
/** ISO 4217 code */
|
|
39
|
-
currency_code: string;
|
|
40
|
-
formatted_amount: string;
|
|
41
|
-
}
|
|
1
|
+
import { UbContextType } from '../enums/ub-menu';
|
|
2
|
+
import { UbDayOfWeek, UbLocationType } from '../enums/ub-utils';
|
|
3
|
+
export interface UbMultiLanguageText {
|
|
4
|
+
/** key: 'en_us' (locale codes) */
|
|
5
|
+
translations: {
|
|
6
|
+
[key: string]: string;
|
|
7
|
+
};
|
|
8
|
+
}
|
|
9
|
+
export interface UbServiceAvailability {
|
|
10
|
+
day_of_week: UbDayOfWeek;
|
|
11
|
+
time_periods: UbTimePeriod[];
|
|
12
|
+
}
|
|
13
|
+
export interface UbTimePeriod {
|
|
14
|
+
/** HH:MM '00:00' - '23:59' */
|
|
15
|
+
start_time: string;
|
|
16
|
+
/** HH:MM '00:00' - '23:59' */
|
|
17
|
+
end_time: string;
|
|
18
|
+
}
|
|
19
|
+
export interface UbOverride {
|
|
20
|
+
context_type: UbContextType;
|
|
21
|
+
/** context ID */
|
|
22
|
+
context_value: string;
|
|
23
|
+
}
|
|
24
|
+
export interface UbHoursOfWeek {
|
|
25
|
+
day_of_week: UbDayOfWeek;
|
|
26
|
+
time_periods: UbTimePeriod;
|
|
27
|
+
}
|
|
28
|
+
export interface UbLocation {
|
|
29
|
+
type: UbLocationType;
|
|
30
|
+
street_address?: string;
|
|
31
|
+
latitude?: number;
|
|
32
|
+
longitude?: number;
|
|
33
|
+
google_place_id?: string;
|
|
34
|
+
unit_number?: string;
|
|
35
|
+
}
|
|
36
|
+
export interface UbMoney {
|
|
37
|
+
amount: number;
|
|
38
|
+
/** ISO 4217 code */
|
|
39
|
+
currency_code: string;
|
|
40
|
+
formatted_amount: string;
|
|
41
|
+
}
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
//# sourceMappingURL=ub-utils.js.map
|