Exemplo n.º 1
0
        public IAOPResult UpdatePermissionResource(PermissionResource resource)
        {
            this.PermissionDataService.UpdatePermissionResource(resource);

            this.WritePermissionLog(string.Format("更新了权限资源:[{0}]{1}", resource.PermissionNo, resource.Title), resource);

            this.SetCachedPermissionResourcesExpired();
            return(AOPResult.Success());
        }
Exemplo n.º 2
0
        public IAOPResult AddPermissionResource(PermissionResource resource)
        {
            this.PermissionDataService.AddPermissionResource(resource, this.Setting.DefaultRole);

            this.WritePermissionLog(string.Format("添加了权限资源:[{0}]{1}", resource.PermissionNo, resource.Title), resource);

            this.SetCachedPermissionResourcesExpired();
            this.SetCachedPermissionRelationsExpired();            //增加权限会默认添加到管理员角色
            return(AOPResult.Success());
        }