From b23a2d2989c2ed98409b489fd6683b5313eb1549 Mon Sep 17 00:00:00 2001 From: Yoga Pangestu Date: Thu, 6 Nov 2025 13:44:26 +0700 Subject: [PATCH] chore(choose us): menghapus kolom icon dan warna dan menyesuaikan logikanya --- .../Forms/Studio/Feature/ChooseUsForm.php | 14 -------------- ...025_11_06_100555_create_choose_us_table.php | 2 -- .../studio/feature/choose-us.blade.php | 18 ------------------ 3 files changed, 34 deletions(-) diff --git a/app/Livewire/Forms/Studio/Feature/ChooseUsForm.php b/app/Livewire/Forms/Studio/Feature/ChooseUsForm.php index 6b809d4..84aa4b6 100644 --- a/app/Livewire/Forms/Studio/Feature/ChooseUsForm.php +++ b/app/Livewire/Forms/Studio/Feature/ChooseUsForm.php @@ -13,17 +13,11 @@ class ChooseUsForm extends Form public string $description = ''; - public string $color = ''; - - public string $icon = ''; - public function rules(): array { return [ 'name' => ['required', 'string', 'max:50'], 'description' => ['required', 'string'], - 'color' => ['required', 'string', 'max:20'], - 'icon' => ['required', 'string', 'max:20'], ]; } @@ -32,8 +26,6 @@ public function validationAttributes(): array return [ 'name' => 'nama', 'description' => 'keterangan', - 'color' => 'warna', - 'icon' => 'ikon', ]; } @@ -43,8 +35,6 @@ public function setChooseUs(ChooseUs $chooseUs) $this->name = $chooseUs->name; $this->description = $chooseUs->description; - $this->color = $chooseUs->color; - $this->icon = $chooseUs->icon; } public function store() @@ -54,8 +44,6 @@ public function store() ChooseUs::create([ 'name' => $this->name, 'description' => $this->description, - 'color' => $this->color, - 'icon' => $this->icon, 'sort_order' => ChooseUs::count() + 1, ]); } @@ -67,8 +55,6 @@ public function update() $this->chooseUs->update([ 'name' => $this->name, 'description' => $this->description, - 'color' => $this->color, - 'icon' => $this->icon, ]); } diff --git a/database/migrations/2025_11_06_100555_create_choose_us_table.php b/database/migrations/2025_11_06_100555_create_choose_us_table.php index 45125b8..c2d0717 100644 --- a/database/migrations/2025_11_06_100555_create_choose_us_table.php +++ b/database/migrations/2025_11_06_100555_create_choose_us_table.php @@ -15,8 +15,6 @@ public function up(): void $table->id(); $table->string('name', 50); $table->text('description'); - $table->string('icon', 20); - $table->string('color', 20); $table->unsignedInteger('sort_order'); $table->timestamp('created_at')->useCurrent(); $table->timestamp('updated_at')->useCurrent()->useCurrentOnUpdate(); diff --git a/resources/views/livewire/studio/feature/choose-us.blade.php b/resources/views/livewire/studio/feature/choose-us.blade.php index 0a298ea..778bbb4 100644 --- a/resources/views/livewire/studio/feature/choose-us.blade.php +++ b/resources/views/livewire/studio/feature/choose-us.blade.php @@ -37,24 +37,6 @@ auotocomplete="off" /> -
-
- - Warna * - - - - - - Icon * - - - -
-
-