mirror of https://gitgud.io/fatchan/jschan.git
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
27 lines
904 B
27 lines
904 B
extends ../layout.pug
|
|
include ../mixins/globalmanagenav.pug
|
|
|
|
block head
|
|
title Edit role
|
|
|
|
block content
|
|
h1.board-title Global Management
|
|
br
|
|
+globalmanagenav('roles', true)
|
|
hr(size=1)
|
|
h4.mv-5 Edit role "#{roleNameMap[rolePermissions.base64]}"
|
|
- const jsonPermissions = rolePermissions.toJSON();
|
|
.form-wrapper.flexleft
|
|
form(action=`/forms/global/editrole` method='POST')
|
|
input(type='hidden' name='_csrf' value=csrf)
|
|
input(type='hidden' name='roleid' value=role._id)
|
|
for perm, index in Object.keys(jsonPermissions)
|
|
if jsonPermissions[perm].title && index > 0
|
|
hr(size=1)
|
|
h4.mv-5 #{jsonPermissions[perm].title}
|
|
.row
|
|
label.postform-style.ph-5
|
|
input(type='checkbox' name=perm value=jsonPermissions[perm].bit checked=jsonPermissions[perm].state)
|
|
.rlabel #{jsonPermissions[perm].label}
|
|
p #{jsonPermissions[perm].desc}
|
|
input(type='submit', value='Save')
|
|
|