In the following example I want to show the Id of the category when the corresponding "columns.values" is not found. Is there a way to do it easily?
in the "burger" line it is blank, and I want that in that case at least its category is displayed
<div id="grid"></div>
<script>
$("#grid").kendoGrid({
columns: [
{ field: "productName" },
{ field: "category", values: [
{ text: "Beverages", value: 1 },
{ text: "Food", value: 2 }
] }
],
dataSource: [
{ productName: "Tea", category: 1 },
{ productName: "Ham", category: 2 },
{ productName: "Burger", category: 3 },
],editable: true,
});
</script>