From 04b4d4d975858a0d5e207b9df9f3bb46cc6c14fd Mon Sep 17 00:00:00 2001
From: yusijie <ysj@hz-kingdee.com>
Date: 星期一, 17 十一月 2025 11:41:24 +0800
Subject: [PATCH] 添康排产页面直接修改排产数量;
---
WebAPI/Controllers/CJGL/Cj_SingleStationController.cs | 150 +++++++++++++++++++++++++++++++++++++++++++++++++
1 files changed, 148 insertions(+), 2 deletions(-)
diff --git a/WebAPI/Controllers/CJGL/Cj_SingleStationController.cs b/WebAPI/Controllers/CJGL/Cj_SingleStationController.cs
index 2650cec..1e76dd7 100644
--- a/WebAPI/Controllers/CJGL/Cj_SingleStationController.cs
+++ b/WebAPI/Controllers/CJGL/Cj_SingleStationController.cs
@@ -2856,8 +2856,8 @@
{
objJsonResult.code = "0";
objJsonResult.count = 0;
- objJsonResult.Message = "";
- objJsonResult.data = "娌℃湁鏌ヨ鍒版暟鎹�";
+ objJsonResult.Message = "娌℃湁鏌ヨ鍒版暟鎹�";
+ objJsonResult.data = "";
return objJsonResult;
}
@@ -3301,6 +3301,152 @@
}
}
#endregion
+
+ #region 杩囩珯瑙g粦鍒楄〃 鏌ヨ
+ [Route("Cj_SingleStation/UnbindBarList")]
+ [HttpGet]
+ public object BarList(string sWhere, string user)
+ {
+ try
+ {
+ List<object> columnNameList = new List<object>();
+ //鏌ョ湅鏉冮檺
+ if (!DBUtility.ClsPub.Security_Log("Cj_SingleStation_UnbindBarList", 1, false, user))
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 0;
+ objJsonResult.Message = "鏃犳煡鐪嬫潈闄愶紒";
+ objJsonResult.data = null;
+ return objJsonResult;
+ }
+
+ if (sWhere == null || sWhere.Equals(""))
+ {
+ ds = oCN.RunProcReturn("select * from h_v_Sc_UnbindStation_BarList order by 鏉$爜鏃ユ湡 desc", "h_v_Sc_UnbindStation_BarList");
+ }
+ else
+ {
+ string sql1 = "select * from h_v_Sc_UnbindStation_BarList where 1 = 1 ";
+ string sql = sql1 + sWhere + " order by 鏉$爜鏃ユ湡 desc";
+ ds = oCN.RunProcReturn(sql, "h_v_Sc_UnbindStation_BarList");
+ }
+
+ //娣诲姞鍒楀悕
+ 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 e)
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 0;
+ objJsonResult.Message = "Exception锛�" + e.ToString();
+ objJsonResult.data = null;
+ return objJsonResult;
+ }
+ }
+ #endregion
+
+ #region 閲嶅伐鏉$爜淇℃伅 鏌ヨ
+ [Route("Cj_SingleStation/UnbindBarInfo")]
+ [HttpGet]
+ public object UnbindBarInfo(string HBarCodeIDs, string user)
+ {
+ try
+ {
+ if (HBarCodeIDs == null || HBarCodeIDs.Equals(""))
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 0;
+ objJsonResult.Message = "閲嶅伐鏉$爜淇℃伅鏈�掑叆锛岃閫�鍑洪噸璇�";
+ objJsonResult.data = null;
+ return objJsonResult;
+ }
+ else
+ {
+ string sql = "exec h_p_Sc_UnbindBarInfo '" + HBarCodeIDs + "'";
+ ds = oCN.RunProcReturn(sql, "h_p_Sc_UnbindBarInfo");
+ }
+
+ objJsonResult.code = "1";
+ objJsonResult.count = 1;
+ objJsonResult.Message = "Sucess锛�";
+ objJsonResult.data = ds;
+ return objJsonResult;
+ }
+ catch (Exception e)
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 0;
+ objJsonResult.Message = "Exception锛�" + e.ToString();
+ objJsonResult.data = null;
+ return objJsonResult;
+ }
+ }
+ #endregion
+
+ #region 瑙i櫎鍖呰鍏崇郴銆佹媶闄ょ墿鏂�(1:瑙i櫎鍖呰鍏崇郴锛�2.鎷嗛櫎鐗╂枡)
+ [Route("Cj_SingleStation/DelRelation")]
+ [HttpGet]
+ public object DelRelation(string HBarCodeIDs, Int64 HICMOInterID, Int64 HICMOEntryID, Int64 HProcID, Int64 HType, string user)
+ {
+ try
+ {
+ if (HBarCodeIDs == null || HBarCodeIDs.Equals(""))
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 0;
+ objJsonResult.Message = "鎷嗛櫎鏉$爜淇℃伅鏈�掑叆锛岃閫�鍑洪噸璇�";
+ objJsonResult.data = null;
+ return objJsonResult;
+ }
+ else
+ {
+ string sql = "exec h_p_Sc_DelbindBarRelation '" + HBarCodeIDs + "'," + HICMOInterID + "," + HICMOEntryID + "," + HProcID + "," + HType;
+ ds = oCN.RunProcReturn(sql, "h_p_Sc_DelbindBarRelation");
+ }
+
+ if (ds.Tables[0].Rows[0]["HBack"].ToString() == "0")
+ {
+ objJsonResult.code = "1";
+ objJsonResult.count = 1;
+ objJsonResult.Message = "Sucess锛�";
+ objJsonResult.data = ds;
+ return objJsonResult;
+ }
+ else
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 0;
+ objJsonResult.Message = ds.Tables[0].Rows[0]["HBackRemark"].ToString();
+ objJsonResult.data = "";
+ return objJsonResult;
+ }
+
+
+ }
+ catch (Exception e)
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 0;
+ objJsonResult.Message = "Exception锛�" + e.ToString();
+ objJsonResult.data = null;
+ return objJsonResult;
+ }
+ }
+ #endregion
+
+
#endregion
}
--
Gitblit v1.9.1