/// <summary> /// 加载列表 /// </summary> /// <returns></returns> public TableData Load() { return(new TableData() { statusText = "success", data = RoleManagerApp.Load() }); }
public Response <Role> Update([FromBody] Role role) { var result = new Response <Role>(); try { RoleManagerApp.Update(role); } catch (Exception e) { result.Code = 500; result.Message = e.InnerException?.Message ?? e.Message; } return(result); }
public Response <string> Delete(string ids) { var result = new Response <string>(); try { RoleManagerApp.Delete(ids); result.Result = ids; } catch (Exception e) { result.Code = 500; result.Message = e.InnerException?.Message ?? e.Message; } return(result); }
public RolesController(RoleManagerApp roleManagerApp, IAuth auth) { RoleManagerApp = roleManagerApp; Auth = auth; }
public RoleManagerController() { _app = AutofacExt.GetFromFac <RoleManagerApp>(); }