{"action":"created","issue":{"url":"https://api.github.com/repos/aspnet/AspNetCore/issues/3636","repository_url":"https://api.github.com/repos/aspnet/AspNetCore","labels_url":"https://api.github.com/repos/aspnet/AspNetCore/issues/3636/labels{/name}","comments_url":"https://api.github.com/repos/aspnet/AspNetCore/issues/3636/comments","events_url":"https://api.github.com/repos/aspnet/AspNetCore/issues/3636/events","html_url":"https://github.com/aspnet/AspNetCore/issues/3636","id":370708518,"node_id":"MDU6SXNzdWUzNzA3MDg1MTg=","number":3636,"title":"Url.Action takes attribute routing in to account, but not clear how","user":{"login":"vankampenp","id":16002371,"node_id":"MDQ6VXNlcjE2MDAyMzcx","avatar_url":"https://avatars0.githubusercontent.com/u/16002371?v=4","gravatar_id":"","url":"https://api.github.com/users/vankampenp","html_url":"https://github.com/vankampenp","followers_url":"https://api.github.com/users/vankampenp/followers","following_url":"https://api.github.com/users/vankampenp/following{/other_user}","gists_url":"https://api.github.com/users/vankampenp/gists{/gist_id}","starred_url":"https://api.github.com/users/vankampenp/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vankampenp/subscriptions","organizations_url":"https://api.github.com/users/vankampenp/orgs","repos_url":"https://api.github.com/users/vankampenp/repos","events_url":"https://api.github.com/users/vankampenp/events{/privacy}","received_events_url":"https://api.github.com/users/vankampenp/received_events","type":"User","site_admin":false},"labels":[{"id":85297674,"node_id":"MDU6TGFiZWw4NTI5NzY3NA==","url":"https://api.github.com/repos/aspnet/AspNetCore/labels/question","name":"question","color":"cc317c","default":true},{"id":792347848,"node_id":"MDU6TGFiZWw3OTIzNDc4NDg=","url":"https://api.github.com/repos/aspnet/AspNetCore/labels/repo:Routing","name":"repo:Routing","color":"5319e7","default":false}],"state":"closed","locked":false,"assignee":{"login":"JamesNK","id":303201,"node_id":"MDQ6VXNlcjMwMzIwMQ==","avatar_url":"https://avatars2.githubusercontent.com/u/303201?v=4","gravatar_id":"","url":"https://api.github.com/users/JamesNK","html_url":"https://github.com/JamesNK","followers_url":"https://api.github.com/users/JamesNK/followers","following_url":"https://api.github.com/users/JamesNK/following{/other_user}","gists_url":"https://api.github.com/users/JamesNK/gists{/gist_id}","starred_url":"https://api.github.com/users/JamesNK/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/JamesNK/subscriptions","organizations_url":"https://api.github.com/users/JamesNK/orgs","repos_url":"https://api.github.com/users/JamesNK/repos","events_url":"https://api.github.com/users/JamesNK/events{/privacy}","received_events_url":"https://api.github.com/users/JamesNK/received_events","type":"User","site_admin":false},"assignees":[{"login":"JamesNK","id":303201,"node_id":"MDQ6VXNlcjMwMzIwMQ==","avatar_url":"https://avatars2.githubusercontent.com/u/303201?v=4","gravatar_id":"","url":"https://api.github.com/users/JamesNK","html_url":"https://github.com/JamesNK","followers_url":"https://api.github.com/users/JamesNK/followers","following_url":"https://api.github.com/users/JamesNK/following{/other_user}","gists_url":"https://api.github.com/users/JamesNK/gists{/gist_id}","starred_url":"https://api.github.com/users/JamesNK/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/JamesNK/subscriptions","organizations_url":"https://api.github.com/users/JamesNK/orgs","repos_url":"https://api.github.com/users/JamesNK/repos","events_url":"https://api.github.com/users/JamesNK/events{/privacy}","received_events_url":"https://api.github.com/users/JamesNK/received_events","type":"User","site_admin":false}],"milestone":null,"comments":3,"created_at":"2018-10-16T17:02:36Z","updated_at":"2018-10-16T19:41:45Z","closed_at":"2018-10-16T19:41:45Z","author_association":"NONE","body":"   1. Description of the problem:\r\n Url.Action(\"index\", \"base\", new { loginid = clientKeep.Login, pwd= pwd}, \"https\");\r\n\r\nReturns\r\n`\r\nhttps://Contoso.com/default.aspx?login=<login>&pwd=<pwd>\r\n`\r\nwhere the action in the BaseController is:\r\n\r\n ```\r\n        [ HttpGet]\r\n        [AllowAnonymous]\r\n        [Route(\"\"), Route(\"default.aspx\"),Route(\"index\")]\r\n        public async Task<IActionResult> Index([FromQuery] string loginid, [FromQuery] string sessionid)\r\n        {\r\n        }\r\n```\r\nwhere I would like to have\r\n\r\n```\r\nhttps://Contoso.com?login=<login>&pwd=<pwd>\r\n```\r\nthe default.aspx is for backward compatibility.  \r\nI tried to change the order of the routing attributes, but this did not change the result. \r\n \r\nI think it should be predicable and controllable which of the routing attributes is used.\r\n\r\nMicrosoft.AspNetCore.App 2.1.1\r\nMicrosoft.NetCore.App 2.1.0\r\n\r\ndotnet --info:\r\nHost (useful for support):\r\n  Version: 2.1.5\r\n  Commit:  290303f510\r\n\r\n.NET Core SDKs installed:\r\n  No SDKs were found.\r\n\r\n.NET Core runtimes installed:\r\n  Microsoft.AspNetCore.All 2.1.1 [C:\\Program Files\\dotnet\\shared\\Microsoft.AspNetCore.All]\r\n  Microsoft.AspNetCore.All 2.1.2 [C:\\Program Files\\dotnet\\shared\\Microsoft.AspNetCore.All]\r\n  Microsoft.AspNetCore.All 2.1.5 [C:\\Program Files\\dotnet\\shared\\Microsoft.AspNetCore.All]\r\n  Microsoft.AspNetCore.App 2.1.1 [C:\\Program Files\\dotnet\\shared\\Microsoft.AspNetCore.App]\r\n  Microsoft.AspNetCore.App 2.1.2 [C:\\Program Files\\dotnet\\shared\\Microsoft.AspNetCore.App]\r\n  Microsoft.AspNetCore.App 2.1.5 [C:\\Program Files\\dotnet\\shared\\Microsoft.AspNetCore.App]\r\n  Microsoft.NETCore.App 2.0.6 [C:\\Program Files\\dotnet\\shared\\Microsoft.NETCore.App]\r\n  Microsoft.NETCore.App 2.1.1 [C:\\Program Files\\dotnet\\shared\\Microsoft.NETCore.App]\r\n  Microsoft.NETCore.App 2.1.2 [C:\\Program Files\\dotnet\\shared\\Microsoft.NETCore.App]\r\n  Microsoft.NETCore.App 2.1.5 [C:\\Program Files\\dotnet\\shared\\Microsoft.NETCore.App]\r\n\r\nTo install additional .NET Core runtimes or SDKs:\r\n  https://aka.ms/dotnet-download\r\n\r\n\r\n"},"comment":{"url":"https://api.github.com/repos/aspnet/AspNetCore/issues/comments/430372888","html_url":"https://github.com/aspnet/AspNetCore/issues/3636#issuecomment-430372888","issue_url":"https://api.github.com/repos/aspnet/AspNetCore/issues/3636","id":430372888,"node_id":"MDEyOklzc3VlQ29tbWVudDQzMDM3Mjg4OA==","user":{"login":"vankampenp","id":16002371,"node_id":"MDQ6VXNlcjE2MDAyMzcx","avatar_url":"https://avatars0.githubusercontent.com/u/16002371?v=4","gravatar_id":"","url":"https://api.github.com/users/vankampenp","html_url":"https://github.com/vankampenp","followers_url":"https://api.github.com/users/vankampenp/followers","following_url":"https://api.github.com/users/vankampenp/following{/other_user}","gists_url":"https://api.github.com/users/vankampenp/gists{/gist_id}","starred_url":"https://api.github.com/users/vankampenp/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vankampenp/subscriptions","organizations_url":"https://api.github.com/users/vankampenp/orgs","repos_url":"https://api.github.com/users/vankampenp/repos","events_url":"https://api.github.com/users/vankampenp/events{/privacy}","received_events_url":"https://api.github.com/users/vankampenp/received_events","type":"User","site_admin":false},"created_at":"2018-10-16T19:41:45Z","updated_at":"2018-10-16T19:41:45Z","author_association":"NONE","body":"@poke Thanks for the excellent and clear answer. Your solution works.\r\nI would have never guest the alphabet  sorting for creating the Url. Basically I assumed that there was a default Order attribute. My bad.\r\n"}}
{"actor":{"display_login":"vankampenp"}}