@trusted-solutions/sdit.models 0.18.0-alpha.13 → 0.18.0-alpha.17
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/enums/real-time-switch-type.d.ts +1 -1
- package/enums/real-time-switch-type.js +1 -1
- package/enums/real-time-switch-type.js.map +1 -1
- package/lambda/online-ordering.d.ts +12 -0
- package/lambda/request/real-time-switch.d.ts +10 -4
- package/lambda/request/store.d.ts +1 -0
- package/models/order.d.ts +7 -1
- package/package.json +1 -1
|
@@ -4,5 +4,5 @@ export declare enum RealTimeSwitchType {
|
|
|
4
4
|
ServeTypeDisableDineIn = "ServeTypeDisableDineIn",
|
|
5
5
|
ServeTypeDisableTakeout = "ServeTypeDisableTakeout",
|
|
6
6
|
DisableKiosk = "DisableKiosk",
|
|
7
|
-
|
|
7
|
+
OnlineOrderUntilOpen = "OnlineOrderUntilOpen"
|
|
8
8
|
}
|
|
@@ -8,6 +8,6 @@ var RealTimeSwitchType;
|
|
|
8
8
|
RealTimeSwitchType["ServeTypeDisableDineIn"] = "ServeTypeDisableDineIn";
|
|
9
9
|
RealTimeSwitchType["ServeTypeDisableTakeout"] = "ServeTypeDisableTakeout";
|
|
10
10
|
RealTimeSwitchType["DisableKiosk"] = "DisableKiosk";
|
|
11
|
-
RealTimeSwitchType["
|
|
11
|
+
RealTimeSwitchType["OnlineOrderUntilOpen"] = "OnlineOrderUntilOpen";
|
|
12
12
|
})(RealTimeSwitchType = exports.RealTimeSwitchType || (exports.RealTimeSwitchType = {}));
|
|
13
13
|
//# sourceMappingURL=real-time-switch-type.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"real-time-switch-type.js","sourceRoot":"","sources":["../../../projects/sdit-model-lib/src/enums/real-time-switch-type.ts"],"names":[],"mappings":";;;AAAA,IAAY,kBAOX;AAPD,WAAY,kBAAkB;IAC5B,uDAAiC,CAAA;IACjC,yEAAmD,CAAA;IACnD,uEAAiD,CAAA;IACjD,yEAAmD,CAAA;IACnD,mDAA6B,CAAA;IAC7B,
|
|
1
|
+
{"version":3,"file":"real-time-switch-type.js","sourceRoot":"","sources":["../../../projects/sdit-model-lib/src/enums/real-time-switch-type.ts"],"names":[],"mappings":";;;AAAA,IAAY,kBAOX;AAPD,WAAY,kBAAkB;IAC5B,uDAAiC,CAAA;IACjC,yEAAmD,CAAA;IACnD,uEAAiD,CAAA;IACjD,yEAAmD,CAAA;IACnD,mDAA6B,CAAA;IAC7B,mEAA6C,CAAA;AAC/C,CAAC,EAPW,kBAAkB,GAAlB,0BAAkB,KAAlB,0BAAkB,QAO7B"}
|
|
@@ -175,6 +175,18 @@ export interface SOGetPaymentUrlRequest {
|
|
|
175
175
|
storeId: string;
|
|
176
176
|
/** online Order Id */
|
|
177
177
|
id: string;
|
|
178
|
+
/**
|
|
179
|
+
* 以MyPay為例
|
|
180
|
+
* 可在產生付款網址時,決定returnUrl
|
|
181
|
+
* 若不填寫,則以MyPay特約店家後台設定的為主
|
|
182
|
+
*/
|
|
183
|
+
successReturnUrl?: string;
|
|
184
|
+
/**
|
|
185
|
+
* 以MyPay為例
|
|
186
|
+
* 可在產生付款網址時,決定returnUrl
|
|
187
|
+
* 若不填寫,則以MyPay特約店家後台設定的為主
|
|
188
|
+
*/
|
|
189
|
+
failureReturnUrl?: string;
|
|
178
190
|
}
|
|
179
191
|
export interface SOGetPaymentUrlResponse {
|
|
180
192
|
payUrl: string;
|
|
@@ -1,27 +1,33 @@
|
|
|
1
1
|
import { RealTimeSwitchType } from '../../enums/real-time-switch-type';
|
|
2
|
-
export declare type RealTimeSwitchRequest = ProductRealTimeSwitchRequest | ProductAttributeRealTimeSwitchRequest | DisableDineInRealTimeSwitchRequest | DisableTakeoutRealTimeSwitchRequest | DisableKioskRealTimeSwitchRequest |
|
|
2
|
+
export declare type RealTimeSwitchRequest = ProductRealTimeSwitchRequest | ProductAttributeRealTimeSwitchRequest | DisableDineInRealTimeSwitchRequest | DisableTakeoutRealTimeSwitchRequest | DisableKioskRealTimeSwitchRequest | OnlineOrderUntilOpenSwitchRequest;
|
|
3
3
|
export interface BaseRealTimeSwitchRequest {
|
|
4
4
|
storeId: string;
|
|
5
5
|
type: RealTimeSwitchType;
|
|
6
|
-
value: boolean;
|
|
6
|
+
value: boolean | number;
|
|
7
7
|
}
|
|
8
8
|
export interface ProductRealTimeSwitchRequest extends BaseRealTimeSwitchRequest {
|
|
9
9
|
type: RealTimeSwitchType.ProductSoldOut;
|
|
10
10
|
productId: string;
|
|
11
|
+
value: boolean;
|
|
11
12
|
}
|
|
12
13
|
export interface ProductAttributeRealTimeSwitchRequest extends BaseRealTimeSwitchRequest {
|
|
13
14
|
type: RealTimeSwitchType.ProductAttributeSoldOut;
|
|
14
15
|
productAttributeId: string;
|
|
16
|
+
value: boolean;
|
|
15
17
|
}
|
|
16
18
|
export interface DisableDineInRealTimeSwitchRequest extends BaseRealTimeSwitchRequest {
|
|
17
19
|
type: RealTimeSwitchType.ServeTypeDisableDineIn;
|
|
20
|
+
value: boolean;
|
|
18
21
|
}
|
|
19
22
|
export interface DisableTakeoutRealTimeSwitchRequest extends BaseRealTimeSwitchRequest {
|
|
20
23
|
type: RealTimeSwitchType.ServeTypeDisableTakeout;
|
|
24
|
+
value: boolean;
|
|
21
25
|
}
|
|
22
26
|
export interface DisableKioskRealTimeSwitchRequest extends BaseRealTimeSwitchRequest {
|
|
23
27
|
type: RealTimeSwitchType.DisableKiosk;
|
|
28
|
+
value: boolean;
|
|
24
29
|
}
|
|
25
|
-
export interface
|
|
26
|
-
type: RealTimeSwitchType.
|
|
30
|
+
export interface OnlineOrderUntilOpenSwitchRequest extends BaseRealTimeSwitchRequest {
|
|
31
|
+
type: RealTimeSwitchType.OnlineOrderUntilOpen;
|
|
32
|
+
value: number;
|
|
27
33
|
}
|
|
@@ -21,6 +21,7 @@ export interface GetStoresRequest extends Filterable, CursorPaginationEnabled, W
|
|
|
21
21
|
}
|
|
22
22
|
export interface GetStoreByIdRequest {
|
|
23
23
|
storeId: string;
|
|
24
|
+
skipGetRelatedProperty?: boolean;
|
|
24
25
|
blockVersion?: BlockVersion;
|
|
25
26
|
}
|
|
26
27
|
export interface UpdateStoreRequest {
|
package/models/order.d.ts
CHANGED
|
@@ -7,7 +7,7 @@ import { InvoiceConfig, Tax } from './invoice-config';
|
|
|
7
7
|
import { InvoiceCarrierType } from './../enums/invoice-carrier-type';
|
|
8
8
|
import { OrderStatus } from '../enums/order-status';
|
|
9
9
|
import { DiscountModuleTypeEnum, OrderSourceType, CloseType, OrderItemPaidStatus, OrderItemStatus } from '../enums';
|
|
10
|
-
import { Receipt } from './receipt';
|
|
10
|
+
import { Receipt, Transaction } from './receipt';
|
|
11
11
|
import { Customer } from './customer';
|
|
12
12
|
import { Operator } from './store';
|
|
13
13
|
import { OnlinePlatformType, OOReasonCode, OnlineOrderMappingWarningCode } from './online-integration';
|
|
@@ -113,6 +113,12 @@ export interface Order {
|
|
|
113
113
|
canceledByParty?: SOOperateParty;
|
|
114
114
|
/** 消費者是否選擇線上付款 */
|
|
115
115
|
isOnSitePayment?: boolean;
|
|
116
|
+
/**
|
|
117
|
+
* 線上點餐、UberEats等等外送平台,線上成功收款後的
|
|
118
|
+
* Transaction會暫時存在這個Property,待POS接單後,
|
|
119
|
+
* 再將這個Transaction包成Receipt
|
|
120
|
+
*/
|
|
121
|
+
externalPayment?: Transaction;
|
|
116
122
|
}
|
|
117
123
|
export interface OrderItem {
|
|
118
124
|
id?: string;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@trusted-solutions/sdit.models",
|
|
3
|
-
"version": "0.18.0-alpha.
|
|
3
|
+
"version": "0.18.0-alpha.17",
|
|
4
4
|
"description": "TODO: Give a short introduction of your project. Let this section explain the objectives or the motivation behind this project.",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"scripts": {
|