mirror of
https://gitlab.com/crafty-controller/crafty-4.git
synced 2024-08-30 18:23:09 +00:00
Fix API perms request returning stack
This commit is contained in:
parent
f3ca5b9ca7
commit
afb7575398
@ -52,6 +52,8 @@ class ApiUsersUserPermissionsHandler(BaseApiHandler):
|
|||||||
},
|
},
|
||||||
)
|
)
|
||||||
|
|
||||||
|
counter_data = PermissionsCrafty.get_created_quantity_list(user_id)
|
||||||
|
|
||||||
self.finish_json(
|
self.finish_json(
|
||||||
200,
|
200,
|
||||||
{
|
{
|
||||||
@ -59,9 +61,9 @@ class ApiUsersUserPermissionsHandler(BaseApiHandler):
|
|||||||
"data": {
|
"data": {
|
||||||
"permissions": res_data.permissions,
|
"permissions": res_data.permissions,
|
||||||
"counters": {
|
"counters": {
|
||||||
SERVER_CREATION: res_data.created_server,
|
SERVER_CREATION: counter_data["SERVER_CREATION"],
|
||||||
USER_CONFIG: res_data.created_user,
|
USER_CONFIG: counter_data["USER_CONFIG"],
|
||||||
ROLES_CONFIG: res_data.created_role,
|
ROLES_CONFIG: counter_data["ROLES_CONFIG"],
|
||||||
},
|
},
|
||||||
"limits": {
|
"limits": {
|
||||||
SERVER_CREATION: res_data.limit_server_creation,
|
SERVER_CREATION: res_data.limit_server_creation,
|
||||||
|
Loading…
Reference in New Issue
Block a user