public ShowRole GetAllot([FromForm] RBAC_Allots model) { int Rowcount = 0; List <RBAC_Allots> slist = _allotinterface.GetAllot(model.PageIndex, model.PageSize, model.Dep_Name, ref Rowcount); int count = (Rowcount / model.PageSize) + (Rowcount % model.PageSize > 0 ? 1 : 0); ShowRole show = new ShowRole(); show.alist = slist; show.Count = count; return(show); }
//添加权限分配 public int AddAllot(RBAC_Allots model) { string ProName = "pro_Add_Allot"; SqlParameter[] parametr = new SqlParameter[] { new SqlParameter { ParameterName = "@Allot_Code", Value = model.Allot_Code, DbType = DbType.String, Direction = ParameterDirection.Input }, new SqlParameter { ParameterName = "@Allot_Name", Value = model.Allot_Name, DbType = DbType.String, Direction = ParameterDirection.Input }, new SqlParameter { ParameterName = "@Allot_Grade", Value = model.Allot_Grade, DbType = DbType.String, Direction = ParameterDirection.Input }, new SqlParameter { ParameterName = "@Allot_BaoId", Value = model.Allot_BaoId, DbType = DbType.String, Direction = ParameterDirection.Input }, }; return(_idbhelper.ExecuteNonQueryProc(ProName, parametr)); }
public int Update_Role([FromForm] RBAC_Allots model) { return(_allotinterface.UpdaAllot(model)); }
public int Add_Allot([FromForm] RBAC_Allots model) { return(_allotinterface.AddAllot(model)); }