{"action":"created","issue":{"url":"https://api.github.com/repos/cakephp/cakephp/issues/6136","labels_url":"https://api.github.com/repos/cakephp/cakephp/issues/6136/labels{/name}","comments_url":"https://api.github.com/repos/cakephp/cakephp/issues/6136/comments","events_url":"https://api.github.com/repos/cakephp/cakephp/issues/6136/events","html_url":"https://github.com/cakephp/cakephp/issues/6136","id":63527889,"number":6136,"title":"3.0: Routing and mixing Route classes.","user":{"login":"dereuromark","id":39854,"avatar_url":"https://avatars.githubusercontent.com/u/39854?v=3","gravatar_id":"","url":"https://api.github.com/users/dereuromark","html_url":"https://github.com/dereuromark","followers_url":"https://api.github.com/users/dereuromark/followers","following_url":"https://api.github.com/users/dereuromark/following{/other_user}","gists_url":"https://api.github.com/users/dereuromark/gists{/gist_id}","starred_url":"https://api.github.com/users/dereuromark/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dereuromark/subscriptions","organizations_url":"https://api.github.com/users/dereuromark/orgs","repos_url":"https://api.github.com/users/dereuromark/repos","events_url":"https://api.github.com/users/dereuromark/events{/privacy}","received_events_url":"https://api.github.com/users/dereuromark/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/cakephp/cakephp/labels/Defect","name":"Defect","color":"f7c6c7"},{"url":"https://api.github.com/repos/cakephp/cakephp/labels/routing","name":"routing","color":"FFFFFF"}],"state":"open","locked":false,"assignee":{"login":"markstory","id":24086,"avatar_url":"https://avatars.githubusercontent.com/u/24086?v=3","gravatar_id":"","url":"https://api.github.com/users/markstory","html_url":"https://github.com/markstory","followers_url":"https://api.github.com/users/markstory/followers","following_url":"https://api.github.com/users/markstory/following{/other_user}","gists_url":"https://api.github.com/users/markstory/gists{/gist_id}","starred_url":"https://api.github.com/users/markstory/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/markstory/subscriptions","organizations_url":"https://api.github.com/users/markstory/orgs","repos_url":"https://api.github.com/users/markstory/repos","events_url":"https://api.github.com/users/markstory/events{/privacy}","received_events_url":"https://api.github.com/users/markstory/received_events","type":"User","site_admin":false},"milestone":{"url":"https://api.github.com/repos/cakephp/cakephp/milestones/7","html_url":"https://github.com/cakephp/cakephp/milestones/3.0.0","labels_url":"https://api.github.com/repos/cakephp/cakephp/milestones/7/labels","id":453043,"number":7,"title":"3.0.0","description":"New major release that breaks compatibility with 2.x\r\n\r\n- PHP5.4.19+\r\n- New ORM & behaviors.\r\n- Improved Routing\r\n- PSR-0 and composer support.\r\n- Simpler configuration and bootstrapping.\r\n- Improved configuration handling.\r\n- Improved bake.\r\n\r\nSee [the roadmap](http://github.com/cakephp/cakephp/wiki/3.0-roadmap) for more details.","creator":{"login":"lh-import","id":5175817,"avatar_url":"https://avatars.githubusercontent.com/u/5175817?v=3","gravatar_id":"","url":"https://api.github.com/users/lh-import","html_url":"https://github.com/lh-import","followers_url":"https://api.github.com/users/lh-import/followers","following_url":"https://api.github.com/users/lh-import/following{/other_user}","gists_url":"https://api.github.com/users/lh-import/gists{/gist_id}","starred_url":"https://api.github.com/users/lh-import/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lh-import/subscriptions","organizations_url":"https://api.github.com/users/lh-import/orgs","repos_url":"https://api.github.com/users/lh-import/repos","events_url":"https://api.github.com/users/lh-import/events{/privacy}","received_events_url":"https://api.github.com/users/lh-import/received_events","type":"User","site_admin":false},"open_issues":10,"closed_issues":2464,"state":"open","created_at":"2013-10-11T20:56:23Z","updated_at":"2015-03-22T13:12:19Z","due_on":"2015-03-22T04:00:00Z","closed_at":null},"comments":2,"created_at":"2015-03-22T12:31:06Z","updated_at":"2015-03-22T13:26:37Z","closed_at":null,"body":"With prefix and plugin the Routing does not consistently work with different Route classes right now.\r\n\r\nIf I set the app's routes config to `Router::defaultRouteClass('InflectedRoute');`\r\nand have a plugin config that looks like this:\r\n```\r\nRouter::prefix('admin', function ($routes) {\r\n\t$routes->plugin('AuthSandbox', function ($routes) {\r\n\t\t$routes->connect('/:controller', ['action' => 'index'], ['routeClass' => 'DashedRoute']);\r\n\t\t$routes->connect('/:controller/:action/*', [], ['routeClass' => 'DashedRoute']);\r\n\t});\r\n});\r\nRouter::plugin('AuthSandbox', function ($routes) {\r\n\t\t\t$routes->connect('/:controller', ['action' => 'index'], ['routeClass' => 'DashedRoute']);\r\n\t\t\t$routes->connect('/:controller/:action/*', [], ['routeClass' => 'DashedRoute']);\r\n});\r\n```\r\nThen the resulting URL is still containing the InflectedRoute part in the plugin (not the controller/action).\r\n\r\nIf we can set a different route class for plugins it should then completely overwrite, not just partially IMO.\r\n\r\nSee https://github.com/dereuromark/cakephp-sandbox/blob/3.0/src/Plugin/AuthSandbox/config/routes.php and the result `/auth_sandbox/auth-sandbox`"},"comment":{"url":"https://api.github.com/repos/cakephp/cakephp/issues/comments/84608110","html_url":"https://github.com/cakephp/cakephp/issues/6136#issuecomment-84608110","issue_url":"https://api.github.com/repos/cakephp/cakephp/issues/6136","id":84608110,"user":{"login":"dereuromark","id":39854,"avatar_url":"https://avatars.githubusercontent.com/u/39854?v=3","gravatar_id":"","url":"https://api.github.com/users/dereuromark","html_url":"https://github.com/dereuromark","followers_url":"https://api.github.com/users/dereuromark/followers","following_url":"https://api.github.com/users/dereuromark/following{/other_user}","gists_url":"https://api.github.com/users/dereuromark/gists{/gist_id}","starred_url":"https://api.github.com/users/dereuromark/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dereuromark/subscriptions","organizations_url":"https://api.github.com/users/dereuromark/orgs","repos_url":"https://api.github.com/users/dereuromark/repos","events_url":"https://api.github.com/users/dereuromark/events{/privacy}","received_events_url":"https://api.github.com/users/dereuromark/received_events","type":"User","site_admin":false},"created_at":"2015-03-22T13:26:37Z","updated_at":"2015-03-22T13:26:37Z","body":"`/auth_sandbox/auth-sandbox` vs expected `/auth-sandbox/auth-sandbox`"}}