I have searched for a long time for this and I'm sure I must have missed something because it is such a basic ask.
I define the formats in my grid through the cellClass field in defaultColDef:
cellClass: (params) => {
if (params.data.signal_days === 1 && params.data.trade_type !== "taken" ) {
return "signals-blotter-cell-new";
} else if (params.data.trade_type === "taken" ) {
return "signals-blotter-cell-taken";
}
}
Depending on the value of the signal_days and trade_type columns, different css classes get applied.
I also have a onCellValueChanged event listener defined as such :
onCellValueChanged: (event) => {
if (event.column.colId === "trade_type") {
}
}
How can I refresh the cells for the whole row where the modification happened so that my css classes are properly applied ? I would need to refresh when the value of the trade_type column changes from anything to "taken". Some other question use that same mechanism for a single cell which does not help me in that case.