From ed0cec5ba6fac3d37d138666fe27d3ef5df055e3 Mon Sep 17 00:00:00 2001 From: Marcus Moore Date: Mon, 13 Jan 2025 12:17:01 -0800 Subject: [PATCH 01/11] Introduce select component --- resources/views/blade/input/select.blade.php | 25 ++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 resources/views/blade/input/select.blade.php diff --git a/resources/views/blade/input/select.blade.php b/resources/views/blade/input/select.blade.php new file mode 100644 index 000000000000..c96b5e177220 --- /dev/null +++ b/resources/views/blade/input/select.blade.php @@ -0,0 +1,25 @@ +@props([ + // can either be provided as key => value pairs + // or passed in via the default $slot + 'options', + 'selected' => null, + 'includeEmpty' => false, + 'forLivewire' => false, +]) + + From d74454620a728f9e8f9113c85ca7992ce4389904 Mon Sep 17 00:00:00 2001 From: Marcus Moore Date: Mon, 13 Jan 2025 12:45:49 -0800 Subject: [PATCH 02/11] Convert Form::select to blade component --- resources/views/categories/edit.blade.php | 9 ++++++++- resources/views/custom_fields/fields/edit.blade.php | 9 ++++++++- resources/views/custom_fields/fieldsets/view.blade.php | 8 ++++++-- resources/views/hardware/bulk.blade.php | 8 +++++++- resources/views/hardware/checkin.blade.php | 10 ++++++++-- resources/views/hardware/checkout.blade.php | 8 +++++++- 6 files changed, 44 insertions(+), 8 deletions(-) diff --git a/resources/views/categories/edit.blade.php b/resources/views/categories/edit.blade.php index 1ef3b7aa6a8d..d19e44dcd42c 100755 --- a/resources/views/categories/edit.blade.php +++ b/resources/views/categories/edit.blade.php @@ -15,7 +15,14 @@
- {{ Form::select('category_type', $category_types , old('category_type', $item->category_type), array('class'=>'select2', 'style'=>'min-width:350px', 'aria-label'=>'category_type', ($item->category_type!='') || ($item->itemCount() > 0) ? 'disabled' : '')) }} + {!! $errors->first('category_type', '') !!}
diff --git a/resources/views/custom_fields/fields/edit.blade.php b/resources/views/custom_fields/fields/edit.blade.php index 12c3a3fb735e..463019f884ea 100644 --- a/resources/views/custom_fields/fields/edit.blade.php +++ b/resources/views/custom_fields/fields/edit.blade.php @@ -88,7 +88,14 @@ } @endphp
- {{ Form::select("format",Helper::predefined_formats(), ($field_format == '') ? $field->format : $field_format, array('class'=>'format select2 form-control', 'aria-label'=>'format', 'style' => 'width:100%;')) }} + {!! $errors->first('format', '') !!}
diff --git a/resources/views/custom_fields/fieldsets/view.blade.php b/resources/views/custom_fields/fieldsets/view.blade.php index b73ae708c669..6868c2163434 100644 --- a/resources/views/custom_fields/fieldsets/view.blade.php +++ b/resources/views/custom_fields/fieldsets/view.blade.php @@ -98,8 +98,12 @@ - {{ Form::select("field_id",$custom_fields_list,"",['aria-label'=>'field_id', 'class'=>'select2', 'style' => 'min-width:400px;']) }} - +
@@ -142,4 +148,4 @@ -@stop \ No newline at end of file +@stop diff --git a/resources/views/hardware/checkout.blade.php b/resources/views/hardware/checkout.blade.php index e0dc8ef51912..ca297fa9ce02 100755 --- a/resources/views/hardware/checkout.blade.php +++ b/resources/views/hardware/checkout.blade.php @@ -82,7 +82,13 @@ {{ trans('admin/hardware/form.status') }}
- {{ Form::select('status_id', $statusLabel_list, $asset->status_id, array('class'=>'select2', 'style'=>'width:100%','', 'aria-label'=>'status_id')) }} + {!! $errors->first('status_id', '') !!}
From 2206b0a69937af9467609e173c1db16ca314fa75 Mon Sep 17 00:00:00 2001 From: Marcus Moore Date: Mon, 13 Jan 2025 12:50:18 -0800 Subject: [PATCH 03/11] Convert additional Form::select to blade component --- resources/views/hardware/quickscan-checkin.blade.php | 8 +++++++- ...ustom-field-set-default-values-for-model.blade.php | 11 ++++++++++- 2 files changed, 17 insertions(+), 2 deletions(-) diff --git a/resources/views/hardware/quickscan-checkin.blade.php b/resources/views/hardware/quickscan-checkin.blade.php index de892399cc3a..c79ca605d86c 100644 --- a/resources/views/hardware/quickscan-checkin.blade.php +++ b/resources/views/hardware/quickscan-checkin.blade.php @@ -47,7 +47,13 @@ {{ trans('admin/hardware/form.status') }}
- {{ Form::select('status_id', $statusLabel_list, '', array('class'=>'select2', 'style'=>'width:100%','', 'aria-label'=>'status_id')) }} + {!! $errors->first('status_id', '') !!}
diff --git a/resources/views/livewire/custom-field-set-default-values-for-model.blade.php b/resources/views/livewire/custom-field-set-default-values-for-model.blade.php index 9f09d111b14e..cf3eac3f07eb 100644 --- a/resources/views/livewire/custom-field-set-default-values-for-model.blade.php +++ b/resources/views/livewire/custom-field-set-default-values-for-model.blade.php @@ -4,7 +4,16 @@ {{ trans('admin/models/general.fieldset') }}
- {{ Form::select('fieldset_id', Helper::customFieldsetList(), old('fieldset_id', $fieldset_id), array('class'=>'select2 js-fieldset-field livewire-select2', 'style'=>'width:100%; min-width:350px', 'aria-label'=>'custom_fieldset', 'data-livewire-component' => $this->getId())) }} + {!! $errors->first('custom_fieldset', '') !!}
From 589ec3a564b83fb405f4d4d7e8113bf4edd56e78 Mon Sep 17 00:00:00 2001 From: Marcus Moore Date: Mon, 13 Jan 2025 13:08:59 -0800 Subject: [PATCH 04/11] Convert additional Form::select to blade component --- resources/views/livewire/importer.blade.php | 50 +++++++++++-------- .../livewire/slack-settings-form.blade.php | 18 ++++--- .../modals/partials/fieldset-select.blade.php | 12 ++++- 3 files changed, 51 insertions(+), 29 deletions(-) diff --git a/resources/views/livewire/importer.blade.php b/resources/views/livewire/importer.blade.php index b0ba7e037bce..3511a81bb239 100644 --- a/resources/views/livewire/importer.blade.php +++ b/resources/views/livewire/importer.blade.php @@ -155,15 +155,20 @@ class="col-md-12 table table-striped snipe-table">
- {{ Form::select('typeOfImport', $importTypes, $typeOfImport, [ - 'id' => 'import_type', - 'class' => 'livewire-select2', - 'style' => 'min-width: 350px', - 'data-placeholder' => trans('general.select_var', ['thing' => trans('general.import_type')]), - 'placeholder' => '', //needed so that the form-helper will put an empty option first - 'data-minimum-results-for-search' => '-1', // Remove this if the list gets long enough that we need to search - 'data-livewire-component' => $this->getId() - ]) }} + @if ($typeOfImport === 'asset' && $snipeSettings->auto_increment_assets == 0)

{{ trans('general.auto_incrementing_asset_tags_disabled_so_tags_required') }} @@ -238,17 +243,22 @@ class="col-md-12 table table-striped snipe-table">

- - {{ Form::select('field_map.'.$index, $columnOptions[$typeOfImport], @$field_map[$index], - [ - 'class' => 'mappings livewire-select2', - 'placeholder' => trans('general.importer.do_not_import'), - 'style' => 'min-width: 100%', - 'data-livewire-component' => $this->getId() - ],[ - '-' => ['disabled' => true] // this makes the "-----" line unclickable - ]) - }} + + + @foreach($columnOptions[$typeOfImport] as $key => $value) + + @endforeach +
@if (($this->activeFile->first_row) && (array_key_exists($index, $this->activeFile->first_row)))
diff --git a/resources/views/livewire/slack-settings-form.blade.php b/resources/views/livewire/slack-settings-form.blade.php index 76b3987229e3..09b4b0347404 100644 --- a/resources/views/livewire/slack-settings-form.blade.php +++ b/resources/views/livewire/slack-settings-form.blade.php @@ -66,13 +66,17 @@
- - @if (Helper::isDemoMode()) - {{ Form::select('webhook_selected', array('slack' => trans('admin/settings/general.slack'), 'general' => trans('admin/settings/general.general_webhook'),'google' => trans('admin/settings/general.google_workspaces'), 'microsoft' => trans('admin/settings/general.ms_teams')), old('webhook_selected', $webhook_selected), array('class'=>'select2 form-control', 'aria-label' => 'webhook_selected', 'id' => 'select2', 'style'=>'width:100%', 'disabled')) }} - @else - {{ Form::select('webhook_selected', array('slack' => trans('admin/settings/general.slack'), 'general' => trans('admin/settings/general.general_webhook'),'google' => trans('admin/settings/general.google_workspaces'), 'microsoft' => trans('admin/settings/general.ms_teams')), old('webhook_selected', $webhook_selected), array('class'=>'select2 form-control', 'aria-label' => 'webhook_selected', 'id' => 'select2', 'data-minimum-results-for-search' => '-1', 'style'=>'width:100%')) }} - @endif - +
diff --git a/resources/views/modals/partials/fieldset-select.blade.php b/resources/views/modals/partials/fieldset-select.blade.php index 3f4efc24b6d7..ec1e178f221e 100644 --- a/resources/views/modals/partials/fieldset-select.blade.php +++ b/resources/views/modals/partials/fieldset-select.blade.php @@ -1,6 +1,14 @@
-
{{ Form::select('fieldset_id', Helper::customFieldsetList(),old('fieldset_id'), array('class'=>'select2', 'id'=>'modal-fieldset_id', 'style'=>'width:100%;')) }}
+
+ +
- \ No newline at end of file + From 1f4cc0a4b4b01c887f247de53876b7e922d2fc25 Mon Sep 17 00:00:00 2001 From: Marcus Moore Date: Mon, 13 Jan 2025 15:23:43 -0800 Subject: [PATCH 05/11] Convert additional Form::select to blade component --- resources/views/modals/statuslabel.blade.php | 10 +++++++++- resources/views/models/bulk-edit.blade.php | 15 +++++++++++++-- .../views/models/custom_fields_form.blade.php | 9 +++++++-- 3 files changed, 29 insertions(+), 5 deletions(-) diff --git a/resources/views/modals/statuslabel.blade.php b/resources/views/modals/statuslabel.blade.php index e7076f1bbbf0..a6676c9292a0 100644 --- a/resources/views/modals/statuslabel.blade.php +++ b/resources/views/modals/statuslabel.blade.php @@ -16,7 +16,15 @@
-
{{ Form::select('type', $statuslabel_types, '', array('class'=>'select2', 'style'=>'width:100%','id' =>'modal-type', 'required',)) }}
+
+ +
diff --git a/resources/views/models/bulk-edit.blade.php b/resources/views/models/bulk-edit.blade.php index 8a053b048fbf..553914947175 100644 --- a/resources/views/models/bulk-edit.blade.php +++ b/resources/views/models/bulk-edit.blade.php @@ -62,7 +62,13 @@ {{ trans('admin/models/general.fieldset') }}
- {{ Form::select('fieldset_id', $fieldset_list , old('fieldset_id', 'NC'), array('class'=>'select2 js-fieldset-field', 'style'=>'width:350px')) }} + {!! $errors->first('fieldset_id', '') !!}
@@ -74,7 +80,12 @@ {{ trans('general.depreciation') }}
- {{ Form::select('depreciation_id', $depreciation_list , old('depreciation_id', 'NC'), array('class'=>'select2', 'style'=>'width:350px')) }} + {!! $errors->first('depreciation_id', '') !!}
diff --git a/resources/views/models/custom_fields_form.blade.php b/resources/views/models/custom_fields_form.blade.php index 4949fae71c6e..1da3609c929a 100644 --- a/resources/views/models/custom_fields_form.blade.php +++ b/resources/views/models/custom_fields_form.blade.php @@ -9,8 +9,13 @@ @if ($field->element=='listbox') - {{ Form::select($field->db_column_name(), $field->formatFieldValuesAsArray(), - old($field->db_column_name(),(isset($item) ? Helper::gracefulDecrypt($field, $item->{$field->db_column_name()}) : $field->defaultValue($model->id))), ['class' => 'format select2 form-control', ($field->pivot->required=='1' ? ' required' : '') ]) }} + @elseif ($field->element=='textarea') From bc3f236b86c827fe3c9abba9cb41d7fabcb2507e Mon Sep 17 00:00:00 2001 From: Marcus Moore Date: Mon, 13 Jan 2025 15:38:45 -0800 Subject: [PATCH 06/11] Weaken comparsion so string and int keys match --- resources/views/blade/input/select.blade.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/resources/views/blade/input/select.blade.php b/resources/views/blade/input/select.blade.php index c96b5e177220..9ddbbd6d7c0a 100644 --- a/resources/views/blade/input/select.blade.php +++ b/resources/views/blade/input/select.blade.php @@ -17,7 +17,7 @@ {{-- map the simple key => value pairs when nothing is passed in via the slot --}} @if($slot->isEmpty()) @foreach($options as $key => $value) - + @endforeach @else {{ $slot }} From 888c96718ca036379b61270738c128f18690a4d0 Mon Sep 17 00:00:00 2001 From: Marcus Moore Date: Mon, 13 Jan 2025 15:38:51 -0800 Subject: [PATCH 07/11] Convert additional Form::select to blade component --- .../views/models/custom_fields_form_bulk_edit.blade.php | 8 ++++++-- .../views/partials/forms/edit/depreciation.blade.php | 9 ++++++++- 2 files changed, 14 insertions(+), 3 deletions(-) diff --git a/resources/views/models/custom_fields_form_bulk_edit.blade.php b/resources/views/models/custom_fields_form_bulk_edit.blade.php index e048b38d0962..cea495ccd2e3 100644 --- a/resources/views/models/custom_fields_form_bulk_edit.blade.php +++ b/resources/views/models/custom_fields_form_bulk_edit.blade.php @@ -24,8 +24,12 @@ @if ($field->element!='text') @if ($field->element=='listbox') - {{ Form::select($field->db_column_name(), $field->formatFieldValuesAsArray(), - old($field->db_column_name(),(isset($item) ? Helper::gracefulDecrypt($field, $item->{$field->db_column_name()}) : $field->defaultValue($model->id))), ['class'=>'format select2 form-control']) }} + @elseif ($field->element=='textarea') @if($field->is_unique) diff --git a/resources/views/partials/forms/edit/depreciation.blade.php b/resources/views/partials/forms/edit/depreciation.blade.php index 4478a9c05fba..8195ac394ef0 100644 --- a/resources/views/partials/forms/edit/depreciation.blade.php +++ b/resources/views/partials/forms/edit/depreciation.blade.php @@ -2,7 +2,14 @@
- {{ Form::select('depreciation_id', $depreciation_list , old('depreciation_id', $item->depreciation_id), array('class'=>'select2', 'style'=>'width:350px', 'aria-label'=>'depreciation_id')) }} + {!! $errors->first('depreciation_id', '') !!}
From 3eb307a01900a512d2e44260b157af7d30e035c9 Mon Sep 17 00:00:00 2001 From: Marcus Moore Date: Mon, 13 Jan 2025 15:58:15 -0800 Subject: [PATCH 08/11] Convert additional Form::select to blade component --- .../forms/edit/maintenance_type.blade.php | 9 +++- .../partials/forms/edit/status.blade.php | 11 ++++- resources/views/settings/branding.blade.php | 47 +++++++++++++++++-- 3 files changed, 60 insertions(+), 7 deletions(-) diff --git a/resources/views/partials/forms/edit/maintenance_type.blade.php b/resources/views/partials/forms/edit/maintenance_type.blade.php index 24d008fa2332..b82bead76b04 100644 --- a/resources/views/partials/forms/edit/maintenance_type.blade.php +++ b/resources/views/partials/forms/edit/maintenance_type.blade.php @@ -3,7 +3,14 @@
- {{ Form::select('asset_maintenance_type', $assetMaintenanceType , old('asset_maintenance_type', $item->asset_maintenance_type), ['class'=>'select2', 'aria-label'=>'asset_maintenance_type', 'required' => Helper::checkIfRequired($item, 'asset_maintenance_type') ? true : '', 'style'=> 'width:100%;']) }} + {!! $errors->first('asset_maintenance_type', '') !!}
diff --git a/resources/views/partials/forms/edit/status.blade.php b/resources/views/partials/forms/edit/status.blade.php index 8554f9a59c95..01dd14612e7a 100644 --- a/resources/views/partials/forms/edit/status.blade.php +++ b/resources/views/partials/forms/edit/status.blade.php @@ -2,7 +2,16 @@
- {{ Form::select('status_id', $statuslabel_list , old('status_id', $item->status_id), array('class'=>'select2 status_id', 'style'=>'width:100%','id'=>'status_select_id', 'aria-label'=>'status_id', 'required' => 'required')) }} + {!! $errors->first('status_id', '') !!}
diff --git a/resources/views/settings/branding.blade.php b/resources/views/settings/branding.blade.php index c586917ef534..be6120a4f727 100644 --- a/resources/views/settings/branding.blade.php +++ b/resources/views/settings/branding.blade.php @@ -67,7 +67,14 @@ {{ Form::label('brand', trans('admin/settings/general.web_brand')) }}
- {!! Form::select('brand', array('1'=>'Text','2'=>'Logo','3'=>'Logo + Text'), old('brand', $setting->brand), array('class' => 'form-control select2', 'style'=>'width: 150px ;')) !!} + {!! $errors->first('brand', '') !!}
@@ -252,10 +259,25 @@
@if (config('app.lock_passwords')===true) - {!! Form::select('support_footer', array('on'=>'Enabled','off'=>'Disabled','admin'=>'Superadmin Only'), old('support_footer', $setting->support_footer), ['class' => 'form-control select2 disabled', 'style'=>'width: 150px ;', 'disabled' => 'disabled']) !!} +

{{ trans('general.feature_disabled') }}

@else - {!! Form::select('support_footer', array('on'=>'Enabled','off'=>'Disabled','admin'=>'Superadmin Only'), old('support_footer', $setting->support_footer), array('class' => 'form-control select2', 'style'=>'width: 150px ;')) !!} + @endif @@ -271,10 +293,25 @@
@if (config('app.lock_passwords')===true) - {!! Form::select('version_footer', array('on'=>'Enabled','off'=>'Disabled','admin'=>'Superadmin Only'), old('version_footer', $setting->version_footer), ['class' => 'form-control select2 disabled', 'style'=>'width: 150px ;', 'disabled' => 'disabled']) !!} +

{{ trans('general.feature_disabled') }}

@else - {!! Form::select('version_footer', array('on'=>'Enabled','off'=>'Disabled','admin'=>'Superadmin Only'), old('version_footer', $setting->version_footer), array('class' => 'form-control select2', 'style'=>'width: 150px ;')) !!} + @endif

{{ trans('admin/settings/general.version_footer_help') }}

From 9a043da005f2be2e90b5191c3d2baddeaf840b84 Mon Sep 17 00:00:00 2001 From: Marcus Moore Date: Mon, 13 Jan 2025 16:16:49 -0800 Subject: [PATCH 09/11] Convert additional Form::select to blade component --- resources/views/settings/general.blade.php | 21 ++++++++----- resources/views/settings/labels.blade.php | 33 +++++++++++++++------ resources/views/statuslabels/edit.blade.php | 8 ++++- 3 files changed, 44 insertions(+), 18 deletions(-) diff --git a/resources/views/settings/general.blade.php b/resources/views/settings/general.blade.php index 1de5d4035d85..3a549525d359 100644 --- a/resources/views/settings/general.blade.php +++ b/resources/views/settings/general.blade.php @@ -359,9 +359,12 @@ trans('general.pie_chart_type')) }}
- {{ Form::select('dash_chart_type', array( - 'name' => 'Status Label Name', - 'type' => 'Status Label Type'), old('dash_chart_type', $setting->dash_chart_type), ['class' =>'select2', 'style' => 'width: 80%']) }} +
@@ -372,11 +375,13 @@ {{ Form::label('depreciation_method', trans('Depreciation method')) }}
- {{ Form::select('depreciation_method', array( - 'default' => 'Linear (default)', - 'half_1' => 'Half-year convention, always applied', - 'half_2' => 'Half-year convention, applied with condition', - ), old('username_format', $setting->depreciation_method), ['class' =>'select2', 'style' => 'width: 80%']) }} +
diff --git a/resources/views/settings/labels.blade.php b/resources/views/settings/labels.blade.php index fa8c5dc858b2..8666ab87273c 100644 --- a/resources/views/settings/labels.blade.php +++ b/resources/views/settings/labels.blade.php @@ -170,7 +170,14 @@ class="table table-striped snipe-table" 'none' => trans('admin/settings/general.none'), ]; @endphp - {{ Form::select('label2_1d_type', $select1DValues, old('label2_1d_type', $setting->label2_1d_type), [ 'class'=>'select2 col-md-4', 'aria-label'=>'label2_1d_type' ]) }} + {!! $errors->first('label2_1d_type', '') !!}

{{ trans('admin/settings/general.label2_1d_type_help') }}. @@ -214,7 +221,14 @@ class="table table-striped snipe-table" 'none' => trans('admin/settings/general.none'), ]); @endphp - {{ Form::select('label2_2d_type', $select2DValues, old('label2_2d_type', $setting->label2_2d_type), [ 'class'=>'select2 col-md-4', 'aria-label'=>'label2_2d_type' ]) }} + {!! $errors->first('label2_2d_type', '') !!}

{{ trans('admin/settings/general.label2_2d_type_help', ['current' => $setting->barcode_type]) }}. @@ -277,13 +291,14 @@ class="table table-striped snipe-table" {{ Form::label('label2_2d_target', trans('admin/settings/general.label2_2d_target'), ['class'=>'control-label']) }}

- {{ Form::select('label2_2d_target', [ - 'hardware_id' => trans('general.url') .': /hardware/{id} ('.trans('admin/settings/general.default').')', - 'ht_tag' => trans('general.url') .': /ht/{asset_tag}', - 'plain_asset_id' => trans('admin/settings/general.data') .': '. trans('admin/settings/general.asset_id') .' {id}', - 'plain_asset_tag' => trans('admin/settings/general.data') .': '. trans('general.asset_tag') .' {asset_tag}', - 'plain_serial_number' => trans('admin/settings/general.data') .': '. trans('general.serial_number') .' {serial}', - ], old('label2_2d_target', $setting->label2_2d_target), [ 'class'=>'select2 col-md-4', 'aria-label'=>'label2_2d_target' ]) }} + {!! $errors->first('label2_2d_target', '') !!}

{{ trans('admin/settings/general.label2_2d_target_help') }}

diff --git a/resources/views/statuslabels/edit.blade.php b/resources/views/statuslabels/edit.blade.php index af69f35de81e..27fb91148b92 100755 --- a/resources/views/statuslabels/edit.blade.php +++ b/resources/views/statuslabels/edit.blade.php @@ -27,7 +27,13 @@ {{ trans('admin/statuslabels/table.status_type') }}
- {{ Form::select('statuslabel_types', $statuslabel_types, $item->getStatuslabelType(), array('class'=>'select2', 'style'=>'width: 100%; min-width:400px', 'aria-label'=>'statuslabel_types')) }} + {!! $errors->first('statuslabel_types', '') !!}
From 3fadeebd8240638951db7235911d4390c5aefa96 Mon Sep 17 00:00:00 2001 From: Marcus Moore Date: Mon, 13 Jan 2025 16:20:02 -0800 Subject: [PATCH 10/11] Convert additional Form::select to blade component --- resources/views/users/confirm-bulk-delete.blade.php | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/resources/views/users/confirm-bulk-delete.blade.php b/resources/views/users/confirm-bulk-delete.blade.php index 8e4ba3307123..0234ce576b2f 100644 --- a/resources/views/users/confirm-bulk-delete.blade.php +++ b/resources/views/users/confirm-bulk-delete.blade.php @@ -109,7 +109,15 @@ - {{ Form::select('status_id', $statuslabel_list , old('status_id'), array('class'=>'select2', 'style'=>'width:250px', 'required' => true)) }} + @@ -159,4 +167,4 @@ } }); -@stop \ No newline at end of file +@stop From abb50fcd0951618372139f870cdceb18cd38f2ef Mon Sep 17 00:00:00 2001 From: Marcus Moore Date: Mon, 13 Jan 2025 16:21:19 -0800 Subject: [PATCH 11/11] Delete unused partials --- .../views/partials/forms/edit/category.blade.php | 8 -------- resources/views/partials/forms/edit/company.blade.php | 11 ----------- .../views/partials/forms/edit/location.blade.php | 8 -------- .../views/partials/forms/edit/manufacturer.blade.php | 8 -------- .../views/partials/forms/edit/supplier.blade.php | 11 ----------- 5 files changed, 46 deletions(-) delete mode 100644 resources/views/partials/forms/edit/category.blade.php delete mode 100644 resources/views/partials/forms/edit/company.blade.php delete mode 100644 resources/views/partials/forms/edit/location.blade.php delete mode 100644 resources/views/partials/forms/edit/manufacturer.blade.php delete mode 100644 resources/views/partials/forms/edit/supplier.blade.php diff --git a/resources/views/partials/forms/edit/category.blade.php b/resources/views/partials/forms/edit/category.blade.php deleted file mode 100644 index 158cc3508bb6..000000000000 --- a/resources/views/partials/forms/edit/category.blade.php +++ /dev/null @@ -1,8 +0,0 @@ - -
- -
- {{ Form::select('category_id', $category_list , old('category_id', $item->category_id), array('class'=>'select2', 'style'=>'width:100%', 'required' => Helper::checkIfRequired($item, 'category_id') ? true : '')) }} - {!! $errors->first('category_id', '') !!} -
-
diff --git a/resources/views/partials/forms/edit/company.blade.php b/resources/views/partials/forms/edit/company.blade.php deleted file mode 100644 index 22cb623584ac..000000000000 --- a/resources/views/partials/forms/edit/company.blade.php +++ /dev/null @@ -1,11 +0,0 @@ -@if (\App\Models\Company::isCurrentUserAuthorized()) -
-
- {{ Form::label('company_id', trans('general.company'), array('class' => 'col-md-3 control-label', 'for' => 'company_id')) }} -
-
- {{ Form::select('company_id', $company_list , old('company_id', $item->company_id), array('class'=>'select2', 'style'=>'width:100%', 'required' => Helper::checkIfRequired($item, 'company_id') ? true : '')) }} - {!! $errors->first('company_id', '') !!} -
-
-@endif diff --git a/resources/views/partials/forms/edit/location.blade.php b/resources/views/partials/forms/edit/location.blade.php deleted file mode 100644 index 49bc2976d0a6..000000000000 --- a/resources/views/partials/forms/edit/location.blade.php +++ /dev/null @@ -1,8 +0,0 @@ - -
- -
- {{ Form::select('location_id', $location_list , old('location_id', $item->location_id), array('class'=>'select2', 'style'=>'width:350px')) }} - {!! $errors->first('location_id', '') !!} -
-
diff --git a/resources/views/partials/forms/edit/manufacturer.blade.php b/resources/views/partials/forms/edit/manufacturer.blade.php deleted file mode 100644 index 644b70d7bac7..000000000000 --- a/resources/views/partials/forms/edit/manufacturer.blade.php +++ /dev/null @@ -1,8 +0,0 @@ - -
- -
- {{ Form::select('manufacturer_id', $manufacturer_list , old('manufacturer_id', $item->manufacturer_id), array('class'=>'select2', 'style'=>'width:100%', 'required' => Helper::checkIfRequired($item, 'manufacturer_id') ? true : '')) }} - {!! $errors->first('manufacturer_id', '') !!} -
-
diff --git a/resources/views/partials/forms/edit/supplier.blade.php b/resources/views/partials/forms/edit/supplier.blade.php deleted file mode 100644 index 40c1e2b2792c..000000000000 --- a/resources/views/partials/forms/edit/supplier.blade.php +++ /dev/null @@ -1,11 +0,0 @@ - -
- -
- {{ Form::select('supplier_id', $supplier_list , old('supplier_id', $item->supplier_id), ['class'=>'select2', 'style'=>'min-width:350px', 'id' => 'supplier_select_id', 'required' => Helper::checkIfRequired($item, 'supplier_id') ? true : '']) }} - {!! $errors->first('supplier_id', '') !!} -
- -