feat(19.6.1-01): Roles screen

- Settings -> System -> Roles (summercms.cabana.roles, backend.manage_roles,
  order 110): name, code slugged from the name, description, checkbox
  permission editor with the editor's ceiling
- system roles (is_system or code-declared grants) keep their code and
  cannot be deleted; a role any admin holds (deleted ones included) cannot
  be deleted, the refusal names the role and the count
- role codes unique among roles
This commit is contained in:
Jakub Zych
2026-10-22 11:18:30 +02:00
parent 530b02af9c
commit 653307de0c
9 changed files with 392 additions and 2 deletions

View File

@@ -0,0 +1,26 @@
columns:
name:
label: backend::lang.user.role.name_field
searchable: true
sortable: true
code:
label: backend::lang.user.role.code_field
searchable: true
sortable: true
description:
label: backend::lang.user.role.description_field
searchable: true
is_system:
label: backend::lang.user.role.is_system
type: switch
sortable: true
created_at:
label: backend::lang.user.created_at
type: datetime
invisible: true
sortable: true
updated_at:
label: backend::lang.list.column_updated
type: datetime
invisible: true
sortable: true

View File

@@ -0,0 +1,26 @@
fields:
name:
label: backend::lang.user.role.name_field
comment: backend::lang.user.role.name_comment
type: text
span: left
code:
label: backend::lang.user.role.code_field
comment: backend::lang.user.role.code_comment
type: text
span: right
preset:
type: slug
field: name
description:
label: backend::lang.user.role.description_field
type: textarea
size: tiny
span: full
permissions:
label: backend::lang.user.role.permissions_field
comment: backend::lang.user.role.permissions_comment
type: permissioneditor
mode: checkbox
span: full
tab: backend::lang.user.permissions