mirror of
https://git.imnavajas.es/jjimenez/erp-imprimelibros.git
synced 2026-01-23 01:00:23 +00:00
trabajando en modificar para obtener los servicios
This commit is contained in:
@ -1390,9 +1390,18 @@ class PresupuestoCliente {
|
||||
this.summaryTableExtras.addClass('d-none');
|
||||
} else {
|
||||
|
||||
const servicios = [];
|
||||
$('.service-checkbox:checked').each(function () {
|
||||
const $servicio = $(this);
|
||||
servicios.push({
|
||||
id: $(`label[for="${$servicio.attr('id')}"] .service-title`).text().trim() || $servicio.attr('id'),
|
||||
price: $(`label[for="${$servicio.attr('id')}"] .service-price`).text().trim() || $servicio.attr('price')
|
||||
});
|
||||
});
|
||||
|
||||
const body = {
|
||||
presupuesto: this.#getPresupuestoData(), // objeto JS con campos que coincidan con la entidad
|
||||
servicios: this.formData.servicios.servicios // array de strings
|
||||
servicios: servicios
|
||||
};
|
||||
|
||||
$.ajax({
|
||||
|
||||
Reference in New Issue
Block a user