This is a migrated thread and some comments may be shown as answers.

Manually set grid row as dirty

2 Answers 3633 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Grady
Top achievements
Rank 1
Grady asked on 09 Sep 2013, 06:11 PM
I have a grid with inline editing.  Everything is working as intended except one of the gridcells has a file upload that is not hooked into the datasource so when a file is uploaded the row does not know it should be updated i.e. the dirty flag is not set.  How can I manually set this row to update even if none of the values in the dataset have changed?

Thanks!

2 Answers, 1 is accepted

Sort by
0
Accepted
Grady
Top achievements
Rank 1
answered on 10 Sep 2013, 08:51 PM
In case anyone else needs to know:

function success(e) {
    var uid = this.element.closest("[data-uid]").data("uid"),
        dataSource = $("#GridName").data("kendoGrid").dataSource,
        item = dataSource.getByUid(uid);
    item.dirty = true;
}
0
Landon
Top achievements
Rank 1
answered on 09 May 2018, 05:36 PM
Thank you so much! Been trying to get an issue resolved for awhile now and this is exactly what I was looking for.
Tags
Grid
Asked by
Grady
Top achievements
Rank 1
Answers by
Grady
Top achievements
Rank 1
Landon
Top achievements
Rank 1
Share this question
or