falta calcular maximo solapas

This commit is contained in:
2025-01-23 14:26:51 +01:00
parent 98d8d45899
commit 0d3ea391d7
6 changed files with 146 additions and 91 deletions

View File

@ -244,7 +244,11 @@ class Comparador {
this.gramajeSobrecubierta.init();
this.papelSobrecubierta.onChange(() => self.gramajeSobrecubierta.empty());
this.sobrecubierta.on('change', () => {
if (this.sobrecubierta.val() == 1) {
if (this.sobrecubierta.select2('data')[0].id == 1) {
if($('#solapas_sobrecubierta').prop('checked') == false){
this.sobrecubierta.val(0);
popErrorAlert(window.language.Presupuestos.errores.error_sobrecubierta_sin_solapas, 'divAlarmasComparador')
}
$('#solapas_sobrecubierta').prop('checked', true);
$('#div_solapas_ancho_sobrecubierta').removeClass('d-none');
$('#solapas_ancho_sobrecubierta').val(60);
@ -316,7 +320,6 @@ class Comparador {
if (this.tipo_impresion_id == 1 || this.tipo_impresion_id == 3 || this.tipo_impresion_id == 5 || this.tipo_impresion_id == 7) {
$('.comp_guardas_items').on('change', this.obtenerComparadorGuardas.bind(this));
}
}
#changePaginasComparador(element) {