| | |
| | | return objJsonResult; |
| | | } |
| | | |
| | | if (oSystemParameter.omodel.WMS_CampanyName != "å¸
å¨") |
| | | if (oSystemParameter.omodel.WMS_CampanyName != "å¸
å¨"&& oSystemParameter.omodel.WMS_CampanyName != "å®å·¥" && oSystemParameter.omodel.WMS_CampanyName != "ä¸å") |
| | | { |
| | | if (oSub.HLeadTime_Sec == 0 || oSub.HLeadTime_Sec == null) |
| | | { |
| | |
| | | tb2.Rows[i]["HUnitID"] = ds.Tables[0].Rows[0]["HItemID"].ToString(); |
| | | } |
| | | |
| | | //JITç©æåç±» |
| | | if (JITType == "") |
| | | string msg = ""; |
| | | oSystemParameter.ShowBill(ref msg); |
| | | if (oSystemParameter.omodel.WMS_CampanyName == "å®å·¥") |
| | | { |
| | | objJsonResult.code = "0"; |
| | | objJsonResult.count = 0; |
| | | objJsonResult.Message = "第" + index + "è¡,JITç©æå类为空ï¼"; |
| | | objJsonResult.data = null; |
| | | return objJsonResult; |
| | | //JITä¾è´§æåæï¼å¤©ï¼ |
| | | if (JISLT == "") |
| | | { |
| | | objJsonResult.code = "0"; |
| | | objJsonResult.count = 0; |
| | | objJsonResult.Message = "第" + index + "è¡,JITä¾è´§æåæï¼å¤©ï¼ä¸ºç©ºï¼"; |
| | | objJsonResult.data = null; |
| | | return objJsonResult; |
| | | } |
| | | } |
| | | |
| | | //JITæè´§ç»æµæ¹é |
| | | if (JIPEB == "") |
| | | else |
| | | { |
| | | objJsonResult.code = "0"; |
| | | objJsonResult.count = 0; |
| | | objJsonResult.Message = "第" + index + "è¡,JITæè´§ç»æµæ¹é为空ï¼"; |
| | | objJsonResult.data = null; |
| | | return objJsonResult; |
| | | } |
| | | //JITç©æåç±» |
| | | if (JITType == "") |
| | | { |
| | | objJsonResult.code = "0"; |
| | | objJsonResult.count = 0; |
| | | objJsonResult.Message = "第" + index + "è¡,JITç©æå类为空ï¼"; |
| | | objJsonResult.data = null; |
| | | return objJsonResult; |
| | | } |
| | | |
| | | //JITä¾è´§æåæï¼å¤©ï¼ |
| | | if (JISLT == "") |
| | | { |
| | | objJsonResult.code = "0"; |
| | | objJsonResult.count = 0; |
| | | objJsonResult.Message = "第" + index + "è¡,JITä¾è´§æåæï¼å¤©ï¼ä¸ºç©ºï¼"; |
| | | objJsonResult.data = null; |
| | | return objJsonResult; |
| | | } |
| | | //JITæè´§ç»æµæ¹é |
| | | if (JIPEB == "") |
| | | { |
| | | objJsonResult.code = "0"; |
| | | objJsonResult.count = 0; |
| | | objJsonResult.Message = "第" + index + "è¡,JITæè´§ç»æµæ¹é为空ï¼"; |
| | | objJsonResult.data = null; |
| | | return objJsonResult; |
| | | } |
| | | |
| | | //JITå°è´§åç½®æï¼å¤©ï¼ |
| | | if (JIDLT == "") |
| | | { |
| | | objJsonResult.code = "0"; |
| | | objJsonResult.count = 0; |
| | | objJsonResult.Message = "第" + index + "è¡,JITå°è´§åç½®æï¼å¤©ï¼ä¸ºç©ºï¼"; |
| | | objJsonResult.data = null; |
| | | return objJsonResult; |
| | | } |
| | | //JITä¾è´§æåæï¼å¤©ï¼ |
| | | if (JISLT == "") |
| | | { |
| | | objJsonResult.code = "0"; |
| | | objJsonResult.count = 0; |
| | | objJsonResult.Message = "第" + index + "è¡,JITä¾è´§æåæï¼å¤©ï¼ä¸ºç©ºï¼"; |
| | | objJsonResult.data = null; |
| | | return objJsonResult; |
| | | } |
| | | |
| | | //JITæå°èµ·éé |
| | | if (JIMLC == "") |
| | | { |
| | | objJsonResult.code = "0"; |
| | | objJsonResult.count = 0; |
| | | objJsonResult.Message = "第" + index + "è¡,JITæå°èµ·éé为空ï¼"; |
| | | objJsonResult.data = null; |
| | | return objJsonResult; |
| | | } |
| | | //JITå°è´§åç½®æï¼å¤©ï¼ |
| | | if (JIDLT == "") |
| | | { |
| | | objJsonResult.code = "0"; |
| | | objJsonResult.count = 0; |
| | | objJsonResult.Message = "第" + index + "è¡,JITå°è´§åç½®æï¼å¤©ï¼ä¸ºç©ºï¼"; |
| | | objJsonResult.data = null; |
| | | return objJsonResult; |
| | | } |
| | | |
| | | //å®¡æ ¸ä»£ç æ¯å¦åç |
| | | if (!DBUtility.ClsPub.AllowNumber(HMaterNumer)) |
| | | { |
| | | objJsonResult.code = "0"; |
| | | objJsonResult.count = 0; |
| | | objJsonResult.Message = "第" + index + "è¡,ç©æä»£ç ä¸ä¸è½åºç°è¿ç»â.âå¹¶ä¸é¦ä½æ«ä½ä¸è½ä¸ºâ.âï¼"; |
| | | objJsonResult.data = null; |
| | | return objJsonResult; |
| | | } |
| | | //JITæå°èµ·éé |
| | | if (JIMLC == "") |
| | | { |
| | | objJsonResult.code = "0"; |
| | | objJsonResult.count = 0; |
| | | objJsonResult.Message = "第" + index + "è¡,JITæå°èµ·éé为空ï¼"; |
| | | objJsonResult.data = null; |
| | | return objJsonResult; |
| | | } |
| | | |
| | | //å®¡æ ¸ä»£ç æ¯å¦åç |
| | | if (!DBUtility.ClsPub.AllowNumber(HMaterNumer)) |
| | | { |
| | | objJsonResult.code = "0"; |
| | | objJsonResult.count = 0; |
| | | objJsonResult.Message = "第" + index + "è¡,ç©æä»£ç ä¸ä¸è½åºç°è¿ç»â.âå¹¶ä¸é¦ä½æ«ä½ä¸è½ä¸ºâ.âï¼"; |
| | | objJsonResult.data = null; |
| | | return objJsonResult; |
| | | } |
| | | } |
| | | } |
| | | else |
| | | { |
| | |
| | | "HLeadTime, HLeadTime_Sec, HDeliveryMode, HDeliveryDaysCtrl,HUnitID,HJITMinDeliveryQty)values" + |
| | | $"({HInterID}, 1, '{HRemark}', {(HSupID == "" ? "0" : HSupID)}, '{HSupplierName}', {(HMaterID == "" ? "0" : HMaterID)}," + |
| | | $" '{HMaterName}', '{HMaterModel}', '{JITType}', {(JITPSL == "" ? "0" : JITPSL)}, {(JITMDSC == "" ? "0" : JITMDSC)},{(JIPEB == "" ? "0" : JIPEB)},{(JITPBCC == "" ? "0" : JITPBCC)}," + |
| | | $" {(JISLT == "" ? "0" : JISLT)}, {(JIDLT == "" ? "0" : JIDLT)}, '', {(JITDCD == "" ? "0" : JITDCD)} ,{HUnitID},{JIMLC})"; |
| | | $" {(JISLT == "" ? "0" : JISLT)}, {(JIDLT == "" ? "0" : JIDLT)}, '', {(JITDCD == "" ? "0" : JITDCD)} ,{HUnitID},{(JIMLC==""?"0": JIMLC)})"; |
| | | //主表 |
| | | oCN.RunProc(sql); |
| | | //å表 |
| | |
| | | |
| | | public json AddNeedBillSub(string msg3) |
| | | { |
| | | string Ret = ""; |
| | | omodelNeedsub = Newtonsoft.Json.JsonConvert.DeserializeObject<List<JIT_NeedMaterPlanConfigBillSub>>(msg3); |
| | | |
| | | oSystemParameter.ShowBill(ref Ret); |
| | | foreach (Models.JIT_NeedMaterPlanConfigBillSub oSub in omodelNeedsub) |
| | | { |
| | | if (oSub.HWorkShopID == 0 || oSub.HWorkShopID == null) |
| | |
| | | objJsonResult.data = null; |
| | | return objJsonResult; |
| | | } |
| | | if (oSub.HDeliveryDaysCtrl == 0 || oSub.HDeliveryDaysCtrl == null) |
| | | if (oSystemParameter.omodel.WMS_CampanyName != "å®å·¥"&& oSystemParameter.omodel.WMS_CampanyName != "ä¸å") |
| | | { |
| | | objJsonResult.code = "0"; |
| | | objJsonResult.count = 0; |
| | | objJsonResult.Message = " JITéè´§æ§å¶å¤©æ°ä¸è½ä¸ºç©º"; |
| | | objJsonResult.data = null; |
| | | return objJsonResult; |
| | | if (oSub.HDeliveryDaysCtrl == 0 || oSub.HDeliveryDaysCtrl == null) |
| | | { |
| | | objJsonResult.code = "0"; |
| | | objJsonResult.count = 0; |
| | | objJsonResult.Message = " JITéè´§æ§å¶å¤©æ°ä¸è½ä¸ºç©º"; |
| | | objJsonResult.data = null; |
| | | return objJsonResult; |
| | | } |
| | | } |
| | | |
| | | } |
| | | |
| | | //å é¤å表 |