@aptos-scp/scp-component-store-selling-features-domain-model 1.50.0 → 1.52.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,17 +1,13 @@
1
+ import { ExtensibilityFormFieldDataType } from "@aptos-scp/scp-types-commerce-transaction";
1
2
  export interface IExtensibilityForm {
2
3
  formName: string;
3
4
  namespace: string;
4
5
  fields?: IExtensibilityFormFields;
5
6
  }
6
7
  export interface IExtensibilityFormFields {
7
- [k: string]: any;
8
+ [k: string]: string | IExtensibilityFormFieldObject;
8
9
  }
9
- export declare enum ExtensibilityFormTypeOfDataEnum {
10
- StringData = "StringData",
11
- IntegerData = "IntegerData",
12
- BooleanData = "BooleanData",
13
- DateData = "DateData",
14
- TimeData = "TimeData",
15
- DateTimeData = "DateTimeData",
16
- Unknown = "Unknown"
10
+ export interface IExtensibilityFormFieldObject {
11
+ value: string;
12
+ dataType: ExtensibilityFormFieldDataType;
17
13
  }
@@ -1,13 +1,3 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- var ExtensibilityFormTypeOfDataEnum;
4
- (function (ExtensibilityFormTypeOfDataEnum) {
5
- ExtensibilityFormTypeOfDataEnum["StringData"] = "StringData";
6
- ExtensibilityFormTypeOfDataEnum["IntegerData"] = "IntegerData";
7
- ExtensibilityFormTypeOfDataEnum["BooleanData"] = "BooleanData";
8
- ExtensibilityFormTypeOfDataEnum["DateData"] = "DateData";
9
- ExtensibilityFormTypeOfDataEnum["TimeData"] = "TimeData";
10
- ExtensibilityFormTypeOfDataEnum["DateTimeData"] = "DateTimeData";
11
- ExtensibilityFormTypeOfDataEnum["Unknown"] = "Unknown";
12
- })(ExtensibilityFormTypeOfDataEnum = exports.ExtensibilityFormTypeOfDataEnum || (exports.ExtensibilityFormTypeOfDataEnum = {}));
13
3
  //# sourceMappingURL=IExtensibilityForm.js.map
@@ -3,7 +3,6 @@ function __export(m) {
3
3
  for (var p in m) if (!exports.hasOwnProperty(p)) exports[p] = m[p];
4
4
  }
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
- __export(require("./IExtensibilityForm"));
7
6
  __export(require("./ExtensibilityFormDataLine"));
8
7
  __export(require("./VoidedExtensibilityFormDataLineDecorator"));
9
8
  __export(require("./BaseExtensibilityFormDataLineDecorator"));
@@ -2,7 +2,7 @@ import { Money, Price, Quantity } from "@aptos-scp/scp-component-business-core";
2
2
  import { IUser } from "@aptos-scp/scp-component-store-selling-core";
3
3
  import { IAppliedTax } from "@aptos-scp/scp-component-taxation";
4
4
  import { IAuthorizationResponse } from "@aptos-scp/scp-types-commerce-devices";
5
- import { ActionType, IPriceChange, ISubline as IPostableSubline, ITaxByTaxRule, ITaxExempt, ITaxOverride, ITaxOverrideDetails, ItemType, ITransactionLineReferenceType, SourceIndicator, UnitPriceSourceIndicator } from "@aptos-scp/scp-types-commerce-transaction";
5
+ import { ActionType, IPriceChange, ISubline as IPostableSubline, ITaxByTaxRule, ITaxExempt, ITaxOverride, ITaxOverrideDetails, ItemType, ITransactionLineReferenceType, SourceIndicator, UnitPriceSourceIndicator, StyleTypeEnum } from "@aptos-scp/scp-types-commerce-transaction";
6
6
  import { ISublinePricingAdjustmentWithSource } from "./ISerializedPriceCalculationResultsWithSource";
7
7
  import { BaseLineDecorator } from "../../model/BaseLineDecorator";
8
8
  import { IItemPriceSource, ItemLookupKey, SelectedUnitPrice, StoreItem } from "../../model/StoreItem";
@@ -25,6 +25,7 @@ export declare abstract class BaseItemLineDecorator extends BaseLineDecorator<II
25
25
  static getLineSavingsFromJsonObject(transactionLineJsonObject: any): Money;
26
26
  static getSublinesFromJsonObject(transactionLineJsonObject: any): IItemSubline[];
27
27
  get preferredDisplayKeyType(): string;
28
+ get displayedStyleType(): StyleTypeEnum;
28
29
  get enteredLookupKey(): ItemLookupKey;
29
30
  get item(): StoreItem;
30
31
  get itemType(): ItemType;
@@ -27,6 +27,9 @@ class BaseItemLineDecorator extends BaseLineDecorator_1.BaseLineDecorator {
27
27
  get preferredDisplayKeyType() {
28
28
  return this.decoratedTransactionLine.preferredDisplayKeyType;
29
29
  }
30
+ get displayedStyleType() {
31
+ return this.decoratedTransactionLine.displayedStyleType;
32
+ }
30
33
  get enteredLookupKey() {
31
34
  return this.decoratedTransactionLine.enteredLookupKey;
32
35
  }
@@ -2,7 +2,7 @@ import { Money, Price, Quantity } from "@aptos-scp/scp-component-business-core";
2
2
  import { ITransactionLine, IUser } from "@aptos-scp/scp-component-store-selling-core";
3
3
  import { IAppliedTax } from "@aptos-scp/scp-component-taxation";
4
4
  import { IAuthorizationResponse } from "@aptos-scp/scp-types-commerce-devices";
5
- import { ActionType, IPriceChange, ISubline as IPostableSubline, ITaxByTaxAuthority, ITaxByTaxRule, ITaxExempt, ITaxOverride, ITaxOverrideDetails, ItemType, ITransactionLineReferenceType, IUser as IPostedUser, LoyaltyRedemptionType, SourceIndicator, UnitPriceSourceIndicator, ICompetitivePriceInformation, IProratedItemLineReference, IReason } from "@aptos-scp/scp-types-commerce-transaction";
5
+ import { ActionType, IPriceChange, ISubline as IPostableSubline, ITaxByTaxAuthority, ITaxByTaxRule, ITaxExempt, ITaxOverride, ITaxOverrideDetails, ItemType, ITransactionLineReferenceType, IUser as IPostedUser, LoyaltyRedemptionType, SourceIndicator, UnitPriceSourceIndicator, ICompetitivePriceInformation, IProratedItemLineReference, IReason, StyleTypeEnum } from "@aptos-scp/scp-types-commerce-transaction";
6
6
  import { ISerializedSublinePricingAdjustmentWithSource, ISublinePricingAdjustmentWithSource } from "./ISerializedPriceCalculationResultsWithSource";
7
7
  import { SecurityAuthorizationStatusType } from "../Constants";
8
8
  import { Customer } from "../Customer";
@@ -18,6 +18,7 @@ export declare function isTransactionLineTaxesMaintainer(transactionLine: ITrans
18
18
  export interface IItemLine extends ITransactionLine, IVoidableLine, IPriceProvider {
19
19
  readonly enteredLookupKey: ItemLookupKey;
20
20
  readonly preferredDisplayKeyType?: string;
21
+ readonly displayedStyleType?: StyleTypeEnum;
21
22
  readonly item: StoreItem;
22
23
  readonly itemType: ItemType;
23
24
  readonly originalTaxGroupId: string;
@@ -3,7 +3,7 @@ import { ICopyableLine } from "@aptos-scp/scp-component-store-selling-core/lib/d
3
3
  import { IExtendedAmountMaintainer, ITransactionLine, IUser, UiBusinessEvent } from "@aptos-scp/scp-component-store-selling-core";
4
4
  import { IAppliedTax } from "@aptos-scp/scp-component-taxation";
5
5
  import { IAuthorizationResponse } from "@aptos-scp/scp-types-commerce-devices";
6
- import { ActionType, ISameTransactionLineReference, ISubline as IPostableSubline, ITaxByTaxRule, ITaxExempt, ITaxOverride, ITaxOverrideDetails, ItemType, ITransactionLineReferenceType, SourceIndicator, UnitPriceSourceIndicator, IPriceChange, IReason } from "@aptos-scp/scp-types-commerce-transaction";
6
+ import { ActionType, ISameTransactionLineReference, ISubline as IPostableSubline, ITaxByTaxRule, ITaxExempt, ITaxOverride, ITaxOverrideDetails, ItemType, ITransactionLineReferenceType, SourceIndicator, UnitPriceSourceIndicator, IPriceChange, IReason, StyleTypeEnum } from "@aptos-scp/scp-types-commerce-transaction";
7
7
  import { ISublinePricingAdjustmentWithSource } from "./ISerializedPriceCalculationResultsWithSource";
8
8
  import { ItemTaxExemptLine, TransactionTaxExemptLine } from "../../model/taxExempt";
9
9
  import { BaseTransactionLine } from "../BaseTransactionLine";
@@ -48,6 +48,7 @@ export declare class ItemLine extends BaseTransactionLine implements IItemLine,
48
48
  private _taxExempt;
49
49
  private _preTaxExemptDetails?;
50
50
  private _preferredDisplayKeyType;
51
+ private _displayedStyleType;
51
52
  private _pointsEligible;
52
53
  private _unitPriceSourceIndicator;
53
54
  private _inputSource;
@@ -129,6 +130,7 @@ export declare class ItemLine extends BaseTransactionLine implements IItemLine,
129
130
  get enteredLookupKey(): ItemLookupKey;
130
131
  get itemLookupKeys(): ItemLookupKey[];
131
132
  get preferredDisplayKeyType(): string;
133
+ get displayedStyleType(): StyleTypeEnum;
132
134
  get item(): StoreItem;
133
135
  get itemType(): ItemType;
134
136
  get originalTaxGroupId(): string;
@@ -48,6 +48,7 @@ class ItemLine extends BaseTransactionLine_1.BaseTransactionLine {
48
48
  const storeItem = collectedData.get("storeItem");
49
49
  const actionType = collectedData.get(Constants_1.CollectedDataKey.ActionType);
50
50
  const preferredDisplayKeyType = collectedData.get("preferredDisplayKeyType");
51
+ const displayedStyleType = collectedData.get("displayedStyleType");
51
52
  const fulfillmentGroupId = collectedData.get(Constants_1.CollectedDataKey.FulfillmentGroupId);
52
53
  const orderLineReference = collectedData.get(Constants_1.CollectedDataKey.OrderLineReference);
53
54
  const lineNumberFromOrder = collectedData.get(Constants_1.CollectedDataKey.LineNumberFromOrder);
@@ -67,6 +68,9 @@ class ItemLine extends BaseTransactionLine_1.BaseTransactionLine {
67
68
  if (preferredDisplayKeyType) {
68
69
  itemLine._preferredDisplayKeyType = preferredDisplayKeyType;
69
70
  }
71
+ if (displayedStyleType) {
72
+ itemLine._displayedStyleType = displayedStyleType;
73
+ }
70
74
  if (orderLineReference) {
71
75
  itemLine._orderLineReference = orderLineReference;
72
76
  }
@@ -331,6 +335,9 @@ class ItemLine extends BaseTransactionLine_1.BaseTransactionLine {
331
335
  get preferredDisplayKeyType() {
332
336
  return this._preferredDisplayKeyType;
333
337
  }
338
+ get displayedStyleType() {
339
+ return this._displayedStyleType;
340
+ }
334
341
  get item() {
335
342
  return this._item;
336
343
  }
@@ -869,6 +876,7 @@ class ItemLine extends BaseTransactionLine_1.BaseTransactionLine {
869
876
  newItemLine._taxOverride = this._taxOverride;
870
877
  newItemLine._preTaxOverrideDetails = this._preTaxOverrideDetails;
871
878
  newItemLine._preferredDisplayKeyType = this._preferredDisplayKeyType;
879
+ newItemLine._displayedStyleType = this._displayedStyleType;
872
880
  newItemLine._pointsEligible = this._pointsEligible;
873
881
  newItemLine._unitPriceSourceIndicator = this._unitPriceSourceIndicator;
874
882
  newItemLine._inputSource = this._inputSource;
@@ -981,6 +989,7 @@ class ItemLine extends BaseTransactionLine_1.BaseTransactionLine {
981
989
  ? new scp_component_business_core_1.Money(transactionLineJsonObj._unitCost)
982
990
  : undefined;
983
991
  this._preferredDisplayKeyType = transactionLineJsonObj._preferredDisplayKeyType;
992
+ this._displayedStyleType = transactionLineJsonObj._displayedStyleType;
984
993
  this._pointsEligible = transactionLineJsonObj._pointsEligible;
985
994
  this._unitPriceSourceIndicator = transactionLineJsonObj._unitPriceSourceIndicator;
986
995
  this._inputSource = transactionLineJsonObj._inputSource;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@aptos-scp/scp-component-store-selling-features-domain-model",
3
- "version": "1.50.0",
3
+ "version": "1.52.0",
4
4
  "description": "This component library provides the common components to handle the coordination of processing the business events from the UI.",
5
5
  "private": false,
6
6
  "license": "SEE LICENSE IN LICENSE.md",
@@ -62,7 +62,7 @@
62
62
  "@aptos-scp/scp-types-client-registration": "^1.4.0",
63
63
  "@aptos-scp/scp-types-core-config": "^2.2.1",
64
64
  "@aptos-scp/scp-types-commerce-devices": "^3.14.0",
65
- "@aptos-scp/scp-types-commerce-transaction": "^1.72.0",
65
+ "@aptos-scp/scp-types-commerce-transaction": "^1.74.0",
66
66
  "@aptos-scp/scp-types-customer": "^3.7.0",
67
67
  "@aptos-scp/scp-types-einvoice": "^1.17.0",
68
68
  "@aptos-scp/scp-types-inventory": "^2.0.0",
@@ -84,7 +84,7 @@
84
84
  "@aptos-scp/scp-component-user": "^1.4.0",
85
85
  "@aptos-scp/scp-types-client-registration": "^1.4.0",
86
86
  "@aptos-scp/scp-types-commerce-devices": "^3.14.0",
87
- "@aptos-scp/scp-types-commerce-transaction": "^1.72.0",
87
+ "@aptos-scp/scp-types-commerce-transaction": "^1.74.0",
88
88
  "@aptos-scp/scp-types-core": "^1.0.5",
89
89
  "@aptos-scp/scp-types-core-config": "^2.2.1",
90
90
  "@aptos-scp/scp-types-currency-conversion": "^1.2.0",