/// <summary> /// 修改计划任务截止时间 /// </summary> /// <param name="model"></param> /// <returns></returns> public int UpdateScheduleDeadLine(DBModelTimeCustom model) { try { int res = mapContext.Update("UpdateScheduleDeadLine", model); return(res); } catch (Exception ex) { throw ex; } }
/// <summary> /// 修改计划延期时间 /// </summary> /// <param name="id"></param> /// <param name="deadLineType"></param> /// <param name="endTime"></param> /// <returns></returns> public bool DelayDeadLine(int id, int delayMonth, DateTime endTime) { try { DBModelTimeCustom custom = new DBModelTimeCustom(); //DateTime tranEndTime = DateTime.Parse(endTime); //custom.dt = tranEndTime.AddMonths(delayMonth); custom.dt = endTime.AddMonths(delayMonth); custom.id = id; int res = servScheduleDal.UpdateScheduleDeadLine(custom); return(res > 0 ? true : false); } catch (Exception ex) { throw ex; } }