#1 Pulizia codice delle view spostando le parti in javascript in file separati sotto /js/app/xxx.js

This commit is contained in:
2023-05-26 08:16:42 +02:00
parent f517547f5f
commit dae4b7b797
14 changed files with 108 additions and 215 deletions

View File

@@ -7,4 +7,27 @@ $(document).ready(function() {
$('#listrapportoE').DataTable({
responsive: true
});
});
});
$(document).ready(function() {
$('#categorie').DataTable({
responsive: true
});
$(document).on('click','.open_modal',function(){
var url = "catmodify";
var riga_id= $(this).val();
$.getJSON(url + '/' + riga_id, function (data) {
//success data
console.log(data[0]);
console.log(data[0].cat_name);
$('#H_cat_cat_name').val(data[0].cat_name);
$('#H_cat_id').val(data[0].id);
$('#myModal').modal('show');
});
});
$(document).on('click','.open_modal_new',function(){
$('#myModal_new').modal('show');
});
});

6
public/js/app/dashboard.js vendored Normal file
View File

@@ -0,0 +1,6 @@
$(document).ready(function() {
$('#categorie').DataTable({
responsive: true
});
});

5
public/js/app/enel.js vendored Normal file
View File

@@ -0,0 +1,5 @@
$(document).ready(function() {
$('#listaLettureEnel').DataTable({
responsive: true
});
});

5
public/js/app/gas.js vendored Normal file
View File

@@ -0,0 +1,5 @@
$(document).ready(function() {
$('#listaLettureGas').DataTable({
responsive: true
});
});

0
public/js/app/tag.js vendored Normal file
View File