mirror of
https://gitee.com/dotnetchina/OpenAuth.Net.git
synced 2025-09-20 10:37:55 +08:00
v1.1 实现用户分级授权,得到权限的用户只能在自己的权限范围内再进一步操作
This commit is contained in:
@@ -46,7 +46,7 @@ namespace OpenAuth.Mvc.Controllers
|
||||
/// </summary>
|
||||
public string Load(int categoryId, int pageCurrent = 1, int pageSize = 30)
|
||||
{
|
||||
return JsonHelper.Instance.Serialize(_app.Load(categoryId, pageCurrent, pageSize));
|
||||
return JsonHelper.Instance.Serialize(_app.Load(User.Identity.Name, categoryId, pageCurrent, pageSize));
|
||||
}
|
||||
|
||||
public string LoadForTree()
|
||||
@@ -94,7 +94,7 @@ namespace OpenAuth.Mvc.Controllers
|
||||
/// <returns>System.String.</returns>
|
||||
public string LoadWithAccess(int cId, int firstId, string key)
|
||||
{
|
||||
return JsonHelper.Instance.Serialize(_app.LoadWithAccess(key,firstId, cId));
|
||||
return JsonHelper.Instance.Serialize(_app.LoadWithAccess(User.Identity.Name,key,firstId, cId));
|
||||
}
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user