Alexander Musikhin 7 місяців тому
батько
коміт
b8bc84fa21
1 змінених файлів з 2 додано та 2 видалено
  1. 2 2
      resources/views/reclamations/edit.blade.php

+ 2 - 2
resources/views/reclamations/edit.blade.php

@@ -23,7 +23,7 @@
                     @include('partials.select', ['name' => 'user_id', 'title' => 'Менеджер', 'options' => $users, 'value' => $reclamation->user_id ?? old('user_id') ?? auth()->user()->id])
                     @include('partials.input', ['name' => 'create_date', 'title' => 'Дата создания', 'type' => 'date', 'required' => true, 'value' => $reclamation->create_date ?? date('Y-m-d')])
                     @include('partials.input', ['name' => 'finish_date', 'title' => 'Дата завершения', 'type' => 'date', 'required' => true, 'value' => $reclamation->finish_date ?? date('Y-m-d', strtotime('+30 days'))])
-                    @include('partials.textarea', ['name' => 'reason', 'title' => 'Причина', 'size' => 6, 'value' => $reclamation->reason ?? ''])
+                    @include('partials.select', ['name' => 'reason', 'title' => 'Причина', 'size' => 6, 'value' => $reclamation->reason ?? '', 'options' => ['Вандализм', 'Гарантия', 'Сервисное обслуживание'], 'key_as_val' => true])
                     @include('partials.textarea', ['name' => 'guarantee', 'title' => 'Гарантии', 'size' => 6, 'value' => $reclamation->guarantee ?? ''])
                     @include('partials.textarea', ['name' => 'whats_done', 'title' => 'Что сделано', 'size' => 6, 'value' => $reclamation->whats_done ?? ''])
                     <input type="hidden" name="redirect_url" value="{{ url()->previous() }}">
@@ -110,7 +110,7 @@
                         <div class="row">
                             <div class="col-12 text-end">
                                 <span class="text-secondary small">Для удаления детали поставьте в количество 0</span>
-                                <a href="#" class="btn btn-light" onclick="let x = $('.rows').children().last().clone(); $('.rows').append(x);">Добавить строку</a>
+                                <span class="btn btn-light cursor-pointer" onclick="$('.rows').children().last().clone().appendTo('.rows');">Добавить строку</span>
                                 <button class="btn btn-primary btn-sm" type="submit">Сохранить детали</button>
                             </div>
                         </div>