Currently there is the following code in CellState.filteredCellValue()
if (column.type.isSelect) {
return column.type.select.items.contains(newValue) == true
? newValue
: oldValue;
}
When I'm implementing some custom PlutoColumnType, I would like to have an ability to check newValue by myself.
Please add the following method to PlutoColumnType:
(bool, dynamic) filteredValue({
dynamic newValue,
dynamic oldValue,
}) => (false, newValue);
so I can override it in my custom PlutoColumnType.
And call it from the CellState.filteredCellValue() as the first statement:
final typeResult = column.type.filteredValue(oldValue: oldValue, newValue: newValue);
if (typeResult.$1) return typeResult.$2;
//... rest of current CellState.filteredCellValue() code
Currently there is the following code in CellState.filteredCellValue()
When I'm implementing some custom PlutoColumnType, I would like to have an ability to check newValue by myself.
Please add the following method to PlutoColumnType:
so I can override it in my custom PlutoColumnType.
And call it from the CellState.filteredCellValue() as the first statement: