<div id="tile"></div>
<div id="imageTemplate">
<div id="appimage">
</div>
<div class="tileMargin">
<span class="caption">Google Search</span><br />
<span class="description">The world’s information</span><br />
<span class="sub">Free</span>
</div>
</div>
<div id="captionTemplate" class="title">Windows Store</div>
However the documentation didn't tell how could we insert the values into the template, say we would like to replace "Google Search" with Id iterate from our model, can we have a sample on how to do that?
For Tree View, we have the following code:<script id="treeTemplate" type="text/x-jsrender">
{{if HasChild}}
<div class={{>Name}} -style>{{>Name}}</div>
{{else}}
<div class="cont-list">
<div class="cont-details">
<span>{{>Name}}</span>
<span>{{>Count}}</span>
</div>
<div class="cont-del"></div>
<div class="treeFooter"></div>
</div>
{{/if}}
</script>
@(Html.EJ().TreeView("tree").Template("#treeTemplate").LoadOnDemand(true)
.ClientSideEvents(e => e.NodeSelect("onTreeNodeSelect"))
.ClientSideEvents(e => e.BeforeExpand("onBeforeExpand"))
.TreeViewFields(f => f.Datasource(Model).Id("Id").ParentId("Pid").Text("Name").Expanded("Expanded").HasChild("HasChild"))
)
But the tree rendered the same as without specify the Template("#treeTemplate") attribute, are we missed something?