I would like to use a template for my upload widget that creates a link to the file so the user can preview them. However I can't figure out how to pass the file path into the template.
var draftFiles = [
@foreach(var a in Model.InvoiceDraftCopies)
{
@:{ name: "@(a.FileName)", extension: "@(a.FileExtension)", size: "@(a.FileSize)", path: "@(a.FilePath)" },
}
];
template: kendo.template("<a href='#=path#' target='_blank'>#=name#</a><button type='button' class='k-upload-action'></button>")
I added "path" to the initialfiles array, but can't get to it in the template. I get an error on #=path#. ('path' is undefined).