Hi.
I saw the response for the post "Datasource with model and Data Annotations with URL insert, edit, delete in a grid with dialogtemplate", thread # 124436.
I would like to use helper controls in the template (modal dialog), like @Html.EJ().NumericTextbox, etc using model object,.
Is there a way to use a partial view instead javascript template for modal CRUD with MVC Data Annotations? I think that will be ease to write the Razor code instead directly html/javascript code.
The partial views will be like this:
@model mymodel
<form id="formCRUD" method="post">
<div class="panel panel-primary">
<div class="panel-heading text-center">
<h3 class="panel-title">My Title</h3>
</div>
<div id="corpoForm" class="panel-body">
<fieldset>
<div class="form-group">
@Html.LabelFor(m => m.pro1, new { @class = "control-label" })
@Html.EJ().NumericTextbox(m => m.prop1, new { @class = "form-control", placeholder = "my placeholder..." })
</div>
...
</fieldset>
<div class="panel-footer">
...
</div>
</div>
</div>
Thank you.