Kendo mvc grid template format -
my application mvc5 c#; using kendo mvc grid, need format currency item.
columns.bound(p => p.isfree).template(@<text> @if (item.isfree) { <span>free</span> } else { <span>@item.price </span> }</text>).title("cost");
could not find documentation how format @item.price currency.
you can use clienttemplate instead of template if else condition below
columns.bound(c => c.isfree).clienttemplate("# if(isfree) {# <span>free</span> #} else{# <span>#= kendo.tostring(price, 'c') #</span> #}#").title("cost")
Comments
Post a Comment