Commit 69efe129 authored by Anthony Gautreau's avatar Anthony Gautreau
Browse files

Soucis de relation

parent ec810e70
Loading
Loading
Loading
Loading
Loading
+1 −4
Changes for api/src/Entity/AbstractRole.php: 1 added line, 4 removed lines.
Original line number Diff line number Diff line
@@ -36,10 +36,7 @@ abstract class AbstractRole implements RoleInterface
    #[ORM\ManyToMany(targetEntity: UnicaenUserInterface::class, mappedBy: 'roles')]
    protected Collection $users;

    #[ORM\ManyToMany(targetEntity: PrivilegeInterface::class, inversedBy: 'roles')]
    #[ORM\JoinTable(name: 'unicaen_privilege_role_privilege')]
    #[ORM\JoinColumn(name: 'role_id', referencedColumnName: 'id', onDelete: 'CASCADE')]
    #[ORM\InverseJoinColumn(name: 'privilege_id', referencedColumnName: 'id', onDelete: 'CASCADE')]
    #[ORM\ManyToMany(targetEntity: PrivilegeInterface::class, mappedBy: 'roles')]
    protected Collection $privileges;

    public function getId() : ?int