This commit is contained in:
2026-01-27 18:07:41 +01:00
parent f3102ee835
commit 509dcac22e

View File

@@ -265,6 +265,10 @@ class AutomationDocument(ModelSQL, ModelView, Workflow):
logger.info("WITH_DEC:%s",sale_line)
vlot = sale_line.lots[0]
lqt = LotQt.search([('lot_s','=',vlot.id)])
if lqt:
lqt[0].lot_quantity += round(lot_net_weight,2)
logger.info("QUANTITY_UPDATED:%s",lqt[0].lot_quantity)
LotQt.save(lqt)
if lqt and lqt[0].lot_p:
logger.info("VLOT_P:%s",lqt[0].lot_p)
lqt[0].lot_p.updateVirtualPart(round(lot_net_weight,2),sh[0],lqt[0].lot_s)