Open abbasgholia opened 2 years ago
how to filter "blue" and "red" and "pink" in columns? in filterable
please see the code below :
, Column::callback(['color'],function ($color){ if ($color == 1){ return "blue"; }elseif($color == 2){ return "red"; }else{ return "pink"; } }) ->label('Status') ->filterable(['blue','red','pink'])
I suggest to use "filterOn" at the end, something like:
->filterable(['blue','red','pink']) ->filterOn('CASE ' . 'WHEN color = 1 THEN "blue" ' . 'WHEN color = 2 THEN "red" ' . 'ELSE "pink" ' . 'END')
how to filter "blue" and "red" and "pink" in columns? in filterable
please see the code below :