I have bind a progress bar inside a Tree View as given.
<script id="progressField" type="text/x-kendo-template">
#if(CurrentStatus == "Progress")
{# <div class='progressDetails'></div> #}
else if(CurrentStatus == "Error")
{# // Other task #}
</script>
And added the same to Tree List View as given
columns: [ { field: "CurrentStatus", title: "Status", template: $("#progressField").html(), width: "170px" } ],
And updated the same on DataBound
function dataBound(e)
{
var tree = this; $(".progressDetails").each(function ()
{
var row = $(this).closest("tr");
var model = tree.dataItem(row);
$(this).kendoProgressBar({
change: function (e)
{
if (model.CurrentStatus == "Progress")
{ colorCode = "#235400"; }
this.progressWrapper.css(
{ "background-color": colorCode, "border-color": colorCode });
}
});
$(this).data("kendoProgressBar").value(model.Percentage);
});
};
On load, Sorting and Filtering the tree list shows up the Progress bar. However when I click on expand arrow, The Progress bar is not showing up. Any help is appreciated.