重构代码:更改缓存键值名称

This commit is contained in:
Argo-MacBookPro 2018-10-28 21:14:03 +08:00
parent 33e9c09c01
commit 57efd8d419
4 changed files with 12 additions and 12 deletions

View File

@ -65,21 +65,21 @@
"CacheItems": [
{
"Enabled": true,
"Key": "BootstrapAdminAuthorizeFilter-RetrieveRolesByUrl",
"Key": "RoleHelper-RetrieveRolesByUrl",
"Interval": 600,
"SlidingExpiration": true,
"Desc": "通过菜单获得角色数据"
},
{
"Enabled": true,
"Key": "BootstrapAdminGroupMiddleware-RetrieveGroupsByUserName",
"Key": "GroupHelper-RetrieveGroupsByUserName",
"Interval": 600,
"SlidingExpiration": true,
"Desc": "指定用户组数据缓存"
},
{
"Enabled": true,
"Key": "BootstrapAdminRoleMiddleware-RetrieveRolesByUserName",
"Key": "RoleHelper-RetrieveRolesByUserName",
"Interval": 600,
"SlidingExpiration": true,
"Desc": "指定用户角色数据缓存"
@ -100,7 +100,7 @@
},
{
"Enabled": true,
"Key": "BootstrapUser-RetrieveUsers",
"Key": "UserHelper-RetrieveUsers",
"Interval": 600,
"SlidingExpiration": true,
"Desc": "所有用户数据"
@ -114,14 +114,14 @@
},
{
"Enabled": true,
"Key": "BootstrapUser-RetrieveUsersByRoleId",
"Key": "UserHelper-RetrieveUsersByRoleId",
"Interval": 600,
"SlidingExpiration": true,
"Desc": "通过角色ID获得所有用户数据"
},
{
"Enabled": true,
"Key": "BootstrapUser-RetrieveUsersByGroupId",
"Key": "UserHelper-RetrieveUsersByGroupId",
"Interval": 600,
"SlidingExpiration": true,
"Desc": "通过部门ID获得所有用户数据"

View File

@ -13,7 +13,7 @@ namespace Bootstrap.DataAccess
public const string RetrieveGroupsDataKey = "GroupHelper-RetrieveGroups";
public const string RetrieveGroupsByUserIdDataKey = "GroupHelper-RetrieveGroupsByUserId";
public const string RetrieveGroupsByRoleIdDataKey = "GroupHelper-RetrieveGroupsByRoleId";
public const string RetrieveGroupsByUserNameDataKey = "BootstrapAdminGroupMiddleware-RetrieveGroupsByUserName";
public const string RetrieveGroupsByUserNameDataKey = "GroupHelper-RetrieveGroupsByUserName";
/// <summary>
/// 查询所有群组信息
/// </summary>

View File

@ -14,8 +14,8 @@ namespace Bootstrap.DataAccess
public const string RetrieveRolesByUserIdDataKey = "RoleHelper-RetrieveRolesByUserId";
public const string RetrieveRolesByMenuIdDataKey = "RoleHelper-RetrieveRolesByMenuId";
public const string RetrieveRolesByGroupIdDataKey = "RoleHelper-RetrieveRolesByGroupId";
public const string RetrieveRolesByUserNameDataKey = "BootstrapAdminRoleMiddleware-RetrieveRolesByUserName";
public const string RetrieveRolesByUrlDataKey = "BootstrapAdminAuthorizeFilter-RetrieveRolesByUrl";
public const string RetrieveRolesByUserNameDataKey = "RoleHelper-RetrieveRolesByUserName";
public const string RetrieveRolesByUrlDataKey = "RoleHelper-RetrieveRolesByUrl";
/// <summary>
/// 查询所有角色
/// </summary>

View File

@ -10,9 +10,9 @@ namespace Bootstrap.DataAccess
/// </summary>
public static class UserHelper
{
public const string RetrieveUsersDataKey = "BootstrapUser-RetrieveUsers";
public const string RetrieveUsersByRoleIdDataKey = "BootstrapUser-RetrieveUsersByRoleId";
public const string RetrieveUsersByGroupIdDataKey = "BootstrapUser-RetrieveUsersByGroupId";
public const string RetrieveUsersDataKey = "UserHelper-RetrieveUsers";
public const string RetrieveUsersByRoleIdDataKey = "UserHelper-RetrieveUsersByRoleId";
public const string RetrieveUsersByGroupIdDataKey = "UserHelper-RetrieveUsersByGroupId";
public const string RetrieveNewUsersDataKey = "UserHelper-RetrieveNewUsers";
public const string RetrieveUsersByNameDataKey = "BootstrapUser-RetrieveUsersByName";
/// <summary>