<
script
id
=
"row_template"
type
=
"text/x-kendo-tmpl"
>
<
tr
>
<
td
>
#= UserName #
</
td
>
<
td
>
#= FirstName #
</
td
>
<
td
>
#= LastName #
</
td
>
</
tr
>
</
script
>
<
script
id
=
"empty_row"
type
=
"text/x-kendo-tmpl"
>
<
tr
>
<
td
colspan
=
"7"
>No records found</
td
>
</
tr
>
</
script
>
$(
"table.kendo_grid"
).kendoGrid({
dataSource: {
transport: {
...
},
schema: {
...
},
change:
function
(data) {
if
(data.sender.total() == 0) {
// What I need to write here?
}
},
...
];
$j("#ComapnyDetailsGrid").kendoGrid({
dataSource: {
data: data,
batch: true,
pageSize: 30,
schema: {
model: {
fields: {
Company: { validation: { required: true} },
Country: { type: "string" }
}
}
}
},
editable: true,
toolbar: ["create", "save", "cancel"],
columns: [
{ field: "Company", title: "Company*" },
{ field: "Country", title: "Country" },
{
command: "destroy"
}
]
});