mirror of
https://github.com/Part-DB/Part-DB-server.git
synced 2025-07-01 05:54:32 +02:00
Deny access to part import tool without permission and added to tools menu
This commit is contained in:
parent
bd5ee837f4
commit
9ac8098f15
2 changed files with 8 additions and 0 deletions
|
@ -143,6 +143,12 @@ class ToolsTreeBuilder
|
|||
$this->urlGenerator->generate('tools_ic_logos')
|
||||
))->setIcon('fa-treeview fa-fw fa-solid fa-flag');
|
||||
}
|
||||
if ($this->security->isGranted('@parts.import')) {
|
||||
$nodes[] = (new TreeViewNode(
|
||||
$this->translator->trans('parts.import.title'),
|
||||
$this->urlGenerator->generate('parts_import')
|
||||
))->setIcon('fa-treeview fa-fw fa-solid fa-file-import');
|
||||
}
|
||||
|
||||
return $nodes;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue