原材料仓、中储仓出入库优化

This commit is contained in:
2024-08-01 13:57:29 +08:00
parent be72cfb46f
commit 5693ef6ed2
9 changed files with 85 additions and 17 deletions

View File

@@ -60,6 +60,8 @@ namespace Tnb.WarehouseMgr
var db = _db;
if (dbConn != null)
db = dbConn;
string type = "";
try
{
await db.Ado.BeginTranAsync();
@@ -67,7 +69,6 @@ namespace Tnb.WarehouseMgr
WmsPrdInstockH prdInstockH = db.Queryable<WmsPrdInstockH>().Where(r => r.prd_bill_code == input.prd_bill_code).First();
string prd_instock_code_id = "";
string type = "";
// 新建主表
if (prdInstockH == null)
{
@@ -142,6 +143,19 @@ namespace Tnb.WarehouseMgr
await db.Insertable(WmsPrdInstockCodes).ExecuteCommandAsync();
if (type == "25019163616533")
{
await _s_taskExecuteSemaphore_F1ZCCInstock.WaitAsync();
}
else if (type == "25019172714005")
{
await _s_taskExecuteSemaphore_F1ZCCInstock.WaitAsync();
}
else if (type == "25019191681045")
{
}
foreach (WmsPrdInstockD wmsPrdInstockD in WmsPrdInstockDs)
{
//入库取终点
@@ -275,6 +289,19 @@ namespace Tnb.WarehouseMgr
}
finally
{
if (type == "25019163616533")
{
_s_taskExecuteSemaphore_F1ZCCInstock.Release();
}
else if (type == "25019172714005")
{
_s_taskExecuteSemaphore_F1ZCCInstock.Release();
}
else if (type == "25019191681045")
{
}
_wareHouseService.GenTaskExecute();
}