1
duhe
2026-04-01 f7d9e845fa65d5d95ca22fff220da7a182544fb6
WebAPI/Controllers/SCGL/Sc_MESBeginWorkBillController.cs
@@ -465,7 +465,8 @@
        /// <returns></returns>
        [Route("Sc_MESBeginWorkBill/SaveGetMESBeginWorkFrom_KS")]
        [HttpGet]
        public object SaveGetMESBeginWorkFrom_KS(string HBillType,int HSourceInterID,int HSourceEntryID,string HSourceBillNo,string user,string HSourceBillType)
        public object SaveGetMESBeginWorkFrom_KS(string HBillType,int HSourceInterID,int HSourceEntryID,
            string HSourceBillNo,string user,string HSourceBillType)
        {
         
@@ -1618,7 +1619,8 @@
        #region 报工平台快捷开工
        [Route("Sc_MESBeginWorkBill/FastBeginWorkBill")]
        [HttpGet]
        public object FastBeginWorkBill(string HBillType, int HSourceInterID, int HSourceEntryID, string HSourceBillNo, string HSourceBillType,string user)
        public object FastBeginWorkBill(string HBillType, int HSourceInterID, int HSourceEntryID,
            string HSourceBillNo, string HSourceBillType,string user)
        {
@@ -1675,7 +1677,7 @@
                {
                    ClsSc_MESBeginWorkBillMain.HWorkShiftID = int.Parse(set.Tables[0].Rows[0]["HInterID"].ToString());
                }
                ds = oCN.RunProcReturn("select * from h_v_Cj_GetDefValByUser where 用户名称='" + user + "'", "h_v_xt_UserAssociationSelect");
                ds = oCN.RunProcReturn("select * from h_v_Cj_GetDefValByUser where 用户名称='" + user + "'", "h_v_Cj_GetDefValByUser");
                //if (ds.Tables[0].Rows[0]["HGroupID"].ToString() == "0")
                //{
@@ -1732,16 +1734,16 @@
                    bResult = oBill.AddBill(ref DBUtility.ClsPub.sExeReturnInfo);
                }
                //ds = oCN.RunProcReturn("select * from Sc_MESBeginWorkBillMain where HBillNo='" + oBill.omodel.HBillNo + "'", "Sc_MESBeginWorkBillMain");
                //if (ds.Tables[0].Rows.Count == 0)
                //{
                //    oCN.RollBack();
                //    objJsonResult.code = "0";
                //    objJsonResult.count = 0;
                //    objJsonResult.Message = "查无单据!";
                //    objJsonResult.data = 1;
                //    return objJsonResult;
                //}
                ds = oCN.RunProcReturn("select * from Sc_MESBeginWorkBillMain where HBillNo='" + oBill.omodel.HBillNo + "'", "Sc_MESBeginWorkBillMain");
                if (ds.Tables[0].Rows.Count == 0)
                {
                    oCN.RollBack();
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
                    objJsonResult.Message = "查无单据!";
                    objJsonResult.data = 1;
                    return objJsonResult;
                }
                string sAutoCheck = oClsXt_SystemParameter.GetSingleSystemParameter("Sc_MESBeginWorkBill_AutoCheck", ref DBUtility.ClsPub.sExeReturnInfo);
                if (sAutoCheck == "Y")