]> Raphaël G. Git Repositories - userbundle/commitdiff
Rename default controller to user controller
authorRaphaël Gertz <git@rapsys.eu>
Mon, 11 Dec 2023 02:10:42 +0000 (03:10 +0100)
committerRaphaël Gertz <git@rapsys.eu>
Mon, 11 Dec 2023 02:10:42 +0000 (03:10 +0100)
Remove field, hash and mail from register
Sort by route name

Resources/config/routes/rapsys_user.yaml

index b67c83feaa1e9c7543852dfc2f8c963a0b3a7be1..304077065595e1b3f333232c2011987c9b170d03 100644 (file)
@@ -1,6 +1,14 @@
 rapsys_user_confirm:
     path: /confirm/{hash}/{mail}
 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=_-]+'
     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}
 
 rapsys_user_login:
     path: /login/{hash}/{mail}
-    controller: Rapsys\UserBundle\Controller\DefaultController::login
+    controller: Rapsys\UserBundle\Controller\UserController::login
     defaults:
         hash: ~
         mail: ~
     defaults:
         hash: ~
         mail: ~
@@ -23,7 +31,7 @@ rapsys_user_logout:
 
 rapsys_user_recover:
     path: /recover/{hash}/{pass}/{mail}
 
 rapsys_user_recover:
     path: /recover/{hash}/{pass}/{mail}
-    controller: Rapsys\UserBundle\Controller\DefaultController::recover
+    controller: Rapsys\UserBundle\Controller\UserController::recover
     defaults:
         hash: ~
         pass: ~
     defaults:
         hash: ~
         pass: ~
@@ -35,26 +43,11 @@ rapsys_user_recover:
     methods: GET|POST
 
 rapsys_user_register:
     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
 
     methods: GET|POST
 
-rapsys_user_index:
+rapsys_user:
     path: /
     path: /
+    controller: Rapsys\UserBundle\Controller\UserController::index
     methods: GET
     methods: GET