lineas presupuesto actualizadas con tirada

This commit is contained in:
2025-01-08 17:34:29 +01:00
parent a88f3fb009
commit 642b445cd2
7 changed files with 106 additions and 35 deletions

View File

@ -194,10 +194,10 @@ class PresupuestoCliente {
console.log("Error en el calculo del lomo interior.");
return;
}
if(response.errors.status == 1){
if (response.errors.status == 1) {
popErrorAlert('' + response.errors.value, "sk-alert", false);
}
else{
else {
popAlert2Hide('sk-alert');
}
},
@ -477,6 +477,13 @@ class PresupuestoCliente {
try {
$('#loader').modal('show');
if (this.direcciones.tiradaSeleccionada == null || this.direcciones.tiradaSeleccionada == undefined
|| this.direcciones.tiradaSeleccionada == "" || this.direcciones.tiradaSeleccionada == 0) {
popErrorAlert("Seleccione una tirada en la pestaña direcciones para guardar el presupuesto.");
$('#loader').modal('hide');
return;
}
this.#getDatos();
let datos_to_check = this.#prepareData();
@ -780,16 +787,16 @@ class PresupuestoCliente {
self.direcciones.cargarDatos(response.data.direcciones, response.data.datosGenerales);
try{
try {
self.disenioInterior.cargarDatos(response.data.interior, response.data.datosGenerales.papelInteriorDiferente);
}
catch(e){
catch (e) {
console.log("Error al cargar diseño interior: " + e);
}
try{
try {
self.disenioCubierta.cargarDatos(response.data.cubierta, response.data.guardas, response.data.sobrecubierta);
}
catch(e){
catch (e) {
console.log("Error al cargar diseño cubierta: " + e);
}