@trusted-solutions/sdit.models 0.28.0-alpha.8 → 0.29.0-alpha.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/constants/client-endpoints.js +2 -2
- package/constants/client-endpoints.js.map +1 -1
- package/lambda/online-ordering.d.ts +12 -2
- package/models/customer.d.ts +1 -0
- package/models/online-ordering.d.ts +17 -1
- package/models/online-ordering.js +6 -0
- package/models/online-ordering.js.map +1 -1
- package/models/store.d.ts +12 -2
- package/package.json +1 -1
|
@@ -4,8 +4,8 @@ exports.clientEndpoints = void 0;
|
|
|
4
4
|
exports.clientEndpoints = {
|
|
5
5
|
KshopOnline: {
|
|
6
6
|
dev: 'http://localhost:4200',
|
|
7
|
-
qa: 'https://
|
|
8
|
-
prod: 'https://
|
|
7
|
+
qa: 'https://customer-qa.posky.net',
|
|
8
|
+
prod: 'https://customer.posky.net',
|
|
9
9
|
}
|
|
10
10
|
};
|
|
11
11
|
//# sourceMappingURL=client-endpoints.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"client-endpoints.js","sourceRoot":"","sources":["../../../projects/sdit-model-lib/src/constants/client-endpoints.ts"],"names":[],"mappings":";;;AAAa,QAAA,eAAe,GAAG;IAC7B,WAAW,EAAE;QACX,GAAG,EAAE,uBAAuB;QAC5B,EAAE,EAAE
|
|
1
|
+
{"version":3,"file":"client-endpoints.js","sourceRoot":"","sources":["../../../projects/sdit-model-lib/src/constants/client-endpoints.ts"],"names":[],"mappings":";;;AAAa,QAAA,eAAe,GAAG;IAC7B,WAAW,EAAE;QACX,GAAG,EAAE,uBAAuB;QAC5B,EAAE,EAAE,+BAA+B;QACnC,IAAI,EAAE,4BAA4B;KACnC;CACF,CAAC"}
|
|
@@ -30,6 +30,10 @@ export interface SOGetStoreInfoResponse {
|
|
|
30
30
|
* 店址
|
|
31
31
|
*/
|
|
32
32
|
address?: Address;
|
|
33
|
+
/**
|
|
34
|
+
* 根據店址 `address` 取得經緯度
|
|
35
|
+
*/
|
|
36
|
+
addressLonLat?: number[];
|
|
33
37
|
/**
|
|
34
38
|
* 因應政府「網路銷售營業人新制」上路,營業人資訊揭露
|
|
35
39
|
*/
|
|
@@ -68,8 +72,8 @@ export interface SOGetStoreInfoResponse {
|
|
|
68
72
|
orderItemNoteHidden: boolean;
|
|
69
73
|
/**
|
|
70
74
|
* 關閉統編/載具輸入
|
|
71
|
-
* 若沒啟用統一發票強制 false
|
|
72
|
-
* @Default
|
|
75
|
+
* 若沒啟用統一發票強制 false (KPOS)
|
|
76
|
+
* @Default true
|
|
73
77
|
*/
|
|
74
78
|
buyerIdInputHidden: boolean;
|
|
75
79
|
/**
|
|
@@ -116,6 +120,11 @@ export interface SOGetStoreInfoResponse {
|
|
|
116
120
|
* 免外送費門檻 @Default 0
|
|
117
121
|
*/
|
|
118
122
|
storeDeliveryFreeThresholdAmount: number;
|
|
123
|
+
/**
|
|
124
|
+
* 外送距離限制 @Default 0
|
|
125
|
+
* 0=沒有限制
|
|
126
|
+
*/
|
|
127
|
+
storeDeliveryDistanceLimit: number;
|
|
119
128
|
/**
|
|
120
129
|
* 內用桌ID
|
|
121
130
|
*/
|
|
@@ -152,6 +161,7 @@ export interface SOGetStoreMenuResponse {
|
|
|
152
161
|
export interface SOValidateMutationRequest {
|
|
153
162
|
storeId: string;
|
|
154
163
|
traceId: string;
|
|
164
|
+
serveType: ServeType;
|
|
155
165
|
/**
|
|
156
166
|
* 預計取餐時間 timestamp ms
|
|
157
167
|
* 不給值 = 盡快
|
package/models/customer.d.ts
CHANGED
|
@@ -20,7 +20,13 @@ export declare enum SOOrderErrorType {
|
|
|
20
20
|
/** 不開放點餐 */
|
|
21
21
|
storeNotOpening = "storeNotOpening",
|
|
22
22
|
/** 未啟用線上點餐功能 */
|
|
23
|
-
storeNotEnabled = "storeNotEnabled"
|
|
23
|
+
storeNotEnabled = "storeNotEnabled",
|
|
24
|
+
/** 未啟用外送 */
|
|
25
|
+
deliveryNotEnabled = "deliveryNotEnabled",
|
|
26
|
+
/** 未啟用預訂 */
|
|
27
|
+
reserveNotEnabled = "reserveNotEnabled",
|
|
28
|
+
/** 預訂時間不允許 */
|
|
29
|
+
reserveNotAllowed = "reserveNotAllowed"
|
|
24
30
|
}
|
|
25
31
|
export interface SOPaymentMethod {
|
|
26
32
|
paymentServiceProvider: PaymentServiceProvider;
|
|
@@ -80,6 +86,10 @@ export interface SOOrder {
|
|
|
80
86
|
displayId: string;
|
|
81
87
|
state: SOOrderState;
|
|
82
88
|
serveType: ServeType;
|
|
89
|
+
/** 訂購人 CognitoUserId */
|
|
90
|
+
customerCognitoId?: string;
|
|
91
|
+
/** 訂購人在店家的顧客Id */
|
|
92
|
+
customerId?: string;
|
|
83
93
|
/** 訂購人 */
|
|
84
94
|
eater: SOEater;
|
|
85
95
|
/** 品項們 */
|
|
@@ -136,6 +146,10 @@ export interface SOUnavailableCartItem {
|
|
|
136
146
|
* 線上品項或Attr Id
|
|
137
147
|
*/
|
|
138
148
|
menuItemId: string;
|
|
149
|
+
/**
|
|
150
|
+
* 品項名稱
|
|
151
|
+
*/
|
|
152
|
+
menuItemName: string;
|
|
139
153
|
}
|
|
140
154
|
export declare enum SOUnavailableCartItemReasonCode {
|
|
141
155
|
soldOut = "soldOut",
|
|
@@ -152,6 +166,8 @@ export interface SOValidateCartItem {
|
|
|
152
166
|
menuId: string;
|
|
153
167
|
productCategoryId: string;
|
|
154
168
|
productId: string;
|
|
169
|
+
/** 商品名稱 */
|
|
170
|
+
productName: string;
|
|
155
171
|
/** 原單價 */
|
|
156
172
|
productAmount: number;
|
|
157
173
|
/** 數量 */
|
|
@@ -15,6 +15,12 @@ var SOOrderErrorType;
|
|
|
15
15
|
SOOrderErrorType["storeNotOpening"] = "storeNotOpening";
|
|
16
16
|
/** 未啟用線上點餐功能 */
|
|
17
17
|
SOOrderErrorType["storeNotEnabled"] = "storeNotEnabled";
|
|
18
|
+
/** 未啟用外送 */
|
|
19
|
+
SOOrderErrorType["deliveryNotEnabled"] = "deliveryNotEnabled";
|
|
20
|
+
/** 未啟用預訂 */
|
|
21
|
+
SOOrderErrorType["reserveNotEnabled"] = "reserveNotEnabled";
|
|
22
|
+
/** 預訂時間不允許 */
|
|
23
|
+
SOOrderErrorType["reserveNotAllowed"] = "reserveNotAllowed";
|
|
18
24
|
})(SOOrderErrorType = exports.SOOrderErrorType || (exports.SOOrderErrorType = {}));
|
|
19
25
|
var SOOperateParty;
|
|
20
26
|
(function (SOOperateParty) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"online-ordering.js","sourceRoot":"","sources":["../../../projects/sdit-model-lib/src/models/online-ordering.ts"],"names":[],"mappings":";;;AAeA,IAAY,
|
|
1
|
+
{"version":3,"file":"online-ordering.js","sourceRoot":"","sources":["../../../projects/sdit-model-lib/src/models/online-ordering.ts"],"names":[],"mappings":";;;AAeA,IAAY,gBAmBX;AAnBD,WAAY,gBAAgB;IAC1B,YAAY;IACZ,qDAAiC,CAAA;IACjC,eAAe;IACf,iEAA6C,CAAA;IAC7C,WAAW;IACX,+CAA2B,CAAA;IAC3B,aAAa;IACb,mDAA+B,CAAA;IAC/B,YAAY;IACZ,uDAAmC,CAAA;IACnC,gBAAgB;IAChB,uDAAmC,CAAA;IACnC,YAAY;IACZ,6DAAyC,CAAA;IACzC,YAAY;IACZ,2DAAuC,CAAA;IACvC,cAAc;IACd,2DAAuC,CAAA;AACzC,CAAC,EAnBW,gBAAgB,GAAhB,wBAAgB,KAAhB,wBAAgB,QAmB3B;AAmDD,IAAY,cAIX;AAJD,WAAY,cAAc;IACxB,iCAAe,CAAA;IACf,iCAAe,CAAA;IACf,mCAAiB,CAAA;AACnB,CAAC,EAJW,cAAc,GAAd,sBAAc,KAAd,sBAAc,QAIzB;AAkGD,IAAY,+BAGX;AAHD,WAAY,+BAA+B;IACzC,sDAAmB,CAAA;IACnB,kEAA+B,CAAA;AACjC,CAAC,EAHW,+BAA+B,GAA/B,uCAA+B,KAA/B,uCAA+B,QAG1C;AAgCD,IAAY,YAMX;AAND,WAAY,YAAY;IACtB,mCAAmB,CAAA;IACnB,qCAAqB,CAAA;IACrB,iCAAiB,CAAA;IACjB,qCAAqB,CAAA;IACrB,qCAAqB,CAAA;AACvB,CAAC,EANW,YAAY,GAAZ,oBAAY,KAAZ,oBAAY,QAMvB"}
|
package/models/store.d.ts
CHANGED
|
@@ -106,6 +106,10 @@ export interface Store {
|
|
|
106
106
|
* 店址
|
|
107
107
|
*/
|
|
108
108
|
onlineAddress?: Address;
|
|
109
|
+
/**
|
|
110
|
+
* 店址經緯度,用於外送距離計算
|
|
111
|
+
*/
|
|
112
|
+
onlineAddressLonLat?: number[];
|
|
109
113
|
/**
|
|
110
114
|
* 線上店營業時間
|
|
111
115
|
*/
|
|
@@ -138,7 +142,7 @@ export interface Store {
|
|
|
138
142
|
*/
|
|
139
143
|
onlineOrderItemNoteHidden?: boolean;
|
|
140
144
|
/**
|
|
141
|
-
*
|
|
145
|
+
* 關閉統編輸入,無值時應視為 true
|
|
142
146
|
*/
|
|
143
147
|
onlineBuyerIdInputHidden?: boolean;
|
|
144
148
|
/**
|
|
@@ -152,9 +156,13 @@ export interface Store {
|
|
|
152
156
|
*/
|
|
153
157
|
onlineEnabled?: boolean;
|
|
154
158
|
/**
|
|
155
|
-
*
|
|
159
|
+
* 外帶外送線上點餐支付方式
|
|
156
160
|
*/
|
|
157
161
|
onlinePaymentConfigs?: PaymentConfig[];
|
|
162
|
+
/**
|
|
163
|
+
* 內用線上點餐支付方式
|
|
164
|
+
*/
|
|
165
|
+
onlineDineInPaymentConfigs?: PaymentConfig[];
|
|
158
166
|
/**
|
|
159
167
|
* 線上點餐預計等待時間(分)
|
|
160
168
|
*/
|
|
@@ -169,6 +177,8 @@ export interface Store {
|
|
|
169
177
|
onlineStoreDeliveryCharge?: number;
|
|
170
178
|
/** 線上點餐免外送費訂單金額門檻 */
|
|
171
179
|
onlineStoreDeliveryFreeThresholdAmount?: number;
|
|
180
|
+
/** 最大外送距離(km) */
|
|
181
|
+
onlineStoreDeliveryDistanceLimit?: number;
|
|
172
182
|
}
|
|
173
183
|
export interface SimpleStore {
|
|
174
184
|
id: string;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@trusted-solutions/sdit.models",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.29.0-alpha.0",
|
|
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": {
|