wtt
2024-09-29 0af01498dc2ba8002149f3d5c19c5bc7823adf00
tk 工艺路线工价,多级审批添加
2个文件已添加
9个文件已修改
1965 ■■■■■ 已修改文件
DAL/计划管理/ClsGy_RoutingBill.cs 4 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
WebAPI/Controllers/JHGL/Gy_RoutingBillController.cs 652 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
WebAPI/Controllers/基础资料/基础资料/Gy_ProcMulController.cs 537 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
WebAPI/Controllers/工资管理/Pay_ProcPriceRequestBillController.cs 626 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
WebAPI/DLL/ClsGy_ProcMul_Ctl.cs 102 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
WebAPI/Properties/PublishProfiles/FolderProfilewtt.pubxml.user 42 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
WebAPI/WebAPI.csproj 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
sdk_dingding/TopSdk/bin/Debug/TopSdk.dll 补丁 | 查看 | 原始文档 | blame | 历史
sdk_dingding/TopSdk/bin/Debug/TopSdk.pdb 补丁 | 查看 | 原始文档 | blame | 历史
sdk_dingding/TopSdk/obj/Debug/TopSdk.dll 补丁 | 查看 | 原始文档 | blame | 历史
sdk_dingding/TopSdk/obj/Debug/TopSdk.pdb 补丁 | 查看 | 原始文档 | blame | 历史
DAL/¼Æ»®¹ÜÀí/ClsGy_RoutingBill.cs
@@ -280,7 +280,7 @@
            {
                //查询主表
                DataSet Ds ;
                Ds = oCn.RunProcReturn("Select * from Gy_RoutingBillMain Where HInterID=" + lngBillKey.ToString()+" and HPRDORGID='"+DBUtility.ClsPub.HOrgID.ToString()+"'", "Gy_RoutingBillMain");
                Ds = oCn.RunProcReturn("Select * from Gy_RoutingBillMain Where HInterID=" + lngBillKey.ToString(), "Gy_RoutingBillMain");
                if(Ds.Tables[0].Rows.Count==0)
                {
                    sReturn = "单据未找到!";
@@ -288,6 +288,8 @@
                }
                //赋值
                omodel.HInterID =DBUtility.ClsPub.isLong(Ds.Tables[0].Rows[0]["HInterID"].ToString());
                omodel.HBillStatus = DBUtility.ClsPub.isInt(Ds.Tables[0].Rows[0]["HBillStatus"].ToString());
                omodel.HBillNo = Ds.Tables[0].Rows[0]["HBillNo"].ToString().Trim();
                omodel.HName = Ds.Tables[0].Rows[0]["HName"].ToString().Trim();
                omodel.HDate = Convert.ToDateTime(Ds.Tables[0].Rows[0]["HDate"].ToString().Trim());
WebAPI/Controllers/JHGL/Gy_RoutingBillController.cs
@@ -13,7 +13,7 @@
using System.Windows.Forms;
using WebAPI.Controllers.SCGL.日计划管理;
using WebAPI.Models;
using SyntacticSugar.constant;
namespace WebAPI.Controllers
{
    //工艺路线Controller
@@ -198,7 +198,8 @@
                int IsProNo = mainList[0].IsProNo;//是否转工序                     
                HName_LongShan = mainList[0].HName;//工艺路线名称
                string HProcPriceType = mainList[0].HProcPriceType;//定额类型(临时定额,永久定额)
                DateTime HBeginDate = mainList[0].HBeginDate;//开始日期
                DateTime HEndDate = mainList[0].HEndDate;//失效日期
                if (oSystemParameter.omodel.WMS_CampanyName == "凯贝奈特")
                {
@@ -267,13 +268,13 @@
                    ",HRoutingGroupID,HUnitID,HMaterNumber,HUnitNumber,HStandard" +
                    ",HMainGroupID,HMainProcID,HMainCenterID,HMainTimeUnit,HMainUnitTime,HMainWorkQty" +
                    ",HMainPrice,HStdSourceQty,HAddSourceRate,HPRDORGID,HDelSourceRate" +
                    ",HPicNumVer,HPicNumAssemble,HMaterTexture,HProductNum,HVerNum,HOrgID,HProcPriceType) " +
                    ",HPicNumVer,HPicNumAssemble,HMaterTexture,HProductNum,HVerNum,HOrgID,HProcPriceType,HBeginDate,HEndDate) " +
                    " values('" + BillType + "','"+ HBillSubType + "'," + HInterID + ",'" + HBillNo + "','" + HDate + "'" +
                    "," + HYear + "," + HPeriod + ",'" + HRemark + "','" + HMaker + "',getdate()," + HMaterID + ",'" + HName + "'," + HMaterTypeID +
                    "," + HRoutingGroupID + "," + HUnitID + ",'" + HMaterNumber + "','" + HUnitNumber + "'," + Convert.ToString(HStandard ? 1 : 0) +
                    "," + HMainGroupID + "," + HMainProcID + "," + HMainCenterID + ",'" + HMainTimeUnit + "'," + HMainUnitTime + "," + HMainWorkQty +
                    "," + HMainPrice + "," + HStdSourceQty + "," + HAddSourceRate + "," + HPRDORGID + "," + HDelSourceRate +
                    ",'" + HPicNumVer + "','" + HPicNumAssemble + "','" + HMaterTexture + "','" + HProductNum + "','" + HVerNum + "'," + HOrgID + ",'"+ HProcPriceType + "') ");
                    ",'" + HPicNumVer + "','" + HPicNumAssemble + "','" + HMaterTexture + "','" + HProductNum + "','" + HVerNum + "'," + HOrgID + ",'"+ HProcPriceType + "','" + HBeginDate + "','" + HEndDate + "') ");
                    LogService.Write("用户:" + user + ",日期:" + DateTime.Now + ",新增工艺路线单据:" + HBillNo);
                    oCN.RunProc("Insert into System_log (GeginDate, userid, WorkstationName, WorkList, SystemName, NetuserName, State) select GETDATE(),'" + user + "','" + HComputerName + "','" + "新增工艺路线单据:" + HBillNo + "','LMES-工艺路线模块','" + DBUtility.ClsPub.IPAddress + "','新增单据'", ref DBUtility.ClsPub.sExeReturnInfo);
@@ -289,7 +290,7 @@
                       "',HMainTimeUnit='" + HMainTimeUnit + "',HMainUnitTime='" + HMainUnitTime + "',HMainWorkQty='" + HMainWorkQty + "',HMainPrice='" + HMainPrice +
                       "',HStdSourceQty='" + HStdSourceQty + "',HAddSourceRate='" + HAddSourceRate + "',HDelSourceRate='" + HDelSourceRate +
                        "',HPicNumVer='" + HPicNumVer + "',HPicNumAssemble='" + HPicNumAssemble + "',HMaterTexture='" + HMaterTexture + "'" +
                        ",HProductNum='" + HProductNum + "',HVerNum='" + HVerNum + "',HProcPriceType = '" + HProcPriceType + "' where HInterID='" + HInterID + "'");
                        ",HProductNum='" + HProductNum + "',HVerNum='" + HVerNum + "',HProcPriceType = '" + HProcPriceType + "',HBeginDate = '" + HBeginDate + "',HEndDate = '" + HEndDate + "' where HInterID='" + HInterID + "'");
                    //删除子表
                    oCN.RunProc("delete from Gy_RoutingBillSub where HInterID='" + HInterID + "'");
@@ -502,7 +503,28 @@
                        oCN.RunProc("Insert into System_log (GeginDate, userid, WorkstationName, WorkList, SystemName, NetuserName, State) select GETDATE(),'" + user_LongShan + "','" + HComputerName + "','" + "Gy_RoutingBill_Edit,工艺路线_编辑" + "','LMES系统-工艺路线编辑模块','" + DBUtility.ClsPub.IPAddress + "','" + "修改了工艺路线:" + HName_LongShan + " å·¥åºå·ï¼š" + oSub.HProcNo + " å·¥ä»·ä¸ºï¼š" + oSub.HProcPrice.ToString() + "'", ref DBUtility.ClsPub.sExeReturnInfo);
                    }
                }
                }
                //保存后控制=========================================           æ·»åŠ å®¡æ‰¹æµ
                ds = oCN.RunProcReturn("exec h_p_Gy_RoutingBill_AfterSaveCtrl " + HInterID, "h_p_Gy_RoutingBill_AfterSaveCtrl");
                if (ds == null || ds.Tables[0].Rows.Count == 0)
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
                    objJsonResult.Message = "保存后判断失败!";
                    objJsonResult.data = null;
                    return objJsonResult;
                }
                if (DBUtility.ClsPub.isStrNull(ds.Tables[0].Rows[0]["HBack"]) != "0")
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
                    objJsonResult.Message = "保存失败!" + DBUtility.ClsPub.isStrNull(ds.Tables[0].Rows[0]["HBackRemark"]);
                    objJsonResult.data = null;
                    return objJsonResult;
                }
                //=========================================================
            }
            objJsonResult.code = "1";
@@ -1485,5 +1507,623 @@
        }
        #endregion
        #region å·¥è‰ºè·¯çº¿éœ€è¦æˆ‘审批流审批的
        [Route("Gy_Routing/NeedChecklist")]
        [HttpGet]
        public object NeedChecklist(string user, string userid)
        {
            try
            {
                List<object> columnNameList = new List<object>();
                //判断是否有查询权限
                if (!DBUtility.ClsPub.Security_Log("Gy_RoutingBill_Query", 1, false, user))
                {
                    objJsonResult.code = CodeConstant.FAIL;
                    objJsonResult.count = CountConstant.FAIL;
                    objJsonResult.Message = "无权限查看!";
                    objJsonResult.data = null;
                    return objJsonResult;
                }
                //搜索需要审核的
                string sql = "  select a.*,c.HItemID as HCheckFlowStatusID,m.HName as å®¡æ‰¹æµ,c.HCheckFlowID,i.HName as å®¡æ‰¹é¡¹ç›®åç§°,c.HCheckItemID,c.HChecker as é¡¹ç›®å®¡æ ¸äºº,c.HCheckNote as å®¡æ‰¹æµå®¡æ ¸å»ºè®®,c.HCheckDate å®¡æ‰¹æµå®¡æ ¸æ—¥æœŸ   from h_v_Gy_RoutingBillList AS a LEFT JOIN Xt_BillCheckFlowStatus AS c ON a.hmainid = c.HBillInterID and a.单据类型 = c.HBillTypeID" +
                    " LEFT JOIN Xt_CheckFlowMain as m ON m.HInterID = c.HCheckFlowID" +
                    " LEFT JOIN Gy_RoutingBillMain as po ON a.hmainid = po.HInterID" +
                    " LEFT JOIN Xt_CheckItem as i ON i.HItemID = c.HCheckItemID" +
                    " LEFT JOIN Xt_CheckUserRight as cr ON cr.HCheckItemID = i.HItemID and cr.HCheckFlowInterID = m.HInterID" +
                    " where po.HBillStatus = 6 and po.HCheckItemNowID = i.HItemID  and cr.HUserID = '" + userid + "'";
                ds = oCN.RunProcReturn(sql, "h_v_Gy_RoutingBillList");
                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 = CodeConstant.SUCCEED;
                objJsonResult.count = CountConstant.SUCCEED;
                objJsonResult.Message = "Sucess!";
                objJsonResult.data = ds.Tables[0];
                objJsonResult.list = columnNameList;
                return objJsonResult;
            }
            catch (Exception e)
            {
                objJsonResult.code = CodeConstant.FAIL;
                objJsonResult.count = CountConstant.FAIL;
                objJsonResult.Message = "Exception!" + e.ToString();
                objJsonResult.data = null;
                return objJsonResult;
            }
        }
        #endregion
        #region å·¥è‰ºè·¯çº¿å·²ç»å®¡æ‰¹æµå®¡æ‰¹çš„
        [Route("Gy_Routing/Checkedlist")]
        [HttpGet]
        public object Checkedlist(string user)
        {
            try
            {
                List<object> columnNameList = new List<object>();
                //判断是否有查询权限
                if (!DBUtility.ClsPub.Security_Log("Gy_RoutingBill_Query", 1, false, user))
                {
                    objJsonResult.code = CodeConstant.FAIL;
                    objJsonResult.count = CountConstant.FAIL;
                    objJsonResult.Message = "无权限查看!";
                    objJsonResult.data = null;
                    return objJsonResult;
                }
                //搜索需要审核的
                string sql = "  select DISTINCT a.*,c.HItemID as HCheckFlowStatusID,m.HName as å®¡æ‰¹æµ,c.HCheckFlowID,i.HName as å®¡æ‰¹é¡¹ç›®åç§°,c.HCheckItemID,c.HChecker as é¡¹ç›®å®¡æ ¸äºº,c.HCheckNote as å®¡æ‰¹æµå®¡æ ¸å»ºè®®,c.HCheckDate å®¡æ‰¹æµå®¡æ ¸æ—¥æœŸ   from h_v_Gy_RoutingBillList AS a LEFT JOIN Xt_BillCheckFlowStatus AS c ON a.hmainid = c.HBillInterID and a.单据类型 = c.HBillTypeID" +
                    " LEFT JOIN Xt_CheckFlowMain as m ON m.HInterID = c.HCheckFlowID" +
                    " LEFT JOIN Xt_CheckItem as i ON i.HItemID = c.HCheckItemID" +
                    " where c.HCheckDate is  not NUll and c.HChecker = '" + user + "'";
                ds = oCN.RunProcReturn(sql, "h_v_Gy_RoutingBillList");
                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 = CodeConstant.SUCCEED;
                objJsonResult.count = CountConstant.SUCCEED;
                objJsonResult.Message = "Sucess!";
                objJsonResult.data = ds.Tables[0];
                objJsonResult.list = columnNameList;
                return objJsonResult;
            }
            catch (Exception e)
            {
                objJsonResult.code = CodeConstant.FAIL;
                objJsonResult.count = CountConstant.FAIL;
                objJsonResult.Message = "Exception!" + e.ToString();
                objJsonResult.data = null;
                return objJsonResult;
            }
        }
        #endregion
        #region å·¥è‰ºè·¯çº¿é©³å›ž
        [Route("Gy_Routing/RejectCheckFlow")]
        [HttpGet]
        public object RejectCheckFlow(string HInterID, string CurUserID)
        {
            try
            {
                Int64 lngBillKey = 0;
                lngBillKey = DBUtility.ClsPub.isLong(HInterID);      //对HInterID进行类型的转换
                DAL.ClsGy_RoutingBill oBill = new DAL.ClsGy_RoutingBill();                              //实例化单据操作类,用于进行相关操作
                if (oBill.ShowBill(lngBillKey, ref DBUtility.ClsPub.sExeReturnInfo))                    //根据HInterID获取该单据的数据
                {
                    if (oBill.omodel.HBillStatus != 6)
                    {
                        objJsonResult.code = CodeConstant.FAIL;
                        objJsonResult.count = CountConstant.FAIL;
                        objJsonResult.Message = "单据未在审核中不能驳回";
                        objJsonResult.data = null;
                        return objJsonResult;
                    }
                    //发起驳回
                    if (oBill.RejectCheckFlowProgress(lngBillKey, oBill.omodel.HBillNo, CurUserID, ref DBUtility.ClsPub.sExeReturnInfo) == true)
                    {
                        objJsonResult.code = CodeConstant.SUCCEED;
                        objJsonResult.count = CountConstant.SUCCEED;
                        objJsonResult.Message = "驳回成功";
                        objJsonResult.data = null;
                        return objJsonResult;
                    }
                    else
                    {
                        objJsonResult.code = CodeConstant.FAIL;
                        objJsonResult.count = CountConstant.FAIL;
                        objJsonResult.Message = "驳回失败失败!原因:" + DBUtility.ClsPub.sExeReturnInfo;
                        objJsonResult.data = null;
                        return objJsonResult;
                    }
                }
                else
                {
                    objJsonResult.code = CodeConstant.FAIL;
                    objJsonResult.count = CountConstant.FAIL;
                    objJsonResult.Message = "单据不存在!原因:" + DBUtility.ClsPub.sExeReturnInfo;
                    objJsonResult.data = null;
                    return objJsonResult;
                }
            }
            catch (Exception e)
            {
                oCN.RollBack();
                objJsonResult.code = CodeConstant.FAIL;
                objJsonResult.count = CountConstant.FAIL;
                objJsonResult.Message = "Exception!" + e.ToString();
                objJsonResult.data = null;
                return objJsonResult;
            }
        }
        #endregion
        #region å·¥è‰ºè·¯çº¿ å‘起审批
        [Route("Gy_Routing/StartCheckFlow")]
        [HttpGet]
        public object StartCheckFlow(int HInterID, string CurUserName)
        {
            DBUtility.ClsPub.CurUserName = CurUserName;
            try
            {
                ////审核权限
                //if (!DBUtility.ClsPub.Security_Log_second(ModRightNameCheck, 1, false, CurUserName))
                //{
                //    objJsonResult.code = "0";
                //    objJsonResult.count = 0;
                //    objJsonResult.Message = "审核失败!无权限!";
                //    objJsonResult.data = null;
                //    return objJsonResult;
                //}
                //HInterID数据判断
                if (HInterID <= 0)
                {
                    objJsonResult.code = CodeConstant.FAIL;
                    objJsonResult.count = CountConstant.FAIL;
                    objJsonResult.Message = "HInterID小于0!";
                    objJsonResult.data = null;
                    return objJsonResult;
                }
                Int64 lngBillKey = 0;
                lngBillKey = DBUtility.ClsPub.isLong(HInterID);                                         //对HInterID进行类型的转换
                DAL.ClsGy_RoutingBill oBill = new DAL.ClsGy_RoutingBill();                              //实例化单据操作类,用于进行相关操作
                //发起审批
                if (oBill.startCheckFlow(lngBillKey, ref DBUtility.ClsPub.sExeReturnInfo) == true)
                {
                    objJsonResult.code = CodeConstant.SUCCEED;
                    objJsonResult.count = CountConstant.SUCCEED;
                    objJsonResult.Message = "发起审批成功";
                    objJsonResult.data = null;
                    return objJsonResult;
                }
                else
                {
                    objJsonResult.code = CodeConstant.FAIL;
                    objJsonResult.count = CountConstant.FAIL;
                    objJsonResult.Message = "发起审批失败!原因:" + DBUtility.ClsPub.sExeReturnInfo;
                    objJsonResult.data = null;
                    return objJsonResult;
                }
            }
            catch (Exception e)
            {
                objJsonResult.code = CodeConstant.FAIL;
                objJsonResult.count = CountConstant.FAIL;
                objJsonResult.Message = "发起审批失败失败!" + e.ToString();
                objJsonResult.data = null;
                return objJsonResult;
            }
        }
        #endregion
        #region å·¥è‰ºè·¯çº¿ å¤šçº§ å®¡æ ¸/反审核
        /// <summary>
        /// </summary>
        /// <param name="HInterID">单据ID</param>
        /// <param name="IsAudit">审核(0),反审核(1)</param>
        /// <param name="CurUserName">审核人</param>
        /// <returns></returns>
        [Route("Gy_Routing/AuditFlow")]
        [HttpGet]
        public object AuditGy_Routing_Flow(int HInterID, int IsAudit, string CurUserName, string CurUserID)
        {
            //string ModRightNameCheck = "Gy_Routing_Check";
            DBUtility.ClsPub.CurUserName = CurUserName;
            try
            {
                ////审核权限
                //if (!DBUtility.ClsPub.Security_Log_second(ModRightNameCheck, 1, false, CurUserName))
                //{
                //    objJsonResult.code = "0";
                //    objJsonResult.count = 0;
                //    objJsonResult.Message = "审核失败!无权限!";
                //    objJsonResult.data = null;
                //    return objJsonResult;
                //}
                //HInterID数据判断
                if (HInterID <= 0)
                {
                    objJsonResult.code = CodeConstant.FAIL;
                    objJsonResult.count = CountConstant.FAIL;
                    objJsonResult.Message = "HInterID小于0!";
                    objJsonResult.data = null;
                    return objJsonResult;
                }
                Int64 lngBillKey = 0;
                lngBillKey = DBUtility.ClsPub.isLong(HInterID);                                         //对HInterID进行类型的转换
                DAL.ClsGy_RoutingBill oBill = new DAL.ClsGy_RoutingBill();                              //实例化单据操作类,用于进行相关操作
                //针对需要进行的操作,检验当前单据的状态是否支持需要进行的操作
                if (oBill.ShowBill(lngBillKey, ref DBUtility.ClsPub.sExeReturnInfo))                    //根据HInterID获取该单据的数据
                {
                    if (oBill.omodel.HCloseMan.Trim() != "")
                    {
                        objJsonResult.code = CodeConstant.FAIL;
                        objJsonResult.count = CountConstant.FAIL;
                        objJsonResult.Message = "单据已关闭!不能再次审核!";
                        objJsonResult.data = null;
                        return objJsonResult;
                    }
                    if (oBill.omodel.HDeleteMan.Trim() != "")
                    {
                        objJsonResult.code = CodeConstant.FAIL;
                        objJsonResult.count = CountConstant.FAIL;
                        objJsonResult.Message = "单据已作废!不能再次审核!";
                        objJsonResult.data = null;
                        return objJsonResult;
                    }
                    if (IsAudit == TypeConstant.AUDIT)  //审核判断
                    {
                        //判断是否已经发起审批
                        string sql0 = "select * from Xt_BillCheckFlowStatus where HBillInterID = " + lngBillKey + " and HBillTypeID = '" + oBill.BillType + "'";
                        DataSet ds0 = oCN.RunProcReturn(sql0, "Xt_BillCheckFlowStatus");
                        if (ds0 != null && ds0.Tables[0].Rows.Count == 0)
                        {
                            objJsonResult.code = CodeConstant.FAIL;
                            objJsonResult.count = CountConstant.FAIL;
                            objJsonResult.Message = "审核失败!原因:单据未发起审批!";
                            objJsonResult.data = null;
                            return objJsonResult;
                        }
                        //判断单据当前状态
                        if (oBill.omodel.HChecker.Trim() != "")
                        {
                            objJsonResult.code = CodeConstant.FAIL;
                            objJsonResult.count = CountConstant.FAIL;
                            objJsonResult.Message = "审核失败!原因:单据已完成审核!不能继续审核!";
                            objJsonResult.data = null;
                            return objJsonResult;
                        }
                    }
                    if (IsAudit == TypeConstant.REVERSE_AUDIT) //反审核判断
                    {
                        //判断是否存在审核过的项目
                        string sql0 = "select * from Xt_BillCheckFlowStatus where HBillInterID = " + lngBillKey + " and HBillTypeID = '" + oBill.BillType + "' and ISNULL(HChecker,'') <> ''";
                        DataSet ds0 = oCN.RunProcReturn(sql0, "Xt_BillCheckFlowStatus");
                        if (ds0 != null && ds0.Tables[0].Rows.Count == 0)
                        {
                            objJsonResult.code = CodeConstant.FAIL;
                            objJsonResult.count = CountConstant.FAIL;
                            objJsonResult.Message = "反审核失败!原因:单据不存在已经审核的项目!!";
                            objJsonResult.data = null;
                            return objJsonResult;
                        }
                    }
                }
                else
                {
                    objJsonResult.code = CodeConstant.FAIL;
                    objJsonResult.count = CountConstant.FAIL;
                    objJsonResult.Message = "单据不存在!原因:" + DBUtility.ClsPub.sExeReturnInfo;
                    objJsonResult.data = null;
                    return objJsonResult;
                }
                oCN.BeginTran();
                //进行需要进行的审核/反审核操作
                if (IsAudit == TypeConstant.AUDIT) //审核提交
                {
                    #region å®¡æ ¸å‰çš„相关判断
                    //审核前控制=========================================
                    //string sql1 = "exec h_p_Gy_Routing_BeforeCheckCtrl " + oBill.omodel.HInterID + ",'" + oBill.omodel.HBillNo + "','" + CurUserName + "'";
                    //ds = oCN.RunProcReturn(sql1, "h_p_Gy_Routing_BeforeCheckCtrl");
                    //if (ds == null || ds.Tables.Count == 0 || ds.Tables[0].Rows.Count == 0)
                    //{
                    //    objJsonResult.code = "0";
                    //    objJsonResult.count = 0;
                    //    objJsonResult.Message = "审核失败!原因:审核前判断失败,请与网络管理人员联系";
                    //    objJsonResult.data = null;
                    //    return objJsonResult;
                    //}
                    //if (ds.Tables[0].Rows[0]["HBack"].ToString() != "0")
                    //{
                    //    objJsonResult.code = "0";
                    //    objJsonResult.count = 0;
                    //    objJsonResult.Message = "审核失败!原因:" + ds.Tables[0].Rows[0]["HRemark"].ToString(); ;
                    //    objJsonResult.data = null;
                    //    return objJsonResult;
                    //}
                    //==================================================================================
                    //进行 ä¼šè®¡æœŸé—´ ç»“è´¦ çš„判断和控制
                    string s = "";
                    int sYear = 0;
                    int sPeriod = 0;
                    DateTime HDate = DateTime.Now;
                    if (DBUtility.Xt_BaseBillFun.Fun_AllowYearPeriod(HDate, ref sYear, ref sPeriod, ref s) == false)
                    {
                        objJsonResult.Message = s;
                        return objJsonResult;
                    }
                    #endregion
                    //获取当前审核项目
                    string sql0 = "select * from " + oBill.MvarItemKey + " where HInterID = " + lngBillKey;
                    DataSet ds0 = oCN.RunProcReturn(sql0, oBill.MvarItemKey);
                    string HCheckFlowID = ds0.Tables[0].Rows[0]["HCheckFlowID"].ToString();             //审批流内码
                    string HCheckItemNowID = ds0.Tables[0].Rows[0]["HCheckItemNowID"].ToString();       //当前审批项目内码
                    string HCheckItemNextID = ds0.Tables[0].Rows[0]["HCheckItemNextID"].ToString();     //待审批项目内码
                    //判断用户是否有权限 å®¡æ‰¹ å½“前审批流的审批项目
                    //string sql01 = "select * from Xt_CheckUserRight where HUserID = '" + CurUserID + "' and HCheckFlowInterID = " + HCheckFlowID + " and HCheckItemID = " + HCheckItemNowID + " and HValue = 1";
                    string sql01 = "select * from Xt_CheckUserRight where HUserID = '" + CurUserID + "' and HCheckFlowInterID = " + HCheckFlowID + " and HCheckItemID = " + HCheckItemNowID + "";
                    DataSet ds01 = oCN.RunProcReturn(sql01, "Xt_CheckUserRight");
                    if (ds01.Tables[0].Rows.Count == 0)
                    {
                        objJsonResult.code = CodeConstant.FAIL;
                        objJsonResult.count = CountConstant.FAIL;
                        objJsonResult.Message = "审核失败!原因:用户无当前审核项目的审核权限!";
                        objJsonResult.data = null;
                        return objJsonResult;
                    }
                    //更新 å•据审批状态表 ä¸­å¯¹åº”审核项目的审核状态
                    string sql02 = "update Xt_BillCheckFlowStatus set HChecker='" + CurUserName + "',HCheckDate=getdate() where HBillTypeID = '" + oBill.BillType + "' and HBillInterID=" + lngBillKey + " and HCheckFlowID=" + HCheckFlowID + " and HCheckItemID=" + HCheckItemNowID;
                    oCN.RunProc(sql02);
                    //判断当前审核项目是否是最后一个项目,如果是,审核后反写单据的单据状态。如果不是,获取下一个审核项目并更新到销售订单主表
                    if (HCheckItemNextID != "0")                //刚刚审核的审核项目不是最后一个审核项目
                    {
                        string sql03 = "select b.HInterID,b.HCheckItemID from Xt_CheckFlowMain as a " +
                                "inner join Xt_CheckFlowSub as b on a.HInterID = b.HInterID " +
                                "where a.HBillTypeID = '" + oBill.BillType + "' " +
                                "and a.HInterID = " + HCheckFlowID + " " +
                                "order by b.HFlowNo asc";
                        DataSet ds03 = oCN.RunProcReturn(sql03, "Xt_CheckFlowMain");
                        //获取新的当前审核项目和待审核项目
                        for (int i = 0; i < ds03.Tables[0].Rows.Count; i++)
                        {
                            if (ds03.Tables[0].Rows[i]["HCheckItemID"].ToString() == HCheckItemNextID)
                            {
                                HCheckItemNowID = HCheckItemNextID;
                            }
                            else if (HCheckItemNowID == HCheckItemNextID)
                            {
                                HCheckItemNextID = ds03.Tables[0].Rows[i]["HCheckItemID"].ToString();
                                break;
                            }
                        }
                        //新的当前审核项目为最后一个审核项目,待审核项目不存在,设为默认值"0"
                        if (HCheckItemNowID == HCheckItemNextID)
                        {
                            HCheckItemNextID = "0";
                        }
                        //更新单据主表的审批流数据
                        string sql04 = "update " + oBill.MvarItemKey + " set HCheckItemNowID=" + HCheckItemNowID + ",HCheckItemNextID=" + HCheckItemNextID + " where HInterID = " + lngBillKey;
                        oCN.RunProc(sql04);
                        objJsonResult.code = CodeConstant.SUCCEED;
                        objJsonResult.count = CountConstant.SUCCEED;
                        objJsonResult.Message = "审核成功";
                        objJsonResult.data = null;
                    }
                    else                                                                //刚刚审核的审核项目是最后一个审核项目
                    {
                        //更新单据主表的审批流数据
                        HCheckItemNowID = "0";
                        HCheckItemNextID = "0";
                        string sql04 = "update " + oBill.MvarItemKey + " set HCheckItemNowID=" + HCheckItemNowID + ",HCheckItemNextID=" + HCheckItemNextID + " where HInterID = " + lngBillKey;
                        oCN.RunProc(sql04);
                        //更新单据的单据状态
                        if (oBill.CheckBill(oBill.omodel.HInterID, ref DBUtility.ClsPub.sExeReturnInfo) == true)
                        {
                            objJsonResult.code = CodeConstant.SUCCEED;
                            objJsonResult.count = CountConstant.SUCCEED;
                            objJsonResult.Message = "审核成功";
                            objJsonResult.data = null;
                        }
                        else
                        {
                            objJsonResult.code = CodeConstant.FAIL;
                            objJsonResult.count = CountConstant.FAIL;
                            objJsonResult.Message = "审核失败!原因:" + DBUtility.ClsPub.sExeReturnInfo;
                            objJsonResult.data = null;
                            oCN.RollBack();
                            return objJsonResult;
                        }
                    }
                }
                if (IsAudit == TypeConstant.REVERSE_AUDIT) //反审核提交
                {
                    #region åå®¡æ ¸å‰çš„相关判断
                    //反审核前控制=========================================
                    //DataSet ds = oCN.RunProcReturn("Exec h_p_Gy_Routing_BeforeUnCheckCtrl " + oBill.omodel.HInterID + ",'" + oBill.omodel.HBillNo + "','" + CurUserName + "'", "h_p_Gy_Routing_BeforeUnCheckCtrl");
                    //if (ds == null)
                    //{
                    //    objJsonResult.code = CodeConstant.FAIL;
                    //    objJsonResult.count = CountConstant.FAIL;
                    //    objJsonResult.Message = "反审核失败!原因:" + "反审核前判断失败!";
                    //    objJsonResult.data = null;
                    //    return objJsonResult;
                    //}
                    //if (DBUtility.ClsPub.isStrNull(ds.Tables[0].Rows[0]["HBack"]) != "0")
                    //{
                    //    objJsonResult.code = CodeConstant.FAIL;
                    //    objJsonResult.count = CountConstant.FAIL;
                    //    objJsonResult.Message = "反审核失败!原因:" + DBUtility.ClsPub.isStrNull(ds.Tables[0].Rows[0]["HBackRemark"]);
                    //    objJsonResult.data = null;
                    //    return objJsonResult;
                    //}
                    //=========================================================
                    //进行 ä¼šè®¡æœŸé—´ ç»“è´¦ çš„判断和控制
                    string s = "";
                    int sYear = 0;
                    int sPeriod = 0;
                    DateTime HDate = DateTime.Now;
                    if (DBUtility.Xt_BaseBillFun.Fun_AllowYearPeriod(HDate, ref sYear, ref sPeriod, ref s) == false)
                    {
                        objJsonResult.Message = s;
                        return objJsonResult;
                    }
                    #endregion
                    //获取需要反审核的审核项目
                    string sql0 = "select c.* from Xt_CheckFlowMain as a " +
                                  "inner join Xt_CheckFlowSub as b on a.HInterID = b.HInterID " +
                                  "inner join Xt_BillCheckFlowStatus as c on a.HBillTypeID = c.HBillTypeID and b.HCheckItemID = c.HCheckItemID " +
                                  "where c.HBillTypeID = '" + oBill.BillType + "' and c.HBillInterID = " + lngBillKey + " " +
                                  "order by b.HFlowNo asc";
                    DataSet ds0 = oCN.RunProcReturn(sql0, "Xt_BillCheckFlowStatus");
                    if (ds0 == null || ds0.Tables[0].Rows.Count == 0)
                    {
                        objJsonResult.code = CodeConstant.FAIL;
                        objJsonResult.count = CountConstant.FAIL;
                        objJsonResult.Message = "反审核失败!原因:未发起审批!";
                        objJsonResult.data = null;
                        return objJsonResult;
                    }
                    string HCheckFlowID = ds0.Tables[0].Rows[0]["HCheckFlowID"].ToString();             //审批流内码
                    string HCheckItemNowID = "0";       //当前审批项目内码
                    string HCheckItemNextID = "0";     //待审批项目内码
                    if (oBill.omodel.HBillStatus == 6)
                    {
                        for (int i = 0; i < ds0.Tables[0].Rows.Count; i++)
                        {
                            if (ds0.Tables[0].Rows[i]["HChecker"].ToString() != "")
                            {
                                HCheckItemNowID = ds0.Tables[0].Rows[i]["HCheckItemID"].ToString();
                                HCheckItemNextID = ds0.Tables[0].Rows[i]["HCheckItemID"].ToString();
                            }
                            else
                            {
                                HCheckItemNextID = ds0.Tables[0].Rows[i]["HCheckItemID"].ToString();
                                break;
                            }
                        }
                        if (HCheckItemNowID == HCheckItemNextID)
                        {
                            HCheckItemNextID = "0";
                        }
                    }
                    else
                    {
                        HCheckItemNowID = ds0.Tables[0].Rows[ds0.Tables[0].Rows.Count - 1]["HCheckItemID"].ToString();
                        HCheckItemNextID = "0";
                    }
                    //判断用户是否有权限 å®¡æ‰¹ å½“前审批流的审批项目
                    //string sql01 = "select * from Xt_CheckUserRight where HUserID = '" + CurUserID + "' and HCheckFlowInterID = " + HCheckFlowID + " and HCheckItemID = " + HCheckItemNowID + " and HValue = 1";
                    string sql01 = "select * from Xt_CheckUserRight where HUserID = '" + CurUserID + "' and HCheckFlowInterID = " + HCheckFlowID + " and HCheckItemID = " + HCheckItemNowID + "";
                    DataSet ds01 = oCN.RunProcReturn(sql01, "Xt_CheckUserRight");
                    if (ds01.Tables[0].Rows.Count == 0)
                    {
                        objJsonResult.code = CodeConstant.FAIL;
                        objJsonResult.count = CountConstant.FAIL;
                        objJsonResult.Message = "反审核失败!原因:用户无当前审核项目的审核权限!";
                        objJsonResult.data = null;
                        return objJsonResult;
                    }
                    //更新 å•据审批状态表 ä¸­å¯¹åº”审核项目的审核状态
                    string sql02 = "update Xt_BillCheckFlowStatus set HChecker='',HCheckDate='' where HBillTypeID = '" + oBill.BillType + "' and HBillInterID=" + lngBillKey + " and HCheckFlowID=" + HCheckFlowID + " and HCheckItemID=" + HCheckItemNowID;
                    oCN.RunProc(sql02);
                    //判断反审核的单据是否已经审核完成,若审核完成,反审核需要变更单据状态。
                    if (oBill.omodel.HBillStatus == 6)
                    {
                        //更新单据主表的审批流数据
                        string sql04 = "update " + oBill.MvarItemKey + " set HCheckItemNowID=" + HCheckItemNowID + ",HCheckItemNextID=" + HCheckItemNextID + " where HInterID = " + lngBillKey;
                        oCN.RunProc(sql04);
                        objJsonResult.code = CodeConstant.SUCCEED;
                        objJsonResult.count = CountConstant.SUCCEED;
                        objJsonResult.Message = "审核成功";
                        objJsonResult.data = null;
                    }
                    else
                    {
                        //反审核提交AbandonCheck
                        if (oBill.AbandonCheck(oBill.omodel.HInterID, ref DBUtility.ClsPub.sExeReturnInfo) == true)
                        {
                            //更新单据主表的审批流数据
                            string sql04 = "update " + oBill.MvarItemKey + " set HCheckItemNowID=" + HCheckItemNowID + ",HCheckItemNextID=" + HCheckItemNextID + ",HBillStatus=6 " + " where HInterID = " + lngBillKey;
                            oCN.RunProc(sql04);
                            objJsonResult.code = CodeConstant.SUCCEED;
                            objJsonResult.count = CountConstant.SUCCEED;
                            objJsonResult.Message = "反审核成功";
                            objJsonResult.data = null;
                        }
                        else
                        {
                            objJsonResult.code = CodeConstant.FAIL;
                            objJsonResult.count = CountConstant.FAIL;
                            objJsonResult.Message = "反审核失败!原因:" + DBUtility.ClsPub.sExeReturnInfo;
                            objJsonResult.data = null;
                            oCN.RollBack();
                            return objJsonResult;
                        }
                    }
                }
                oCN.Commit();
                return objJsonResult;
            }
            catch (Exception e)
            {
                objJsonResult.code = CodeConstant.FAIL;
                objJsonResult.count = CountConstant.FAIL;
                objJsonResult.Message = "审核失败或者反审核失败!" + e.ToString();
                objJsonResult.data = null;
                oCN.RollBack();
                return objJsonResult;
            }
        }
        #endregion
    }
}
WebAPI/Controllers/»ù´¡×ÊÁÏ/»ù´¡×ÊÁÏ/Gy_ProcMulController.cs
New file
@@ -0,0 +1,537 @@
using Newtonsoft.Json;
using Newtonsoft.Json.Linq;
using System;
using System.Collections.Generic;
using System.Data;
using System.Linq;
using System.Net;
using System.Net.Http;
using System.Web.Http;
using WebAPI.Models;
using SyntacticSugar.constant;
namespace WebAPI.Controllers.基础资料.基础资料
{
    public class Gy_ProcMulController : ApiController
    {
        private json objJsonResult = new json();
        SQLHelper.ClsCN oCN = new SQLHelper.ClsCN();
        DataSet ds;
        #region  å·¥æ®µ  æŸ¥è¯¢
        [Route("Gy_ProcMul/Gy_ProcMulList")]
        [HttpGet]
        public object Gy_ProcMulList(string sWhere, string user)
        {
            try
            {
                List<object> columnNameList = new List<object>();
                //查看权限
                if (!DBUtility.ClsPub.Security_Log("Gy_ProcMul_Query", 1, false, user))
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
                    objJsonResult.Message = "无查看权限!";
                    objJsonResult.data = null;
                    return objJsonResult;
                }
                string sql1 = "select * from  h_v_Gy_ProcMulList where 1 = 1";
                string sql = sql1 + sWhere + " order by å·¥æ®µä»£ç  ";
                ds = oCN.RunProcReturn(sql, "h_v_Gy_ProcMulList");
                //添加列名
                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)
            {
                objJsonResult.code = "0";
                objJsonResult.count = 0;
                objJsonResult.Message = "Exception!" + e.ToString();
                objJsonResult.data = null;
                return objJsonResult;
            }
        }
        #endregion
        #region  å·¥æ®µ å®¡æ ¸ï¼Œåå®¡æ ¸
        [Route("Gy_ProcMul/AuditGy_ProcMul")]
        [HttpGet]
        public object AuditGy_ProcMul(int HInterID, int IsAudit, string CurUserName)
        {
            try
            {
                //审核权限
                if (!DBUtility.ClsPub.Security_Log_second("Gy_ProcMul_Check", 1, false, CurUserName))
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
                    objJsonResult.Message = "审核失败!无权限!";
                    objJsonResult.data = null;
                    return objJsonResult;
                }
                var ds = oCN.RunProcReturn("select * from Gy_ProcMul where HItemID=" + HInterID, "Gy_ProcMul");
                if (ds.Tables[0].Rows.Count > 0)
                {
                    if (IsAudit == 0)  //审核判断
                    {
                        if (ds.Tables[0].Rows[0]["HCheckEmp"].ToString() != "")
                        {
                            objJsonResult.code = "0";
                            objJsonResult.count = 0;
                            objJsonResult.Message = "单据已审核!不能再次审核!";
                            objJsonResult.data = null;
                            return objJsonResult;
                        }
                    }
                    if (IsAudit == 1) //反审核判断
                    {
                        if (ds.Tables[0].Rows[0]["HCheckEmp"].ToString() == "")
                        {
                            objJsonResult.code = "0";
                            objJsonResult.count = 0;
                            objJsonResult.Message = "单据未审核!不需要反审核!";
                            objJsonResult.data = null;
                            return objJsonResult;
                        }
                    }
                }
                else
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
                    objJsonResult.Message = "单据不存在!";
                    objJsonResult.data = null;
                    return objJsonResult;
                }
                oCN.BeginTran();
                if (IsAudit == 0)  //审核判断
                {
                    oCN.RunProc("update Gy_ProcMul set HCheckEmp='" + CurUserName + "',HCheckTime=getdate() where HItemID=" + HInterID);
                    objJsonResult.code = "1";
                    objJsonResult.count = 1;
                    objJsonResult.Message = "审核成功";
                    objJsonResult.data = null;
                }
                if (IsAudit == 1) //反审核判断
                {
                    oCN.RunProc("update Gy_ProcMul set HCheckEmp='',HCheckTime=null where HItemID=" + HInterID);
                    objJsonResult.code = "1";
                    objJsonResult.count = 1;
                    objJsonResult.Message = "反审核成功";
                    objJsonResult.data = null;
                }
                oCN.Commit();
                return objJsonResult;
            }
            catch (Exception e)
            {
                oCN.RollBack();
                objJsonResult.code = "0";
                objJsonResult.count = 0;
                objJsonResult.Message = "审核失败或者反审核失败!" + e.ToString();
                objJsonResult.data = null;
                return objJsonResult;
            }
        }
        #endregion
        #region  å·¥æ®µ  ç¦ç”¨ï¼Œåç¦ç”¨
        [Route("Gy_ProcMul/StopGy_ProcMul")]
        [HttpGet]
        public object StopGy_ProcMul(int HInterID, int IsStop, string CurUserName)
        {
            try
            {
                //审核权限
                if (!DBUtility.ClsPub.Security_Log_second("Gy_ProcMul_Close", 1, false, CurUserName))
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
                    objJsonResult.Message = "禁用失败!无权限!";
                    objJsonResult.data = null;
                    return objJsonResult;
                }
                var ds = oCN.RunProcReturn("select * from Gy_ProcMul where HItemID=" + HInterID, "Gy_ProcMul");
                if (ds.Tables[0].Rows.Count > 0)
                {
                    if (IsStop == 0)  //禁用判断
                    {
                        if (ds.Tables[0].Rows[0]["HStopEmp"].ToString() != "")
                        {
                            objJsonResult.code = "0";
                            objJsonResult.count = 0;
                            objJsonResult.Message = "单据已禁用!不能再次禁用!";
                            objJsonResult.data = null;
                            return objJsonResult;
                        }
                    }
                    if (IsStop == 1) //反禁用判断
                    {
                        if (ds.Tables[0].Rows[0]["HStopEmp"].ToString() == "")
                        {
                            objJsonResult.code = "0";
                            objJsonResult.count = 0;
                            objJsonResult.Message = "单据未禁用!不需要反禁用!";
                            objJsonResult.data = null;
                            return objJsonResult;
                        }
                    }
                }
                else
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
                    objJsonResult.Message = "单据不存在!";
                    objJsonResult.data = null;
                    return objJsonResult;
                }
                oCN.BeginTran();
                if (IsStop == 0)  //禁用判断
                {
                    oCN.RunProc("update Gy_ProcMul set HStopEmp='" + CurUserName + "',HStopTime=getdate(),HStopflag=1 where HItemID=" + HInterID);
                    objJsonResult.code = "1";
                    objJsonResult.count = 1;
                    objJsonResult.Message = "禁用成功";
                    objJsonResult.data = null;
                }
                if (IsStop == 1) //反禁用判断
                {
                    oCN.RunProc("update Gy_ProcMul set HStopEmp='',HStopTime=null,HStopflag=0 where HItemID=" + HInterID);
                    objJsonResult.code = "1";
                    objJsonResult.count = 1;
                    objJsonResult.Message = "反禁用成功";
                    objJsonResult.data = null;
                }
                oCN.Commit();
                return objJsonResult;
            }
            catch (Exception e)
            {
                oCN.RollBack();
                objJsonResult.code = "0";
                objJsonResult.count = 0;
                objJsonResult.Message = "禁用失败或者反禁用失败!" + e.ToString();
                objJsonResult.data = null;
                return objJsonResult;
            }
        }
        #endregion
        #region  å·¥æ®µ ä¿å­˜
        [Route("Gy_ProcMul/SaveGy_ProcMulList")]
        [HttpPost]
        public object SaveGy_ProcMulList([FromBody] JObject msg)
        {
            DataSet ds;
            var _value = msg["msg"].ToString();
            string msg3 = _value.ToString();
            string[] sArray = msg3.Split(new string[] { ";" }, StringSplitOptions.RemoveEmptyEntries);
            string msg1 = sArray[0].ToString();
            string msg2 = sArray[1].ToString();
            //查看权限
            if (!DBUtility.ClsPub.Security_Log("Gy_ProcMul_Edit", 1, false, msg2))
            {
                objJsonResult.code = "0";
                objJsonResult.count = 0;
                objJsonResult.Message = "无保存权限!";
                objJsonResult.data = null;
                return objJsonResult;
            }
            Int64 HItemID = 0;
            SQLHelper.ClsCN oCN = new SQLHelper.ClsCN();
            //获取最大ID值赋值
            DataSet Maxds = oCN.RunProcReturn("select isNull(MAX(HItemID),0) HItemID from Gy_ProcMul ", "Gy_ProcMul");
            if (Maxds != null || Maxds.Tables[0].Rows.Count > 0)
            {
                //HItemID= Maxds.Tables[0].Rows[0]["HItemID"]
                var maxid = Convert.ToInt32(Maxds.Tables[0].Rows[0]["HItemID"]);
                maxid += 1;
                HItemID = maxid;
            }
            ListModels oListModels = new ListModels();
            try
            {
                WebAPI.DLL.ClsGy_ProcMul_Ctl oBill = new WebAPI.DLL.ClsGy_ProcMul_Ctl();
                List<Model.ClsGy_ProcMul_Model> lsmain = new List<Model.ClsGy_ProcMul_Model>();
                msg1 = msg1.Replace("\\", "");
                msg1 = msg1.Replace("\n", "");  //\n
                string jsonString = "[" + msg1.ToString() + "]";
                List<Model.ClsGy_ProcMul_Model> list = Newtonsoft.Json.JsonConvert.DeserializeObject<List<Model.ClsGy_ProcMul_Model>>(jsonString);
                lsmain = list;
                foreach (Model.ClsGy_ProcMul_Model oItem in lsmain)
                {
                    if (oItem.HNumber.Trim() == "")
                    {
                        objJsonResult.code = "0";
                        objJsonResult.count = 0;
                        objJsonResult.Message = "保存失败!代码不能为空!";
                        objJsonResult.data = 1;
                        return objJsonResult;
                    }
                    if (oItem.HName.Trim() == "")
                    {
                        objJsonResult.code = "0";
                        objJsonResult.count = 0;
                        objJsonResult.Message = "保存失败!名称不能为空!";
                        objJsonResult.data = 1;
                        return objJsonResult;
                    }
                    if (!DBUtility.ClsPub.AllowNumber(oItem.HNumber.Trim()))
                    {
                        objJsonResult.code = "0";
                        objJsonResult.count = 0;
                        objJsonResult.Message = "保存失败!代码中不能出现连续‘.’并且首位末位不能为‘.’!";
                        objJsonResult.data = 1;
                        return objJsonResult;
                    }
                    //查询数据中是否存在重复代码
                    ds = oCN.RunProcReturn("select * from  Gy_ProcMul where HStopflag=0 and HNumber='" + oItem.HNumber.Trim() + "'", "Gy_ProcMul");
                    if (oItem.HNumber.Trim() == "")
                    {
                        objJsonResult.code = "0";
                        objJsonResult.count = 0;
                        objJsonResult.Message = "保存失败!代码为空!";
                        objJsonResult.data = 1;
                        return objJsonResult;
                    }
                    //新增时判断
                    if (oItem.HItemID == 0)
                    {
                        if (ds == null || ds.Tables[0].Rows.Count == 0)
                        {
                        }
                        else
                        {
                            objJsonResult.code = "0";
                            objJsonResult.count = 0;
                            objJsonResult.Message = "保存失败!代码重复!";
                            objJsonResult.data = 1;
                            return objJsonResult;
                        }
                        //检查父级是否存在
                        string sParent;
                        sParent = DBUtility.ClsPub.GetParentCode(oItem.HNumber.Trim());
                        if (sParent.Trim() == "")
                        {
                            oBill.oModel.HParentID = 0;
                        }
                        else
                        {
                            if (oBill.HavParentCode(sParent.Trim(), HItemID))
                            {
                                oBill.oModel.HParentID = oBill.oModel.HItemID;
                            }
                            else
                            {
                                objJsonResult.code = "0";
                                objJsonResult.count = 0;
                                objJsonResult.Message = "保存失败!上级代码不存在或被禁用!";
                                objJsonResult.data = 1;
                                return objJsonResult;
                            }
                        }
                    }
                    else//编辑时判断
                    {
                        //检查父级是否存在
                        string sParent;
                        sParent = DBUtility.ClsPub.GetParentCode(oItem.HNumber.Trim());
                        if (sParent.Trim() == "")
                        {
                            oBill.oModel.HParentID = 0;
                        }
                        else
                        {
                            if (oBill.HavParentCode(sParent.Trim(), oItem.HItemID))
                            {
                                oBill.oModel.HParentID = oBill.oModel.HItemID;
                            }
                            else
                            {
                                objJsonResult.code = "0";
                                objJsonResult.count = 0;
                                objJsonResult.Message = "保存失败!上级代码不存在或被禁用!";
                                objJsonResult.data = 1;
                                return objJsonResult;
                            }
                        }
                    }
                    //得到短代码
                    string sShortNumber;
                    sShortNumber = DBUtility.ClsPub.GetShortNumber(oItem.HNumber.Trim());
                    if (sShortNumber.Trim() == "")
                    {
                        objJsonResult.code = "0";
                        objJsonResult.count = 0;
                        objJsonResult.Message = "保存失败!短代码为空!";
                        objJsonResult.data = 1;
                        return objJsonResult;
                    }
                    oItem.HShortNumber = sShortNumber;//短代码
                    oItem.HEndFlag = true;//末级标志
                    oItem.HLevel = DBUtility.ClsPub.GetLevel(oItem.HNumber.Trim()); //等级
                    oItem.HMakeEmp = msg2; //创建人
                    oBill.oModel = oItem;
                }
                //保存
                //保存完毕后处理
                bool bResult;
                if (oBill.oModel.HItemID == 0)
                {
                    // bResult = oBill.AddBill(ref DBUtility.ClsPub.sExeReturnInfo);
                    bResult = oBill.AddNew();
                }
                else
                {
                    bResult = oBill.ModifyByID(oBill.oModel.HItemID);
                }
                if (bResult)
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 1;
                    objJsonResult.Message = "保存成功!";
                    //WebAPIController.Add_Log("送货单下推", UserName, "生成送货单");
                    objJsonResult.data = 1;
                    return objJsonResult;
                }
                else
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
                    objJsonResult.Message = "保存失败!" + DBUtility.ClsPub.sExeReturnInfo;
                    objJsonResult.data = 1;
                    return objJsonResult;
                }
            }
            catch (Exception e)
            {
                objJsonResult.code = "0";
                objJsonResult.count = 0;
                objJsonResult.Message = "保存失败!" + e.ToString();
                objJsonResult.data = 1;
                return objJsonResult;
            }
        }
        #endregion
        #region  å·¥æ®µ åˆ é™¤
        [Route("Gy_ProcMul/DeltetGy_ProcMul")]
        [HttpGet]
        public object DeltetGy_ProcMul(string HItemID, string user)
        {
            DataSet ds;
            //string ModRightNameCheck = "Sc_ProcessReport_check";
            try
            {
                //删除权限
                if (!DBUtility.ClsPub.Security_Log("Gy_ProcMul_Delete", 1, false, user))
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
                    objJsonResult.Message = "无删除权限!";
                    objJsonResult.data = null;
                    return objJsonResult;
                }
                SQLHelper.ClsCN oCN = new SQLHelper.ClsCN();
                if (string.IsNullOrWhiteSpace(HItemID))
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
                    objJsonResult.Message = "HItemID为空!";
                    objJsonResult.data = null;
                    return objJsonResult;
                }
                oCN.BeginTran();//开始事务
                ds = oCN.RunProcReturn("select * from Gy_ProcMul where HItemID=" + HItemID, "Gy_ProcMul");
                if (ds == null || ds.Tables[0].Rows.Count == 0)
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
                    objJsonResult.Message = "没有数据,无法删除!";
                    objJsonResult.data = null;
                    return objJsonResult; ;
                }
                oCN.RunProc("delete Gy_ProcMul where HItemID=" + HItemID);
                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
        #region å·¥æ®µ ç¼–辑获取细节
        [Route("Gy_ProcMul/GetGy_ProcMulDetail")]
        [HttpGet]
        public object GetGy_ProcMulDetail(string HID)
        {
            try
            {
                List<object> columnNameList = new List<object>();
                string sql1 = "select * from  h_v_Gy_ProcMulList where  HItemID= " + HID + " ";
                ds = oCN.RunProcReturn(sql1, "h_v_Gy_ProcMulList");
                objJsonResult.code = "1";
                objJsonResult.count = 1;
                objJsonResult.Message = "Sucess!";
                objJsonResult.data = ds.Tables[0];
                return objJsonResult;
            }
            catch (Exception e)
            {
                objJsonResult.code = "0";
                objJsonResult.count = 0;
                objJsonResult.Message = "Exception!" + e.ToString();
                objJsonResult.data = null;
                return objJsonResult;
            }
        }
        #endregion
    }
}
WebAPI/Controllers/¹¤×ʹÜÀí/Pay_ProcPriceRequestBillController.cs
@@ -9,7 +9,7 @@
using System.Web.Http;
using WebAPI.Models;
using System.Windows.Forms;
using SyntacticSugar.constant;
namespace WebAPI.Controllers
{
    //班组Controller
@@ -1014,5 +1014,629 @@
            }
        }
        #endregion
        #region å®šé¢ç”³è¯·å•需要我审批流审批的
        [Route("Pay_ProcPriceRequestBill/NeedChecklist")]
        [HttpGet]
        public object NeedChecklist(string user, string userid)
        {
            try
            {
                List<object> columnNameList = new List<object>();
                //判断是否有查询权限
                if (!DBUtility.ClsPub.Security_Log(ModRightNameList, 1, false, user))
                {
                    objJsonResult.code = CodeConstant.FAIL;
                    objJsonResult.count = CountConstant.FAIL;
                    objJsonResult.Message = "无权限查看!";
                    objJsonResult.data = null;
                    return objJsonResult;
                }
                //搜索需要审核的
                string sql = "  select a.*,c.HItemID as HCheckFlowStatusID,m.HName as å®¡æ‰¹æµ,c.HCheckFlowID,i.HName as å®¡æ‰¹é¡¹ç›®åç§°,c.HCheckItemID,c.HChecker as é¡¹ç›®å®¡æ ¸äºº,c.HCheckNote as å®¡æ‰¹æµå®¡æ ¸å»ºè®®,c.HCheckDate å®¡æ‰¹æµå®¡æ ¸æ—¥æœŸ   from h_v_Pay_ProcPriceRequestBillList AS a LEFT JOIN Xt_BillCheckFlowStatus AS c ON a.hmainid = c.HBillInterID and a.HBillType = c.HBillTypeID" +
                    " LEFT JOIN Xt_CheckFlowMain as m ON m.HInterID = c.HCheckFlowID" +
                    " LEFT JOIN Pay_ProcPriceRequestBillMain as po ON a.hmainid = po.HInterID" +
                    " LEFT JOIN Xt_CheckItem as i ON i.HItemID = c.HCheckItemID" +
                    " LEFT JOIN Xt_CheckUserRight as cr ON cr.HCheckItemID = i.HItemID and cr.HCheckFlowInterID = m.HInterID" +
                    " where po.HBillStatus = 6 and po.HCheckItemNowID = i.HItemID  and cr.HUserID = '" + userid + "'";
                ds = oCn.RunProcReturn(sql, "h_v_Pay_ProcPriceRequestBillList");
                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 = CodeConstant.SUCCEED;
                objJsonResult.count = CountConstant.SUCCEED;
                objJsonResult.Message = "Sucess!";
                objJsonResult.data = ds.Tables[0];
                objJsonResult.list = columnNameList;
                return objJsonResult;
            }
            catch (Exception e)
            {
                objJsonResult.code = CodeConstant.FAIL;
                objJsonResult.count = CountConstant.FAIL;
                objJsonResult.Message = "Exception!" + e.ToString();
                objJsonResult.data = null;
                return objJsonResult;
            }
        }
        #endregion
        #region å®šé¢ç”³è¯·å•已经审批流审批的
        [Route("Pay_ProcPriceRequestBill/Checkedlist")]
        [HttpGet]
        public object Checkedlist(string user)
        {
            try
            {
                List<object> columnNameList = new List<object>();
                //判断是否有查询权限
                if (!DBUtility.ClsPub.Security_Log(ModRightNameList, 1, false, user))
                {
                    objJsonResult.code = CodeConstant.FAIL;
                    objJsonResult.count = CountConstant.FAIL;
                    objJsonResult.Message = "无权限查看!";
                    objJsonResult.data = null;
                    return objJsonResult;
                }
                //搜索需要审核的
                string sql = "  select DISTINCT a.*,c.HItemID as HCheckFlowStatusID,m.HName as å®¡æ‰¹æµ,c.HCheckFlowID,i.HName as å®¡æ‰¹é¡¹ç›®åç§°,c.HCheckItemID,c.HChecker as é¡¹ç›®å®¡æ ¸äºº,c.HCheckNote as å®¡æ‰¹æµå®¡æ ¸å»ºè®®,c.HCheckDate å®¡æ‰¹æµå®¡æ ¸æ—¥æœŸ   from h_v_Pay_ProcPriceRequestBillList AS a LEFT JOIN Xt_BillCheckFlowStatus AS c ON a.hmainid = c.HBillInterID and a.HBillType = c.HBillTypeID" +
                    " LEFT JOIN Xt_CheckFlowMain as m ON m.HInterID = c.HCheckFlowID" +
                    " LEFT JOIN Xt_CheckItem as i ON i.HItemID = c.HCheckItemID" +
                    " where c.HCheckDate is  not NUll and c.HChecker = '" + user + "'";
                ds = oCn.RunProcReturn(sql, "h_v_Pay_ProcPriceRequestBillList");
                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 = CodeConstant.SUCCEED;
                objJsonResult.count = CountConstant.SUCCEED;
                objJsonResult.Message = "Sucess!";
                objJsonResult.data = ds.Tables[0];
                objJsonResult.list = columnNameList;
                return objJsonResult;
            }
            catch (Exception e)
            {
                objJsonResult.code = CodeConstant.FAIL;
                objJsonResult.count = CountConstant.FAIL;
                objJsonResult.Message = "Exception!" + e.ToString();
                objJsonResult.data = null;
                return objJsonResult;
            }
        }
        #endregion
        #region å®šé¢ç”³è¯·å•驳回
        [Route("Pay_ProcPriceRequestBill/RejectCheckFlow")]
        [HttpGet]
        public object RejectCheckFlow(string HInterID, string CurUserID)
        {
            try
            {
                Int64 lngBillKey = 0;
                lngBillKey = DBUtility.ClsPub.isLong(HInterID);      //对HInterID进行类型的转换
                DAL.ClsPay_ProcPriceRequestBill oBill = new DAL.ClsPay_ProcPriceRequestBill();                              //实例化单据操作类,用于进行相关操作
                if (oBill.ShowBill(lngBillKey, ref DBUtility.ClsPub.sExeReturnInfo))                    //根据HInterID获取该单据的数据
                {
                    if (oBill.omodel.HBillStatus != 6)
                    {
                        objJsonResult.code = CodeConstant.FAIL;
                        objJsonResult.count = CountConstant.FAIL;
                        objJsonResult.Message = "单据未在审核中不能驳回";
                        objJsonResult.data = null;
                        return objJsonResult;
                    }
                    //发起驳回
                    if (oBill.RejectCheckFlowProgress(lngBillKey, oBill.omodel.HBillNo, CurUserID, ref DBUtility.ClsPub.sExeReturnInfo) == true)
                    {
                        objJsonResult.code = CodeConstant.SUCCEED;
                        objJsonResult.count = CountConstant.SUCCEED;
                        objJsonResult.Message = "驳回成功";
                        objJsonResult.data = null;
                        return objJsonResult;
                    }
                    else
                    {
                        objJsonResult.code = CodeConstant.FAIL;
                        objJsonResult.count = CountConstant.FAIL;
                        objJsonResult.Message = "驳回失败失败!原因:" + DBUtility.ClsPub.sExeReturnInfo;
                        objJsonResult.data = null;
                        return objJsonResult;
                    }
                }
                else
                {
                    objJsonResult.code = CodeConstant.FAIL;
                    objJsonResult.count = CountConstant.FAIL;
                    objJsonResult.Message = "单据不存在!原因:" + DBUtility.ClsPub.sExeReturnInfo;
                    objJsonResult.data = null;
                    return objJsonResult;
                }
            }
            catch (Exception e)
            {
                oCn.RollBack();
                objJsonResult.code = CodeConstant.FAIL;
                objJsonResult.count = CountConstant.FAIL;
                objJsonResult.Message = "Exception!" + e.ToString();
                objJsonResult.data = null;
                return objJsonResult;
            }
        }
        #endregion
        #region å®šé¢ç”³è¯·å• å‘起审批
        [Route("Pay_ProcPriceRequestBill/StartCheckFlow")]
        [HttpGet]
        public object StartCheckFlow(int HInterID, string CurUserName)
        {
            DBUtility.ClsPub.CurUserName = CurUserName;
            try
            {
                ////审核权限
                //if (!DBUtility.ClsPub.Security_Log_second(ModRightNameCheck, 1, false, CurUserName))
                //{
                //    objJsonResult.code = "0";
                //    objJsonResult.count = 0;
                //    objJsonResult.Message = "审核失败!无权限!";
                //    objJsonResult.data = null;
                //    return objJsonResult;
                //}
                //HInterID数据判断
                if (HInterID <= 0)
                {
                    objJsonResult.code = CodeConstant.FAIL;
                    objJsonResult.count = CountConstant.FAIL;
                    objJsonResult.Message = "HInterID小于0!";
                    objJsonResult.data = null;
                    return objJsonResult;
                }
                Int64 lngBillKey = 0;
                lngBillKey = DBUtility.ClsPub.isLong(HInterID);                                         //对HInterID进行类型的转换
                DAL.ClsPay_ProcPriceRequestBill oBill = new DAL.ClsPay_ProcPriceRequestBill();                              //实例化单据操作类,用于进行相关操作
                //发起审批
                if (oBill.startCheckFlow(lngBillKey, ref DBUtility.ClsPub.sExeReturnInfo) == true)
                {
                    objJsonResult.code = CodeConstant.SUCCEED;
                    objJsonResult.count = CountConstant.SUCCEED;
                    objJsonResult.Message = "发起审批成功";
                    objJsonResult.data = null;
                    return objJsonResult;
                }
                else
                {
                    objJsonResult.code = CodeConstant.FAIL;
                    objJsonResult.count = CountConstant.FAIL;
                    objJsonResult.Message = "发起审批失败!原因:" + DBUtility.ClsPub.sExeReturnInfo;
                    objJsonResult.data = null;
                    return objJsonResult;
                }
            }
            catch (Exception e)
            {
                objJsonResult.code = CodeConstant.FAIL;
                objJsonResult.count = CountConstant.FAIL;
                objJsonResult.Message = "发起审批失败失败!" + e.ToString();
                objJsonResult.data = null;
                return objJsonResult;
            }
        }
        #endregion
        #region å®šé¢ç”³è¯·å• å¤šçº§ å®¡æ ¸/反审核
        /// <summary>
        /// </summary>
        /// <param name="HInterID">单据ID</param>
        /// <param name="IsAudit">审核(0),反审核(1)</param>
        /// <param name="CurUserName">审核人</param>
        /// <returns></returns>
        [Route("Pay_ProcPriceRequestBill/AuditFlow")]
        [HttpGet]
        public object AuditPay_ProcPriceRequestBill_Flow(int HInterID, int IsAudit, string CurUserName, string CurUserID)
        {
            //string ModRightNameCheck = "Pay_ProcPriceRequestBill_Check";
            DBUtility.ClsPub.CurUserName = CurUserName;
            try
            {
                ////审核权限
                //if (!DBUtility.ClsPub.Security_Log_second(ModRightNameCheck, 1, false, CurUserName))
                //{
                //    objJsonResult.code = "0";
                //    objJsonResult.count = 0;
                //    objJsonResult.Message = "审核失败!无权限!";
                //    objJsonResult.data = null;
                //    return objJsonResult;
                //}
                //HInterID数据判断
                if (HInterID <= 0)
                {
                    objJsonResult.code = CodeConstant.FAIL;
                    objJsonResult.count = CountConstant.FAIL;
                    objJsonResult.Message = "HInterID小于0!";
                    objJsonResult.data = null;
                    return objJsonResult;
                }
                Int64 lngBillKey = 0;
                lngBillKey = DBUtility.ClsPub.isLong(HInterID);                                         //对HInterID进行类型的转换
                DAL.ClsPay_ProcPriceRequestBill oBill = new DAL.ClsPay_ProcPriceRequestBill();                              //实例化单据操作类,用于进行相关操作
                //针对需要进行的操作,检验当前单据的状态是否支持需要进行的操作
                if (oBill.ShowBill(lngBillKey, ref DBUtility.ClsPub.sExeReturnInfo))                    //根据HInterID获取该单据的数据
                {
                    if (oBill.omodel.HCloseMan.Trim() != "")
                    {
                        objJsonResult.code = CodeConstant.FAIL;
                        objJsonResult.count = CountConstant.FAIL;
                        objJsonResult.Message = "单据已关闭!不能再次审核!";
                        objJsonResult.data = null;
                        return objJsonResult;
                    }
                    if (oBill.omodel.HDeleteMan.Trim() != "")
                    {
                        objJsonResult.code = CodeConstant.FAIL;
                        objJsonResult.count = CountConstant.FAIL;
                        objJsonResult.Message = "单据已作废!不能再次审核!";
                        objJsonResult.data = null;
                        return objJsonResult;
                    }
                    if (IsAudit == TypeConstant.AUDIT)  //审核判断
                    {
                        //判断是否已经发起审批
                        string sql0 = "select * from Xt_BillCheckFlowStatus where HBillInterID = " + lngBillKey + " and HBillTypeID = '" + oBill.BillType + "'";
                        DataSet ds0 = oCn.RunProcReturn(sql0, "Xt_BillCheckFlowStatus");
                        if (ds0 != null && ds0.Tables[0].Rows.Count == 0)
                        {
                            objJsonResult.code = CodeConstant.FAIL;
                            objJsonResult.count = CountConstant.FAIL;
                            objJsonResult.Message = "审核失败!原因:单据未发起审批!";
                            objJsonResult.data = null;
                            return objJsonResult;
                        }
                        //判断单据当前状态
                        if (oBill.omodel.HChecker.Trim() != "")
                        {
                            objJsonResult.code = CodeConstant.FAIL;
                            objJsonResult.count = CountConstant.FAIL;
                            objJsonResult.Message = "审核失败!原因:单据已完成审核!不能继续审核!";
                            objJsonResult.data = null;
                            return objJsonResult;
                        }
                    }
                    if (IsAudit == TypeConstant.REVERSE_AUDIT) //反审核判断
                    {
                        //判断是否存在审核过的项目
                        string sql0 = "select * from Xt_BillCheckFlowStatus where HBillInterID = " + lngBillKey + " and HBillTypeID = '" + oBill.BillType + "' and ISNULL(HChecker,'') <> ''";
                        DataSet ds0 = oCn.RunProcReturn(sql0, "Xt_BillCheckFlowStatus");
                        if (ds0 != null && ds0.Tables[0].Rows.Count == 0)
                        {
                            objJsonResult.code = CodeConstant.FAIL;
                            objJsonResult.count = CountConstant.FAIL;
                            objJsonResult.Message = "反审核失败!原因:单据不存在已经审核的项目!!";
                            objJsonResult.data = null;
                            return objJsonResult;
                        }
                    }
                }
                else
                {
                    objJsonResult.code = CodeConstant.FAIL;
                    objJsonResult.count = CountConstant.FAIL;
                    objJsonResult.Message = "单据不存在!原因:" + DBUtility.ClsPub.sExeReturnInfo;
                    objJsonResult.data = null;
                    return objJsonResult;
                }
                oCn.BeginTran();
                //进行需要进行的审核/反审核操作
                if (IsAudit == TypeConstant.AUDIT) //审核提交
                {
                    #region å®¡æ ¸å‰çš„相关判断
                    //审核前控制=========================================
                    DataSet BeforeDs = oCn.RunProcReturn("Exec h_p_Pay_ProcPriceRequestBill_BeforeCheckCtrl " + HInterID.ToString() + ",'" + CurUserName + "'", "h_p_Pay_ProcPriceRequestBill_BeforeCheckCtrl");
                    if (BeforeDs == null || BeforeDs.Tables[0].Rows.Count == 0)
                    {
                        objJsonResult.code = CodeConstant.FAIL;
                        objJsonResult.count = CountConstant.FAIL;
                        objJsonResult.Message = "审核前判断失败!";
                        objJsonResult.data = null;
                        return objJsonResult;
                    }
                    else
                    {
                        if (DBUtility.ClsPub.isLong(BeforeDs.Tables[0].Rows[0]["HBack"]) == 1)
                        {
                            objJsonResult.code = CodeConstant.FAIL;
                            objJsonResult.count = CountConstant.FAIL;
                            objJsonResult.Message = "审核失败!" + DBUtility.ClsPub.isStrNull(BeforeDs.Tables[0].Rows[0]["HRemark"]);
                            objJsonResult.data = null;
                            return objJsonResult;
                        }
                    }
                    //==================================================================================
                    //进行 ä¼šè®¡æœŸé—´ ç»“è´¦ çš„判断和控制
                    string s = "";
                    int sYear = 0;
                    int sPeriod = 0;
                    DateTime HDate = DateTime.Now;
                    if (DBUtility.Xt_BaseBillFun.Fun_AllowYearPeriod(HDate, ref sYear, ref sPeriod, ref s) == false)
                    {
                        objJsonResult.Message = s;
                        return objJsonResult;
                    }
                    #endregion
                    //获取当前审核项目
                    string sql0 = "select * from " + oBill.MvarItemKey + " where HInterID = " + lngBillKey;
                    DataSet ds0 = oCn.RunProcReturn(sql0, oBill.MvarItemKey);
                    string HCheckFlowID = ds0.Tables[0].Rows[0]["HCheckFlowID"].ToString();             //审批流内码
                    string HCheckItemNowID = ds0.Tables[0].Rows[0]["HCheckItemNowID"].ToString();       //当前审批项目内码
                    string HCheckItemNextID = ds0.Tables[0].Rows[0]["HCheckItemNextID"].ToString();     //待审批项目内码
                    //判断用户是否有权限 å®¡æ‰¹ å½“前审批流的审批项目
                    //string sql01 = "select * from Xt_CheckUserRight where HUserID = '" + CurUserID + "' and HCheckFlowInterID = " + HCheckFlowID + " and HCheckItemID = " + HCheckItemNowID + " and HValue = 1";
                    string sql01 = "select * from Xt_CheckUserRight where HUserID = '" + CurUserID + "' and HCheckFlowInterID = " + HCheckFlowID + " and HCheckItemID = " + HCheckItemNowID + "";
                    DataSet ds01 = oCn.RunProcReturn(sql01, "Xt_CheckUserRight");
                    if (ds01.Tables[0].Rows.Count == 0)
                    {
                        objJsonResult.code = CodeConstant.FAIL;
                        objJsonResult.count = CountConstant.FAIL;
                        objJsonResult.Message = "审核失败!原因:用户无当前审核项目的审核权限!";
                        objJsonResult.data = null;
                        return objJsonResult;
                    }
                    //更新 å•据审批状态表 ä¸­å¯¹åº”审核项目的审核状态
                    string sql02 = "update Xt_BillCheckFlowStatus set HChecker='" + CurUserName + "',HCheckDate=getdate() where HBillTypeID = '" + oBill.BillType + "' and HBillInterID=" + lngBillKey + " and HCheckFlowID=" + HCheckFlowID + " and HCheckItemID=" + HCheckItemNowID;
                    oCn.RunProc(sql02);
                    //判断当前审核项目是否是最后一个项目,如果是,审核后反写单据的单据状态。如果不是,获取下一个审核项目并更新到销售订单主表
                    if (HCheckItemNextID != "0")                //刚刚审核的审核项目不是最后一个审核项目
                    {
                        string sql03 = "select b.HInterID,b.HCheckItemID from Xt_CheckFlowMain as a " +
                                "inner join Xt_CheckFlowSub as b on a.HInterID = b.HInterID " +
                                "where a.HBillTypeID = '" + oBill.BillType + "' " +
                                "and a.HInterID = " + HCheckFlowID + " " +
                                "order by b.HFlowNo asc";
                        DataSet ds03 = oCn.RunProcReturn(sql03, "Xt_CheckFlowMain");
                        //获取新的当前审核项目和待审核项目
                        for (int i = 0; i < ds03.Tables[0].Rows.Count; i++)
                        {
                            if (ds03.Tables[0].Rows[i]["HCheckItemID"].ToString() == HCheckItemNextID)
                            {
                                HCheckItemNowID = HCheckItemNextID;
                            }
                            else if (HCheckItemNowID == HCheckItemNextID)
                            {
                                HCheckItemNextID = ds03.Tables[0].Rows[i]["HCheckItemID"].ToString();
                                break;
                            }
                        }
                        //新的当前审核项目为最后一个审核项目,待审核项目不存在,设为默认值"0"
                        if (HCheckItemNowID == HCheckItemNextID)
                        {
                            HCheckItemNextID = "0";
                        }
                        //更新单据主表的审批流数据
                        string sql04 = "update " + oBill.MvarItemKey + " set HCheckItemNowID=" + HCheckItemNowID + ",HCheckItemNextID=" + HCheckItemNextID + " where HInterID = " + lngBillKey;
                        oCn.RunProc(sql04);
                        objJsonResult.code = CodeConstant.SUCCEED;
                        objJsonResult.count = CountConstant.SUCCEED;
                        objJsonResult.Message = "审核成功";
                        objJsonResult.data = null;
                    }
                    else                                                                //刚刚审核的审核项目是最后一个审核项目
                    {
                        //更新单据主表的审批流数据
                        HCheckItemNowID = "0";
                        HCheckItemNextID = "0";
                        string sql04 = "update " + oBill.MvarItemKey + " set HCheckItemNowID=" + HCheckItemNowID + ",HCheckItemNextID=" + HCheckItemNextID + " where HInterID = " + lngBillKey;
                        oCn.RunProc(sql04);
                        //更新单据的单据状态
                        if (oBill.CheckBill(oBill.omodel.HInterID, oBill.omodel.HBillNo, "h_p_Pay_ProcPriceRequestBill_AfterCheckCtrl", CurUserName, ref DBUtility.ClsPub.sExeReturnInfo) == true)
                        {
                            objJsonResult.code = CodeConstant.SUCCEED;
                            objJsonResult.count = CountConstant.SUCCEED;
                            objJsonResult.Message = "审核成功";
                            objJsonResult.data = null;
                        }
                        else
                        {
                            objJsonResult.code = CodeConstant.FAIL;
                            objJsonResult.count = CountConstant.FAIL;
                            objJsonResult.Message = "审核失败!原因:" + DBUtility.ClsPub.sExeReturnInfo;
                            objJsonResult.data = null;
                            oCn.RollBack();
                            return objJsonResult;
                        }
                    }
                }
                if (IsAudit == TypeConstant.REVERSE_AUDIT) //反审核提交
                {
                    #region åå®¡æ ¸å‰çš„相关判断
                    //反审核前控制=========================================
                    DataSet BeforeDs = oCn.RunProcReturn("Exec h_p_Pay_ProcPriceRequestBill_BeforeUnCheckCtrl " + HInterID.ToString() + ",'" + CurUserName + "'", "h_p_Pay_ProcPriceRequestBill_BeforeUnCheckCtrl");
                    if (BeforeDs == null || BeforeDs.Tables[0].Rows.Count == 0)
                    {
                        objJsonResult.code = CodeConstant.FAIL;
                        objJsonResult.count = CountConstant.FAIL;
                        objJsonResult.Message = "反审核前判断失败!";
                        objJsonResult.data = null;
                        return objJsonResult;
                    }
                    else
                    {
                        if (DBUtility.ClsPub.isLong(BeforeDs.Tables[0].Rows[0]["HBack"]) == 1)
                        {
                            objJsonResult.code = CodeConstant.FAIL;
                            objJsonResult.count = CountConstant.FAIL;
                            objJsonResult.Message = "反审核失败!" + DBUtility.ClsPub.isStrNull(BeforeDs.Tables[0].Rows[0]["HRemark"]);
                            objJsonResult.data = null;
                            return objJsonResult;
                        }
                    }
                    //=========================================================
                    //进行 ä¼šè®¡æœŸé—´ ç»“è´¦ çš„判断和控制
                    string s = "";
                    int sYear = 0;
                    int sPeriod = 0;
                    DateTime HDate = DateTime.Now;
                    if (DBUtility.Xt_BaseBillFun.Fun_AllowYearPeriod(HDate, ref sYear, ref sPeriod, ref s) == false)
                    {
                        objJsonResult.Message = s;
                        return objJsonResult;
                    }
                    #endregion
                    //获取需要反审核的审核项目
                    string sql0 = "select c.* from Xt_CheckFlowMain as a " +
                                  "inner join Xt_CheckFlowSub as b on a.HInterID = b.HInterID " +
                                  "inner join Xt_BillCheckFlowStatus as c on a.HBillTypeID = c.HBillTypeID and b.HCheckItemID = c.HCheckItemID " +
                                  "where c.HBillTypeID = '" + oBill.BillType + "' and c.HBillInterID = " + lngBillKey + " " +
                                  "order by b.HFlowNo asc";
                    DataSet ds0 = oCn.RunProcReturn(sql0, "Xt_BillCheckFlowStatus");
                    if (ds0 == null || ds0.Tables[0].Rows.Count == 0)
                    {
                        objJsonResult.code = CodeConstant.FAIL;
                        objJsonResult.count = CountConstant.FAIL;
                        objJsonResult.Message = "反审核失败!原因:未发起审批!";
                        objJsonResult.data = null;
                        return objJsonResult;
                    }
                    string HCheckFlowID = ds0.Tables[0].Rows[0]["HCheckFlowID"].ToString();             //审批流内码
                    string HCheckItemNowID = "0";       //当前审批项目内码
                    string HCheckItemNextID = "0";     //待审批项目内码
                    if (oBill.omodel.HBillStatus == 6)
                    {
                        for (int i = 0; i < ds0.Tables[0].Rows.Count; i++)
                        {
                            if (ds0.Tables[0].Rows[i]["HChecker"].ToString() != "")
                            {
                                HCheckItemNowID = ds0.Tables[0].Rows[i]["HCheckItemID"].ToString();
                                HCheckItemNextID = ds0.Tables[0].Rows[i]["HCheckItemID"].ToString();
                            }
                            else
                            {
                                HCheckItemNextID = ds0.Tables[0].Rows[i]["HCheckItemID"].ToString();
                                break;
                            }
                        }
                        if (HCheckItemNowID == HCheckItemNextID)
                        {
                            HCheckItemNextID = "0";
                        }
                    }
                    else
                    {
                        HCheckItemNowID = ds0.Tables[0].Rows[ds0.Tables[0].Rows.Count - 1]["HCheckItemID"].ToString();
                        HCheckItemNextID = "0";
                    }
                    //判断用户是否有权限 å®¡æ‰¹ å½“前审批流的审批项目
                    //string sql01 = "select * from Xt_CheckUserRight where HUserID = '" + CurUserID + "' and HCheckFlowInterID = " + HCheckFlowID + " and HCheckItemID = " + HCheckItemNowID + " and HValue = 1";
                    string sql01 = "select * from Xt_CheckUserRight where HUserID = '" + CurUserID + "' and HCheckFlowInterID = " + HCheckFlowID + " and HCheckItemID = " + HCheckItemNowID + "";
                    DataSet ds01 = oCn.RunProcReturn(sql01, "Xt_CheckUserRight");
                    if (ds01.Tables[0].Rows.Count == 0)
                    {
                        objJsonResult.code = CodeConstant.FAIL;
                        objJsonResult.count = CountConstant.FAIL;
                        objJsonResult.Message = "反审核失败!原因:用户无当前审核项目的审核权限!";
                        objJsonResult.data = null;
                        return objJsonResult;
                    }
                    //更新 å•据审批状态表 ä¸­å¯¹åº”审核项目的审核状态
                    string sql02 = "update Xt_BillCheckFlowStatus set HChecker='',HCheckDate='' where HBillTypeID = '" + oBill.BillType + "' and HBillInterID=" + lngBillKey + " and HCheckFlowID=" + HCheckFlowID + " and HCheckItemID=" + HCheckItemNowID;
                    oCn.RunProc(sql02);
                    //判断反审核的单据是否已经审核完成,若审核完成,反审核需要变更单据状态。
                    if (oBill.omodel.HBillStatus == 6)
                    {
                        //更新单据主表的审批流数据
                        string sql04 = "update " + oBill.MvarItemKey + " set HCheckItemNowID=" + HCheckItemNowID + ",HCheckItemNextID=" + HCheckItemNextID + " where HInterID = " + lngBillKey;
                        oCn.RunProc(sql04);
                        objJsonResult.code = CodeConstant.SUCCEED;
                        objJsonResult.count = CountConstant.SUCCEED;
                        objJsonResult.Message = "审核成功";
                        objJsonResult.data = null;
                    }
                    else
                    {
                        //反审核提交AbandonCheck
                        if (oBill.AbandonCheck(oBill.omodel.HInterID, oBill.omodel.HBillNo, "h_p_Pay_ProcPriceRequestBill_AfterUnCheckCtrl", CurUserName, ref DBUtility.ClsPub.sExeReturnInfo) == true)
                        {
                            //更新单据主表的审批流数据
                            string sql04 = "update " + oBill.MvarItemKey + " set HCheckItemNowID=" + HCheckItemNowID + ",HCheckItemNextID=" + HCheckItemNextID + ",HBillStatus=6 " + " where HInterID = " + lngBillKey;
                            oCn.RunProc(sql04);
                            objJsonResult.code = CodeConstant.SUCCEED;
                            objJsonResult.count = CountConstant.SUCCEED;
                            objJsonResult.Message = "反审核成功";
                            objJsonResult.data = null;
                        }
                        else
                        {
                            objJsonResult.code = CodeConstant.FAIL;
                            objJsonResult.count = CountConstant.FAIL;
                            objJsonResult.Message = "反审核失败!原因:" + DBUtility.ClsPub.sExeReturnInfo;
                            objJsonResult.data = null;
                            oCn.RollBack();
                            return objJsonResult;
                        }
                    }
                }
                oCn.Commit();
                return objJsonResult;
            }
            catch (Exception e)
            {
                objJsonResult.code = CodeConstant.FAIL;
                objJsonResult.count = CountConstant.FAIL;
                objJsonResult.Message = "审核失败或者反审核失败!" + e.ToString();
                objJsonResult.data = null;
                oCn.RollBack();
                return objJsonResult;
            }
        }
        #endregion
    }
}
WebAPI/DLL/ClsGy_ProcMul_Ctl.cs
New file
@@ -0,0 +1,102 @@
using System;
using System.Collections.Generic;
using System.Text;
using System.Data;
namespace WebAPI.DLL
{
    public class ClsGy_ProcMul_Ctl : DBUtility.ClsGy_Base_Ctl
    {
        SQLHelper.ClsCN oCn = new SQLHelper.ClsCN();
        //原代码 ç”¨äºŽ æ›¿æ¢å­é¡¹ç›®
        public string HOldNumber;
        public Model.ClsGy_ProcMul_Model oModel = new Model.ClsGy_ProcMul_Model();
        //新增
        public override bool AddNew()
        {
            //
            try
            {
                oCn.BeginTran();
                oCn.RunProc("Insert into " + MvarItemKey + " " +
                    " (HNumber,HName,HHelpCode,HShortNumber,HParentID" +
                    ",HLevel,HEndFlag,HStopflag,HRemark,HMakeTime,HUSEORGID,HUseFlag,HMakeEmp,HCREATEORGID,HDeptID) " +
                    " Values('" + oModel.HNumber + "','" + oModel.HName + "','" + oModel.HHelpCode + "','" + oModel.HShortNumber + "'," + oModel.HParentID.ToString() +
                    "," + oModel.HLevel.ToString() + "," + Convert.ToString(oModel.HEndFlag ? 1 : 0) + "," + Convert.ToString(oModel.HStopflag ? 1 : 0) + ",'" + oModel.HRemark + "','" +DateTime.Now+ "','" + oModel.HUSEORGID + "','" + oModel.HUseFlag + "','" + oModel.HMakeEmp+ "','" + oModel.HUSEORGID +"'," + oModel.HDeptID+")", ref DBUtility.ClsPub.sExeReturnInfo);
                //修改上级为非末级代码
                oCn.RunProc("Update " + MvarItemKey + " set HEndflag=0 where HItemID=" + oModel.HParentID, ref DBUtility.ClsPub.sExeReturnInfo);
                oCn.Commit();
                return true;
            }
            catch (Exception e)
            {
                oCn.RollBack();
                throw (e);
            }
        }
        //修改
        public override bool ModifyByID(Int64 sItemID)
        {
            try
            {
                oCn.BeginTran();
                oCn.RunProc("Update " + MvarItemKey + " set " +
                    " HNumber='" + oModel.HNumber + "'" +
                    ",HName='" + oModel.HName + "'" +
                    ",HShortNumber='" + oModel.HShortNumber + "'" +
                    ",HHelpCode='" + oModel.HHelpCode + "'" +
                    ",HModifyTime='" + DateTime.Now + "'" +
                    ",HUSEORGID='" + oModel.HUSEORGID + "'" +
                    ",HModifyEmp ='" + oModel.HMakeEmp + "'" +
                    ",HUseFlag='" + oModel.HUseFlag + "'" +
                    ",HStopflag=" + Convert.ToString(oModel.HStopflag ? 1 : 0) +
                    ",HRemark= '" + oModel.HRemark + "',"+
                    "HDeptID = "+ oModel.HDeptID + " Where HItemID=" + sItemID, ref DBUtility.ClsPub.sExeReturnInfo);
                //修改子项目代码
                oCn.RunProc("exec h_p_Gy_UpdateNumber '" + MvarItemKey + "','" + oModel.HNumber + ".','" + this.HOldNumber + ".'", ref DBUtility.ClsPub.sExeReturnInfo);
                //将上级 ä¸ºéžæœ«çº§
                oCn.RunProc("Update " + MvarItemKey + " set HEndflag=0 where HItemID=" + oModel.HParentID, ref DBUtility.ClsPub.sExeReturnInfo);
                //
                oCn.Commit();
                return true;
            }
            catch (Exception e)
            {
                oCn.RollBack();
                throw (e);
            }
        }
        //根据代码判断信息
        public override bool HavParentCode(string sCode, Int64 sItemID)
        {
            DataSet DS;
            try
            {
                DS = oCn.RunProcReturn("Select * from " + MvarItemKey + " Where HStopflag=0 and HNumber='" + sCode + "' and HItemID<>" + sItemID, MvarItemKey, ref Pub_Class.ClsPub.sExeReturnInfo);
                if (DS.Tables[0].Rows.Count == 0)
                    return false;
                else
                {
                    oModel.HItemID = Convert.ToInt64(DS.Tables[0].Rows[0]["HItemID"]);
                    return true;
                }
            }
            catch (Exception e)
            {
                throw (e);
            }
        }
        //构造函数
        public ClsGy_ProcMul_Ctl()
        {
            MvarItemKey = "Gy_ProcMul";
            MvarReportTitle = "工段设置";
            oModel = new Model.ClsGy_ProcMul_Model();
        }
    }
}
WebAPI/Properties/PublishProfiles/FolderProfilewtt.pubxml.user
@@ -4,7 +4,7 @@
-->
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
  <PropertyGroup>
    <History>True|2024-09-25T08:07:23.2747063Z;True|2024-09-25T14:55:37.9194143+08:00;True|2024-09-24T20:03:43.9841995+08:00;True|2024-09-24T19:42:48.7479102+08:00;True|2024-09-24T19:38:31.5777012+08:00;True|2024-09-24T16:26:58.5969765+08:00;True|2024-09-24T15:31:00.7140362+08:00;True|2024-09-24T10:17:46.7830753+08:00;True|2024-09-24T09:40:19.5788062+08:00;False|2024-09-24T09:39:27.4521802+08:00;True|2024-09-23T19:35:55.3572583+08:00;True|2024-09-23T18:53:15.4480118+08:00;False|2024-09-23T18:52:22.0135173+08:00;True|2024-09-20T09:59:12.9943442+08:00;False|2024-09-20T09:58:18.6945854+08:00;True|2024-09-12T20:40:58.7161451+08:00;False|2024-09-12T20:40:00.0672966+08:00;True|2024-09-12T16:47:22.7671323+08:00;True|2024-09-12T16:34:18.5850144+08:00;True|2024-09-12T16:13:32.1929032+08:00;True|2024-09-12T09:12:54.4456999+08:00;False|2024-09-12T09:12:06.1002866+08:00;False|2024-09-11T21:06:15.4423786+08:00;True|2024-09-10T15:26:48.7055081+08:00;True|2024-09-10T09:26:36.8509916+08:00;True|2024-09-09T19:51:32.6059511+08:00;True|2024-09-09T19:05:47.5349922+08:00;True|2024-09-09T09:26:23.2022383+08:00;False|2024-09-09T09:25:27.3736749+08:00;True|2024-09-06T15:32:52.1865278+08:00;True|2024-09-06T15:16:01.1405794+08:00;True|2024-09-06T14:21:05.7482343+08:00;True|2024-09-06T14:09:17.1494566+08:00;True|2024-09-06T13:49:56.4128481+08:00;True|2024-09-06T13:11:53.0863947+08:00;True|2024-09-06T09:34:54.5934463+08:00;True|2024-09-06T08:47:19.9744092+08:00;True|2024-09-05T15:01:38.6968629+08:00;True|2024-09-05T14:56:09.3505818+08:00;True|2024-09-05T14:49:56.8774757+08:00;True|2024-09-05T08:14:13.2359921+08:00;False|2024-09-05T08:13:11.8797534+08:00;True|2024-09-03T16:52:02.8227375+08:00;False|2024-09-03T16:51:32.4250926+08:00;True|2024-09-03T16:33:05.7269609+08:00;True|2024-09-03T16:00:15.0288548+08:00;True|2024-08-29T08:06:32.4732067+08:00;False|2024-08-29T08:06:02.4801886+08:00;True|2024-08-26T10:17:08.7733750+08:00;False|2024-08-26T10:11:05.1864217+08:00;False|2024-08-26T09:50:31.1539306+08:00;False|2024-08-26T09:47:37.4351309+08:00;True|2024-08-16T16:55:32.0918962+08:00;True|2024-08-16T16:53:23.3505641+08:00;False|2024-08-16T16:49:30.4579212+08:00;False|2024-08-16T16:47:01.9799743+08:00;</History>
    <History>True|2024-09-26T01:50:22.2637977Z;True|2024-09-25T20:44:33.3994634+08:00;True|2024-09-25T16:07:23.2747063+08:00;True|2024-09-25T14:55:37.9194143+08:00;True|2024-09-24T20:03:43.9841995+08:00;True|2024-09-24T19:42:48.7479102+08:00;True|2024-09-24T19:38:31.5777012+08:00;True|2024-09-24T16:26:58.5969765+08:00;True|2024-09-24T15:31:00.7140362+08:00;True|2024-09-24T10:17:46.7830753+08:00;True|2024-09-24T09:40:19.5788062+08:00;False|2024-09-24T09:39:27.4521802+08:00;True|2024-09-23T19:35:55.3572583+08:00;True|2024-09-23T18:53:15.4480118+08:00;False|2024-09-23T18:52:22.0135173+08:00;True|2024-09-20T09:59:12.9943442+08:00;False|2024-09-20T09:58:18.6945854+08:00;True|2024-09-12T20:40:58.7161451+08:00;False|2024-09-12T20:40:00.0672966+08:00;True|2024-09-12T16:47:22.7671323+08:00;True|2024-09-12T16:34:18.5850144+08:00;True|2024-09-12T16:13:32.1929032+08:00;True|2024-09-12T09:12:54.4456999+08:00;False|2024-09-12T09:12:06.1002866+08:00;False|2024-09-11T21:06:15.4423786+08:00;True|2024-09-10T15:26:48.7055081+08:00;True|2024-09-10T09:26:36.8509916+08:00;True|2024-09-09T19:51:32.6059511+08:00;True|2024-09-09T19:05:47.5349922+08:00;True|2024-09-09T09:26:23.2022383+08:00;False|2024-09-09T09:25:27.3736749+08:00;True|2024-09-06T15:32:52.1865278+08:00;True|2024-09-06T15:16:01.1405794+08:00;True|2024-09-06T14:21:05.7482343+08:00;True|2024-09-06T14:09:17.1494566+08:00;True|2024-09-06T13:49:56.4128481+08:00;True|2024-09-06T13:11:53.0863947+08:00;True|2024-09-06T09:34:54.5934463+08:00;True|2024-09-06T08:47:19.9744092+08:00;True|2024-09-05T15:01:38.6968629+08:00;True|2024-09-05T14:56:09.3505818+08:00;True|2024-09-05T14:49:56.8774757+08:00;True|2024-09-05T08:14:13.2359921+08:00;False|2024-09-05T08:13:11.8797534+08:00;True|2024-09-03T16:52:02.8227375+08:00;False|2024-09-03T16:51:32.4250926+08:00;True|2024-09-03T16:33:05.7269609+08:00;True|2024-09-03T16:00:15.0288548+08:00;True|2024-08-29T08:06:32.4732067+08:00;False|2024-08-29T08:06:02.4801886+08:00;True|2024-08-26T10:17:08.7733750+08:00;False|2024-08-26T10:11:05.1864217+08:00;False|2024-08-26T09:50:31.1539306+08:00;False|2024-08-26T09:47:37.4351309+08:00;True|2024-08-16T16:55:32.0918962+08:00;True|2024-08-16T16:53:23.3505641+08:00;False|2024-08-16T16:49:30.4579212+08:00;False|2024-08-16T16:47:01.9799743+08:00;</History>
    <_PublishTargetUrl>G:\issWeb\网站发布\API</_PublishTargetUrl>
  </PropertyGroup>
  <ItemGroup>
@@ -45,28 +45,28 @@
      <publishTime>02/22/2013 16:43:40</publishTime>
    </File>
    <File Include="bin/BLL.dll">
      <publishTime>09/25/2024 16:06:54</publishTime>
      <publishTime>09/29/2024 18:19:44</publishTime>
    </File>
    <File Include="bin/BLL.pdb">
      <publishTime>09/25/2024 16:06:54</publishTime>
      <publishTime>09/29/2024 18:19:44</publishTime>
    </File>
    <File Include="bin/BouncyCastle.Crypto.dll">
      <publishTime>12/18/2020 05:32:28</publishTime>
    </File>
    <File Include="bin/DAL.dll">
      <publishTime>09/25/2024 16:06:52</publishTime>
      <publishTime>09/29/2024 18:19:42</publishTime>
    </File>
    <File Include="bin/DAL.pdb">
      <publishTime>09/25/2024 16:06:52</publishTime>
      <publishTime>09/29/2024 18:19:42</publishTime>
    </File>
    <File Include="bin/Dapper.dll">
      <publishTime>07/22/2016 22:52:40</publishTime>
    </File>
    <File Include="bin/DBUtility.dll">
      <publishTime>09/25/2024 16:06:47</publishTime>
      <publishTime>09/29/2024 18:19:37</publishTime>
    </File>
    <File Include="bin/DBUtility.pdb">
      <publishTime>09/25/2024 16:06:47</publishTime>
      <publishTime>09/29/2024 18:19:37</publishTime>
    </File>
    <File Include="bin/Grpc.Core.Api.dll">
      <publishTime>03/22/2022 13:17:26</publishTime>
@@ -111,10 +111,10 @@
      <publishTime>07/25/2012 19:48:56</publishTime>
    </File>
    <File Include="bin/Model.dll">
      <publishTime>09/25/2024 16:06:49</publishTime>
      <publishTime>09/29/2024 18:19:38</publishTime>
    </File>
    <File Include="bin/Model.pdb">
      <publishTime>09/25/2024 16:06:49</publishTime>
      <publishTime>09/29/2024 18:19:38</publishTime>
    </File>
    <File Include="bin/Models/ClsSc_MouldScrapOutBillMain.cs">
      <publishTime>04/15/2024 12:55:45</publishTime>
@@ -147,34 +147,34 @@
      <publishTime>10/23/2021 17:07:54</publishTime>
    </File>
    <File Include="bin/Pub_Class.dll">
      <publishTime>09/25/2024 16:06:46</publishTime>
      <publishTime>09/29/2024 18:19:35</publishTime>
    </File>
    <File Include="bin/Pub_Class.pdb">
      <publishTime>09/25/2024 16:06:46</publishTime>
      <publishTime>09/29/2024 18:19:35</publishTime>
    </File>
    <File Include="bin/Pub_Control.dll">
      <publishTime>09/25/2024 16:06:46</publishTime>
      <publishTime>09/29/2024 18:19:36</publishTime>
    </File>
    <File Include="bin/Pub_Control.pdb">
      <publishTime>09/25/2024 16:06:46</publishTime>
      <publishTime>09/29/2024 18:19:36</publishTime>
    </File>
    <File Include="bin/RestSharp.dll">
      <publishTime>08/31/2012 06:22:50</publishTime>
    </File>
    <File Include="bin/SQLHelper.dll">
      <publishTime>09/25/2024 16:06:46</publishTime>
      <publishTime>09/29/2024 18:19:36</publishTime>
    </File>
    <File Include="bin/SQLHelper.pdb">
      <publishTime>09/25/2024 16:06:46</publishTime>
      <publishTime>09/29/2024 18:19:36</publishTime>
    </File>
    <File Include="bin/Swashbuckle.Core.dll">
      <publishTime>02/16/2015 01:57:08</publishTime>
    </File>
    <File Include="bin/SyntacticSugar.dll">
      <publishTime>09/25/2024 16:04:54</publishTime>
      <publishTime>09/29/2024 18:17:40</publishTime>
    </File>
    <File Include="bin/SyntacticSugar.pdb">
      <publishTime>09/25/2024 16:04:54</publishTime>
      <publishTime>09/29/2024 18:17:40</publishTime>
    </File>
    <File Include="bin/System.Buffers.dll">
      <publishTime>07/19/2017 18:01:28</publishTime>
@@ -285,19 +285,19 @@
      <publishTime>05/09/2023 10:43:40</publishTime>
    </File>
    <File Include="bin/TopSdk.dll">
      <publishTime>09/25/2024 16:05:00</publishTime>
      <publishTime>09/29/2024 18:17:46</publishTime>
    </File>
    <File Include="bin/TopSdk.pdb">
      <publishTime>09/25/2024 16:05:00</publishTime>
      <publishTime>09/29/2024 18:17:46</publishTime>
    </File>
    <File Include="bin/WebActivatorEx.dll">
      <publishTime>11/24/2014 19:18:48</publishTime>
    </File>
    <File Include="bin/WebAPI.dll">
      <publishTime>09/25/2024 16:07:20</publishTime>
      <publishTime>09/29/2024 18:20:15</publishTime>
    </File>
    <File Include="bin/WebAPI.pdb">
      <publishTime>09/25/2024 16:07:20</publishTime>
      <publishTime>09/29/2024 18:20:15</publishTime>
    </File>
    <File Include="bin/WebAPI.XmlSerializers.dll">
      <publishTime>08/16/2024 16:55:28</publishTime>
WebAPI/WebAPI.csproj
@@ -598,6 +598,7 @@
    <Compile Include="Controllers\基础资料\基础资料\Gy_OperatorController.cs" />
    <Compile Include="Controllers\基础资料\基础资料\Gy_PaymentConditionListBillController.cs" />
    <Compile Include="Controllers\基础资料\基础资料\Gy_DisposeWayController.cs" />
    <Compile Include="Controllers\基础资料\基础资料\Gy_ProcMulController.cs" />
    <Compile Include="Controllers\基础资料\基础资料\Gy_ScrapReasonController.cs" />
    <Compile Include="Controllers\基础资料\基础资料\Gy_TemporaryAreaController.cs" />
    <Compile Include="Controllers\基础资料\基础资料\Gy_RateTypeController.cs" />
@@ -724,6 +725,7 @@
    <Compile Include="Dapper\SqlPools.cs" />
    <Compile Include="DbUntil\DataFormatUntil.cs" />
    <Compile Include="DLL\ClsGy_BadPhenomena_Ctl.cs" />
    <Compile Include="DLL\ClsGy_ProcMul_Ctl.cs" />
    <Compile Include="DLL\ClsGy_TechnologyParameterType_Ctl.cs" />
    <Compile Include="DLL\ClsGy_InspectInstruMent_Ctl.cs" />
    <Compile Include="DLL\ClsGy_InspectBasis_Ctl.cs" />
sdk_dingding/TopSdk/bin/Debug/TopSdk.dll
Binary files differ
sdk_dingding/TopSdk/bin/Debug/TopSdk.pdb
Binary files differ
sdk_dingding/TopSdk/obj/Debug/TopSdk.dll
Binary files differ
sdk_dingding/TopSdk/obj/Debug/TopSdk.pdb
Binary files differ