(Woocommerce integration) PO's should update Woocommerce with the actual received stock
My request is to change the way DEAR PO's update the stock quantity in Woocommerce when PO is set to "received". Now, if you set the PO to received DEAR will update the stock with the new available units, and not the actual stock received.
Let me explain why by showing this scenario using "Capture order when it is PAID", where our client has 48 hours to pay, the stock is reserved until paid or order is cancelled.
- Opening stock of product A:
- Client orders 5 x product A -> Woocommerce status "On Hold" and stock is reserved, not picked -> stock decrease in Woocommerce to 0 -> stock is not decreased in DEAR or Warehouse because order is not paid leaving stock at 5.
This is Good!
- PO on 10 x product A is set to "Received" in DEAR, this results in stock on product A being increased to 15 in DEAR AND Woocommerce.
So stock jumps from 0 to 15 in Woocommerce. This is Bad! (5 units more available for sale than what's actually available, because 5 x product A is reserved for the client and was registered in Woocommerce)
- When the order is paid, let's say after 24 hours, the order is registered in DEAR and stock is decreased in DEAR and the Warehouse
But stock is left the same in Woocommerce from the correction made by the PO. This is bad! as there is still 5 too much available for sale.
Fix: let DEAR PO's update woocommerce stock with the actual stock received in the PO.