New to Kendo UI for jQueryStart a free 30-day trial

PushUpdate

methods

Updates the specified data items without marking them as "dirty". The data source will not sync data items appended via pushUpdate. If the data items are not found (using schema.model.id), they will be appended.

The difference between pushUpdate and updating items via their set method is that items updated via set are synced with the remote service.

Parameters:itemsObject|Array

The data item or data items to update.

<script>
var dataSource = new kendo.data.DataSource({
  schema: {
    model: {
      id: "id"
    }
  },
  data: [
     { id: 1, name: "John Doe" }
  ]
});
dataSource.read();
dataSource.pushUpdate({ id: 1, name: "Jane Doe" });
/* The result can be observed in the DevTools(F12) console of the browser. */
console.log(dataSource.at(0).name); // displays "Jane Doe"
/* The result can be observed in the DevTools(F12) console of the browser. */
console.log(dataSource.at(0).dirty); // displays "false"
/* The result can be observed in the DevTools(F12) console of the browser. */
console.log(dataSource.hasChanges()); // displays "false"
</script>
<script>
var dataSource = new kendo.data.DataSource({
  schema: {
    model: {
      id: "id"
    }
  },
  data: [
     { id: 1, name: "John Doe" },
     { id: 2, name: "Jane Doe" }
  ]
});
dataSource.read();
dataSource.pushUpdate([
    { id: 1, name: "John" },
    { id: 2, name: "Jane" }
]);
/* The result can be observed in the DevTools(F12) console of the browser. */
console.log(dataSource.at(0).name); // displays "John"
/* The result can be observed in the DevTools(F12) console of the browser. */
console.log(dataSource.at(0).dirty); // displays "false"
/* The result can be observed in the DevTools(F12) console of the browser. */
console.log(dataSource.hasChanges()); // displays "false"
</script>
Not finding the help you need?
Contact Support