Hi,
We use MVC 4 and EF 4.5.
I have grid with " .Editable(e => e.Mode(GridEditMode.PopUp).TemplateName("Company"))".
My EditorTemplate looks like this:
I want the field "CompanyUrl" to be readonly and for that I call "DisplayFor" but when I click for editing DisplayFor shows
nothing.
When I'm using GridEditMode.InLine and m.Field(f => f.CompanyUrl).DefaultValue(string.Empty).Editable(false); everything is OK. I want to use popup because my class has too many fields and default popup editor shows too many unwanted fields.
Am I doing something wrong ?
Thanks
P.S One more thing. I want a field edited with kendo editor to be shown formatted in the grid column, not like now "<p>Some Text</p><p><strong>New Line</strong></p>
". The column is in " .ClientDetailTemplateId("clientCommentsTemplate")"
We use MVC 4 and EF 4.5.
I have grid with " .Editable(e => e.Mode(GridEditMode.PopUp).TemplateName("Company"))".
My EditorTemplate looks like this:
...
<
div
class
=
"editor-label"
>
@Html.LabelFor(model => model.CompanyUrl)
</
div
>
<
div
class
=
"editor-field"
>
@Html.DisplayFor(model => model.CompanyUrl)
</
div
>
<
div
class
=
"editor-label"
>
@Html.LabelFor(model => model.FirstName)
</
div
>
<
div
class
=
"editor-field"
>
@Html.EditorFor(model => model.FirstName)
@Html.ValidationMessageFor(model => model.FirstName)
</
div
>
...
nothing.
When I'm using GridEditMode.InLine and m.Field(f => f.CompanyUrl).DefaultValue(string.Empty).Editable(false); everything is OK. I want to use popup because my class has too many fields and default popup editor shows too many unwanted fields.
Am I doing something wrong ?
Thanks
P.S One more thing. I want a field edited with kendo editor to be shown formatted in the grid column, not like now "<p>Some Text</p><p><strong>New Line</strong></p>
". The column is in " .ClientDetailTemplateId("clientCommentsTemplate")"