feat: user preview, bulk and record actions and the permanent delete

- the list opens the preview, which shows one status hint (banned,
  deactivated, not activated, suspended) and the IP address fields
- bulk actions activate, deactivate, restore, ban and unban; record
  actions activate, unban and unsuspend, offered while they apply
- delete (form button and bulk) removes the user for good with the
  throttle rows, group memberships and attachments in one transaction;
  blobs go after the commit
- a privileged-group member is still refused, a bulk delete as a whole
This commit is contained in:
Jakub Zych
2026-10-05 13:10:12 +02:00
parent ebaf3a0817
commit 970eba7734
12 changed files with 1125 additions and 15 deletions

View File

@@ -0,0 +1,7 @@
{{- /* Status hint above the user preview: one callout, or nothing (usersHintView). */ -}}
{{- if .Data.Title -}}
<div class="summer-callout summer-callout--{{ .Data.Kind }}" role="status">
<p class="summer-callout__title">{{ trans .Data.Title }}</p>
<p class="summer-callout__text">{{ trans .Data.Text }}</p>
</div>
{{- end -}}

View File

@@ -5,10 +5,16 @@ defaultRedirect: golem15/user/users
update:
redirect: golem15/user/users/update/:id
redirectClose: golem15/user/users
redirectClose: golem15/user/users/preview/:id
preview:
headerPartial: hint
recordActions: [activate, unban, unsuspend]
messages:
update: backend::lang.messages.form.update
saved: backend::lang.messages.form.saved
deleteConfirm: golem15.user::lang.users.delete_confirm
deleted: backend::lang.messages.form.deleted
edit: golem15.user::lang.users.update_details

View File

@@ -1,7 +1,7 @@
list: ~/plugins/golem15/user/models/user/columns.yaml
modelClass: Golem15\User\Models\User
title: golem15.user::lang.users.list_title
recordUrl: golem15/user/users/update/:id
recordUrl: golem15/user/users/preview/:id
noRecordsMessage: backend::lang.list.no_records
recordsPerPage: 20
showCheckboxes: true
@@ -9,12 +9,16 @@ showSetup: true
filter: config_filter.yaml
toolbar:
buttons: []
buttons: [delete]
search:
prompt: backend::lang.list.search_prompt
bulkActions: [activate, deactivate, restore, ban, unban]
messages:
empty: golem15.user::lang.users.list_empty
deleteConfirm: golem15.user::lang.users.delete_selected_confirm
deleted: backend::lang.messages.list.deleted
rowStateDeleted: golem15.user::lang.users.state_deactivated
rowStateNegative: golem15.user::lang.users.state_banned
rowStateDisabled: golem15.user::lang.users.state_not_activated