add validator, optimizations
This commit is contained in:
@@ -1,10 +1,9 @@
|
||||
<div class="row mt-3">
|
||||
<div class="col-12">
|
||||
@include('Admin.Shop.Articles.partials.characteristics')
|
||||
</div>
|
||||
</div>
|
||||
{{ Form::open(['route' => 'Admin.Shop.Articles.store', 'id' => 'article-form', 'autocomplete' => 'off', 'files' => true]) }}
|
||||
<input type="hidden" name="id" id="id" value="{{ $article['id'] ?? null }}">
|
||||
@include('Admin.Shop.Articles.partials.characteristics')
|
||||
{{ Form::close() }}
|
||||
|
||||
@include('components.save')
|
||||
<x-save />
|
||||
|
||||
@include('load.form.appender')
|
||||
@include('load.form.editor')
|
||||
@@ -17,20 +16,22 @@
|
||||
@include('load.layout.modal')
|
||||
|
||||
@push('js')
|
||||
<script>
|
||||
$(function() {
|
||||
{!! JsValidator::formRequest('App\Http\Requests\Admin\Shop\StoreArticlePost', '#article-form') !!}
|
||||
|
||||
$('.active-checkbox').bootstrapToggle();
|
||||
$('.active-checkbox').off('change').on('change', function(e) {
|
||||
var id = $('#id').val();
|
||||
// handleAdmin.toggle(id, $(this).prop('checked'));
|
||||
});
|
||||
<script>
|
||||
$(function() {
|
||||
|
||||
initChevron();
|
||||
initEditor();
|
||||
initSaveForm('#article-form');
|
||||
initSelect2();
|
||||
$('.active-checkbox').bootstrapToggle();
|
||||
$('.active-checkbox').off('change').on('change', function(e) {
|
||||
var id = $('#id').val();
|
||||
// handleAdmin.toggle(id, $(this).prop('checked'));
|
||||
});
|
||||
|
||||
});
|
||||
</script>
|
||||
@endpush
|
||||
initChevron();
|
||||
initEditor();
|
||||
initSaveForm('#article-form');
|
||||
initSelect2();
|
||||
|
||||
});
|
||||
</script>
|
||||
@endpush
|
||||
|
||||
Reference in New Issue
Block a user