wtt
10 小时以前 6daa91098fe4a1a9109f460ace857b9c341de4a9
WebAPI/Controllers/CJGL/Cj_SingleStationController.cs
@@ -171,6 +171,7 @@
                long HMainSourceEntryID = mainList[0].HICMOEntryID;
                string HMainSourceBillNo = mainList[0].HICMOBillNo;
                //判断生产质量汇报单是否存在
                ds = oCN.RunProcReturn("select * from Sc_QualityReportBillMain WITH(NOLOCK) where HInterID=" + HInterID + " and HBillNo='" + HBillNo + "'", "Sc_QualityReportBillMain");
                if (ds.Tables[0].Rows.Count != 0) {
                    objJsonResult.code = "0";
@@ -544,7 +545,7 @@
                List<Model.ClsSc_AssemblyBillSub> sub = new List<Model.ClsSc_AssemblyBillSub>();
                sub = JsonConvert.DeserializeObject<List<Model.ClsSc_AssemblyBillSub>>(sSubStr);
                //条码上道工序是否过站
                ds = oCN.RunProcReturn("exec h_p_Sc_SNBarcodeProcCtrl_S '" + omodel.HBarCode_P + "'," + omodel.HProcID, "h_v_Gy_QualifiedRecordsList");
                if (ClsPub.isInt(ds.Tables[0].Rows.Count) == 0)
                {
@@ -563,6 +564,7 @@
                    return objJsonResult;
                }
                //判断条码是否已经出站
                ds = oCN.RunProcReturn("select  * from h_v_Gy_QualifiedRecordsList WITH(NOLOCK) where 产品条码='" + omodel.HBarCode_P + "' and HProcExchInterID="+ omodel .HProcExchInterID+ " and HProcExchEntryID="+ omodel.HProcExchEntryID + " and HProcID="+ omodel.HProcID, "h_v_Gy_QualifiedRecordsList");
                if (ds.Tables[0].Rows.Count > 0)
@@ -705,11 +707,13 @@
                int HTemporaryAreaID = 0;//暂放区
                int HShiftsID = 0;
                //获取当前班次
                DataSet set = oCN.RunProcReturn("exec h_p_Gy_GetWorkShiftInfo " + HDeptID + "," + HCenterID, "h_p_Gy_GetWorkShiftInfo");
                if (set.Tables[0].Rows.Count > 0)
                {
                    HShiftsID = int.Parse(set.Tables[0].Rows[0]["HInterID"].ToString());
                }
                //判断当天当前的流转卡是否有出站单
                ds = oCN.RunProcReturn("select  * from Sc_StationOutBillMain a WITH(NOLOCK) left join  Sc_StationOutBillSub_SN sn WITH(NOLOCK) on a.HInterID=sn.HInterID where a.HInterID=" + HInterID + " and HBillNo='" + HBillNo + "' and CONVERT(varchar(10),HDate,20) ='" + DateTime.Now.ToString("yyyy-MM-dd") + "' ", "Sc_StationOutBillMain");
                if (ds.Tables[0].Rows.Count == 0)
@@ -1164,6 +1168,7 @@
                ds = oCN.RunProcReturn("select * from gy_czygl WITH(NOLOCK) where czymc='" + user + "'", "gy_czygl");
                string HProcID = ds.Tables[0].Rows[0]["HProcID"].ToString();
                //查询流转卡所有工序信息
                ds = oCN.RunProcReturn(@"select * from h_v_Gy_BarCodeBillHICOMProcessExchange WITH(NOLOCK) where 条码='" + HBarCode + "' ", "h_v_Gy_BarCodeBillHICOMProcessExchange");
                if (ds.Tables[0].Rows.Count == 0)
@@ -1638,7 +1643,7 @@
                    Model.Sc_AssemblyBill_BindSourceTemp temp = new Model.Sc_AssemblyBill_BindSourceTemp();
                    temp = JsonConvert.DeserializeObject<Model.Sc_AssemblyBill_BindSourceTemp>(sSubStr);
                    //工序返修记录单 配件表
                    ds = oCN.RunProcReturn("select * from Sc_SourceLineRepairBillSub_Mater where HInterID=" + model.HInterID+ " order by HEntryID  desc", "Sc_SourceLineRepairBillSub_Mater");
                    oCN.RunProc($@"insert into Sc_SourceLineRepairBillSub_Mater
@@ -1652,7 +1657,7 @@
                    oCN.RunProc("update Sc_AssemblyBillSub set HBarCode='" + temp.HBarCode + "' where HInterID=" + temp.HInterID + " and HEntryID=" + temp.HEntryID);
                    //oCN.RunProc("exec h_p_AssemblyBill_Temp '" + temp.HProcExchBillNo + "'," + model.HProcess + "," + temp.HMaterID + ",'" + temp.HBatchNo + "'");
                }
                else if (HResult == "NG"|| HResult == "OK") {
                else if (HResult == "NG"|| HResult == "OK") {
                    Model.ClsSc_SourceLineRepairBillMain model = new Model.ClsSc_SourceLineRepairBillMain();
                    model = JsonConvert.DeserializeObject<Model.ClsSc_SourceLineRepairBillMain>(sMainStr);
@@ -2164,6 +2169,7 @@
                List<object> columnNameList = new List<object>();
                //查询配件清单信息
                string sql = @"exec h_p_GZ_BarCodeBillList '" + HMaterNumber + "','" + HBatchNo + "','" + sWhere + "'";
                ds = oCN.RunProcReturn(sql, "h_p_GZ_BarCodeBillList");