From a91fdba94705dd25cecccc7a4a5dcc2b3f2c09a6 Mon Sep 17 00:00:00 2001
From: llj <132905093+newwwwwwtree@users.noreply.github.com>
Date: 星期一, 22 十二月 2025 16:16:00 +0800
Subject: [PATCH] Merge branch 'master' of http://101.37.171.70:10101/r/MES-WEB-API
---
WebAPI/Controllers/Sc_MouldRepairInBillListController.cs | 75 +++++++++++++++++++++++++++++++------
1 files changed, 62 insertions(+), 13 deletions(-)
diff --git a/WebAPI/Controllers/Sc_MouldRepairInBillListController.cs b/WebAPI/Controllers/Sc_MouldRepairInBillListController.cs
index 8c05fd9..f19f304 100644
--- a/WebAPI/Controllers/Sc_MouldRepairInBillListController.cs
+++ b/WebAPI/Controllers/Sc_MouldRepairInBillListController.cs
@@ -2070,7 +2070,6 @@
return objJsonResult;
}
- sWhere = sWhere.Replace("'", "''");
if (sWhere == null || sWhere.Equals(""))
{
@@ -2078,6 +2077,7 @@
}
else
{
+ sWhere = sWhere.Replace("'", "''");
ds = oCN.RunProcReturn("exec h_p_IF_SellOutBillList " + page + "," + size + ",'" + Organization + "','" + sWhere + "'", "h_p_IF_SellOutBillList");
}
@@ -2089,12 +2089,24 @@
columnNameList.Add(JsonConvert.DeserializeObject(ColmString));//鑾峰彇鍒癉ataColumn鍒楀璞$殑鍒楀悕
}
- objJsonResult.code = "1";
- objJsonResult.count = int.Parse(ds.Tables[1].Rows[0]["count"].ToString());
- objJsonResult.Message = "Sucess锛�";
- objJsonResult.list = columnNameList;
- objJsonResult.data = ds.Tables[0];
- return objJsonResult;
+ if(ds.Tables[0].Rows.Count > 0)
+ {
+ objJsonResult.code = "1";
+ objJsonResult.count = int.Parse(ds.Tables[1].Rows[0]["count"].ToString());
+ objJsonResult.Message = "Sucess锛�";
+ objJsonResult.list = columnNameList;
+ objJsonResult.data = ds.Tables[0];
+ return objJsonResult;
+ }else
+ {
+ objJsonResult.code = "1";
+ objJsonResult.count = 1;
+ objJsonResult.Message = "娌℃湁杩斿洖浠讳綍璁板綍锛�";
+ objJsonResult.list = columnNameList;
+ objJsonResult.data = ds.Tables[0];
+ return objJsonResult;
+ }
+
}
catch (Exception ex)
{
@@ -15641,12 +15653,23 @@
[HttpPost]
public object UploadFile_Gy_QCVerification()
{
-
+ string path = "";
string HBillNo = HttpContext.Current.Request.Params["HBillNo"]; //鍗曟嵁鍙�
string HRemark = HttpContext.Current.Request.Params["HRemark"]; //澶囨敞
string HUserName = HttpContext.Current.Request.Params["HUserName"]; //鍒涘缓浜�
- HttpPostedFile files = HttpContext.Current.Request.Files["file"];
- string path = HttpContext.Current.Server.MapPath("~/../Files/Gy_QCVerification/" + HBillNo);
+ HttpPostedFile files = HttpContext.Current.Request.Files["file"];
+ string Ret = "";
+ if (oSystemParameter.ShowBill(ref Ret))
+ {
+ if (oSystemParameter.omodel.WMS_CampanyName == "鍑礉濂堢壒")
+ {
+ path = "D:/缃戠珯鍙戝竷/LAYUI/Files/Gy_QCVerification/" + HBillNo;
+ }
+ else
+ {
+ path = HttpContext.Current.Server.MapPath("~/../Files/Gy_QCVerification/" + HBillNo);
+ }
+ }
dynamic dyResult = UploadFile_Gy_QCVerification(files, path, HBillNo, HRemark, HUserName);
if (dyResult != null && dyResult.result == 1)
{
@@ -15701,7 +15724,20 @@
{
File.Delete(fileurl); //鍒犻櫎鎸囧畾鏂囦欢
files.SaveAs(fileurl);
- string StrPath = "/files/Gy_QCVerification/" + HBillNo + "/" + filename;
+ string StrPath = "";
+
+ string Ret = "";
+ if (oSystemParameter.ShowBill(ref Ret))
+ {
+ if (oSystemParameter.omodel.WMS_CampanyName == "鍑礉濂堢壒")
+ {
+ StrPath = "D:/缃戠珯鍙戝竷/LAYUI/Files/Gy_QCVerification/" + HBillNo + "/" + filename;
+ }
+ else
+ {
+ StrPath = "/files/Gy_QCVerification/" + HBillNo + "/" + filename;
+ }
+ }
if (File.Exists(fileurl))
{
//杩欓噷鍙互鎵ц涓�浜涘叾瀹冪殑鎿嶄綔锛屾瘮濡傛洿鏂版暟鎹簱
@@ -15761,8 +15797,19 @@
[HttpGet]
public object Gy_QCVerification_Filelist(string HBillNo)
{
- var url = fileip + "/Files/Gy_QCVerification/" + HBillNo + "/";
-
+ string Ret = "";
+ var url = "";
+ if (oSystemParameter.ShowBill(ref Ret))
+ {
+ if (oSystemParameter.omodel.WMS_CampanyName == "鍑礉濂堢壒")
+ {
+ url = "D:/缃戠珯鍙戝竷/LAYUI/Files/Gy_QCVerification/" + HBillNo + "/";
+ }
+ else
+ {
+ url = fileip + "/Files/Gy_QCVerification/" + HBillNo + "/";
+ }
+ }
try
{
ds = oCN.RunProcReturn("select *,'" + url + "'+CAST(HFileName as varchar(200))as url from MES_AccessoriesList where HSourceBillNo='" + HBillNo + "'", "MES_AccessoriesList");
@@ -15814,6 +15861,8 @@
}
}
#endregion
+
+
#endregion
--
Gitblit v1.9.1