| xqd
@@ -38,7 +38,9 @@ class ProductController extends AdminController
|
|
|
$grid->filter(function (Grid\Filter $filter) {
|
|
|
$filter->panel();
|
|
|
$filter->like('name')->width(3);
|
|
|
- $filter->equal('type')->select(\App\Models\ProductType::selectOptions())->width(3);
|
|
|
+ $filter->where('type',function ($query){
|
|
|
+ $query->whereJsonContains('type',[intval($this->input)]);
|
|
|
+ })->select(\App\Models\ProductType::selectOptions())->width(4);
|
|
|
|
|
|
});
|
|
|
});
|