We need to know the next Seed of the Number Sequence related to Sales Transactions which is going to be used for generating ReceiptId previously to be generated by standard POS in a sales transaction #227
Unanswered
rociouchapaz
asked this question in
Q&A
Replies: 1 comment 1 reply
-
we are able to mitigate this by using getNextReceiptIdAsync |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
We need to know the next Seed of the Number Sequence related to Sales Transactions in Commerce which is going to be used for generating the next ReceiptId previously to be generated by standard POS in a sales transaction
We are using this piece of code in POS side:
let numberSequence: any = (window).Commerce.NumberSequence;
await numberSequence.getNextValueAsync(Commerce.Proxy.Entities.NumberSequenceSeedType.ReceiptSale)
.then((transId) => { receiptId = transId });
This piece of code is working well, but only in one case it is not working well.
When I deactivate Store Commerce APP and then I activate Store Commerce App, then I have this strange behavior:
When our extension code in POS side is executed we have the next Seed of Number Sequence which is going to be used for generating ReceiptId, but then, in this specific scenario "the first time after activate Store Commerce APP", System doesn't generate the same ReceiptId which previously was generated by our code, the System generates previously ReceiptId which was generated by our code + 1.
In other scenarios, the system generates the same ReceiptId which previously was generated by our code,.
How can we manage this strange behavior? (The first time after activating of Store Commerce App)
Beta Was this translation helpful? Give feedback.
All reactions