This question is locked. New answers and comments are not allowed.
I've been facing an issue for a few weeks - and I've finally discovered the cause.
I have a grid set up for batch edit mode. The grid has some standard bound columns (bound to a string property), and some bound via foreign key.
The strange thing is that I have been able to successfully edit the foreign key columns, but not the string values. As soon as I leave edit mode on the string column, the value is reverting back to the original.
I eventually tracked it down to my editor template for string:
\Views\Shared\EditorTemplates\String.cshtml
If I take out the new { @class = "t-input" } it all works fine. Strangely,I can supply different HTML attributes and it also works fine, I can also supply a different class name. It seems only that the t-input class is causing the issue. (NOTE: I am using the Metro styles)
Can others replicate this issue?
I have a grid set up for batch edit mode. The grid has some standard bound columns (bound to a string property), and some bound via foreign key.
The strange thing is that I have been able to successfully edit the foreign key columns, but not the string values. As soon as I leave edit mode on the string column, the value is reverting back to the original.
I eventually tracked it down to my editor template for string:
\Views\Shared\EditorTemplates\String.cshtml
@model String@Html.TextBoxFor(m => m, new { @class = "t-input" })If I take out the new { @class = "t-input" } it all works fine. Strangely,I can supply different HTML attributes and it also works fine, I can also supply a different class name. It seems only that the t-input class is causing the issue. (NOTE: I am using the Metro styles)
Can others replicate this issue?