|  |  |  | 
|---|
|  |  |  |  | 
|---|
|  |  |  | private json objJsonResult = new json(); | 
|---|
|  |  |  | Pub_Class.ClsXt_SystemParameter oSystemParameter = new Pub_Class.ClsXt_SystemParameter(); | 
|---|
|  |  |  |  | 
|---|
|  |  |  | public DAL.ClsSc_ICMOBill BillOld = new DAL.ClsSc_ICMOBill(); | 
|---|
|  |  |  | SQLHelper.ClsCN oCN = new SQLHelper.ClsCN(); | 
|---|
|  |  |  | DataSet ds; | 
|---|
|  |  |  |  | 
|---|
|  |  |  | 
|---|
|  |  |  | //} | 
|---|
|  |  |  | #endregion | 
|---|
|  |  |  |  | 
|---|
|  |  |  |  | 
|---|
|  |  |  |  | 
|---|
|  |  |  | /// <summary> | 
|---|
|  |  |  | /// 入库——生产汇报单 | 
|---|
|  |  |  | /// </summary> | 
|---|
|  |  |  | /// <param name="InterID">工序汇报单主ID</param> | 
|---|
|  |  |  | /// <returns></returns> | 
|---|
|  |  |  | [Route("Sc_ProcessMangement/SaveICMOReportBill_Batch")] | 
|---|
|  |  |  | [HttpPost] | 
|---|
|  |  |  | public object SaveICMOReportBill_Batch([FromBody] JObject msg) | 
|---|
|  |  |  | { | 
|---|
|  |  |  | var _value = msg["msg"].ToString(); | 
|---|
|  |  |  | string msg1 = _value.ToString(); | 
|---|
|  |  |  | string[] sArray = msg1.Split(new string[] { ";" }, StringSplitOptions.RemoveEmptyEntries); | 
|---|
|  |  |  | string InterID = sArray[0].ToString(); | 
|---|
|  |  |  | string user = sArray[1].ToString(); | 
|---|
|  |  |  | string BillNo = sArray[2].ToString(); | 
|---|
|  |  |  | string OrganizationID = sArray[3].ToString(); | 
|---|
|  |  |  | ArrayList InterIDArray = new ArrayList(InterID.Split(',')); | 
|---|
|  |  |  | ArrayList BillNoArray = new ArrayList(BillNo.Split(',')); | 
|---|
|  |  |  | try | 
|---|
|  |  |  | { | 
|---|
|  |  |  | string bResult; | 
|---|
|  |  |  | string HMessage = ""; | 
|---|
|  |  |  | string HSuccessBillNo = ""; | 
|---|
|  |  |  | string HFailBillNo = ""; | 
|---|
|  |  |  | WebAPI.Controllers.Sc_ProcessMangementController oBill = new WebAPI.Controllers.Sc_ProcessMangementController(); | 
|---|
|  |  |  | if (InterIDArray.Count != BillNoArray.Count) | 
|---|
|  |  |  | { | 
|---|
|  |  |  | objJsonResult.code = "0"; | 
|---|
|  |  |  | objJsonResult.count = 0; | 
|---|
|  |  |  | objJsonResult.Message = "数据不完整,内码数量不等于单据号数量"; | 
|---|
|  |  |  | objJsonResult.data = null; | 
|---|
|  |  |  | return objJsonResult; | 
|---|
|  |  |  | } | 
|---|
|  |  |  | else | 
|---|
|  |  |  | { | 
|---|
|  |  |  | for (int i = 0; i < InterIDArray.Count;i++) | 
|---|
|  |  |  | { | 
|---|
|  |  |  | bResult = JsonConvert.SerializeObject(oBill.SaveICMOReportBill(InterIDArray[i].ToString(), user, BillNoArray[i].ToString(), OrganizationID)); | 
|---|
|  |  |  |  | 
|---|
|  |  |  | //反序列化 | 
|---|
|  |  |  | bResult = "[" + bResult.ToString() + "]"; | 
|---|
|  |  |  |  | 
|---|
|  |  |  | List<JsonResult> list = Newtonsoft.Json.JsonConvert.DeserializeObject<List<JsonResult>>(bResult); | 
|---|
|  |  |  |  | 
|---|
|  |  |  | if (list[0].count == 1) | 
|---|
|  |  |  | { | 
|---|
|  |  |  | HSuccessBillNo = HSuccessBillNo + BillNoArray[i].ToString()+"," + "\r\n" ; | 
|---|
|  |  |  | } | 
|---|
|  |  |  | else | 
|---|
|  |  |  | { | 
|---|
|  |  |  | HFailBillNo = HFailBillNo + BillNoArray[i].ToString() + ":" + list[0].Message + "," + "\r\n"; | 
|---|
|  |  |  | } | 
|---|
|  |  |  | HMessage = "汇报成功单号:" + HSuccessBillNo + "\r\n" + "  汇报失败单号:" + HFailBillNo; | 
|---|
|  |  |  | } | 
|---|
|  |  |  | } | 
|---|
|  |  |  |  | 
|---|
|  |  |  | objJsonResult.code = "1"; | 
|---|
|  |  |  | objJsonResult.count = 1; | 
|---|
|  |  |  | objJsonResult.Message = HMessage; | 
|---|
|  |  |  | objJsonResult.data = null; | 
|---|
|  |  |  | return objJsonResult; | 
|---|
|  |  |  |  | 
|---|
|  |  |  | } | 
|---|
|  |  |  | catch (Exception e) | 
|---|
|  |  |  | { | 
|---|
|  |  |  | oCN.RollBack(); | 
|---|
|  |  |  | objJsonResult.code = "0"; | 
|---|
|  |  |  | objJsonResult.count = 0; | 
|---|
|  |  |  | objJsonResult.Message = "Exception!" + e.ToString(); | 
|---|
|  |  |  | objJsonResult.data = null; | 
|---|
|  |  |  | return objJsonResult; | 
|---|
|  |  |  | } | 
|---|
|  |  |  | } | 
|---|
|  |  |  |  | 
|---|
|  |  |  |  | 
|---|
|  |  |  | /// <summary> | 
|---|
|  |  |  | /// 入库——生产汇报单 | 
|---|
|  |  |  | /// </summary> | 
|---|
|  |  |  | 
|---|
|  |  |  | { | 
|---|
|  |  |  | try | 
|---|
|  |  |  | { | 
|---|
|  |  |  | string sErr = ""; | 
|---|
|  |  |  | oSystemParameter.ShowBill(ref sErr); | 
|---|
|  |  |  |  | 
|---|
|  |  |  |  | 
|---|
|  |  |  | //获取生产汇报单最大InterID和单据号 | 
|---|
|  |  |  | Int64 HInterID = DBUtility.ClsPub.CreateBillID("3711", ref DBUtility.ClsPub.sExeReturnInfo); | 
|---|
|  |  |  | string HBillNo = DBUtility.ClsPub.CreateBillCode("3711", ref DBUtility.ClsPub.sExeReturnInfo, true); | 
|---|
|  |  |  | 
|---|
|  |  |  | FentityModel.Add("FFinishQty", item["接收数量"].ToString());//完成数量1 | 
|---|
|  |  |  | FentityModel.Add("FQuaQty", item["合格数量"].ToString());//合格数量1FFailQty | 
|---|
|  |  |  | FentityModel.Add("FFailQty", item["不良数量"].ToString());//不合格数量 | 
|---|
|  |  |  | FentityModel.Add("FScrapQty", item["报废数量"].ToString());//报废数量 | 
|---|
|  |  |  | FentityModel.Add("FStockInOrgId ", new JObject() { ["Fnumber"] = OrganizationNUM });// 入库组织 | 
|---|
|  |  |  | FentityModel.Add("FStockId", new JObject() { ["Fnumber"] = dr1["FStockNUM"].ToString() }); // 仓库 | 
|---|
|  |  |  | FentityModel.Add("FMOID", dr1["FMOID"].ToString());// | 
|---|
|  |  |  | 
|---|
|  |  |  | FentityModel.Add("FCostRate", dr1["FCostRate"].ToString());// 成本权重 | 
|---|
|  |  |  | FentityModel.Add("FISBACKFLUSH", dr1["FISBACKFLUSH"].ToString() == "1" ? true : false);// 倒冲领料 | 
|---|
|  |  |  | FentityModel.Add("FMOMAINENTRYID", dr1["FMOENTRYID"].ToString());// | 
|---|
|  |  |  | //FentityModel.Add("F_bsv_Base1", new JObject() { ["Fnumber"] = dr1["FPREBDONENUMBER"].ToString() }); //包装标识 | 
|---|
|  |  |  | if (oSystemParameter.omodel.WMS_CampanyName == "瑞与祺") | 
|---|
|  |  |  | { | 
|---|
|  |  |  | FentityModel.Add("F_bsv_Base1", new JObject() { ["Fnumber"] = dr1["FPREBDONENUMBER"].ToString() });//包装标识 | 
|---|
|  |  |  | } | 
|---|
|  |  |  | FentityModel.Add("FLot", new JObject() { ["FNumber"] = dr1["FBATCHNO"].ToString() }); //批号 | 
|---|
|  |  |  | FentityModel.Add("F_bsv_Text", dr1["工序流转卡号"].ToString()); //流转卡号 | 
|---|
|  |  |  | JArray Fentity2 = new JArray(); | 
|---|
|  |  |  | 
|---|
|  |  |  | objJsonResult.Message = "保存成功!"; | 
|---|
|  |  |  | objJsonResult.data = 1; | 
|---|
|  |  |  | return objJsonResult; | 
|---|
|  |  |  | } | 
|---|
|  |  |  | catch (Exception e) | 
|---|
|  |  |  | { | 
|---|
|  |  |  | oCN.RollBack(); | 
|---|
|  |  |  | objJsonResult.code = "0"; | 
|---|
|  |  |  | objJsonResult.count = 0; | 
|---|
|  |  |  | objJsonResult.Message = "Exception!" + e.ToString(); | 
|---|
|  |  |  | objJsonResult.data = null; | 
|---|
|  |  |  | return objJsonResult; | 
|---|
|  |  |  | } | 
|---|
|  |  |  | } | 
|---|
|  |  |  |  | 
|---|
|  |  |  | /// <summary> | 
|---|
|  |  |  | /// 入库——生产汇报单 | 
|---|
|  |  |  | /// </summary> | 
|---|
|  |  |  | /// <param name="InterID">工序汇报单主ID</param> | 
|---|
|  |  |  | /// <returns></returns> | 
|---|
|  |  |  | [Route("Sc_ProcessMangement/SaveProcdutInBill_Batch")] | 
|---|
|  |  |  | [HttpPost] | 
|---|
|  |  |  | public object SaveProcdutInBill_Batch([FromBody] JObject msg) | 
|---|
|  |  |  | { | 
|---|
|  |  |  | var _value = msg["msg"].ToString(); | 
|---|
|  |  |  | string msg1 = _value.ToString(); | 
|---|
|  |  |  | string[] sArray = msg1.Split(new string[] { ";" }, StringSplitOptions.RemoveEmptyEntries); | 
|---|
|  |  |  | string BillNo = sArray[0].ToString(); | 
|---|
|  |  |  | BillNo = BillNo.Replace("\r\n", "").Replace("[ ", "").Replace("]", ""); | 
|---|
|  |  |  | BillNo = BillNo.Replace("\\", "").Replace("\n", "").Replace("\"", ""); | 
|---|
|  |  |  | BillNo = BillNo.Trim(); | 
|---|
|  |  |  | ArrayList BillNoArray = new ArrayList(BillNo.Split(',')); | 
|---|
|  |  |  |  | 
|---|
|  |  |  | try | 
|---|
|  |  |  | { | 
|---|
|  |  |  | string bResult; | 
|---|
|  |  |  | string HMessage = ""; | 
|---|
|  |  |  | string HSuccessBillNo = ""; | 
|---|
|  |  |  | string HFailBillNo = ""; | 
|---|
|  |  |  | WebAPI.Controllers.Sc_ProcessMangementController oBill = new WebAPI.Controllers.Sc_ProcessMangementController(); | 
|---|
|  |  |  |  | 
|---|
|  |  |  | for (int i = 0; i < BillNoArray.Count; i++) | 
|---|
|  |  |  | { | 
|---|
|  |  |  | bResult = JsonConvert.SerializeObject(oBill.SaveProcdutInBill(BillNoArray[i].ToString().Trim())); | 
|---|
|  |  |  |  | 
|---|
|  |  |  | //反序列化 | 
|---|
|  |  |  | bResult = "[" + bResult.ToString() + "]"; | 
|---|
|  |  |  |  | 
|---|
|  |  |  | List<JsonResult> list = Newtonsoft.Json.JsonConvert.DeserializeObject<List<JsonResult>>(bResult); | 
|---|
|  |  |  |  | 
|---|
|  |  |  | if (list[0].count == 1) | 
|---|
|  |  |  | { | 
|---|
|  |  |  | HSuccessBillNo = HSuccessBillNo + BillNoArray[i].ToString() + "," + "\r\n"; | 
|---|
|  |  |  | } | 
|---|
|  |  |  | else | 
|---|
|  |  |  | { | 
|---|
|  |  |  | HFailBillNo = HFailBillNo + BillNoArray[i].ToString() + ":" + list[0].Message + "," + "\r\n"; | 
|---|
|  |  |  | } | 
|---|
|  |  |  | HMessage = "入库成功单号:" + HSuccessBillNo + "\r\n" + "  入库失败单号:" + HFailBillNo; | 
|---|
|  |  |  | } | 
|---|
|  |  |  |  | 
|---|
|  |  |  |  | 
|---|
|  |  |  | objJsonResult.code = "1"; | 
|---|
|  |  |  | objJsonResult.count = 1; | 
|---|
|  |  |  | objJsonResult.Message = HMessage; | 
|---|
|  |  |  | objJsonResult.data = null; | 
|---|
|  |  |  | return objJsonResult; | 
|---|
|  |  |  |  | 
|---|
|  |  |  | } | 
|---|
|  |  |  | catch (Exception e) | 
|---|
|  |  |  | { | 
|---|
|  |  |  | 
|---|
|  |  |  | // | 
|---|
|  |  |  | //DataSet ds1 = oCN.RunProcReturn("select * from  h_v_TOERPProcduct_LastProc where HLastProc = '是' and  hbillno='" + BillNo.ToString() + "'", "h_v_TOERPProcduct_LastProc"); | 
|---|
|  |  |  | DataSet ds1 = oCN.RunProcReturn("exec h_p_TOERPProcduct_LastProc '" + BillNo + "'", "h_p_TOERPProcduct_LastProc"); | 
|---|
|  |  |  |  | 
|---|
|  |  |  | if (ds1 == null || ds1.Tables[0].Rows.Count == 0) | 
|---|
|  |  |  | { | 
|---|
|  |  |  | objJsonResult.code = "0"; | 
|---|
|  |  |  | objJsonResult.count = 0; | 
|---|
|  |  |  | objJsonResult.Message = "未找到对应的本地或金蝶云生产汇报单记录;1.未查询到对应的生产汇报单;2.请确保当前工序是末道工序3.汇报单对应的入库数量已满 请在金蝶云查看入库记录!"; | 
|---|
|  |  |  | objJsonResult.data = null; | 
|---|
|  |  |  | return objJsonResult; | 
|---|
|  |  |  | } | 
|---|
|  |  |  |  | 
|---|
|  |  |  | DataRow dr1 = ds1.Tables[0].Rows[0]; | 
|---|
|  |  |  | if (double.Parse(dr1[0].ToString()) <= 0) | 
|---|
|  |  |  | { | 
|---|
|  |  |  | 
|---|
|  |  |  | objJsonResult.data = null; | 
|---|
|  |  |  | return objJsonResult; | 
|---|
|  |  |  | } | 
|---|
|  |  |  |  | 
|---|
|  |  |  | //判断唯一ID是否为空 | 
|---|
|  |  |  | foreach (DataRow item in ds1.Tables[0].Rows) | 
|---|
|  |  |  | { | 
|---|
|  |  |  | if (item["HWYID"].ToString() == null || item["HWYID"].ToString() == "" || item["HWYID"].ToString() == "undefined") | 
|---|
|  |  |  | { | 
|---|
|  |  |  | objJsonResult.code = "0"; | 
|---|
|  |  |  | objJsonResult.count = 0; | 
|---|
|  |  |  | objJsonResult.Message = "唯一ID为空,请重新手动入库或联系管理员!"; | 
|---|
|  |  |  | objJsonResult.data = null; | 
|---|
|  |  |  | return objJsonResult; | 
|---|
|  |  |  | } | 
|---|
|  |  |  | } | 
|---|
|  |  |  | } | 
|---|
|  |  |  | } | 
|---|
|  |  |  |  | 
|---|
|  |  |  | 
|---|
|  |  |  | // | 
|---|
|  |  |  | //DataSet ds1 = oCN.RunProcReturn("select * from  h_v_TOERPProcduct_LastProc where HLastProc = '是' and  hbillno='" + BillNo.ToString() + "'", "h_v_TOERPProcduct_LastProc"); | 
|---|
|  |  |  | DataSet ds1 = oCN.RunProcReturn("exec h_p_TOERPProcduct_LastProc_BF '" + BillNo + "'", "h_p_TOERPProcduct_LastProc_BF"); | 
|---|
|  |  |  | if (ds1.Tables[0].Rows.Count == 0) | 
|---|
|  |  |  | { | 
|---|
|  |  |  | objJsonResult.code = "0"; | 
|---|
|  |  |  | objJsonResult.count = 0; | 
|---|
|  |  |  | objJsonResult.Message = "操作失败,查不到对应的出站单据!"; | 
|---|
|  |  |  | objJsonResult.data = null; | 
|---|
|  |  |  | return objJsonResult; | 
|---|
|  |  |  | } | 
|---|
|  |  |  | DataRow dr1 = ds1.Tables[0].Rows[0]; | 
|---|
|  |  |  |  | 
|---|
|  |  |  | JObject model = new JObject(); | 
|---|
|  |  |  | 
|---|
|  |  |  | FentityModel.Add("FSrcInterId", item["HSourceInterID"].ToString());// | 
|---|
|  |  |  | FentityModel.Add("FBasePrdRealQty", item["数量"].ToString());// | 
|---|
|  |  |  | FentityModel.Add("FIsFinished", "false");// | 
|---|
|  |  |  | FentityModel.Add("FStockStatusId", new JObject() { ["FNumber"] = "KCZT08_SYS" }); // | 
|---|
|  |  |  | FentityModel.Add("FStockStatusId", new JObject() { ["FNumber"] = "KCZT001" }); // | 
|---|
|  |  |  | FentityModel.Add("FSrcEntrySeq", item["HSourceSeQ"].ToString());//  源单分录行号 | 
|---|
|  |  |  | FentityModel.Add("FMOMAINENTRYID", item["HMOEntryID"].ToString());// | 
|---|
|  |  |  | FentityModel.Add("FKeeperTypeId", "BD_KeeperOrg"); | 
|---|
|  |  |  | 
|---|
|  |  |  | } | 
|---|
|  |  |  | #endregion | 
|---|
|  |  |  |  | 
|---|
|  |  |  |  | 
|---|
|  |  |  | #region 不良品处理单关闭/反关闭功能 | 
|---|
|  |  |  | [Route("Sc_ProcessMangement/CloseSc_ProcessMangement")] | 
|---|
|  |  |  | [HttpGet] | 
|---|
|  |  |  | public object CloseSc_ProcessMangement(string HInterID, int Type, string user) | 
|---|
|  |  |  | { | 
|---|
|  |  |  | try | 
|---|
|  |  |  | { | 
|---|
|  |  |  | //判断是否有删除权限 | 
|---|
|  |  |  | if (!DBUtility.ClsPub.Security_Log("QC_NoPassProdCheckBill_Close", 1, false, user)) | 
|---|
|  |  |  | { | 
|---|
|  |  |  | objJsonResult.code = "0"; | 
|---|
|  |  |  | objJsonResult.count = 0; | 
|---|
|  |  |  | objJsonResult.Message = "无权限关闭!"; | 
|---|
|  |  |  | objJsonResult.data = null; | 
|---|
|  |  |  | return objJsonResult; | 
|---|
|  |  |  | } | 
|---|
|  |  |  |  | 
|---|
|  |  |  | if (string.IsNullOrWhiteSpace(HInterID)) | 
|---|
|  |  |  | { | 
|---|
|  |  |  | objJsonResult.code = "0"; | 
|---|
|  |  |  | objJsonResult.count = 0; | 
|---|
|  |  |  | objJsonResult.Message = "HInterID为空!"; | 
|---|
|  |  |  | objJsonResult.data = null; | 
|---|
|  |  |  | return objJsonResult; | 
|---|
|  |  |  | } | 
|---|
|  |  |  |  | 
|---|
|  |  |  | ClsPub.CurUserName = user; | 
|---|
|  |  |  | BillOld.MvarItemKey = "QC_NoPassProdCheckBillMain"; | 
|---|
|  |  |  | oCN.BeginTran();//开始事务 | 
|---|
|  |  |  |  | 
|---|
|  |  |  | //Type 1 关闭  2  反关闭 | 
|---|
|  |  |  | if (Type == 1) | 
|---|
|  |  |  | { | 
|---|
|  |  |  | //判断单据是否已经关闭 | 
|---|
|  |  |  | DataSet ds; | 
|---|
|  |  |  | string sql = "select * from " + BillOld.MvarItemKey + " where HinterID = " + HInterID; | 
|---|
|  |  |  | ds = oCN.RunProcReturn(sql, BillOld.MvarItemKey); | 
|---|
|  |  |  | if (ds.Tables[0] != null && ds.Tables[0].Rows.Count > 0) | 
|---|
|  |  |  | { | 
|---|
|  |  |  | if (ds.Tables[0].Rows[0]["HCloseMan"] != null && ds.Tables[0].Rows[0]["HCloseMan"].ToString() != "") | 
|---|
|  |  |  | { | 
|---|
|  |  |  | objJsonResult.code = "0"; | 
|---|
|  |  |  | objJsonResult.count = 0; | 
|---|
|  |  |  | objJsonResult.Message = "单据已关闭!不需要再关闭!"; | 
|---|
|  |  |  | objJsonResult.data = null; | 
|---|
|  |  |  | return objJsonResult; | 
|---|
|  |  |  | } | 
|---|
|  |  |  | } | 
|---|
|  |  |  | //关闭单据 | 
|---|
|  |  |  | if (!BillOld.CloseBill(Int64.Parse(HInterID), ref ClsPub.sExeReturnInfo)) | 
|---|
|  |  |  | { | 
|---|
|  |  |  | objJsonResult.code = "0"; | 
|---|
|  |  |  | objJsonResult.count = 1; | 
|---|
|  |  |  | objJsonResult.Message = "关闭失败!原因:" + ClsPub.sExeReturnInfo; | 
|---|
|  |  |  | objJsonResult.data = null; | 
|---|
|  |  |  | return objJsonResult; | 
|---|
|  |  |  | } | 
|---|
|  |  |  | } | 
|---|
|  |  |  | else | 
|---|
|  |  |  | { | 
|---|
|  |  |  | //判断单据是否已经反关闭 | 
|---|
|  |  |  | DataSet ds; | 
|---|
|  |  |  | string sql = "select * from " + BillOld.MvarItemKey + " where HinterID = " + HInterID; | 
|---|
|  |  |  | ds = oCN.RunProcReturn(sql, BillOld.MvarItemKey); | 
|---|
|  |  |  | if (ds.Tables[0] != null && ds.Tables[0].Rows.Count > 0) | 
|---|
|  |  |  | { | 
|---|
|  |  |  | if (ds.Tables[0].Rows[0]["HCloseMan"] == null || ds.Tables[0].Rows[0]["HCloseMan"].ToString() == "") | 
|---|
|  |  |  | { | 
|---|
|  |  |  | objJsonResult.code = "0"; | 
|---|
|  |  |  | objJsonResult.count = 0; | 
|---|
|  |  |  | objJsonResult.Message = "单据已反关闭!不需要再反关闭!"; | 
|---|
|  |  |  | objJsonResult.data = null; | 
|---|
|  |  |  | return objJsonResult; | 
|---|
|  |  |  | } | 
|---|
|  |  |  | } | 
|---|
|  |  |  | //反关闭单据 | 
|---|
|  |  |  | if (!BillOld.CancelClose(Int64.Parse(HInterID), ref ClsPub.sExeReturnInfo)) | 
|---|
|  |  |  | { | 
|---|
|  |  |  | objJsonResult.code = "0"; | 
|---|
|  |  |  | objJsonResult.count = 1; | 
|---|
|  |  |  | objJsonResult.Message = "反关闭失败!原因:" + ClsPub.sExeReturnInfo; | 
|---|
|  |  |  | objJsonResult.data = null; | 
|---|
|  |  |  | return objJsonResult; | 
|---|
|  |  |  | } | 
|---|
|  |  |  | } | 
|---|
|  |  |  |  | 
|---|
|  |  |  | oCN.Commit();//提交事务 | 
|---|
|  |  |  |  | 
|---|
|  |  |  | objJsonResult.code = "0"; | 
|---|
|  |  |  | objJsonResult.count = 1; | 
|---|
|  |  |  | objJsonResult.Message = "执行成功!"; | 
|---|
|  |  |  | objJsonResult.data = null; | 
|---|
|  |  |  | return objJsonResult; ; | 
|---|
|  |  |  |  | 
|---|
|  |  |  | } | 
|---|
|  |  |  | catch (Exception e) | 
|---|
|  |  |  | { | 
|---|
|  |  |  | objJsonResult.code = "0"; | 
|---|
|  |  |  | objJsonResult.count = 0; | 
|---|
|  |  |  | objJsonResult.Message = "执行失败!" + e.ToString(); | 
|---|
|  |  |  | objJsonResult.data = null; | 
|---|
|  |  |  | return objJsonResult; | 
|---|
|  |  |  | } | 
|---|
|  |  |  | } | 
|---|
|  |  |  | #endregion | 
|---|
|  |  |  |  | 
|---|
|  |  |  |  | 
|---|
|  |  |  |  | 
|---|
|  |  |  | /// <summary> | 
|---|
|  |  |  | /// PDA工序汇报单保存 | 
|---|
|  |  |  | /// </summary> | 
|---|