/// <summary> /// 编辑班级 /// </summary> /// <param name="args"></param> /// <returns></returns> public CommandResult <int> UpdateClass(UpdateClassesArgs args) { ArgumentHelper.Require(args.SchoolId, "SchoolId", Arguments.Positive); ArgumentHelper.Require(args.ModifyBy, "ModifyBy", Arguments.Positive); return(ContainerFactory <IClassesRepository> .Instance.UpdateClass(args)); }
public string UpdateClass(UpdateClassesArgs model) { if (model != null) { model.ModifyBy = ApplicationContext.UserId; model.SchoolId = ApplicationContext.SchoolId; var result = ClassesService.Instance.UpdateClass(model); return(JsonHelper.Serialize(result)); } return(JsonHelper.Serialize(CommandResult.Failure <int>())); }
public CommandResult <int> UpdateClass(UpdateClassesArgs args) { try { var result = ContainerFactory <ISqlExcuteContext> .Instance.ExcuteProceDure(args.SchoolId, "update_class", args); return(result); } catch (Exception e) { LogHelper.Error(this.GetType(), "班级管理-编辑班级失败,ClassId:" + args.ClassId, e); return(CommandResult.Failure <int>(e.ToString())); } }