feat: Order distinct bottle sizes and bypass global scope during formula initialization.
This commit is contained in:
parent
ebf244b9da
commit
ce1541ae4c
@ -34,7 +34,11 @@ class Formula extends Component
|
|||||||
|
|
||||||
public function mount(): void
|
public function mount(): void
|
||||||
{
|
{
|
||||||
$this->sizes = Bottle::distinct()->get()->pluck('size')->toArray();
|
$this->sizes = Bottle::withoutGlobalScope('orderedBySize')
|
||||||
|
->distinct()
|
||||||
|
->orderBy('size')
|
||||||
|
->pluck('size')
|
||||||
|
->toArray();
|
||||||
}
|
}
|
||||||
|
|
||||||
public function create(): void
|
public function create(): void
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user