1
duhe
2023-11-28 6773d107b6d63e8db137e415035a5c14d6b9ba89
1
11个文件已修改
352 ■■■■ 已修改文件
Model/MES/ClsSc_SourceLineRepairBillMain.cs 3 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
WebAPI/Controllers/BLL/Xt_UserController.cs 12 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
WebAPI/Controllers/CJGL/Cj_SingleStationController.cs 160 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
WebAPI/Controllers/MateOutController.cs 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
WebAPI/Controllers/SBGL/Sb_EquipDotCheckPlanBillController.cs 41 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
WebAPI/Controllers/SBGL/Sb_EquipDotCheckRuleBillController.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
WebAPI/Controllers/SBGL/Sb_EquipMaintainPlanBillController.cs 41 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
WebAPI/Controllers/品质管理/工序检验单/QC_ProcessCheckBillController.cs 52 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
WebAPI/Controllers/品质管理/首件检验单/QC_FirstPieceCheckBillController.cs 31 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
WebAPI/Models/Gy_User.cs 3 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
WebAPI/Web.config 6 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Model/MES/ClsSc_SourceLineRepairBillMain.cs
@@ -35,6 +35,9 @@
        public string HMainSourceBillType;
        public Int64 HMainSourceInterID;
        public Int64 HMainSourceEntryID;
        public Int64 HProcExchInterID;
        public Int64 HProcExchEntryID;
        public string HProcExchBillNo;
        public string HMainSourceBillNo;
        public int HPrintQty;
        public int HItemMainID;
WebAPI/Controllers/BLL/Xt_UserController.cs
@@ -202,13 +202,15 @@
                    ",HSellManID,HSellMan,HDeptID,HDept " +
                    ",HWhID,HWHName,HSupID,HSupName " +
                    ",HSCWHID,HSCWHName " +
                    ",HCloudUserName,HCloudUserPsd,HUSEORGID) " +
                    ",HCloudUserName,HCloudUserPsd,HUSEORGID,HProcID" +
                    ",HGroupID,HSourceID) " +
                    "values ('" + lsmain[0].Czybm.ToString() + "','" + lsmain[0].Czymc.ToString() + "','" + ClsPub.StrToPsd(lsmain[0].Czmm.ToString()) + "','" + lsmain[0].Explain.ToString() + "','" + lsmain[0].HEmpID.ToString() + "',"+ lsmain[0].HK3UserID.ToString() + "" +
                    ","+ lsmain[0].HKeeperID.ToString() + ",'"+ lsmain[0].HKeeper.ToString() + "',"+ lsmain[0].HSecManagerID.ToString() + ",'"+ lsmain[0].HSecManager.ToString() + "'" +
                    "," + lsmain[0].HSellManID.ToString() + ",'" + lsmain[0].HSellMan.ToString() + "'," + lsmain[0].HDeptID.ToString() + ",'" + lsmain[0].HDept.ToString() + "'" +
                    "," + lsmain[0].HWhID.ToString() + ",'" + lsmain[0].HWHName.ToString() + "'," + lsmain[0].HSupID.ToString() + ",'" + lsmain[0].HSupName.ToString() + "'" +
                    "," + lsmain[0].HSCWHID.ToString() + ",'" + lsmain[0].HSCWHName.ToString() + "'" + 
                    ",'" + lsmain[0].HCloudUserName.ToString() + "','" + lsmain[0].HCloudUserPsd.ToString() + "',"+ lsmain[0].HOrgID.ToString() + ")");
                    ",'" + lsmain[0].HCloudUserName.ToString() + "','" + lsmain[0].HCloudUserPsd.ToString() + "',"+ lsmain[0].HOrgID.ToString() + "," + lsmain[0].HProcID.ToString() + "" +
                    ","+ lsmain[0].HGroupID.ToString() + ","+ lsmain[0].HSourceID.ToString() + ")");
                    //新增后查询  ç¡®ä¿æ•°æ®æ·»åŠ æˆåŠŸ
                    ds = oCN.RunProcReturn("Select * from  Gy_Czygl where Czybm='" + lsmain[0].Czybm.ToString() + "'", "Gy_Czygl");
@@ -255,6 +257,9 @@
                        ",HSCWHID=" + lsmain[0].HSCWHID.ToString() +
                        ",HSCWHName='" + lsmain[0].HSCWHName.ToString() + "'" +
                        ",HSupID=" + lsmain[0].HSupID.ToString() +
                        ",HProcID=" + lsmain[0].HProcID.ToString() +
                        ",HSourceID=" + lsmain[0].HSourceID.ToString() +
                        ",HGroupID=" + lsmain[0].HGroupID.ToString() +
                        ",HSupName='" + lsmain[0].HSupName.ToString() + "'" +
                        ",HCloudUserName='" + lsmain[0].HCloudUserName.ToString() + "'" +
                        ",HCloudUserPsd='" + lsmain[0].HCloudUserPsd.ToString() + "'" +
@@ -280,6 +285,9 @@
                           ",HSCWHID=" + lsmain[0].HSCWHID.ToString() +
                           ",HSCWHName='" + lsmain[0].HSCWHName.ToString() + "'" +
                           ",HSupID=" + lsmain[0].HSupID.ToString() +
                            ",HProcID=" + lsmain[0].HProcID.ToString() +
                           ",HSourceID=" + lsmain[0].HSourceID.ToString() +
                           ",HGroupID=" + lsmain[0].HGroupID.ToString() +
                           ",HSupName='" + lsmain[0].HSupName.ToString() + "'" +
                           ",HCloudUserName='" + lsmain[0].HCloudUserName.ToString() + "'" +
                           ",HCloudUserPsd='" + lsmain[0].HCloudUserPsd.ToString() + "'" +
WebAPI/Controllers/CJGL/Cj_SingleStationController.cs
@@ -320,15 +320,29 @@
                }
                ds = oCN.RunProcReturn("select * from gy_czygl where czymc='" + user + "'", "gy_czygl");
                string HProcID = ds.Tables[0].Rows[0]["HProcID"].ToString();
                ds = oCN.RunProcReturn(@"exec h_p_Gy_BarCodeBillBomList '" + HBarCode + "'," + ds.Tables[0].Rows[0]["HProcID"].ToString(), "h_p_Gy_BarCodeBillBomList");
                ds = oCN.RunProcReturn(@"exec h_p_Gy_BarCodeBillBomList '" + HBarCode + "'," + HProcID, "h_p_Gy_BarCodeBillBomList");
                if (ds.Tables[0].Rows.Count == 0)
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
                    objJsonResult.Message = "配件清单查无数据!";
                    objJsonResult.data = null;
                    return objJsonResult;
                    DataSet dataSet = oCN.RunProcReturn(@"exec h_p_Sc_ProcessExchangeBillList '" + HBarCode + "'," + HProcID, "h_p_Sc_ProcessExchangeBillList");
                    if (dataSet.Tables[0].Rows.Count > 0)
                    {
                        objJsonResult.code = "2";
                        objJsonResult.count = 2;
                        objJsonResult.Message = "";
                        objJsonResult.data = dataSet.Tables[0];
                        return objJsonResult;
                    }
                    else
                    {
                        objJsonResult.code = "0";
                        objJsonResult.count = 0;
                        objJsonResult.Message = "配件清单查无数据!,可能是当前用户工序不正确或者流转卡输入错误!";
                        objJsonResult.data = null;
                        return objJsonResult;
                    }
                }
                else
                {
@@ -387,7 +401,7 @@
                if (tempList.Count == 0) {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
                    objJsonResult.Message = "无数据!";
                    objJsonResult.Message = "无配件数据!";
                    objJsonResult.data = null;
                    return objJsonResult;
                }
@@ -460,7 +474,7 @@
                sub = JsonConvert.DeserializeObject<List<Model.ClsSc_AssemblyBillSub>>(sSubStr);
                ds = oCN.RunProcReturn("select  * from h_v_Gy_QualifiedRecordsList where äº§å“æ¡ç ='" + omodel.HBarCode_P + "'", "h_v_Gy_QualifiedRecordsList");
                ds = oCN.RunProcReturn("select  * from h_v_Gy_QualifiedRecordsList 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)
                {
                    objJsonResult.code = "0";
@@ -1042,6 +1056,8 @@
                //反写工序出站单的不良数量
                oCN.RunProc("update Sc_StationOutBillMain set HBadCount-=1  where HProcExchInterID='" + HProcExchInterID + "' and HProcExchEntryID=" + HProcExchEntryID);
                //反写流转卡状态
                oCN.RunProc("update Gy_BarCodeBill set HStatus=''  where HBarCode='" + HBarCode + "'");
                oCN.Commit();
@@ -1165,7 +1181,15 @@
                    return objJsonResult;
                }
                if (ds.Tables[0].Rows[0]["HProcID"].ToString() != HProcID)
                int num = 0;
                for (int i = 0; i < ds.Tables[0].Rows.Count; i++)
                {
                    if (ds.Tables[0].Rows[i]["HProcID"].ToString() == HProcID)
                    {
                        num = 1;
                    }
                }
                if (num == 0)
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
@@ -1341,25 +1365,6 @@
({model.HInterID},{(ds.Tables[0].Rows.Count == 0 ? 1 : int.Parse(ds.Tables[0].Rows[0]["HEntryID"].ToString()) + 1)},'{model.HBillNo}','',{temp.HProcExchInterID}
,{temp.HProcExchEntryID},'{temp.HProcExchBillNo}','',{temp.HMaterID},0,'{temp.HBarCode}','{temp.HBatchNo}')");
                    ds = oCN.RunProcReturn("select  * from Sc_SourceLineRepairBillSub where HInterID=" + model.HInterID, "Sc_SourceLineRepairBillSub");
                    if (ds.Tables[0].Rows[0]["HRepairResult"].ToString() == "OK") {
                        //生产工序出站SN数据
                        ds = oCN.RunProcReturn("select top 1  HInterID,HBillNo from Sc_StationOutBillMain where HProcExchInterID=" + temp.HProcExchInterID + " and HProcExchEntryID=" + temp.HProcExchEntryID + " and HBadCount<>0  order by  HInterID desc", "Sc_StationOutBillMain");
                        string HInterIDSN = ds.Tables[0].Rows[0]["HInterID"].ToString();
                        string HBillNoSN = ds.Tables[0].Rows[0]["HBillNo"].ToString();
                        ds = oCN.RunProcReturn("select *  from Sc_StationOutBillSub_SN where HInterID=" + HInterIDSN , "Sc_StationOutBillSub_SN");
                        oCN.RunProc($@"insert into Sc_StationOutBillSub_SN(HInterID,HBillNo_bak,HEntryID,HBarCode,HBarCodeQty,HMakeTime,HRemark,HSourceInterID,HSourceEntryID,HSourceBillNo,HSourceBillType,HRelationQty,HRelationMoney)
values({HInterIDSN}, '{HBillNoSN}', {ds.Tables[0].Rows.Count + 1}, '{model.HBarCode}', 1, GETDATE(), '', "+ temp.HProcExchInterID + ","+ temp.HProcExchEntryID+ ", '"+ temp.HProcExchBillNo+ "', '', 0, 0)");
                        //反写工序出站单 ä¸»è¡¨ ä¸è‰¯æ•°é‡ å’Œ åˆæ ¼æ•°é‡
                        oCN.RunProc("update Sc_StationOutBillMain set HQty+=1,HBadCount-=1  where HInterID='" + HInterIDSN + "'");
                    }
                    //修改产线追溯单绑定的条码批号
                    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 + "'");
@@ -1387,6 +1392,25 @@
                    if (HResult == "OK")
                    {
                        ds = oCN.RunProcReturn("select  * from Sc_SourceLineRepairBillSub where HInterID=" + model.HInterID, "Sc_SourceLineRepairBillSub");
                        if (ds.Tables[0].Rows[0]["HRepairResult"].ToString() == "OK")
                        {
                            //生产工序出站SN数据
                            ds = oCN.RunProcReturn("select top 1  HInterID,HBillNo from Sc_StationOutBillMain where HProcExchInterID=" + model.HProcExchInterID + " and HProcExchEntryID=" + model.HProcExchEntryID + " and HBadCount<>0  order by  HInterID desc", "Sc_StationOutBillMain");
                            string HInterIDSN = ds.Tables[0].Rows[0]["HInterID"].ToString();
                            string HBillNoSN = ds.Tables[0].Rows[0]["HBillNo"].ToString();
                            ds = oCN.RunProcReturn("select *  from Sc_StationOutBillSub_SN where HInterID=" + HInterIDSN, "Sc_StationOutBillSub_SN");
                            oCN.RunProc($@"insert into Sc_StationOutBillSub_SN(HInterID,HBillNo_bak,HEntryID,HBarCode,HBarCodeQty,HMakeTime,HRemark,HSourceInterID,HSourceEntryID,HSourceBillNo,HSourceBillType,HRelationQty,HRelationMoney)
values({HInterIDSN}, '{HBillNoSN}', {ds.Tables[0].Rows.Count + 1}, '{model.HBarCode}', 1, GETDATE(), '', " + model.HProcExchInterID + "," + model.HProcExchEntryID + ", '" + model.HProcExchBillNo + "', '', 0, 0)");
                            //反写工序出站单 ä¸»è¡¨ ä¸è‰¯æ•°é‡ å’Œ åˆæ ¼æ•°é‡
                            oCN.RunProc("update Sc_StationOutBillMain set HQty+=1,HBadCount-=1  where HInterID='" + HInterIDSN + "'");
                        }
                        oCN.RunProc("update Gy_BarCodeBill set HStatus='' where HBarCode='" + model.HBarCode + "'");
                    }
                }
@@ -1577,5 +1601,85 @@
        }
        #endregion
        #region å·¥åºå•品过站 åˆæ ¼è¿½æº¯æŸ¥è¯¢æŠ¥è¡¨
        [Route("Cj_SingleStation/RetrospectiveQueryReport")]
        [HttpGet]
        public object RetrospectiveQueryReport(string HBardCode, string HProcExchBillNo, string HICMOBillNo, string sWhere, string user)
        {
            try
            {
                List<object> columnNameList = new List<object>();
                string sql = @"exec  h_p_RetrospectiveQueryReport '" + sWhere + "', '" + HBardCode + "', '" + HProcExchBillNo + "','" + HICMOBillNo + "' ";
                ds = oCN.RunProcReturn(sql, "h_p_RetrospectiveQueryReport");
                //添加列名
                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));//获取到DataColumn列对象的列名
                }
                objJsonResult.code = "1";
                objJsonResult.count = 1;
                objJsonResult.Message = "Sucess!";
                objJsonResult.data = ds.Tables[0];
                objJsonResult.list = columnNameList;
                return objJsonResult;
            }
            catch (Exception e)
            {
                oCN.RollBack();
                objJsonResult.code = "0";
                objJsonResult.count = 0;
                objJsonResult.Message = "Exception!" + e.ToString();
                objJsonResult.data = null;
                return objJsonResult;
            }
        }
        #endregion
        #region å·¥åºå•品过站 ä¸è‰¯è¿½æº¯æŸ¥è¯¢æŠ¥è¡¨
        [Route("Cj_SingleStation/BadQueryReport")]
        [HttpGet]
        public object BadQueryReport(string HBardCode, string HProcExchBillNo, string HICMOBillNo, string sWhere, string user)
        {
            try
            {
                List<object> columnNameList = new List<object>();
                string sql = @"exec  h_p_BadQueryReport '" + sWhere + "', '" + HBardCode + "', '" + HProcExchBillNo + "','" + HICMOBillNo + "' ";
                ds = oCN.RunProcReturn(sql, "h_p_BadQueryReport");
                //添加列名
                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));//获取到DataColumn列对象的列名
                }
                objJsonResult.code = "1";
                objJsonResult.count = 1;
                objJsonResult.Message = "Sucess!";
                objJsonResult.data = ds.Tables[0];
                objJsonResult.list = columnNameList;
                return objJsonResult;
            }
            catch (Exception e)
            {
                oCN.RollBack();
                objJsonResult.code = "0";
                objJsonResult.count = 0;
                objJsonResult.Message = "Exception!" + e.ToString();
                objJsonResult.data = null;
                return objJsonResult;
            }
        }
        #endregion
    }
}
WebAPI/Controllers/MateOutController.cs
@@ -2075,6 +2075,7 @@
            public string HCustomerName { get; set; }
            public string HProductName { get; set; }
            public string HOtherSearch { get; set; }
            public string HEmpName { get; set; }
        }
        [Route("MaterOutEntryReport/SC_DayRkReport")]
        [HttpGet]
WebAPI/Controllers/SBGL/Sb_EquipDotCheckPlanBillController.cs
@@ -355,6 +355,45 @@
        }
        #endregion
        #region[设备点检计划表编辑时获取表体数据--点检计划]
        [Route("Sb_EquipDotCheckPlanBill/GetPlanList")]
        [HttpGet]
        public object GetPlanList(string sqlWhere)
        {
            DataSet ds;
            try
            {
                SQLHelper.ClsCN oCN = new SQLHelper.ClsCN();
                if (sqlWhere == null || sqlWhere.Equals(""))
                {
                    ds = oCN.RunProcReturn("select * from h_v_Sb_EquipDotCheckPlanList", "h_v_Sb_EquipDotCheckPlanList");
                    objJsonResult.code = "0";
                    objJsonResult.count = 1;
                    objJsonResult.Message = "获取信息成功!";
                    objJsonResult.data = ds.Tables[0];
                }
                else
                {
                    string sql1 = "select * from h_v_Sb_EquipDotCheckPlanList where 1 = 1 ";
                    string sql = sql1 + sqlWhere;
                    ds = oCN.RunProcReturn(sql, "h_v_Sb_EquipDotCheckPlanList");
                    objJsonResult.code = "0";
                    objJsonResult.count = 1;
                    objJsonResult.Message = "获取信息成功!";
                    objJsonResult.data = ds.Tables[0];
                }
            }
            catch (Exception e)
            {
                objJsonResult.code = "0";
                objJsonResult.count = 0;
                objJsonResult.Message = "没有返回任何计划!" + e.ToString();
                objJsonResult.data = null;
            }
            return objJsonResult;
        }
        #endregion
        #region è®¾å¤‡ç‚¹æ£€è®¡åˆ’单审核/反审核功能
        [Route("Sb_EquipDotCheckPlanBill/CheckSb_EquipDotCheckPlanBill")]
        [HttpGet]
@@ -395,6 +434,8 @@
                        objJsonResult.data = null;
                        return objJsonResult;
                    }
                    //自动生成点检计划单
                    oCN.RunProc("exec h_p_Sb_EquipDotCheckPlan_Auto " + HInterID);
                }
                else
                {
WebAPI/Controllers/SBGL/Sb_EquipDotCheckRuleBillController.cs
@@ -175,7 +175,7 @@
            {
                SQLHelper.ClsCN oCN = new SQLHelper.ClsCN();
                string sql1 = @"select ç‚¹æ£€é¡¹ç›®ID HDotCheckItemID,点检项目 HDotCheckItem,点检部位 HDotCheckPart,具体要求 HClaim,负责人ID HManagerID,负责人代码 HManagerNumber,负责人 HManagerName,子备注 HRemark,b.HNumber ç‚¹æ£€é¡¹ç›®ä»£ç   from h_v_Sb_EquipDotCheckRuleList a
                string sql1 = @"select  *  from h_v_Sb_EquipDotCheckRuleList a
                        left join Gy_QCCheckItem b  on a.点检项目ID =b.HItemID where 1 = 1 ";
                string sql = sql1 + sqlWhere;
                ds = oCN.RunProcReturn(sql, "h_v_Sb_EquipDotCheckRuleList");
WebAPI/Controllers/SBGL/Sb_EquipMaintainPlanBillController.cs
@@ -413,6 +413,45 @@
        }
        #endregion
        #region[设备保养计划表编辑时获取表体数据--保养计划]
        [Route("Sb_EquipMaintainPlanBill/GetPlanList")]
        [HttpGet]
        public object GetPlanList(string sqlWhere)
        {
            DataSet ds;
            try
            {
                SQLHelper.ClsCN oCN = new SQLHelper.ClsCN();
                if (sqlWhere == null || sqlWhere.Equals(""))
                {
                    ds = oCN.RunProcReturn("select * from h_v_Sb_EquipMaintainPlanList", "h_v_Sb_EquipMaintainPlanList");
                    objJsonResult.code = "0";
                    objJsonResult.count = 1;
                    objJsonResult.Message = "获取信息成功!";
                    objJsonResult.data = ds.Tables[0];
                }
                else
                {
                    string sql1 = "select * from h_v_Sb_EquipMaintainPlanList where 1 = 1 ";
                    string sql = sql1 + sqlWhere;
                    ds = oCN.RunProcReturn(sql, "h_v_Sb_EquipMaintainPlanList");
                    objJsonResult.code = "0";
                    objJsonResult.count = 1;
                    objJsonResult.Message = "获取信息成功!";
                    objJsonResult.data = ds.Tables[0];
                }
            }
            catch (Exception e)
            {
                objJsonResult.code = "0";
                objJsonResult.count = 0;
                objJsonResult.Message = "没有返回任何计划!" + e.ToString();
                objJsonResult.data = null;
            }
            return objJsonResult;
        }
        #endregion
        #region è®¾å¤‡ä¿å…»è®¡åˆ’单审核/反审核功能
        [Route("Sb_EquipMaintainPlanBill/CheckSb_EquipMaintainPlanBill")]
        [HttpGet]
@@ -453,6 +492,8 @@
                        objJsonResult.data = null;
                        return objJsonResult;
                    }
                    //自动生成点检计划单
                    oCN.RunProc("exec h_p_Sb_EquipMaintainPlan_Auto " + HInterID);
                }
                else
                {
WebAPI/Controllers/Æ·ÖʹÜÀí/¹¤Ðò¼ìÑéµ¥/QC_ProcessCheckBillController.cs
@@ -744,18 +744,55 @@
        {
            try
            {
                if (HInterID == 0 || HBillType.Equals(""))
                List<object> columnNameList = new List<object>();
                string sReturn = "";
                string sql = "";
                if (oSystemParameter.ShowBill(ref sReturn))
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
                    objJsonResult.Message = "参数不全,获取源单信息失败!HInterID:" + HInterID + ";HEntryID:" + HEntryID + ";HBillType:" + HBillType + ";";
                    objJsonResult.data = null;
                    return objJsonResult;
                    switch (oSystemParameter.omodel.QC_ProcessCheckBill_QCSchemeSource)
                    {
                        case "工序":
                            sql = "exec h_p_QC_GetInfoByICMOStatusBill " + "'工序'," + HInterID + "," + HEntryID + "," + HBillType;
                            break;
                        case "物料":
                            sql = "exec h_p_QC_GetInfoByICMOStatusBill " + "'物料'," + HInterID  + "," + HEntryID + "," + HBillType;
                            break;
                        case "工艺路线":
                            sql = "exec h_p_QC_GetInfoByICMOStatusBill " + "'工艺路线'," + HInterID + "," + HEntryID + "," + HBillType;
                            break;
                    }
                }
                ds = oCN.RunProcReturn(sql, "h_p_QC_GetInfoByICMOStatusBill");
                if (ds == null || ds.Tables[0].Rows.Count == 0)
                {
                }
                else
                {
                    ds = oCN.RunProcReturn("exec h_p_QC_GetInfoByICMOStatusBill " + HInterID + "," + HEntryID + "," + HBillType, "h_p_QC_GetInfoByICMOStatusBill");
                    //添加列名
                    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));//获取到DataColumn列对象的列名
                    }
                }
                //if (HInterID == 0 || HBillType.Equals(""))
                //{
                //    objJsonResult.code = "0";
                //    objJsonResult.count = 0;
                //    objJsonResult.Message = "参数不全,获取源单信息失败!HInterID:" + HInterID + ";HEntryID:" + HEntryID + ";HBillType:" + HBillType + ";";
                //    objJsonResult.data = null;
                //    return objJsonResult;
                //}
                //else
                //{
                //    ds = oCN.RunProcReturn("exec h_p_QC_GetInfoByICMOStatusBill " + HInterID + "," + HEntryID + "," + HBillType, "h_p_QC_GetInfoByICMOStatusBill");
                //}
                if (ds == null || ds.Tables[0].Rows.Count == 0)
                {
                    objJsonResult.code = "0";
@@ -770,6 +807,7 @@
                    objJsonResult.count = 1;
                    objJsonResult.Message = "返回记录成功!";
                    objJsonResult.data = ds.Tables[0];
                    objJsonResult.list = columnNameList;
                    return objJsonResult;
                }
            }
WebAPI/Controllers/Æ·ÖʹÜÀí/Ê×¼þ¼ìÑéµ¥/QC_FirstPieceCheckBillController.cs
@@ -500,6 +500,8 @@
        {
            try
            {
                List<object> columnNameList = new List<object>();
                if (HInterID == 0 || HBillType.Equals(""))
                {
                    objJsonResult.code = "0";
@@ -508,15 +510,37 @@
                    objJsonResult.data = null;
                    return objJsonResult;
                }
                else
                string sReturn = "";
                string sql = "";
                if (oSystemParameter.ShowBill(ref sReturn))
                {
                    ds = oCN.RunProcReturn("exec h_p_QC_GetInfoByICMOStatusBill " + HInterID + "," + HEntryID + "," + HBillType, "h_p_QC_GetInfoByICMOStatusBill");
                    switch (oSystemParameter.omodel.QC_FirstPieceCheckBill_QCSchemeSource)
                    {
                        case "物料":
                            sql = "exec h_p_QC_GetInfoByICMOStatusBill " + "'物料'" + "," + HInterID + "," + HEntryID + "," + HBillType;
                            break;
                    }
                }
                ds = oCN.RunProcReturn(sql, "h_p_QC_GetInfoByICMOStatusBill");
                //添加列名
                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));//获取到DataColumn列对象的列名
                }
                if (ds == null || ds.Tables[0].Rows.Count == 0)
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
                    objJsonResult.Message = "查询数据异常,请与管理员联系!";
                    objJsonResult.Message = "没查询到数据!";
                    objJsonResult.data = null;
                    return objJsonResult;
                }
@@ -526,6 +550,7 @@
                    objJsonResult.count = 1;
                    objJsonResult.Message = "返回记录成功!";
                    objJsonResult.data = ds.Tables[0];
                    objJsonResult.list = columnNameList;
                    return objJsonResult;
                }
            }
WebAPI/Models/Gy_User.cs
@@ -31,5 +31,8 @@
        public string HSCWHName;
        public int HSupID;
        public string HSupName;
        public int HProcID;
        public int HGroupID;
        public int HSourceID;
    }
}
WebAPI/Web.config
@@ -35,6 +35,8 @@
        <!--<add key="sUrl" value="http://47.96.97.237/WEBS-WMS/WebService1.asmx"/> -->    <!--测试服务器-->
        <!--<add key="sUrl" value="http://localhost:8082/WEBS/WebService1.asmx"/>    æœ¬åœ°-->
        <!--<add key="sUrl" value="http://192.168.56.1:81/web/WebService1.asmx"/>-->    <!--陈雯静本地配置-->
        <add key="sUrl" value="http://192.168.1.57:8082/WEBS-WMS/WebService1.asmx"/><!--九菱-->
        <add key="webpages:Version" value="3.0.0.0" />
        <add key="webpages:Enabled" value="false" />
        <add key="ClientValidationEnabled" value="true" />
@@ -101,7 +103,7 @@
            </basicHttpBinding>
        </bindings>
        <client>
            <endpoint address="http://192.168.63.20/WEBS-WMS/WebService1.asmx" binding="basicHttpBinding"
            <endpoint address="http://192.168.1.57:8082/WEBS-WMS/WebService1.asmx" binding="basicHttpBinding"
     bindingConfiguration="WebService1Soap" contract="Webs1.WebService1Soap"
     name="WebService1Soap" />
        </client>
@@ -110,7 +112,7 @@
 <applicationSettings>
  <WebAPI.Properties.Settings>
   <setting name="WebAPI_WebS_WebService1" serializeAs="String">
    <value>http://192.168.63.20/WEBS-WMS/WebService1.asmx</value>
    <value>http://192.168.1.57:8082/WEBS-WMS/WebService1.asmx</value>
   </setting>
  </WebAPI.Properties.Settings>
 </applicationSettings>