Add [cmd:permissions]
这个提交包含在:
@@ -98,7 +98,10 @@ Response Handler::handle(const Request &r)
|
||||
|
||||
Permissions Handler::effectivePermissions(std::string page)
|
||||
{
|
||||
return this->database->createPermissionsDao()
|
||||
->find(page, this->userSession->user.login)
|
||||
.value_or(this->userSession->user.permissions);
|
||||
Permissions &userPerms = this->userSession->user.permissions;
|
||||
if(userPerms.isAdmin())
|
||||
{
|
||||
return userPerms;
|
||||
}
|
||||
return this->database->createPermissionsDao()->find(page, this->userSession->user.login).value_or(userPerms);
|
||||
}
|
||||
|
||||
在新工单中引用
屏蔽一个用户