mirror of
https://git.imnavajas.es/jjimenez/safekat.git
synced 2025-07-25 22:52:08 +00:00
terminado. faltan pruebas
This commit is contained in:
@ -352,11 +352,9 @@ class Cosidotapablanda extends \App\Controllers\GoBaseResourceController
|
|||||||
|
|
||||||
// Lineas Presupuesto
|
// Lineas Presupuesto
|
||||||
[$cambios_lineas, $this->viewData['lineasPresupuesto']] = $this->getLineasPresupuesto($presupuestoEntity);
|
[$cambios_lineas, $this->viewData['lineasPresupuesto']] = $this->getLineasPresupuesto($presupuestoEntity);
|
||||||
if($cambios_lineas){
|
$this->viewData['presupuestoEntity']->cambios_lineas=$cambios_lineas;
|
||||||
$this->viewData['presupuestoEntity']->cambios_lineas=true;
|
|
||||||
}
|
|
||||||
// Servicios
|
// Servicios
|
||||||
[$cambios_en_servicios, $servicios] = $this->getLineasServicios($presupuestoEntity);
|
|
||||||
$this->viewData['serviciosPreimpresion'] = $this->getServiciosPreimpresion();
|
$this->viewData['serviciosPreimpresion'] = $this->getServiciosPreimpresion();
|
||||||
$this->viewData['serviciosPreimpresion'] = $this->getServiciosPreimpresion();
|
$this->viewData['serviciosPreimpresion'] = $this->getServiciosPreimpresion();
|
||||||
$this->viewData['serviciosEncuadernacion'] = $this->getServiciosEncuadernacion();
|
$this->viewData['serviciosEncuadernacion'] = $this->getServiciosEncuadernacion();
|
||||||
@ -364,6 +362,8 @@ class Cosidotapablanda extends \App\Controllers\GoBaseResourceController
|
|||||||
$this->viewData['serviciosAcabado'] = $this->getServiciosAcabado();
|
$this->viewData['serviciosAcabado'] = $this->getServiciosAcabado();
|
||||||
|
|
||||||
[$cambios_en_servicios, $servicios] = $this->getLineasServicios($presupuestoEntity);
|
[$cambios_en_servicios, $servicios] = $this->getLineasServicios($presupuestoEntity);
|
||||||
|
$this->viewData['presupuestoEntity']->cambios_servicios=$cambios_en_servicios;
|
||||||
|
|
||||||
$this->viewData['serviciosEncuadernacionList'] = $servicios->serviciosEncuadernacion;
|
$this->viewData['serviciosEncuadernacionList'] = $servicios->serviciosEncuadernacion;
|
||||||
$this->viewData['serviciosAcabadosList'] = $servicios->serviciosAcabado;
|
$this->viewData['serviciosAcabadosList'] = $servicios->serviciosAcabado;
|
||||||
$this->viewData['serviciosManipuladoList'] = $servicios->serviciosManipulado;
|
$this->viewData['serviciosManipuladoList'] = $servicios->serviciosManipulado;
|
||||||
@ -371,6 +371,7 @@ class Cosidotapablanda extends \App\Controllers\GoBaseResourceController
|
|||||||
|
|
||||||
// Direciones presupuesto
|
// Direciones presupuesto
|
||||||
[$cambios_en_direcciones, $this->viewData['direccionesList']] = $this->getLineasDirecciones($presupuestoEntity);
|
[$cambios_en_direcciones, $this->viewData['direccionesList']] = $this->getLineasDirecciones($presupuestoEntity);
|
||||||
|
$this->viewData['presupuestoEntity']->cambios_direcciones=$cambios_en_direcciones;
|
||||||
|
|
||||||
$this->viewData['POD'] = $this->getPOD();
|
$this->viewData['POD'] = $this->getPOD();
|
||||||
|
|
||||||
|
|||||||
@ -249,8 +249,15 @@ return [
|
|||||||
'duplicado' => 'DUPLICADO',
|
'duplicado' => 'DUPLICADO',
|
||||||
|
|
||||||
'duplicarConTipologias' => 'El presupuesto contiene lineas de presupuesto con datos de tipologías. Se va a duplicar el presupuesto con las mismas tipologías',
|
'duplicarConTipologias' => 'El presupuesto contiene lineas de presupuesto con datos de tipologías. Se va a duplicar el presupuesto con las mismas tipologías',
|
||||||
|
|
||||||
|
'presupuestoDuplicadoActualizacion' => 'El presupuesto ha sido creado duplicando un presupuesto existente. Se han actualizado los precios y las líneas de presupuesto con las tarifas actuales. Por favor, revíse la información.',
|
||||||
|
|
||||||
|
'actualizacionPrecios' => 'Los siguientes datos del presupuesto se han actualizado debido a un cambio de tarifas o de los consumibles/maquinaria disponible en el sistema. Revise la información.',
|
||||||
|
'actualizacionPreciosLP' => '\n- Líneas de presupuesto',
|
||||||
|
'actualizacionPreciosServicios' => '\n- Servicios',
|
||||||
|
'actualizacionPreciosEnvios' => '\n- Precio envíos',
|
||||||
|
|
||||||
|
|
||||||
'validation' => [
|
'validation' => [
|
||||||
'decimal' => 'El campo {field} debe contener un número decimal.',
|
'decimal' => 'El campo {field} debe contener un número decimal.',
|
||||||
'integer' => 'El campo {field} debe contener un número entero.',
|
'integer' => 'El campo {field} debe contener un número entero.',
|
||||||
|
|||||||
@ -27,7 +27,7 @@ function asyncMessageDialog(title, msg, callback) {
|
|||||||
$("#labelMsgMessageDialog").html(msg);
|
$("#labelMsgMessageDialog").html(msg);
|
||||||
$("#okButton").off('click').click(function () {
|
$("#okButton").off('click').click(function () {
|
||||||
callback();
|
callback();
|
||||||
$confirmDialog.modal("hide");
|
$messageDialog.modal("hide");
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -85,6 +85,13 @@
|
|||||||
})
|
})
|
||||||
|
|
||||||
if(gotaNegro){
|
if(gotaNegro){
|
||||||
|
const domain = window.location.origin
|
||||||
|
const url = window.location.href;
|
||||||
|
const url_parts = url.split('/');
|
||||||
|
var id = -1;
|
||||||
|
if(url_parts[url_parts.length-2] == 'edit'){
|
||||||
|
id = url_parts[url_parts.length-1];
|
||||||
|
}
|
||||||
asyncMessageDialog('<?= lang("Basic.global.Warning") ?>', '<?= lang("Presupuestos.duplicarConTipologias") ?>', function() {
|
asyncMessageDialog('<?= lang("Basic.global.Warning") ?>', '<?= lang("Presupuestos.duplicarConTipologias") ?>', function() {
|
||||||
$.ajax({
|
$.ajax({
|
||||||
type: 'post',
|
type: 'post',
|
||||||
@ -295,9 +302,36 @@
|
|||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
|
|
||||||
|
|
||||||
|
<?php if (str_contains($formAction, 'edit')): ?>
|
||||||
|
<?= $this->section("additionalInlineJs") ?>
|
||||||
|
if(<?php echo $presupuestoEntity->is_duplicado?'true':'false'; ?>){
|
||||||
|
asyncMessageDialog(
|
||||||
|
'<?= lang("Basic.global.Warning") ?>',
|
||||||
|
'<?= lang("Presupuestos.presupuestoDuplicadoActualizacion") ?>',
|
||||||
|
function(){});
|
||||||
|
}
|
||||||
|
else if(<?php echo ($presupuestoEntity->cambios_lineas? 'true':'false'); ?> ||
|
||||||
|
<?php echo ($presupuestoEntity->cambios_servicios? 'true':'false'); ?> ||
|
||||||
|
<?php echo ($presupuestoEntity->cambios_envios ? 'true':'false'); ?>){
|
||||||
|
|
||||||
|
let text = '<?= lang("Presupuestos.actualizacionPrecios") ?>';
|
||||||
|
if(<?php echo ($presupuestoEntity->cambios_lineas ? 'true':'false'); ?>){
|
||||||
|
text += '<?= lang("Presupuestos.actualizacionPreciosLP") ?>';
|
||||||
|
}
|
||||||
|
else if (<?php echo ($presupuestoEntity->cambios_servicios ? 'true':'false'); ?>){
|
||||||
|
text += '<?= lang("Presupuestos.actualizacionPreciosServicios") ?>';
|
||||||
|
}
|
||||||
|
else if (<?php echo ($presupuestoEntity->cambios_envios ? 'true':'false'); ?>){
|
||||||
|
text += '<?= lang("Presupuestos.actualizacionPreciosEnvios") ?>';
|
||||||
|
}
|
||||||
|
asyncMessageDialog(
|
||||||
|
'<?= lang("Basic.global.Warning") ?>',
|
||||||
|
text,
|
||||||
|
function(){});
|
||||||
|
|
||||||
|
}
|
||||||
|
<?= $this->endSection() ?>
|
||||||
|
<?php endif; ?>
|
||||||
|
|
||||||
<!------------------------------------------->
|
<!------------------------------------------->
|
||||||
<!-- Variables generales usadas en los ficheros js -->
|
<!-- Variables generales usadas en los ficheros js -->
|
||||||
|
|||||||
6742
xdebug.log
6742
xdebug.log
File diff suppressed because one or more lines are too long
Reference in New Issue
Block a user