yangle
2024-07-17 2eef7800f97ba845780c8eee1da191fff4b18d94
WebAPI/DLL/ClsGy_RestDay_Ctl.cs
@@ -15,8 +15,12 @@
        //新增
        public override bool AddNew()
        {
            //
            DataSet ds;
            try
            {
                //先查看数据库有没有
                ds = oCn.RunProcReturn("select * from Gy_RestDay where HRestDay='" + oModel.HRestDay.ToString() + "' and HOrgID='" + oModel.HOrgID.ToString() + "' and HDeptID='" + oModel.HDeptID.ToString() + "'", "Gy_RestDay");
                if (ds.Tables[0].Rows.Count < 1)
            {
                oCn.BeginTran();
                oCn.RunProc("Insert into " + MvarItemKey + " " +
@@ -31,6 +35,12 @@
                oCn.Commit();
                return true;
            }
                else
                {
                    return false;
                }
            }
            catch (Exception e)
            {
                oCn.RollBack();