mirror of
https://github.com/Part-DB/Part-DB-server.git
synced 2025-06-30 13:34:28 +02:00
Disable attachments form if user is not allowed to edit the element.
This commit is contained in:
parent
67fe47bbb9
commit
2e318f9ea1
2 changed files with 3 additions and 1 deletions
|
@ -198,7 +198,8 @@ class UserAdminForm extends AbstractType
|
|||
'entry_options' => [
|
||||
'data_class' => $options['attachment_class'],
|
||||
],
|
||||
'by_reference' => false
|
||||
'by_reference' => false,
|
||||
'disabled' => !$this->security->isGranted($is_new ? 'create' : 'edit', $entity),
|
||||
]);
|
||||
|
||||
//Buttons
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue