intentando resolver conflictos

This commit is contained in:
jaimejimenezortega
2024-05-08 20:44:40 +02:00
parent e2b998bfa4
commit feebbed24d
135 changed files with 0 additions and 0 deletions

View File

@ -0,0 +1,17 @@
/*
fetch("/presupuestos/cosidotapablanda/datatable", {
method: 'POST',
body: JSON.stringify(data),
headers: { 'X-Requested-With': 'XMLHttpRequest' },
})
.then(response => console.log(response))
//.then(json => console.log(json))
.catch(err => console.log(err));
*/

View File

@ -0,0 +1,36 @@
<?= $this->extend('themes/backend/vuexy/main/defaultlayout') ?>
<?= $this->section("additionalInlineJs") ?>
console.log("Hola")
let datos = {
table_type: 'comp_int_bn',
paginas: 200,
tirada: 100,
merma: 10,
ancho: 98 ,
alto: 148,
papel_generico_id: 4,
papel_generico: 'AHUESADO OFFSET',
gramaje: 80,
<?= csrf_token() ?? "token" ?> : <?= csrf_token() ?>v
}
$.ajax({
type:"POST",
url:"cosidotapablanda/datatable",
data:datos, // data recive un objeto con la informacion que se enviara al servidor
success:function(data){ //success es una funcion que se utiliza si el servidor retorna informacion
console.log(data)
yeniden(data.<?= csrf_token() ?>);
},
//dataType: dataType // El tipo de datos esperados del servidor. Valor predeterminado: Intelligent Guess (xml, json, script, text, html).
})
<?=$this->endSection() ?>