Hi.
I´m trying to build a SPA MVC ASP NET web Project which uses
partsviews as a view templates kendo. Like this:
File: Views/Home/Dashboard.cshtml.
<script id="dashboardview" type="text/x-kendo-template">
<div class="container-fluid">
<div class="row">
<div class="col">
<p>
@(Html.Kendo()
.Button()
.Name("PrimaryButton")
.Content("Boton
1 dashboard")
.HtmlAttributes(new { @class = "textButton k-primary" }))
</p>
<p>
@(Html.Kendo()
.Button()
.Name("PrimaryButton2")
.Content("Boton
2 dashboard")
.HtmlAttributes(new { @class = "textButton k-primary" }))
</p>
</div>
</div>
</div>
</script>
All is right when javascript router object is running, the
views are created and destroyed correctly but when one of these view (kendo
templates) has two or more kendo mvc controls, the render is no correctly, and
de control is not render into <div id=”main”></div> how to explain
your documentatio about SPA mvc Apps (Music
Stored Dash Board Tutorial), like following (pay attention at <\/sctript> tag ):
<script id="dashboardview" type="text/x-kendo-template">
<div class="container-fluid">
<div class="row">
<div class="col">
<p>
<button class="textButton
k-primary" id="PrimaryButton"> 1 dashboard</button>
<script>
kendo.syncReady(function(){jQuery("#PrimaryButton").kendoButton({});});
</script>
</p>
<p>
<button class="textButton
k-primary" id="PrimaryButton2"> 2 dashboard</button>
<script>
kendo.syncReady(function(){jQuery("\#PrimaryButton2").kendoButton({});});
<\/script>
</p>
</div>
</div>
</div>
</script>
I´d tried use the ToClientTemplate() method but it doesn´t work. And the
result of view is the first control, render correctly into “body app” and the
second one render outside.
Please, Is there some best practice guide to Spa
MVC Apps with Kendo controls? What error is it?,
Thanks in advance. I´d attached a screenshot browser