From d6478661f2af69e00351dcf241fe94ddeccbc0d1 Mon Sep 17 00:00:00 2001
From: llj <132905093+newwwwwwtree@users.noreply.github.com>
Date: 星期六, 13 九月 2025 10:51:11 +0800
Subject: [PATCH] 群里问题部分进行修改
---
WebAPI/Controllers/SRM_MaterialBarCodeBillController.cs | 16 ++++++++--------
1 files changed, 8 insertions(+), 8 deletions(-)
diff --git a/WebAPI/Controllers/SRM_MaterialBarCodeBillController.cs b/WebAPI/Controllers/SRM_MaterialBarCodeBillController.cs
index 4eeceed..d4af355 100644
--- a/WebAPI/Controllers/SRM_MaterialBarCodeBillController.cs
+++ b/WebAPI/Controllers/SRM_MaterialBarCodeBillController.cs
@@ -151,8 +151,7 @@
string HMaterShortNumber = ls[0].HMaterShortNumber;
string HMaterName = ls[0].HMaterName;
//渚涘簲鍟�
- long HSupID= ls[0].HSupID;
- string HSupName= ls[0].HSupName;
+ long HSupID = lsmain[0].HSupID;
string HMaker= ls[0].HMaker;
DateTime HMakeDate= ls[0].HMakeDate;
double HQty= ls[0].HQty; //鏈鐢熸垚鏉$爜鏁伴噺
@@ -161,7 +160,8 @@
DataSet Ds;
SQLHelper.ClsCN oCn = new SQLHelper.ClsCN();
oCn.BeginTran();
- Ds = oCn.RunProcReturn("exec GetLSH '" + DateTime.Today + "'", "GetLSH");
+ //Ds = oCn.RunProcReturn("exec GetLSH '" + DateTime.Today + "'", "GetLSH");
+ Ds = oCn.RunProcReturn("exec GetLSH '" + HSupID+"_"+ HMaterID+"_" + DateTime.Today+ "'", "GetLSH");
LSH = ClsPub.isInt(Ds.Tables[0].Rows[0][0]);
#endregion
@@ -241,13 +241,13 @@
"HBatchNo, HBarcodeQtys, HBarcodeNo, HSupID, HGroupID, HMaker, HMakeDate, HPrintQty, HEndQty, HSupflag, " +
"HSourceInterID, HSourceEntryID, HSourceBillNo, HSourceBillType, HMTONO, HProduceDate, HExpiryDate, HISKFPERIOD) " +
"VALUES (" +
- linterid.ToString() + ", '" + TM + "', '" + HBarCodeType + "', " + HMaterID + ", " + "0" + ", " + HQty + ", '" + HKFDate + "', " + HKFPeriod + ", '" + HKFDQDate + "', " +
+ linterid.ToString() + ", '" + TM + "', '" + HBarCodeType + "', " + HMaterID + ", " + "0" + ", " + currentQty + ", '" + HKFDate + "', " + HKFPeriod + ", '" + HKFDQDate + "', " +
"'" + HBatchNo + "', " + get_BarCodecount + ", '" + virtualCount + "', " + HSupID + ", " + "0" + ", '" + ClsPub.CurUserName + "', '" + DateTime.Today.ToString("yyyy-MM-dd") + "', " + "1" + ", " + "0" + ", 1, " +
"1, 1, '1', '" + HSourceBillType + "', '1', '" +
HKFDate + "', '" + HKFDQDate + "', " + HISKFPERIOD + ")";
LogService.Write("鐢熸垚鏉$爜锛� " + sql);
- oCn.RunProc(sql);
- oCn.RunProc("exec setLSH '" + DateTime.Today + "'");
+ oCn.RunProc(sql);
+ oCn.RunProc("exec setLSH '" + HSupID + "_" + HMaterID + "_" + DateTime.Today + "'");
virtualCount++;
}
@@ -258,7 +258,7 @@
objJsonResult.code = "0";
objJsonResult.count = 1;
objJsonResult.Message = "鐢熸垚鏉$爜鎴愬姛锛�";
- objJsonResult.data = generatedBarcodes; // 杩斿洖鐢熸垚鐨勬潯鐮佸垪琛�
+ objJsonResult.data =string.Join("~", generatedBarcodes); // 杩斿洖鐢熸垚鐨勬潯鐮佸垪琛�
WebAPIController.Add_Log("鏉$爜涓嬫帹", UserName, "鐢熸垚鏉$爜");
return objJsonResult;
}
@@ -342,7 +342,7 @@
}
// 灏嗛�楀彿鍒嗛殧鐨勬潯鐮佽浆鎹负SQL IN鏌ヨ鏉′欢
- var barcodeList = barcodes.Split(',');
+ var barcodeList = barcodes.Split('~');
// 鏋勫缓IN瀛愬彞锛屼负姣忎釜鏉$爜娣诲姞鍗曞紩鍙�
var inValues = new List<string>();
--
Gitblit v1.9.1