Hey all, is there a way to set the max item quantity a user can order dynamically?
I have a Suitelet which does some calculations with incoming future POs and should also count their remaining free quantity as available in the shop. Backorders are allowed but i want to limit this quantity. Now I've got a SuiteScript2 Service which does a XHR call and loads the right number. But this only changes the displayed quantity, not the validated.
So I was experimenting with an extension to extend the
Configuration.ItemKeyMapping.Site module, successfully setting _stock to something fix for example. But here I can't load this Suitelet to get the data since it's not waiting for the callback.
Now i'm "stuck" at this idea on how to load max quantity and apply it to the item on the fly...
Any ideas or suggestions? Or even a whole new path to solve this? - Thanks for any feedback!