@aptos-scp/scp-component-store-selling-features-domain-model 1.35.0 → 1.36.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.
@@ -427,7 +427,8 @@ export declare enum UiInputKey {
427
427
  ORIGINAL_TENDER = "input_originalTender",
428
428
  REFUNDABLE_TENDERS = "input_refundableTenders",
429
429
  BEST_REDEMPTION_PROMPT_STATUS = "input_bestRedemptionPromptStatus",
430
- TENDER_IS_ORIGINAL_TENDER = "input_tenderIsOriginalTender"
430
+ TENDER_IS_ORIGINAL_TENDER = "input_tenderIsOriginalTender",
431
+ TENDER_KEYED_ENTRY = "input_tenderKeyedEntry"
431
432
  }
432
433
  export declare enum CollectedDataKey {
433
434
  Abort = "abort",
@@ -431,6 +431,7 @@ var UiInputKey;
431
431
  UiInputKey["REFUNDABLE_TENDERS"] = "input_refundableTenders";
432
432
  UiInputKey["BEST_REDEMPTION_PROMPT_STATUS"] = "input_bestRedemptionPromptStatus";
433
433
  UiInputKey["TENDER_IS_ORIGINAL_TENDER"] = "input_tenderIsOriginalTender";
434
+ UiInputKey["TENDER_KEYED_ENTRY"] = "input_tenderKeyedEntry";
434
435
  })(UiInputKey = exports.UiInputKey || (exports.UiInputKey = {}));
435
436
  //
436
437
  // Keys for use in relaying data collectedData (qualification) and nonContextualData (action).
@@ -12,6 +12,7 @@ export declare enum TenderAuthorizationState {
12
12
  BalanceInquiryInProgress = "BalanceInquiryInProgress",
13
13
  GiftCardIssueInProgress = "GiftCardIssueInProgress",
14
14
  GiftCardRefundInProgress = "GiftCardRefundInProgress",
15
+ ManualEntryInProgress = "ManualEntryInProgress",
15
16
  WaitingForPartialAuthorizationApproval = "waitingForPartialAuthorizationApproval",
16
17
  WaitingForRetryLastAuthorization = "WaitingForRetryLastAuthorization",
17
18
  WaitingForNonIntegratedInput = "WaitingForNonIntegratedInput",
@@ -73,6 +74,7 @@ export declare class TenderAuthorizationSession implements IState {
73
74
  get inBalanceInquiryInProgress(): boolean;
74
75
  get inGiftCardIssueInProgress(): boolean;
75
76
  get inGiftCardRefundInProgress(): boolean;
77
+ get inManualEntryInProgress(): boolean;
76
78
  get inWaitingForPartialAuthorizationApproval(): boolean;
77
79
  get inWaitingForTransactionVoid(): boolean;
78
80
  get inWaitingForNonIntegratedInput(): boolean;
@@ -82,6 +84,7 @@ export declare class TenderAuthorizationSession implements IState {
82
84
  startAuthorization(lineNumber: number, tenderAuthCategory?: TenderAuthCategory): TenderAuthorizationSession;
83
85
  startInProgress(lineNumber: number, tenderAuthCategory: TenderAuthCategory, authorizationMode?: AuthorizationMode): TenderAuthorizationSession;
84
86
  startTenderVoid(lineNumber: number, tenderAuthCategory: TenderAuthCategory): TenderAuthorizationSession;
87
+ startManualEntry(lineNumber: number): TenderAuthorizationSession;
85
88
  startBalanceInquiry(lineNumber: number): TenderAuthorizationSession;
86
89
  startGiftCardIssue(lineNumber: number): TenderAuthorizationSession;
87
90
  startGiftCardRefund(lineNumber: number): TenderAuthorizationSession;
@@ -15,6 +15,7 @@ var TenderAuthorizationState;
15
15
  TenderAuthorizationState["BalanceInquiryInProgress"] = "BalanceInquiryInProgress";
16
16
  TenderAuthorizationState["GiftCardIssueInProgress"] = "GiftCardIssueInProgress";
17
17
  TenderAuthorizationState["GiftCardRefundInProgress"] = "GiftCardRefundInProgress";
18
+ TenderAuthorizationState["ManualEntryInProgress"] = "ManualEntryInProgress";
18
19
  TenderAuthorizationState["WaitingForPartialAuthorizationApproval"] = "waitingForPartialAuthorizationApproval";
19
20
  TenderAuthorizationState["WaitingForRetryLastAuthorization"] = "WaitingForRetryLastAuthorization";
20
21
  TenderAuthorizationState["WaitingForNonIntegratedInput"] = "WaitingForNonIntegratedInput";
@@ -41,6 +42,7 @@ const TenderAuthorizationStateNumericMap = {
41
42
  8: "waitingForPartialAuthorizationApproval",
42
43
  9: "GiftCardRefundInProgress",
43
44
  10: "TenderVoidInProgress",
45
+ 11: "ManualEntryInProgress",
44
46
  };
45
47
  exports.TENDER_AUTH_SESSION = "TenderAuthSession";
46
48
  class TenderAuthorizationSession {
@@ -181,6 +183,9 @@ class TenderAuthorizationSession {
181
183
  get inGiftCardRefundInProgress() {
182
184
  return this._state === TenderAuthorizationState.GiftCardRefundInProgress;
183
185
  }
186
+ get inManualEntryInProgress() {
187
+ return this._state === TenderAuthorizationState.ManualEntryInProgress;
188
+ }
184
189
  get inWaitingForPartialAuthorizationApproval() {
185
190
  return this._state === TenderAuthorizationState.WaitingForPartialAuthorizationApproval;
186
191
  }
@@ -199,6 +204,7 @@ class TenderAuthorizationSession {
199
204
  get isAuthorizationDeviceActive() {
200
205
  return (this.inGiftCardIssueInProgress ||
201
206
  this.inBalanceInquiryInProgress ||
207
+ this.inManualEntryInProgress ||
202
208
  this.inWaitingForReversal ||
203
209
  this.inWaitingForTransactionVoid ||
204
210
  this.inCancelInProgress ||
@@ -228,6 +234,12 @@ class TenderAuthorizationSession {
228
234
  ? this
229
235
  : new TenderAuthorizationSession(TenderAuthorizationState.TenderVoidInProgress, lineNumber, undefined, undefined, undefined, undefined, undefined, undefined, undefined, tenderAuthCategory);
230
236
  }
237
+ startManualEntry(lineNumber) {
238
+ logger.traceEntry("startManualEntry");
239
+ return this.inManualEntryInProgress
240
+ ? this
241
+ : new TenderAuthorizationSession(TenderAuthorizationState.ManualEntryInProgress, lineNumber, undefined, undefined);
242
+ }
231
243
  startBalanceInquiry(lineNumber) {
232
244
  logger.traceEntry("startBalanceInquiry");
233
245
  return this.inBalanceInquiryInProgress
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.35.0",
3
+ "version": "1.36.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",