search fix
This commit is contained in:
parent
1f58f19a76
commit
adf9446fc3
|
|
@ -124,7 +124,10 @@ return [
|
|||
'sortableAttributes' => ['name','created_at','min_price'],
|
||||
// Other settings fields...
|
||||
],
|
||||
|
||||
Sarga\Brand\Models\Brand::class => [
|
||||
// 'filterableAttributes'=> ['type' ],
|
||||
'sortableAttributes' => ['name','position'],
|
||||
]
|
||||
],
|
||||
],
|
||||
|
||||
|
|
|
|||
|
|
@ -43,13 +43,15 @@ class Brand extends Model implements BrandContract
|
|||
return [
|
||||
'id' => $this->id,
|
||||
'name' => $this->name,
|
||||
'type' => 'brand'
|
||||
'type' => 'brand',
|
||||
'position' => $this->position,
|
||||
|
||||
];
|
||||
}
|
||||
|
||||
public function shouldBeSearchable()
|
||||
{
|
||||
return true;
|
||||
return $this->status;
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Reference in New Issue