自动修正库存负数

This commit is contained in:
高飞 2025-12-13 15:26:57 +08:00
parent 41a4ffa95f
commit 1e66342daa
1 changed files with 12 additions and 0 deletions

View File

@ -737,6 +737,18 @@
BLL.HJGL_HotProessManageEditService.AddHotProessItemByJoint(item);
}
#endregion
#region
Model.SGGLDB db1 = Funs.DB;
var list = from x in db1.Weld_StockIn
where x.Amount == null || x.Amount < x.UsingAmount
select x;
foreach (var item in list)
{
item.Amount = item.UsingAmount;
}
db1.SubmitChanges();
#endregion
}
protected void Session_Start(object sender, EventArgs e)