I can't get the custom editor function : customEditor : to trigger.
<p>
Rental - selector</p>
<div>
<p>
Mini class</p>
<div id="rentalList">
</div>
<p>
Compact class</p>
</div>
<div id="rentalList2">
</div>
<p>
Select your car</p>
<script type="text/javascript">
var cars = new kendo.data.DataSource({
transport: {
read: {
url: '@Url.Action("GetCars")',
dataType: "json"
},
update: {
url: '@Url.Action("EditCars")',
dataType: "json"
}
},
schema: {
model: {
id: "CarSeq",
fields: {
CarModel: { editable: true },
Name: { editable: true }
}
}
}
});
function customEdit(container, options) {
alert('function called');
}
$("#rentalList").kendoGrid({
selectable: "row",
height: 200,
editable: true,
dataSource: cars,
columns: [
{ title: "Brand", field: "Name" },
{ title: "Model", field: "CarModel", editor: customEdit }
]
});
$("#rentalList2").kendoGrid({
selectable: "row",
height: 200,
dataSource: carDataSource
});
</script>
Can't see that anything is missing in the Kendo part of the javascript. Any clues why this won't trigger?
<p>
Rental - selector</p>
<div>
<p>
Mini class</p>
<div id="rentalList">
</div>
<p>
Compact class</p>
</div>
<div id="rentalList2">
</div>
<p>
Select your car</p>
<script type="text/javascript">
var cars = new kendo.data.DataSource({
transport: {
read: {
url: '@Url.Action("GetCars")',
dataType: "json"
},
update: {
url: '@Url.Action("EditCars")',
dataType: "json"
}
},
schema: {
model: {
id: "CarSeq",
fields: {
CarModel: { editable: true },
Name: { editable: true }
}
}
}
});
function customEdit(container, options) {
alert('function called');
}
$("#rentalList").kendoGrid({
selectable: "row",
height: 200,
editable: true,
dataSource: cars,
columns: [
{ title: "Brand", field: "Name" },
{ title: "Model", field: "CarModel", editor: customEdit }
]
});
$("#rentalList2").kendoGrid({
selectable: "row",
height: 200,
dataSource: carDataSource
});
</script>
Can't see that anything is missing in the Kendo part of the javascript. Any clues why this won't trigger?