Refresh a single Kendo grid row

后端 未结 4 1374
一生所求
一生所求 2020-12-23 16:45

Is there a way to refresh a single Kendo grid row without refreshing the whole datasource or using jQuery to set the value for each cell?

4条回答
  •  轮回少年
    2020-12-23 17:17

    updateRecord(record) {
        const grid = $(this.el.nativeElement).data('kendoGrid');
        const row = grid.select();
        const dataItem = grid.dataItem(row);
        for (const property in record) {
          if (record.hasOwnProperty(property)) {
            dataItem.set(property, record[property]);
          }
        }
      }
    

提交回复
热议问题