by pricerc » Wed Oct 21, 2020 7:16 am
I think I found my problem.
Originally, the project was a POS that was even simpler than the standard Plug-In example one. So, create an order, take a payment, process and close. So instead of just using the Jiwa business objects, I rolled my own, much simpler ones to use within the simplified UI, generating the Jiwa objects just before posting them.
However, the requirements have changed along the way, and I ended up having to reload the order and allow modifications. It also means that I save the order much more frequently than I was expecting.
And of course, after each 'Save', you have to 'Read' the SO again to refresh it with any changes made by the database. I was doing this, but then I forgot to also refresh the lines in my simplified sales order lines wrapper (I keep a reference to the relevant JiwaSales.SalesOrderLine within in my wrapper), which I think was leaving them in a 'funny' state.
In any case, it's working now, so I'm not going to pursue it further.