mirror of
https://github.com/Part-DB/Part-DB-server.git
synced 2026-01-14 14:19:33 +00:00
Füge Baugruppen hinzu
This commit is contained in:
parent
98b8c5b788
commit
5bd0741fba
128 changed files with 23830 additions and 109 deletions
|
|
@ -23,6 +23,7 @@ declare(strict_types=1);
|
|||
namespace App\Security\Voter;
|
||||
|
||||
use App\Entity\Attachments\PartCustomStateAttachment;
|
||||
use App\Entity\Attachments\AssemblyAttachment;
|
||||
use App\Services\UserSystem\VoterHelper;
|
||||
use Symfony\Bundle\SecurityBundle\Security;
|
||||
use App\Entity\Attachments\AttachmentContainingDBElement;
|
||||
|
|
@ -90,6 +91,8 @@ final class AttachmentVoter extends Voter
|
|||
$param = 'currencies';
|
||||
} elseif (is_a($subject, ProjectAttachment::class, true)) {
|
||||
$param = 'projects';
|
||||
} elseif (is_a($subject, AssemblyAttachment::class, true)) {
|
||||
$param = 'assemblies';
|
||||
} elseif (is_a($subject, FootprintAttachment::class, true)) {
|
||||
$param = 'footprints';
|
||||
} elseif (is_a($subject, GroupAttachment::class, true)) {
|
||||
|
|
|
|||
|
|
@ -22,6 +22,7 @@ declare(strict_types=1);
|
|||
|
||||
namespace App\Security\Voter;
|
||||
|
||||
use App\Entity\AssemblySystem\Assembly;
|
||||
use App\Entity\Attachments\AttachmentType;
|
||||
use App\Entity\Parts\PartCustomState;
|
||||
use App\Entity\ProjectSystem\Project;
|
||||
|
|
@ -48,6 +49,7 @@ final class StructureVoter extends Voter
|
|||
AttachmentType::class => 'attachment_types',
|
||||
Category::class => 'categories',
|
||||
Project::class => 'projects',
|
||||
Assembly::class => 'assemblies',
|
||||
Footprint::class => 'footprints',
|
||||
Manufacturer::class => 'manufacturers',
|
||||
StorageLocation::class => 'storelocations',
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue