@aptos-scp/scp-component-store-selling-features-domain-model 1.52.1 → 1.53.1

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.
@@ -137,6 +137,7 @@ export declare const SELL_ITEM_EVENT: string;
137
137
  export declare const SHIPPING_FEE_EVENT = "ShippingFee";
138
138
  export declare const SHIPPING_FEE_CHANGE_EVENT = "ShippingFeeChange";
139
139
  export declare const ADD_SHIPPING_FEE_EVENT = "AddShippingFee";
140
+ export declare const APPLY_FEE_DISCOUNT_EVENT = "ApplyFeeDiscount";
140
141
  export declare const SHIPPING_FEE_REFUND_EVENT: string;
141
142
  export declare const RETURN_ITEM_EVENT: string;
142
143
  export declare const ITEM_FEE_REFUND_EVENT: string;
@@ -140,6 +140,7 @@ exports.SELL_ITEM_EVENT = "SellItem";
140
140
  exports.SHIPPING_FEE_EVENT = "ShippingFee";
141
141
  exports.SHIPPING_FEE_CHANGE_EVENT = "ShippingFeeChange";
142
142
  exports.ADD_SHIPPING_FEE_EVENT = "AddShippingFee";
143
+ exports.APPLY_FEE_DISCOUNT_EVENT = "ApplyFeeDiscount";
143
144
  exports.SHIPPING_FEE_REFUND_EVENT = "ShippingFeeRefund";
144
145
  exports.RETURN_ITEM_EVENT = "ReturnItem";
145
146
  exports.ITEM_FEE_REFUND_EVENT = "RefundItemFee";
@@ -194,6 +194,7 @@ export declare enum UiInputKey {
194
194
  REFUND_ITEM_FEE_ITEM_LINE_REFERENCE = "input_refundFeeItemItemLineReference",
195
195
  RETURNING_ITEM_QUANTITY = "input_returningItemQuantity",
196
196
  SHIPPING = "input_shipping",
197
+ HAS_PROMISED_TO_PAY_WITH_PLCC = "input_hasPromisedToPayWithPLCC",
197
198
  HAS_SHIPPING_FEE_OVERRIDE = "input_hasShippingFeeOverride",
198
199
  SHIPPING_METHOD = "input_shippingMethod",
199
200
  SHIPPING_FEE = "input_shippingFee",
@@ -635,6 +636,7 @@ export declare enum CollectedDataKey {
635
636
  OriginalReceipts = "originalReceipts",
636
637
  ShippingFee = "shippingFee",
637
638
  ShippingMethod = "shippingMethod",
639
+ HasPromisedToPayWithPLCC = "hasPromisedToPayWithPLCC",
638
640
  TaxFreeFormKey = "taxFreeFormKey",
639
641
  TaxOverrideAmount = "taxOverrideAmount",
640
642
  TaxOverrideRate = "taxOverrideRate",
@@ -936,9 +938,7 @@ export declare enum CollectedDataKey {
936
938
  MembershipTypeDescription = "membershipTypeDescription",
937
939
  IsPermanentMembershipDiscount = "isPermanentMembershipDiscount",
938
940
  TerminalForceClosed = "TerminalForceClosed",
939
- TotalLineTax = "totalLineTax",
940
- EmployeeFlag = "employeeFlag",
941
- TriggeredByLoyaltyAwards = "triggeredByLoyaltyAwards"
941
+ TotalLineTax = "totalLineTax"
942
942
  }
943
943
  export declare enum ItemLookupType {
944
944
  ProductInquiryDetail = "ProductInquiryDetail",
@@ -197,6 +197,7 @@ var UiInputKey;
197
197
  UiInputKey["REFUND_ITEM_FEE_ITEM_LINE_REFERENCE"] = "input_refundFeeItemItemLineReference";
198
198
  UiInputKey["RETURNING_ITEM_QUANTITY"] = "input_returningItemQuantity";
199
199
  UiInputKey["SHIPPING"] = "input_shipping";
200
+ UiInputKey["HAS_PROMISED_TO_PAY_WITH_PLCC"] = "input_hasPromisedToPayWithPLCC";
200
201
  UiInputKey["HAS_SHIPPING_FEE_OVERRIDE"] = "input_hasShippingFeeOverride";
201
202
  UiInputKey["SHIPPING_METHOD"] = "input_shippingMethod";
202
203
  UiInputKey["SHIPPING_FEE"] = "input_shippingFee";
@@ -644,6 +645,7 @@ var CollectedDataKey;
644
645
  CollectedDataKey["OriginalReceipts"] = "originalReceipts";
645
646
  CollectedDataKey["ShippingFee"] = "shippingFee";
646
647
  CollectedDataKey["ShippingMethod"] = "shippingMethod";
648
+ CollectedDataKey["HasPromisedToPayWithPLCC"] = "hasPromisedToPayWithPLCC";
647
649
  CollectedDataKey["TaxFreeFormKey"] = "taxFreeFormKey";
648
650
  CollectedDataKey["TaxOverrideAmount"] = "taxOverrideAmount";
649
651
  CollectedDataKey["TaxOverrideRate"] = "taxOverrideRate";
@@ -946,8 +948,6 @@ var CollectedDataKey;
946
948
  CollectedDataKey["IsPermanentMembershipDiscount"] = "isPermanentMembershipDiscount";
947
949
  CollectedDataKey["TerminalForceClosed"] = "TerminalForceClosed";
948
950
  CollectedDataKey["TotalLineTax"] = "totalLineTax";
949
- CollectedDataKey["EmployeeFlag"] = "employeeFlag";
950
- CollectedDataKey["TriggeredByLoyaltyAwards"] = "triggeredByLoyaltyAwards";
951
951
  })(CollectedDataKey = exports.CollectedDataKey || (exports.CollectedDataKey = {}));
952
952
  var ItemLookupType;
953
953
  (function (ItemLookupType) {
@@ -117,6 +117,7 @@ export declare class MerchandiseTransaction extends RetailTransaction implements
117
117
  private _taxCustomer;
118
118
  private _transactionTradeType;
119
119
  private _shouldUpdatePricing;
120
+ private _hasPromisedToPayWithPLCC;
120
121
  private _shouldUpdateTaxation;
121
122
  private _referenceNumber;
122
123
  private _giftReceipt;
@@ -308,6 +309,7 @@ export declare class MerchandiseTransaction extends RetailTransaction implements
308
309
  assignEInvoiceReference(eInvoiceReference: string): ITransaction;
309
310
  setFatalVoidableError(): ITransaction;
310
311
  get shouldUpdatePricing(): boolean;
312
+ get hasPromisedToPayWithPLCC(): boolean;
311
313
  get shouldUpdateTaxation(): boolean;
312
314
  get giftReceiptMode(): GiftReceiptMode;
313
315
  get giftReceipt(): boolean;
@@ -67,6 +67,7 @@ class MerchandiseTransaction extends RetailTransaction_1.RetailTransaction {
67
67
  this._transactionTradeType = undefined;
68
68
  this._salesperson = undefined;
69
69
  this._shouldUpdatePricing = false;
70
+ this._hasPromisedToPayWithPLCC = false;
70
71
  this._shouldUpdateTaxation = false;
71
72
  this._transactionReferenceFormatter = transactionReferenceFormatter;
72
73
  this._giftReceiptMode = giftReceiptMode;
@@ -180,6 +181,7 @@ class MerchandiseTransaction extends RetailTransaction_1.RetailTransaction {
180
181
  transaction._taxCustomer = this._taxCustomer;
181
182
  transaction._transactionTradeType = this._transactionTradeType;
182
183
  transaction._shouldUpdatePricing = this._shouldUpdatePricing;
184
+ transaction._hasPromisedToPayWithPLCC = this._hasPromisedToPayWithPLCC;
183
185
  transaction._shouldUpdateTaxation = this._shouldUpdateTaxation;
184
186
  transaction._transactionReferenceFormatter = this._transactionReferenceFormatter;
185
187
  transaction._referenceNumber = this._referenceNumber;
@@ -768,6 +770,9 @@ class MerchandiseTransaction extends RetailTransaction_1.RetailTransaction {
768
770
  get shouldUpdatePricing() {
769
771
  return this._shouldUpdatePricing;
770
772
  }
773
+ get hasPromisedToPayWithPLCC() {
774
+ return this._hasPromisedToPayWithPLCC;
775
+ }
771
776
  get shouldUpdateTaxation() {
772
777
  return this._shouldUpdateTaxation;
773
778
  }
@@ -855,6 +860,7 @@ class MerchandiseTransaction extends RetailTransaction_1.RetailTransaction {
855
860
  ["transaction.feeExcludingTax", this.transactionFeeExcludingTax],
856
861
  ["transaction.feeTax", this.transactionFeeTax],
857
862
  ["transaction.totalFee", this.transactionTotalFee],
863
+ ["transaction.hasPromisedToPayWithPLCC", this._hasPromisedToPayWithPLCC],
858
864
  ["transaction.transactionTotalFeeAfterTaxAdjustment", this._transactionTotalFeeAfterTaxAdjustment],
859
865
  ["transaction.returnSubTotal", this._returnSubTotal],
860
866
  ["transaction.returnSubTotalExcludingTax", this._returnSubTotalExcludingTax],
@@ -993,6 +999,7 @@ class MerchandiseTransaction extends RetailTransaction_1.RetailTransaction {
993
999
  _taxCustomer: this.taxCustomer,
994
1000
  _transactionTradeType: this.transactionTradeType,
995
1001
  _shouldUpdatePricing: this.shouldUpdatePricing,
1002
+ _hasPromisedToPayWithPLCC: this.hasPromisedToPayWithPLCC,
996
1003
  _shouldUpdateTaxation: this.shouldUpdateTaxation,
997
1004
  _referenceNumber: this.referenceNumber,
998
1005
  _giftReceiptMode: this.giftReceiptMode,
@@ -1138,6 +1145,7 @@ class MerchandiseTransaction extends RetailTransaction_1.RetailTransaction {
1138
1145
  this._taxCustomer = TaxCustomerLine_1.TaxCustomerLine.createFromJsonObject(transactionJsonObj._taxCustomer);
1139
1146
  this._transactionTradeType = utils_1.getTradeType(transactionJsonObj);
1140
1147
  this._shouldUpdatePricing = transactionJsonObj._shouldUpdatePricing;
1148
+ this._hasPromisedToPayWithPLCC = transactionJsonObj._hasPromisedToPayWithPLCC;
1141
1149
  this._shouldUpdateTaxation = transactionJsonObj._shouldUpdateTaxation;
1142
1150
  this._referenceNumber = transactionJsonObj._referenceNumber;
1143
1151
  this._giftReceiptMode = transactionJsonObj._giftReceiptMode;
@@ -14,6 +14,7 @@ export interface IShippingMethod {
14
14
  displayOrder?: number;
15
15
  shippingMethodID: string;
16
16
  shippingCategories?: string[];
17
+ shippingFeeExtendedNetAmount?: IShippingFee;
17
18
  }
18
19
  interface IShippingFee {
19
20
  feeCalculationMethod?: string;
@@ -284,9 +284,6 @@ class BaseManualDiscountLine extends BaseTransactionLine_1.BaseTransactionLine {
284
284
  if (collectedData.has(Constants_1.CollectedDataKey.EmployeeId)) {
285
285
  this._isEmployeeDiscount = !!collectedData.get(Constants_1.CollectedDataKey.EmployeeId);
286
286
  }
287
- else {
288
- this._isEmployeeDiscount = !!collectedData.get(Constants_1.CollectedDataKey.EmployeeFlag);
289
- }
290
287
  }
291
288
  loadAutoAppliedFromCollectedData(collectedData) {
292
289
  if (collectedData.has(Constants_1.CollectedDataKey.AutoApplied)) {
@@ -316,12 +313,10 @@ class BaseManualDiscountLine extends BaseTransactionLine_1.BaseTransactionLine {
316
313
  }
317
314
  loadLoyaltyDiscountFromCollectedData(collectedData) {
318
315
  if (collectedData.has(Constants_1.CollectedDataKey.LoyaltyPlanKey) ||
319
- collectedData.has(Constants_1.CollectedDataKey.MembershipTypeKey) ||
320
- collectedData.has(Constants_1.CollectedDataKey.TriggeredByLoyaltyAwards)) {
316
+ collectedData.has(Constants_1.CollectedDataKey.MembershipTypeKey)) {
321
317
  this._isLoyaltyDiscount =
322
318
  !!collectedData.get(Constants_1.CollectedDataKey.LoyaltyPlanKey) ||
323
- !!collectedData.get(Constants_1.CollectedDataKey.MembershipTypeKey) ||
324
- !!collectedData.get(Constants_1.CollectedDataKey.TriggeredByLoyaltyAwards);
319
+ !!collectedData.get(Constants_1.CollectedDataKey.MembershipTypeKey);
325
320
  }
326
321
  }
327
322
  loadAmountFromJsonObject(transactionLineJsonObj) {
@@ -7,22 +7,18 @@ exports.ITEM_MANUAL_DISCOUNT_LINE_TYPE = "ItemManualDiscount";
7
7
  exports.TRANSACTION_MANUAL_DISCOUNT_LINE_TYPE = "TransactionManualDiscount";
8
8
  exports.LOYALTY_DISCOUNT_LINE_TYPE = "LoyaltyDiscount";
9
9
  function isManualItemDiscountLine(transactionLine) {
10
- return (transactionLine &&
11
- (transactionLine instanceof ManualItemDiscountLine_1.ManualItemDiscountLine ||
12
- (transactionLine.lineType === exports.ITEM_MANUAL_DISCOUNT_LINE_TYPE &&
13
- transactionLine.itemLineReference !== undefined)));
10
+ return (transactionLine instanceof ManualItemDiscountLine_1.ManualItemDiscountLine ||
11
+ (transactionLine.lineType === exports.ITEM_MANUAL_DISCOUNT_LINE_TYPE &&
12
+ transactionLine.itemLineReference !== undefined));
14
13
  }
15
14
  exports.isManualItemDiscountLine = isManualItemDiscountLine;
16
15
  function isManualTransactionDiscountLine(transactionLine) {
17
- return (transactionLine &&
18
- (transactionLine instanceof ManualTransactionDiscountLine_1.ManualTransactionDiscountLine ||
19
- transactionLine.lineType === exports.TRANSACTION_MANUAL_DISCOUNT_LINE_TYPE));
16
+ return (transactionLine instanceof ManualTransactionDiscountLine_1.ManualTransactionDiscountLine ||
17
+ transactionLine.lineType === exports.TRANSACTION_MANUAL_DISCOUNT_LINE_TYPE);
20
18
  }
21
19
  exports.isManualTransactionDiscountLine = isManualTransactionDiscountLine;
22
20
  function isLoyaltyDiscountLine(transactionLine) {
23
- return (transactionLine &&
24
- (transactionLine instanceof LoyaltyDiscountLine_1.LoyaltyDiscountLine ||
25
- transactionLine.lineType === exports.LOYALTY_DISCOUNT_LINE_TYPE));
21
+ return (transactionLine instanceof LoyaltyDiscountLine_1.LoyaltyDiscountLine || transactionLine.lineType === exports.LOYALTY_DISCOUNT_LINE_TYPE);
26
22
  }
27
23
  exports.isLoyaltyDiscountLine = isLoyaltyDiscountLine;
28
24
  function isManualDiscountLine(transactionLine) {
@@ -284,7 +284,6 @@ export interface IOriginalLoyaltyInformation {
284
284
  readonly originalDiscountlineNumber?: number;
285
285
  readonly discountProratedByService?: boolean;
286
286
  readonly itemLineReferences?: IProratedItemLineReference[];
287
- readonly triggeredByLoyaltyAwards?: boolean;
288
287
  }
289
288
  export interface IOriginalCompetitivePriceInformation {
290
289
  readonly pricingRuleId?: string;
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.52.1",
3
+ "version": "1.53.1",
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",