This is a migrated thread and some comments may be shown as answers.

Grid toolbar databind

1 Answer 122 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Bruno
Top achievements
Rank 1
Bruno asked on 26 Oct 2012, 05:26 PM
Hi guys,

I'm currently trying to bind a viewModel value to a toolbar using a template, but no matter what I do it doesn't work, do you have any idea of how I can get it to work?

$("#grid").kendoGrid({
    dataSource: viewModel.data,
    toolbar: [{
        name: "head",
        template: '<span>Type: <label data-bind="text: #=viewModel.type#"></label></span>'
    }],
    columns: [
    { field: "Field1", title: "Column1", template: '#=val1#' },
    { field: "Field2", title: "Column2", template: '#=val2#' },
    { field: "Field3", title: "Column3", template: '#=val3#' }
    ],
    autoBind: true
});

Thank you in advance.

1 Answer, 1 is accepted

Sort by
0
Bruno
Top achievements
Rank 1
answered on 31 Oct 2012, 05:09 PM
Anyone? Please?
Tags
Grid
Asked by
Bruno
Top achievements
Rank 1
Answers by
Bruno
Top achievements
Rank 1
Share this question
or