sk-20 : add form files to presupuesto admin

This commit is contained in:
amazuecos
2025-01-23 20:25:28 +01:00
parent 910df7b822
commit 19220ab985
5 changed files with 200 additions and 1 deletions

View File

@ -10,6 +10,7 @@ import Servicios from './sections/servicios.js';
import Envios from './sections/envios.js';
import TiradasAlernativas from './sections/tiradasAlternativas.js';
import Resumen from './sections/resumen.js';
import FileUploadDropzone from '../../components/forms/fileUploadDropzone.js';
class PresupuestoAdminEdit {
@ -50,6 +51,13 @@ class PresupuestoAdminEdit {
this.guardar = $('#saveForm');
this.calcularPresupuesto = false;
this.configUploadDropzone = {
domElement: '#dropzone-presupuesto-admin-files',
nameId: "presupuesto_id",
getUri: '/presupuestos/presupuestocliente/get_files',
postUri: '/presupuestos/presupuestocliente/upload_files'
}
this.fileUploadDropzone = new FileUploadDropzone(this.configUploadDropzone)
}
init() {
@ -116,6 +124,8 @@ class PresupuestoAdminEdit {
$('#lomo_cubierta').on('change', this.datosLibro.changeAnchoSolapasCubierta);
$('#lomo_sobrecubierta').on('change', this.datosLibro.changeAnchoSolapasSobrecubierta);
this.fileUploadDropzone.init()
}