A continuación tenemos que hacer algunas modificaciones a AppController.
Next we need to make some modifications to AppController.
Las propiedades y métodos creados en tu AppController estarán disponibles para todos los controladores de tu aplicación.
Controller attributes and methods created in your AppController will be available in all controllers that extend it.
Si el inicio de sesión tiene éxito, el objeto AppController responde actualizando la página.
If the login attempt succeeds, the AppController object responds by refreshing the page.
También es posible implementar una solución mas general en AppController, de acuerdo a tus reglas.
You could also be more creative and code something more general in AppController based on your own rules.
Como se comentó en la introducción, la clase AppController es la clase superior a todos los controladores de tu aplicación.
As stated in the introduction, the AppController class is the parent class to all of your application's controllers.
Puedes agregar y ejecutar esto en tu AppController o cualquier otro controlador con ese propósito, solo asegurate de eliminarlo antes de poner la aplicación en producción.
You can add and run this in your AppController or any controller for that matter, just be sure to remove it before putting your application into production.
Si lo ves necesario, inclúyelo en tu AppController.
Often it makes sense to include it in your AppController.
Las propiedades y métodos creados en tu AppController estarán disponibles para todos los controladores de tu aplicación.
Controller attributes and methods created in your AppController will be available to all of your application's controllers.
Los componentes declarados en AppController serán combinados con los de tus otros controladores, así que no hay necesidad de redeclarar el mismo componente dos veces.
Components declared in AppController will be merged with those in your other controllers. So there is no need to re-declare the same component twice.
Abre nuevamente AppController y agregá las siguientes opciones en la configuración del Auth
Again, open the AppController class and add a few more options to the Auth config
Conținut posibil inadecvat
Exemplele au rolul de a te ajuta să traduci cuvinte sau expresii corect si adaptat la context. Nu sunt selectate sau validate manual, așadar pot conține termeni inadecvați. Te rugăm să raportezi exemplele pe care le consideri inadecvate. Traducerile vulgare sau colocviale sunt în general marcate cu roșu sau cu portocaliu.
Înregistrează-te pentru a accesa mai multe exemple