diff --git a/src/Command/AccountCreationStudentCommand.php b/src/Command/AccountCreationStudentCommand.php index 417c074bde99e8776864235a262ee92fdd1854b5..11f12491f57159050afebab50f5f1c80f758baa6 100644 --- a/src/Command/AccountCreationStudentCommand.php +++ b/src/Command/AccountCreationStudentCommand.php @@ -95,14 +95,14 @@ class AccountCreationStudentCommand extends Command $user->setActivePersonalStats(true); // Ajout au groupe correspondant - /*$correctGroup = $this->em->getRepository(Group::class)->findOneBy(['name' => $data[5]]); // TODO (ou 4 peut-être) + changer le nom du groupe en fonction + $correctGroup = $this->em->getRepository(Group::class)->findOneBy(['name' => $data[4]]); // TODO changer le nom du groupe dans le CSV $groupMembership = new GroupMembership(); $groupMembership->setGroup($correctGroup); //$groupMembership->setUser($user); - $groupMembership->setRole(GroupMembership::ROLE_CONTRIBUTOR); // TODO : changer le rôle en fonction de collab ou nonCollab - // $groupMembership->setRole(GroupMembership::ROLE_READER); - $correctGroup->addGroupMembership($groupMembership);*/ + // $groupMembership->setRole(GroupMembership::ROLE_CONTRIBUTOR); // TODO : changer le rôle en fonction de collab ou nonCollab + $groupMembership->setRole(GroupMembership::ROLE_READER); + $correctGroup->addGroupMembership($groupMembership); // Persist the user entity and Flush the changes to the database diff --git a/src/Form/RegistrationFormType.php b/src/Form/RegistrationFormType.php index 6f7bcfcaf74deabffdb3b6ea334565b2176d85eb..1de1587fa8ee73d156b976b04d545d50849c3a7e 100644 --- a/src/Form/RegistrationFormType.php +++ b/src/Form/RegistrationFormType.php @@ -25,7 +25,8 @@ class RegistrationFormType extends AbstractType ->add('pseudo') ->add('agreeTerms', CheckboxType::class, [ 'mapped' => false, - 'label' => "J'accepte les conditions d'utilisations", + 'label' => "J'accepte les <a href='https://wiki.lezinter.net/_/LexgaMe:BaLex/Conditions_d%27utilisation'>conditions d'utilisation</a>", + 'label_html' => true, // Enable HTML in the labels 'constraints' => [ new IsTrue([ 'message' => "Veuillez accepter les conditions d'utilisation.",