Commit 4e4bf31d authored by Jean-Philippe Metivier's avatar Jean-Philippe Metivier
Browse files

Completion de l'assert des agent pour les éléments associés à ceux-ci

parent 9cb336e4
Loading
Loading
Loading
Loading
+0 −15
Changes for module/Application/src/Application/Assertion/AgentAssertion.php: 0 added lines, 15 removed lines.
Original line number Diff line number Diff line
@@ -37,11 +37,6 @@ class AgentAssertion extends AbstractAssertion {
            }
        }

        $isResponsable = false;
        if ($role->getRoleId === RoleConstant::RESPONSABLE_EPRO) {
            //todo
        }

        switch($privilege) {
            case AgentPrivileges::AGENT_ELEMENT_VOIR:
                switch ($role->getRoleId()) {
@@ -76,16 +71,6 @@ class AgentAssertion extends AbstractAssertion {
                }
                return false;
            case AgentPrivileges::AGENT_ELEMENT_VALIDER:
                switch ($role->getRoleId()) {
                    case RoleConstant::ADMIN_FONC:
                    case RoleConstant::ADMIN_TECH:
                        return true;
                    case RoleConstant::GESTIONNAIRE:
                        return $isGestionnaire;
                    case RoleConstant::RESPONSABLE_EPRO:
                        return  $isResponsable;
                }
                return false;
            case AgentPrivileges::AGENT_ELEMENT_AJOUTER_EPRO:
                switch ($role->getRoleId()) {
                    case RoleConstant::ADMIN_FONC: