@trusted-solutions/sdit.models 0.47.0 → 0.48.1-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.
@@ -1,4 +1,4 @@
1
- import { Address, DayOfWeekTimePeriod, GalleryConfig, Operator } from '../models/store';
1
+ import { Address, DayOfWeekTimePeriod, GalleryConfig, Operator, PointProvider } from '../models/store';
2
2
  import { CustomerPointDetail, MultiLanguageText, OrderDiscount } from '../models';
3
3
  import { PaymentServiceProvider, ServeType } from '../enums';
4
4
  import { SOPublicMenu, SOPublicCategory, SOPublicProduct, SOPublicProductAttribute, SOPublicProductAttributeCategory, SOPaymentMethod, SOValidateCart, SOOrderState, SOOrder, SOEater } from '../models/online-ordering';
@@ -159,16 +159,20 @@ export interface SOGetStoreInfoResponse {
159
159
  availableGuest?: boolean;
160
160
  /**
161
161
  * Cognito user pool web client id
162
- * @Default undefined
162
+ * @Default brand的設定
163
163
  */
164
164
  userPoolWebClientId?: string;
165
165
  /**
166
166
  * 是否啟用集點
167
- * @Default undefined
167
+ * @Default brand的設定
168
168
  * undefined/true: 開啟
169
169
  * false: 不開啟
170
170
  */
171
171
  storePointsEnabled?: boolean;
172
+ /**
173
+ * 點數供應商
174
+ */
175
+ storePointsProvider?: PointProvider;
172
176
  /**
173
177
  * 點數名稱
174
178
  */
@@ -177,6 +181,7 @@ export interface SOGetStoreInfoResponse {
177
181
  * 品牌
178
182
  */
179
183
  brandNo?: string;
184
+ brand?: any;
180
185
  }
181
186
  /*******************************/
182
187
  /*******************************/
@@ -1,4 +1,5 @@
1
1
  import { ExternalEnum, CustomerGenderEnum } from "../enums";
2
+ import { PointProvider } from "./store";
2
3
  export interface CustomerConfig {
3
4
  disabled: boolean;
4
5
  applyingOnKiosk: boolean;
@@ -35,8 +36,10 @@ export interface ProductOrderRate {
35
36
  rate: number;
36
37
  }
37
38
  export interface CustomerPointDetail {
39
+ provider: PointProvider;
40
+ /** @deprecated 改用 provider */
38
41
  pointsName: string;
39
42
  redeemPoints: number;
40
43
  redeemAmount: number;
41
- redeemDatetime: string;
44
+ redeemDatetime?: string;
42
45
  }
@@ -8,6 +8,8 @@ export interface Receipt {
8
8
  id: string;
9
9
  /** Copy `invoiceConfig` from `Store` */
10
10
  invoiceConfig: InvoiceConfig;
11
+ /** Copy `displayId` from `Store` */
12
+ storeDisplayId?: string;
11
13
  /**
12
14
  * 有值代表「線上訂單 & 線上付款」。
13
15
  * 若是「線上訂單 & 線上付款」,會走線上取消訂單並退款流程。
@@ -40,6 +42,8 @@ export interface Receipt {
40
42
  /** 混合支付細項 */
41
43
  mixPayments?: Transaction[];
42
44
  mixRefunds?: Transaction[];
45
+ /** 結帳備註,會印在收據上且上傳發票雲 */
46
+ note?: string;
43
47
  }
44
48
  export interface Transaction {
45
49
  accountId: string;
package/models/store.d.ts CHANGED
@@ -23,6 +23,8 @@ export interface Operator {
23
23
  }
24
24
  export interface Store {
25
25
  id?: string;
26
+ /** 讓店家自行定義的店號,會印在發票及收據上 */
27
+ displayId?: string;
26
28
  name: string;
27
29
  createdAt?: number;
28
30
  company: CompanyEnum;
@@ -194,15 +196,33 @@ export interface Store {
194
196
  onlineAvailableFederatedProvider?: string;
195
197
  /** 是否開放訪客點餐 */
196
198
  onlineAvailableGuest?: boolean;
197
- /** Cognito client Id */
199
+ /**
200
+ * 線上點餐登入UserPoolWebClientId
201
+ * 單店設定,用來覆蓋 Brand 的 UserPoolWebClientId
202
+ */
198
203
  onlineUserPoolWebClientId?: string;
199
- /** 是否啟用集點 */
204
+ /**
205
+ * 是否啟用集點
206
+ * 單店設定,用來覆蓋 Brand 的 StorePointsEnabled
207
+ */
200
208
  onlineStorePointsEnabled?: boolean;
201
- /** 點數名稱 */
209
+ /**
210
+ * 點數廠商
211
+ * 單店設定,用來覆蓋 Brand 的 StorePointsProvider
212
+ */
213
+ onlineStorePointsProvider?: PointProvider;
214
+ /**
215
+ * 點數名稱
216
+ * 單店設定,用來覆蓋 Brand 的 StorePointsName
217
+ */
202
218
  onlineStorePointsName?: string;
203
219
  /** 品牌 */
204
220
  brandNo?: string;
205
221
  }
222
+ export declare enum PointProvider {
223
+ Posky = "Posky",
224
+ MitwellSubsidy = "MitwellSubsidy"
225
+ }
206
226
  export interface SimpleStore {
207
227
  id: string;
208
228
  name: string;
package/models/store.js CHANGED
@@ -1,4 +1,10 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.PointProvider = void 0;
3
4
  const enums_1 = require("../enums");
5
+ var PointProvider;
6
+ (function (PointProvider) {
7
+ PointProvider["Posky"] = "Posky";
8
+ PointProvider["MitwellSubsidy"] = "MitwellSubsidy";
9
+ })(PointProvider = exports.PointProvider || (exports.PointProvider = {}));
4
10
  //# sourceMappingURL=store.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"store.js","sourceRoot":"","sources":["../../../projects/sdit-model-lib/src/models/store.ts"],"names":[],"mappings":";;AAEA,oCAAmH"}
1
+ {"version":3,"file":"store.js","sourceRoot":"","sources":["../../../projects/sdit-model-lib/src/models/store.ts"],"names":[],"mappings":";;;AAEA,oCAAmH;AAiPnH,IAAY,aAGX;AAHD,WAAY,aAAa;IACvB,gCAAe,CAAA;IACf,kDAAiC,CAAA;AACnC,CAAC,EAHW,aAAa,GAAb,qBAAa,KAAb,qBAAa,QAGxB"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@trusted-solutions/sdit.models",
3
- "version": "0.47.0",
3
+ "version": "0.48.1-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": {