From a35a334af2f2c626538e0f6245a36f1ce5a5536f Mon Sep 17 00:00:00 2001
From: lazhen <17772815105@139.com>
Date: 星期一, 25 十一月 2024 17:46:05 +0800
Subject: [PATCH] 上线/下线/库存存档bug

---
 _Main/BL/Type_InventoryPlanArchiveRow/Method_SetQuantity.qbl |    7 ++++++-
 1 files changed, 6 insertions(+), 1 deletions(-)

diff --git a/_Main/BL/Type_InventoryPlanArchiveRow/Method_SetQuantity.qbl b/_Main/BL/Type_InventoryPlanArchiveRow/Method_SetQuantity.qbl
index 9896048..8fad06d 100644
--- a/_Main/BL/Type_InventoryPlanArchiveRow/Method_SetQuantity.qbl
+++ b/_Main/BL/Type_InventoryPlanArchiveRow/Method_SetQuantity.qbl
@@ -9,7 +9,12 @@
   TextBody:
   [*
     // 鐢勫叞楦� Jun-24-2024 (created)
-    cell := selectobject( this, Cell, cell, cell.Column() = column );
+    cell        := selectobject( this, Cell, cell, cell.Column() = column );
+    if( isnull( cell ) ){
+      cell      := this.Cell( relnew, PlanQuantity := 0, ActualQuantity := 0 );
+    
+      column.Cell( relinsert, cell );
+    }
     cell.PlanQuantity( cell.PlanQuantity() + planqty );
     cell.ActualQuantity( cell.ActualQuantity() + actualaty );
   *]

--
Gitblit v1.9.3