Closed JanOlsmar closed 7 years ago
there are a lot of starterkits, please be specific about which starterkit you are talking about, so I can know what code is involved
oh wait I see you mentioned ef sql, will check it
ok, figured it out by setting log level to debug to see which route it matched, the problem is this route was catching the request because it is registered first and also matches:
routes.MapRoute(
name: "errorhandler",
template: "{controller}/{action}/{statusCode}"
);
but since the param in the action method was id not statusCode, the model binder ignored it
I fixed it by changing the route to:
routes.MapRoute(
name: "errorhandler",
template: "Home/Error/{statusCode}"
);
which is more specific to match so it falls through to the default route
I will fix it in all the starterkits and post here once I push the changes.
Thanks for letting me know!
ok, this issue is fixed in the starterkits
Thanks Again!
OK Thanks, I will be back if I find more.
Hi and thanks for this project. I have played with it a lot, learned a lot and like it.
I tested to add a own data layer and a controller and basic crud actions. It seem that if you use id the id part disapare. This happens also for the Home controller in the samples. (I have tested ef sql and ef sql identity server)
So if you in Home/about/456 and
` public IActionResult About(int? id) { ViewData["Message"] = "ID " + id + " Your application description page.";
` The id is null.
Jan