From 20f393d326efca14961925c55fc6981e66cfb835 Mon Sep 17 00:00:00 2001 From: Yoga Pangestu Date: Wed, 1 Oct 2025 20:38:51 +0700 Subject: [PATCH] refactor(trait): mengeluarkan WithOutletSelector dari folder Voucher dan menyesuiakan path nya di voucher --- app/Livewire/Studio/Loyalty/Voucher/Create.php | 2 +- app/Livewire/Studio/Loyalty/Voucher/Edit.php | 2 +- app/Traits/Voucher/WithOutletSelector.php | 16 ---------------- 3 files changed, 2 insertions(+), 18 deletions(-) delete mode 100644 app/Traits/Voucher/WithOutletSelector.php diff --git a/app/Livewire/Studio/Loyalty/Voucher/Create.php b/app/Livewire/Studio/Loyalty/Voucher/Create.php index 2c32f24..a9ac311 100644 --- a/app/Livewire/Studio/Loyalty/Voucher/Create.php +++ b/app/Livewire/Studio/Loyalty/Voucher/Create.php @@ -4,7 +4,7 @@ use App\Livewire\Forms\VoucherForm; use App\Models\Outlet; -use App\Traits\Voucher\WithOutletSelector; +use App\Traits\WithOutletSelector; use App\Traits\WithUpdatedData; use Flux\Flux; use Livewire\Attributes\Title; diff --git a/app/Livewire/Studio/Loyalty/Voucher/Edit.php b/app/Livewire/Studio/Loyalty/Voucher/Edit.php index 2597d88..95a6ee6 100644 --- a/app/Livewire/Studio/Loyalty/Voucher/Edit.php +++ b/app/Livewire/Studio/Loyalty/Voucher/Edit.php @@ -5,7 +5,7 @@ use App\Livewire\Forms\VoucherForm; use App\Models\Outlet; use App\Models\Voucher; -use App\Traits\Voucher\WithOutletSelector; +use App\Traits\WithOutletSelector; use App\Traits\WithUpdatedData; use Flux\Flux; use Livewire\Attributes\Title; diff --git a/app/Traits/Voucher/WithOutletSelector.php b/app/Traits/Voucher/WithOutletSelector.php deleted file mode 100644 index 3f09248..0000000 --- a/app/Traits/Voucher/WithOutletSelector.php +++ /dev/null @@ -1,16 +0,0 @@ -form->outlet_ids = array_keys($this->outlets); - } - - public function deselectAll() - { - $this->form->outlet_ids = []; - } -}