Commit 4638e5d861b8a8bffdbdf2f016c4356bab7b1c24
1 parent
bdb825221d
Exists in
master
Cambiado la busqueda de Rol por defecto de Id a Nombre
Showing
1 changed file
with
1 additions
and
1 deletions
Show diff stats
src/AppBundle/Controller/DefaultController.php
| ... | ... | @@ -47,7 +47,7 @@ class DefaultController extends Controller |
| 47 | 47 | ->encodePassword($login, $login->getPlainPassword()); //encripta la contraseña |
| 48 | 48 | $login->setPassword($password); |
| 49 | 49 | $login->setIdRolInstitucion($rol); |
| 50 | - $permiso = $this->getDoctrine()->getRepository('AppBundle:Role')->findOneById(1); | |
| 50 | + $permiso = $this->getDoctrine()->getRepository('AppBundle:Role')->findOneByName("ROLE_DOCENTE"); | |
| 51 | 51 | $login->addRol($permiso); //le añade la permisología básica de docente |
| 52 | 52 | |
| 53 | 53 | $rep = $this->getDoctrine()->getRepository('AppBundle:Rol'); | ... | ... |