[WIP] Fix cosmetics, prices

This commit is contained in:
Ludovic CANDELLIER
2020-06-07 23:15:22 +02:00
parent 424fb43b20
commit 066744e082
35 changed files with 230 additions and 193 deletions

View File

@@ -79,43 +79,17 @@
@push('js')
<script>
$(function() {
$(function() {
$("#model_id").off('change').on('change', function(e) {
var model = $('#model_id').select2('data');
var name = model[0]['text'];
console.log(name);
$('input[name="name"]').val(name);
});
$(".select2").select2();
$('.editor').tinymce({});
$('#model').change( function() {
$.ajax({
url : '{{ route('Botanic.Admin.Varieties.getSelect') }}',
method : 'POST',
data: {model: $('#model').val()},
success : function(data) {
console.log(data);
$("#model_id").select2({
data: data
});
// setOptions('#model_id',data);
//
}
});
});
$('.select2').select2();
$('.editor').tinymce({});
$('.active-checkbox').bootstrapToggle();
$('.active-checkbox').off('change').on('change', function(e) {
var id = $('#id').val();
// handleAdmin.toggle(id, $(this).prop('checked'));
});
});
});
</script>
@endpush