Numerical product SKU #352
Unanswered
nmestriner95
asked this question in
Q&A
Replies: 0 comments
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.
-
Hi all.
I've a question about the standard API Products GetByIds.
the method signature is getByIdsAsync(context: IContext, channelId: number, productIds: number[], inventLocationId?: string | null, catalogId?: number | null):AsyncResult<SimpleProduct[]>
and the parameter productIds is intended as an array of number.
In my case, my sku pattern is a number with fixed dimension, for example 123456 and 012345 because in ERP the sku is intended as string.
In my module i'm obligated to cast the value from a string to a number to call the api but in this way, all the sku that starts with at least a 0 will never get a match because the starter 0 are trimmed.
Has anyone experienced the same problem and, if so, how did they solve it? if no, do you have any suggestion ?
Thanks a lot,
Nicola
Beta Was this translation helpful? Give feedback.
All reactions