From ccc288135b25f61cb24e8753186cac14a9950dc1 Mon Sep 17 00:00:00 2001 From: ilmedova Date: Wed, 23 Nov 2022 02:09:21 +0500 Subject: [PATCH] test select akax field --- .../Admin/TicketCrudController.php | 42 +++++++++---------- 1 file changed, 21 insertions(+), 21 deletions(-) diff --git a/app/Http/Controllers/Admin/TicketCrudController.php b/app/Http/Controllers/Admin/TicketCrudController.php index fa25677c..f4a78ad9 100755 --- a/app/Http/Controllers/Admin/TicketCrudController.php +++ b/app/Http/Controllers/Admin/TicketCrudController.php @@ -105,28 +105,28 @@ protected function setupCreateOperation() 'type' => 'textarea', 'label' => trans('app.ticket.content') ], - [ // SelectMultiple = n-n relationship (with pivot table) - 'label' => trans('app.ticket.account'), - 'type' => 'custom_select_account', - 'name' => 'client_id', // the method that defines the relationship in your Model - 'entity' => 'account', // the method that defines the relationship in your Model - 'model' => "App\Models\Account", // foreign key model - 'attribute_1' => 'name', // foreign key attribute that is shown to user - 'attribute_2' => 'surname', - ], - // [ //NOT WORKING - // 'label' => trans('app.ticket.account'), // Table column heading - // 'type' => "select2_from_ajax", - // 'name' => 'client_id', // the column that contains the ID of that connected entity - // 'entity' => 'account', // the method that defines the relationship in your Model - // 'attribute' => "name", // foreign key attribute that is shown to user - // 'data_source' => backpack_url('account/fetch'), - - // 'placeholder' => "Select a client", // placeholder for the select - // 'minimum_input_length' => 2, // minimum characters to type before querying results - // 'model' => "App\Models\Account", // foreign key model - // 'method' => 'POST', // optional - HTTP method to use for the AJAX call (GET, POST) + // [ // SelectMultiple = n-n relationship (with pivot table) + // 'label' => trans('app.ticket.account'), + // 'type' => 'custom_select_account', + // 'name' => 'client_id', // the method that defines the relationship in your Model + // 'entity' => 'account', // the method that defines the relationship in your Model + // 'model' => "App\Models\Account", // foreign key model + // 'attribute_1' => 'name', // foreign key attribute that is shown to user + // 'attribute_2' => 'surname', // ], + [ //NOT WORKING + 'label' => trans('app.ticket.account'), // Table column heading + 'type' => "select2_from_ajax", + 'name' => 'client_id', // the column that contains the ID of that connected entity + 'entity' => 'account', // the method that defines the relationship in your Model + 'attribute' => "name", // foreign key attribute that is shown to user + 'data_source' => backpack_url('account/fetch'), + + 'placeholder' => "Select a client", // placeholder for the select + 'minimum_input_length' => 2, // minimum characters to type before querying results + 'model' => "App\Models\Account", // foreign key model + 'method' => 'POST', // optional - HTTP method to use for the AJAX call (GET, POST) + ], [ 'name' => 'category_id', 'entity' => 'category',