问题
Please I am using the default ID Generation in raven DB inserting and everything seems to work fine for now
However My ID Has the following format "entityName/1"
so if added as a route value, the following URL Results
http://localhost:10563/Settings/Edit/SystemSettings/1
Which as u can guess results in the following message
Description: HTTP 404. The resource you are looking for (or one of its dependencies) could have been removed, had its name changed, or is temporarily unavailable. Please review the following URL and make sure that it is spelled correctly.
Requested URL: /Settings/Edit/SystemSettings/1
Please how can I change this behavior
Thanks in advance
回答1:
There are multiple ways of solving this conflict between MVC routing and RavenDB's naming conventions, the easiest way is described here (bottom of page): http://ravendb.net/kb/3/using-ravendb-in-an-asp-net-mvc-website
来源:https://stackoverflow.com/questions/19590506/autogenerated-id-in-ravendb