Arreglado preview grapado

This commit is contained in:
imnavajas
2024-04-09 14:00:42 +02:00
parent 71a8f9e135
commit 1086d5f9c1
2 changed files with 9 additions and 6 deletions

View File

@ -1749,8 +1749,8 @@ class PresupuestoService extends BaseService
$linea = PresupuestoService::getLineaPresupuestoPlana($data);
if ($tipo_impresion_id == 5 || $tipo_impresion_id == 6 ||
$tipo_impresion_id == 7 || $tipo_impresion_id == 8 || $tipo_impresion_id == 21) {
$tipo_impresion_id == 7 || $tipo_impresion_id == 8) {
if ($uso == 'cubierta'){
$linea['fields']['num_formas']['num_formas_horizontales'] *= 2;
$linea['fields']['num_formas']['value'] *= 2;

View File

@ -1,5 +1,4 @@
// Global parameters
//var _isCosido = true;
var pvObj;
function previewInteriorPlana(lpTagName, isCosido, isTapaDura) {
@ -987,6 +986,12 @@ function getObjetoLP(lpName, _isCosido, _isTapaDura) {
pvObj.anchoForma = ((2 * pvObj.anchoLibro) + (2 * (pvObj.anchoSolapa + offsetSolapaValor)) + (2 * sangre) + pvObj.lomoLibro);
pvObj.altoForma += (2 * sangre);
}
// Grapado
else if (pvObj.tipoImpresion === 21) {
let sangre = parseFloat(5); // mm
pvObj.anchoForma = ((2 * pvObj.anchoLibro) + (2 * (pvObj.anchoSolapa + offsetSolapaValor)) + (2 * sangre));
pvObj.altoForma += (2 * sangre);
}
// Espiral TD y TB, Wire-o TD y TB
else if (pvObj.tipoImpresion === 5 || pvObj.tipoImpresion === 6 ||
pvObj.tipoImpresion === 7 || pvObj.tipoImpresion === 8) {
@ -1103,6 +1108,4 @@ function getVisibleTabs() {
}
}
});
}
}