From c8b1ba855be2663a1da3444c54d8af5a202a4b7e Mon Sep 17 00:00:00 2001
From: yl <ykxkd@outlook.com>
Date: 星期一, 06 三月 2023 16:33:32 +0800
Subject: [PATCH] 1.节拍工价新增、编辑加工价类型字段区分自制、外协 2.工序编辑,工序类型切换保存时删除对应节拍工价表 3.工单派发时判断区分自制、外协工序 4.计件工资报表增加剔除工序参数

---
 VueWebApi/Controllers/ProductModelController.cs |   36 ++++++++++++++++++++++++++++--------
 1 files changed, 28 insertions(+), 8 deletions(-)

diff --git a/VueWebApi/Controllers/ProductModelController.cs b/VueWebApi/Controllers/ProductModelController.cs
index f74dcc1..dfa7877 100644
--- a/VueWebApi/Controllers/ProductModelController.cs
+++ b/VueWebApi/Controllers/ProductModelController.cs
@@ -17,7 +17,7 @@
 
     [RoutePrefix(prefix: "api/ProductModel")]
     [ControllerGroup("鍒堕�犳ā鍨�", "鍦ㄧ嚎鎺ュ彛")]
-    //[ChannelActionFilter]
+    [ChannelActionFilter]
     public class ProductModelController : ApiController
     {
         //瀹氫箟鍏ㄥ眬淇℃伅杩斿洖鍙橀噺
@@ -243,9 +243,13 @@
             string materialtypecode = obj["materialtypecode"].ToString(); //鐗╂枡绫诲瀷缂栫爜
             string minstockqty = obj["minstockqty"].ToString(); //鏈�灏忓簱瀛�
             string maxstockqty = obj["maxstockqty"].ToString(); //鏈�澶у簱瀛�
+            string is_batchno = obj["is_batchno"].ToString();   //鏄惁鎵规绠$悊
+            string is_fifo = obj["is_fifo"].ToString();         //鏄惁鍏堣繘鍏堝嚭
+            string is_incheck = obj["is_incheck"].ToString();   //鏄惁鍏ュ巶妫�楠�
+            string is_outcheck = obj["is_outcheck"].ToString(); //鏄惁鍑哄巶妫�楠�
             var username = HttpContext.Current.Request.Cookies["admin"].Value.ToString(); //鎿嶄綔浜哄憳
             string OperType = obj["OperType"].ToString();  //鎿嶄綔绫诲瀷
-            mes = ProductModelBLL.AddUpdateInventoryFile(materialid, materialcode, materialname, materialspec, uomcode, warehousecode, stocktypecode, materialtypecode, minstockqty, maxstockqty, username, OperType);
+            mes = ProductModelBLL.AddUpdateInventoryFile(materialid, materialcode, materialname, materialspec, uomcode, warehousecode, stocktypecode, materialtypecode, minstockqty, maxstockqty,is_batchno,is_fifo,is_incheck,is_outcheck, username, OperType);
             return TJson.toJson(mes);
         }
         #endregion
@@ -381,13 +385,28 @@
             string status = obj["status"].ToString();//鍚敤鐘舵��
             string uomcode = obj["uomcode"].ToString(); //璁¢噺鍗曚綅缂栫爜
             string quantity = obj["quantity"].ToString(); //鍩虹鏁伴噺
-            string startdate = obj["startdate"].ToString(); //鍩虹鏁伴噺
-            string version = obj["version"].ToString(); //鍩虹鏁伴噺
-            string worklist = obj["worklist"].ToString(); //鍩虹鏁伴噺
-            string opertype = obj["opertype"].ToString(); //鍩虹鏁伴噺
+            string startdate = obj["startdate"].ToString(); //鍚敤鏃ユ湡
+            string version = obj["version"].ToString(); //鐗堟湰鍙�
+            string worklist = obj["worklist"].ToString(); //鎻愪氦鏁版嵁
+            string opertype = obj["opertype"].ToString(); //鎻愪氦绫诲瀷
             string username = HttpContext.Current.Request.Cookies["admin"].Value.ToString(); //鎿嶄綔浜哄憳
             List<BomSub> objs = Newtonsoft.Json.JsonConvert.DeserializeObject<List<BomSub>>(worklist);
             mes = ProductModelBLL.AddUpdateBoIventory(bomid,parentpartcode, parentpartname, parentpartspec, status, uomcode, quantity, startdate, version, username, opertype, objs);
+            return TJson.toJson(mes);
+        }
+        #endregion
+
+        #region[鐗╂枡娓呭崟鍒犻櫎]
+        /// <summary>
+        /// 鐗╂枡娓呭崟鍒犻櫎
+        /// </summary>
+        /// <param name="bomid">Bom涓昏〃id</param>
+        /// <returns></returns>
+        [Route(template: "DeleteBoIventory")]
+        [HttpPost]
+        public HttpResponseMessage DeleteBoIventory(string bomid)
+        {
+            mes = ProductModelBLL.DeleteBoIventory(bomid);
             return TJson.toJson(mes);
         }
         #endregion
@@ -702,6 +721,7 @@
         /// <param name="partcode">浜у搧缂栫爜</param>
         ///  <param name="routecode">宸ヨ壓璺嚎缂栫爜</param>
         /// <param name="stepcode">宸ュ簭缂栫爜</param>
+        /// <param name="steptype">宸ュ簭绫诲瀷</param>
         /// <param name="page">椤电爜</param>
         /// <param name="rows">姣忛〉鏄剧ず鏉℃暟</param>
         /// <param name="prop">鎺掑簭瀛楁</param>
@@ -709,12 +729,12 @@
         /// <returns></returns>
         [Route(template: "StepSelectEqpList")]
         [HttpGet]
-        public HttpResponseMessage StepSelectEqpList(string partcode, string routecode, string stepcode, int page = 0, int rows = 0, string prop = null, string order = null)
+        public HttpResponseMessage StepSelectEqpList(string partcode, string routecode, string stepcode,string steptype, int page = 0, int rows = 0, string prop = null, string order = null)
         {
 
             int startNum = rows * (page - 1) + 1;  //璧峰璁板綍rowNum
             int endNum = rows * page;   //缁撴潫璁板綍 rowNum
-            mes = ProductModelBLL.StepSelectEqpList(partcode, routecode, stepcode, startNum, endNum, prop, order);
+            mes = ProductModelBLL.StepSelectEqpList(partcode, routecode, stepcode, steptype, startNum, endNum, prop, order);
             return TJson.toJson(mes);
         }
         #endregion

--
Gitblit v1.9.3