@trusted-solutions/sdit.models 0.60.0-alpha.1 → 0.60.0-alpha.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.
@@ -1,4 +1,4 @@
1
- import { Override, OverrideEntityType, OverrideProduct, OverrideProductAttribute, Product, ProductAttribute, ProductAttributeCategory, ProductCategory } from '../models';
1
+ import { BaseOverride, Override, OverrideEntityType, OverrideProductAttribute, Product, ProductAttribute, ProductAttributeCategory, ProductCategory } from '../models';
2
2
  import { MultipleItems, SingleItem } from './response';
3
3
  export interface PutMenuOverrideRequest {
4
4
  menuId: string;
@@ -7,12 +7,13 @@ export interface PutMenuOverrideRequest {
7
7
  entityContent: Partial<Product> | Partial<ProductAttribute> | Partial<ProductAttributeCategory> | Partial<ProductCategory>;
8
8
  }
9
9
  export declare type PutMenuOverrideResponse = SingleItem<Override>;
10
- export interface ListMenuProductOverridesRequest {
10
+ export interface ListMenuOverridesRequest {
11
11
  menuId: string;
12
+ entityType: OverrideEntityType;
12
13
  }
13
- export interface ListMenuProductOverridesResponse extends MultipleItems<OverrideProduct> {
14
+ export interface ListMenuOverridesResponse<T extends BaseOverride> extends MultipleItems<T> {
14
15
  }
15
- export declare type ListMenuProductAttributeOverridesRequest = ListMenuProductOverridesRequest;
16
+ export declare type ListMenuProductAttributeOverridesRequest = ListMenuOverridesRequest;
16
17
  export interface ListMenuProductAttributeOverridesResponse extends MultipleItems<OverrideProductAttribute> {
17
18
  }
18
19
  /** 刪除和menu有關的所有override,包含OverrideProduct, OverrideProductAttribute */
@@ -43,8 +43,14 @@ export interface SOCartItem {
43
43
  quantity: number;
44
44
  name: string;
45
45
  selectedAttributes: SOCartAttributes[];
46
+ /** 套餐的附餐 */
47
+ children?: SOCartItem[];
48
+ /** 附餐本身來自哪一個附餐選項大類 */
49
+ refAttributeCategoryId?: string;
50
+ /** 附餐本身來自哪一個附餐選項 */
51
+ refAttributeId?: string;
46
52
  notes?: string;
47
- /** (attrs + product amount) * quantity */
53
+ /** (children + attrs + product amount) * quantity */
48
54
  subtotal: number;
49
55
  /** sigma(discount.discountReferences.orderItemId === id)) */
50
56
  discountAmount: number;
@@ -1 +1 @@
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;AAkHD,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;AAuCD,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"}
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;AAyDD,IAAY,cAIX;AAJD,WAAY,cAAc;IACxB,iCAAe,CAAA;IACf,iCAAe,CAAA;IACf,mCAAiB,CAAA;AACnB,CAAC,EAJW,cAAc,GAAd,sBAAc,KAAd,sBAAc,QAIzB;AAkHD,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;AAuCD,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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@trusted-solutions/sdit.models",
3
- "version": "0.60.0-alpha.1",
3
+ "version": "0.60.0-alpha.3",
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": {