2

When an item in a row has been edited, I want to mark the row as dirty using a CSS class.

What's the best way to achieve this?

UPDATE I'm trying this, doesn't seem to work:

data.getItemMetadata = function (row) {
   if (data[row].isDirty == true) {
      return { "cssClasses": "dirty" };
   }
};
grid.onCellChange.subscribe(function (e, args) {
   data[args.row].isDirty = true;
});
JontyMC
  • 6,038
  • 6
  • 38
  • 39

1 Answers1

5

Implement getItemMetadata() and specify cssClasses for the dirty row. (https://github.com/mleibman/SlickGrid/wiki/Providing-data-to-the-grid)

Tin
  • 9,082
  • 2
  • 34
  • 32