From f94ed4792fabfff9638ffcfad93a8db4d1059d21 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Rapha=C3=ABl=20Gertz?= Date: Mon, 11 Dec 2023 03:10:42 +0100 Subject: [PATCH] Rename default controller to user controller Remove field, hash and mail from register Sort by route name --- Resources/config/routes/rapsys_user.yaml | 37 ++++++++++-------------- 1 file changed, 15 insertions(+), 22 deletions(-) diff --git a/Resources/config/routes/rapsys_user.yaml b/Resources/config/routes/rapsys_user.yaml index b67c83f..3040770 100644 --- a/Resources/config/routes/rapsys_user.yaml +++ b/Resources/config/routes/rapsys_user.yaml @@ -1,6 +1,14 @@ rapsys_user_confirm: path: /confirm/{hash}/{mail} - controller: Rapsys\UserBundle\Controller\DefaultController::registerMail + controller: Rapsys\UserBundle\Controller\UserController::registerMail + requirements: + hash: '[a-zA-Z0-9=_-]+' + mail: '[a-zA-Z0-9=_-]+' + methods: GET|POST + +rapsys_user_edit: + path: /user/{hash}/{mail} + controller: Rapsys\UserBundle\Controller\UserController::edit requirements: hash: '[a-zA-Z0-9=_-]+' mail: '[a-zA-Z0-9=_-]+' @@ -8,7 +16,7 @@ rapsys_user_confirm: rapsys_user_login: path: /login/{hash}/{mail} - controller: Rapsys\UserBundle\Controller\DefaultController::login + controller: Rapsys\UserBundle\Controller\UserController::login defaults: hash: ~ mail: ~ @@ -23,7 +31,7 @@ rapsys_user_logout: rapsys_user_recover: path: /recover/{hash}/{pass}/{mail} - controller: Rapsys\UserBundle\Controller\DefaultController::recover + controller: Rapsys\UserBundle\Controller\UserController::recover defaults: hash: ~ pass: ~ @@ -35,26 +43,11 @@ rapsys_user_recover: methods: GET|POST rapsys_user_register: - path: /register/{hash}/{field}/{mail} - controller: Rapsys\UserBundle\Controller\DefaultController::register - defaults: - hash: ~ - field: ~ - mail: ~ - requirements: - hash: '[a-zA-Z0-9=_-]+' - field: '[a-zA-Z0-9=_-]+' - mail: '[a-zA-Z0-9=_-]+' - methods: GET|POST - -rapsys_user_edit: - path: /user/{hash}/{mail} - controller: Rapsys\UserBundle\Controller\DefaultController::edit - requirements: - hash: '[a-zA-Z0-9=_-]+' - mail: '[a-zA-Z0-9=_-]+' + path: /register + controller: Rapsys\UserBundle\Controller\UserController::register methods: GET|POST -rapsys_user_index: +rapsys_user: path: / + controller: Rapsys\UserBundle\Controller\UserController::index methods: GET -- 2.41.1