From fbbf0c08bce5575da23252d9227b670213408dde Mon Sep 17 00:00:00 2001
From: duhe <226547893@qq.com>
Date: 星期五, 16 八月 2024 09:45:52 +0800
Subject: [PATCH] 条码档案:动态列
---
WebAPI/Controllers/SCGL/Sc_MESTransFerWorkBillController.cs | 46 +++++++++++++++++++++++++++++++++++++++++++++-
1 files changed, 45 insertions(+), 1 deletions(-)
diff --git a/WebAPI/Controllers/SCGL/Sc_MESTransFerWorkBillController.cs b/WebAPI/Controllers/SCGL/Sc_MESTransFerWorkBillController.cs
index b0a1306..5e17f82 100644
--- a/WebAPI/Controllers/SCGL/Sc_MESTransFerWorkBillController.cs
+++ b/WebAPI/Controllers/SCGL/Sc_MESTransFerWorkBillController.cs
@@ -528,7 +528,8 @@
return new ApiResult<DataSet> { code = -1, msg = "ID涓嶈兘涓虹┖" };
SQLHelper.ClsCN oCN = new SQLHelper.ClsCN();
string sql =string.Format(@"select A.HInterID,b.HEntryID,A.HBillStatus,A.HBillNo,A.HDate,A.HContext,A.HDescription,A.HRemark,
- A.HQty,A.HSendType,
+ A.HQty,A.HSendType,a.HForm,a.HChangeNote,a.HNote,a.HBadProcMan,f1.HName HBadProcManName,
+ a.HQEMan,f2.HName HQEManName,a.HSourceID,s.HName HSourceName,a.HShiftsID,s1.HName HShiftsName,
A.HDeptID,D.HName HDeptName, A.HSendMan,
A.HReceiveMan,A.HCopyMan,A.HHasten,
A.HLevel,A.HMaterNumber,A.HMaterName,A.HMaterModel,
@@ -540,6 +541,10 @@
left join Gy_Department D on A.HDeptID=D.HItemID
left join Gy_Employee f on A.HHandleEmpID=f.HItemID
left join Gy_ErrMsgBackType g on A.HErrMsgBackTypeID=g.HItemID
+ left join Gy_Employee f1 on a.HBadProcMan=f1.HItemID
+ left join Gy_Employee f2 on a.HQEMan=f2.HItemID
+ left join Gy_Source s on a.HSourceID=s.HItemID
+ left join Gy_Shifts s1 on a.HShiftsID=s1.HItemID
where A.HInterID='" + HID + "' and b.HEntryID='" + HEntryID + "'");
var dataSet = oCN.RunProcReturn(sql, "OA_ErrMsgBackBillMain");
if (dataSet == null || dataSet.Tables[0].Rows.Count == 0)
@@ -6907,6 +6912,45 @@
}
#endregion
+ #region 鎶ュ伐鍙拌烦杞紓甯稿弽棣堝崟 寮圭獥鑾峰彇 璁惧缂栫爜
+
+ [Route("Sc_MESTransFerWorkBill/set_EquipFile")]
+ [HttpGet]
+ public object set_EquipFile(string HSourceName)
+ {
+ try
+ {
+ List<object> columnNameList = new List<object>();
+
+ string sql = "select a.HEquipFileNumber 璁惧缂栫爜 ,a.HName 璁惧鍚嶇О from Gy_EquipFileBillMain a left join Gy_Source b on a.HSourceID = b.HItemID where b.HName ='" + HSourceName + "'";
+ ds = oCN.RunProcReturn(sql, "Gy_ErrMsgBackType");
+
+ //娣诲姞鍒楀悕
+ foreach (DataColumn col in ds.Tables[0].Columns)
+ {
+ Type dataType = col.DataType;
+ string ColmString = "{\"ColmCols\":\"" + col.ColumnName + "\",\"ColmType\":\"" + dataType.Name + "\"}";
+ columnNameList.Add(JsonConvert.DeserializeObject(ColmString));//鑾峰彇鍒癉ataColumn鍒楀璞$殑鍒楀悕
+ }
+
+ objJsonResult.code = "1";
+ objJsonResult.count = 1;
+ objJsonResult.Message = "Sucess锛�";
+ objJsonResult.data = ds.Tables[0];
+ objJsonResult.list = columnNameList;
+ return objJsonResult;
+ }
+ catch (Exception ex)
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 0;
+ objJsonResult.Message = "鏌ヨ鏁版嵁寮傚父锛岃涓庣鐞嗗憳鑱旂郴锛�" + ex.ToString();
+ objJsonResult.data = null;
+ return objJsonResult;
+ }
+ }
+ #endregion
+
#region 寮傚父鍙嶉鍗� 璺熻釜鏌ヨ
[Route("Sc_MESTransFerWorkBill/GetErrMsgBackResumeList")]
[HttpGet]
--
Gitblit v1.9.1