From ec3659ef5ebcb970bae91b5a422d4264aa451568 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Cihan=20=C5=9Eent=C3=BCrk?= <53110792+CihanSenturk@users.noreply.github.com> Date: Thu, 27 Feb 2025 13:17:27 +0300 Subject: [PATCH] added option field view components --- .../components/form/group/account.blade.php | 8 +++++++ .../components/form/group/category.blade.php | 16 +++++++++++++ .../views/components/form/group/tax.blade.php | 24 +++++++++++++++---- 3 files changed, 44 insertions(+), 4 deletions(-) diff --git a/resources/views/components/form/group/account.blade.php b/resources/views/components/form/group/account.blade.php index 328caa1d6..68e47f68d 100644 --- a/resources/views/components/form/group/account.blade.php +++ b/resources/views/components/form/group/account.blade.php @@ -6,6 +6,10 @@ name="{{ $name }}" label="{{ trans_choice('general.accounts', 1) }}" :options="$accounts" + :option_field="[ + 'key' => 'id', + 'value' => 'title' + ]" :selected="$selected" :required="$required" change="onChangeAccount" @@ -30,6 +34,10 @@ name="{{ $name }}" label="{{ trans_choice('general.accounts', 1) }}" :options="$accounts" + :option_field="[ + 'key' => 'id', + 'value' => 'title' + ]" :selected="$selected" :required="$required" change="onChangeAccount" diff --git a/resources/views/components/form/group/category.blade.php b/resources/views/components/form/group/category.blade.php index b2fbc9a31..08a3644bb 100644 --- a/resources/views/components/form/group/category.blade.php +++ b/resources/views/components/form/group/category.blade.php @@ -11,6 +11,10 @@ :options="$categories" :selected="$selected" sort-options="false" + :option_field="[ + 'key' => 'id', + 'value' => 'title' + ]" :multiple="$multiple" :group="$group" @@ -38,6 +42,10 @@ :options="$categories" :selected="$selected" sort-options="false" + :option_field="[ + 'key' => 'id', + 'value' => 'title' + ]" :multiple="$multiple" :group="$group" @@ -65,6 +73,10 @@ :options="$categories" :selected="$selected" sort-options="false" + :option_field="[ + 'key' => 'id', + 'value' => 'title' + ]" :multiple="$multiple" :group="$group" @@ -89,6 +101,10 @@ :options="$categories" :selected="$selected" sort-options="false" + :option_field="[ + 'key' => 'id', + 'value' => 'title' + ]" :multiple="$multiple" :group="$group" diff --git a/resources/views/components/form/group/tax.blade.php b/resources/views/components/form/group/tax.blade.php index e0848b010..efc895486 100644 --- a/resources/views/components/form/group/tax.blade.php +++ b/resources/views/components/form/group/tax.blade.php @@ -17,6 +17,10 @@ :selected="$selected" change="{{ $change }}" sort-options="false" + :option_field="[ + 'key' => 'id', + 'value' => 'title' + ]" :multiple="$multiple" :group="$group" @@ -30,7 +34,7 @@