fix pdf font sizes and updated info

This commit is contained in:
amazuecos
2025-05-19 20:47:19 +02:00
parent f5a015bc6d
commit 2ef98a9496
6 changed files with 241 additions and 182 deletions

View File

@ -1,9 +1,7 @@
<table>
<tr class="encuadernacion">
<th >Encuadernacion</th>
<th class="cell-50"></th>
<th class="cell-50"></th>
<th class="cell-50"></th>
<th class="cell-50">Sobrecubierta</th>
<th class="cell-50">Guardas</th>
<th class="cell-50">Retractilado</th>
@ -12,9 +10,7 @@
<?php if (count($encuadernaciones) > 0): ?>
<tr style="color: red;">
<td><?= $encuadernacion->tarifa()->nombre ?></td>
<td></td>
<td></td>
<td></td>
<td><?= $presupuesto->hasSobrecubierta() ? "SI" : "NO" ?></td>
<td><?= $presupuesto->guardas ? "SI" : "NO" ?></td>
<td><?= $presupuesto->retractilado ? "SI" : "NO" ?></td>

View File

@ -56,13 +56,13 @@ $settings = $session->get('settings');
<div class="row">
<div class="col-8">
<div class="px-2 d-flex flex justify-content-between align-items-center" style="background-color: <?= $colors["week_day"]["bg"] ?>;color:<?= $colors["week_day"]["color"] ?>;">
<span><strong><?= $pedido->fecha_encuadernado ? week_day_humanize(Time::createFromFormat("Y-m-d H:i:s", $pedido->fecha_encuadernado)->getDayOfWeek() - 1, true) : "" ?></strong></span>
<span><strong>Comercial:</strong> <?= $cliente->first_name . " " . $cliente->comercial()->last_name ?> </span>
<span><?= $pedido->fecha_encuadernado ? week_day_humanize(Time::createFromFormat("Y-m-d H:i:s", $pedido->fecha_encuadernado)->getDayOfWeek() - 1, true) : "" ?></span>
<span>Comercial: <?= $cliente->first_name . " " . $cliente->comercial()->last_name ?> </span>
</div>
</div>
<div class="col-4">
<div class="px-2 d-flex flex justify-content-center align-items-center w-100">
<span class="w-100 text-center" style="background-color: <?= $colors["impresion_interior_ppal"]["bg"] ?>;color:<?= $colors["impresion_interior_ppal"]["color"] ?>;">
<span class="w-100 text-center code-title" style="background-color: <?= $colors["impresion_interior_ppal"]["bg"] ?>;color:<?= $colors["impresion_interior_ppal"]["color"] ?>;">
<?php if ($isPOD): ?>
<strong>POD</strong>
<?php elseif ($presupuesto->presupuestoLineaImpresion()->isRotativa()): ?>
@ -70,18 +70,19 @@ $settings = $session->get('settings');
<?php else: ?>
<strong>GENERAL</strong>
<?php endif; ?>
</span>
</div>
</div>
</div>
<div class="row p-2">
<div class="col-3 h-100">
<div class="row px-2 d-flex flex justify-content-between align-items-center">
<div class="col-6 w-100 text-center code-title">
<span id="fecha_encuadernado_at" class="code-title fw-bold" style="color:<?= $colors["general"]["color"] ?>;"><?= $pedido->fecha_encuadernado ? Time::createFromFormat("Y-m-d H:i:s", $pedido->fecha_encuadernado)->format('d/m/Y') : "" ?></span>
</div>
</div>
<div class="row px-2 mt-2 h-100">
<table class="h-100 bg-white">
<table class="h-100 bg-white" style="font-size: small;">
<tr>
<th class="bg-white">IN</th>
<td class="t-cell bg-white"><?= $ubicacion ?></td>
@ -103,26 +104,27 @@ $settings = $session->get('settings');
<td class="t-cell bg-white"><?= $ubicacion ?></td>
</tr>
</table>
</div>
</div>
<div class="col-5">
<div class="col-5 h-100">
<div class="row">
<div class="col-12 w-50 text-center" style="background-color: <?= $colors["ot"]["bg"] ?>;color:<?= $colors["ot"]["color"] ?>;">
<strong><?= $encuadernacionCode ?></strong>
<div class="col-12 w-50 text-center code-title fw-bold" style="background-color: <?= $colors["ot"]["bg"] ?>;color:<?= $colors["ot"]["color"] ?>;">
<?= $encuadernacionCode ?>
</div>
</div>
<div class="row h-75">
<div class="col-6 square text-center" style="background-color: <?= $colors["papel_interior"]["bg"] ?>;color:<?= $colors["papel_interior"]["color"] ?>;">
<div class="col-6 square text-center code-title" style="background-color: <?= $colors["papel_interior"]["bg"] ?>;color:<?= $colors["papel_interior"]["color"] ?>;">
<?= $linea_impresion?->papel_impresion()->papel_code_ot ?>
</div>
<div class="col-6 square text-center <?= $linea_impresion->isColor() ? "cmyk" : "bn" ?>">
<div class="col-6 square text-center code-title <?= $linea_impresion->isColor() ? "cmyk" : "bn" ?>">
<?= $tiempo_impresion ?>
</div>
<div class="col-6 square text-center" style="background-color: <?= $colors["papel_cubierta"]["bg"] ?>;color:<?= $colors["papel_cubierta"]["color"] ?>;">
<div class="col-6 square text-center code-title" style="background-color: <?= $colors["papel_cubierta"]["bg"] ?>;color:<?= $colors["papel_cubierta"]["color"] ?>;">
<?= $linea_cubierta?->papel_impresion()->papel_code_ot ?>
</div>
<div class="col-6 square text-center" style="background-color: <?= $colors["plastificado"]["bg"] ?>;color:<?= $colors["plastificado"]["color"] ?>;">
<div class="col-6 square text-center code-title" style="background-color: <?= $colors["plastificado"]["bg"] ?>;color:<?= $colors["plastificado"]["color"] ?>;">
<?= isset($acabados[0]) ? $acabados[0]->tarifa()->code : "" ?>
</div>
<?php foreach ($acabados as $key => $acabado): ?>
@ -137,7 +139,7 @@ $settings = $session->get('settings');
<div class="col-4" style="background-color: <?= $colors["ot"]["bg"] ?>">
<div class="row h-100">
<div class="col-12 h-50 d-flex flex align-items-center justify-content-center">
<span class="fs-large" style="color:<?= $colors["ot"]["color"] ?>;"><strong><?= $ot->id ?></strong></span>
<span class="ot-code" style="color:<?= $colors["ot"]["color"] ?>;"><?= $ot->id ?></span>
</div>
<div class="col-12 h-50 d-flex flex align-items-center justify-content-center bg-white">
<img class="img-fluid" src="data:image/png;base64,<?= $ot->bar_code ?>" alt="barcode" />
@ -151,32 +153,30 @@ $settings = $session->get('settings');
</div>
<div class="row">
<div class="col-8">
<table class="h-50">
<table class="h-100">
<tr>
<th>IDSK</th>
<td class="t-cell">
</td>
<th class="al">IDSK</th>
<td class="t-cell"></td>
</tr>
<tr>
<th>CLIENTE</th>
<th class="al">CLIENTE</th>
<td class="t-cell">
<?= $cliente->alias ?>
</td>
</tr>
<tr>
<th>TITULO</th>
<th class="al">TITULO</th>
<td class="t-cell">
<?= $presupuesto->titulo ?>
</td>
</tr>
<tr>
<th>ISBN</th>
<th class="al">ISBN</th>
<td class="t-cell"><?= $presupuesto->isbn ?></td>
</tr>
<tr>
<th>PEDIDO CLIENTE</th>
<th class="al">PEDIDO</th>
<td class="t-cell"><?= $pedido->id ?></td>
</tr>
</table>
@ -184,12 +184,10 @@ $settings = $session->get('settings');
<div class="col-4">
<div class="col-12 d-flex justify-content-center" style="width: 100%">
<?php if ($imposicion): ?>
<?php if ($imposicion->imposicion_esquema()): ?>
<?= $imposicion->imposicion_esquema()->svg_schema ?>
<?php endif; ?>
<?php endif; ?>
</div>
<div class="col-12">
<div class="imposicion">
@ -204,21 +202,33 @@ $settings = $session->get('settings');
</div>
</div>
<div class="row mb-2">
<div class="section-title impresion">IMP. INTERIOR</div>
<div class="d-flex flex-row gap-2 justify-content-start">
<div class="section-title impresion">IMP. INTERIOR</div>
<?php if ($pedido->fecha_impresion): ?>
<div class="section-title "><?= Time::createFromFormat("Y-m-d H:i:s", $pedido->fecha_impresion)->format('d/m/Y') ?></div>
<?php endif; ?>
</div>
<div class="col-12">
<div>
<table>
<tr>
<th class="t-header" style="width: 10%;"><?= lang('Produccion.size') ?></th>
<td class="t-cell text-center"> <?= $papel_formato->ancho ?>x<?= $papel_formato->alto ?> </td>
<th class="t-header" style="width: 10%;"><?= lang('Produccion.ejemplares') ?></th>
<td class="t-cell text-center"> 1 </td>
<th class="t-header" style="width: 10%;"><?= lang('Produccion.tipo') ?></th>
<td class="t-cell text-center"> <?= $presupuesto->tipo_presupuesto()?->codigo ?? "" ?> </td>
<th class="t-header" style="width: 10%;"><?= lang('Produccion.lomo') ?></th>
<td class="t-cell text-center"> <?= number_format($presupuesto->lomo_cubierta, 2, ',', '.') ?> </td>
</tr>
</table>
<table class="">
<tr>
<th class="t-header"><?= lang('Produccion.size') ?></th>
<th class="t-header"><?= lang('Produccion.ejemplares') ?></th>
<th class="t-header"><?= lang('Produccion.tipo') ?></th>
<th class="t-header"><?= lang('Produccion.lomo') ?></th>
</tr>
<tr>
<?php if ($presupuesto->papel_formato_personalizado): ?>
<td class="t-cell text-center"> <?= $presupuesto->papel_formato_ancho ?>x<?= $presupuesto->papel_formato_alto ?> </td>
<?php else: ?>
<td class="t-cell text-center"> <?= $papel_formato->ancho ?>x<?= $papel_formato->alto ?> </td>
<?php endif; ?>
<td class="t-cell text-center"> 1 </td>
<td class="t-cell text-center"> <?= $presupuesto->tipo_presupuesto()?->codigo ?? "" ?> </td>
<td class="t-cell text-center"> <?= number_format($presupuesto->lomo_cubierta, 2, ',', '.') ?> </td>
</tr>
</table>
<table>
<tr>
<td rowspan="3" class="row-logo-impresion"><img src="<?= site_url($linea_impresion->get_impresion_logo()) ?>" width="35px" height="35px"></td>
@ -251,7 +261,7 @@ $settings = $session->get('settings');
</tr>
</table>
</div>
<div class="comments <?=$ot->comment_interior ? '' : 'd-none' ?>">
<div class="comments <?= $ot->comment_interior ? '' : 'd-none' ?>">
<div class="flex-row impresion">Comentarios impresión interior</div>
<div class="comment-content w-100">
<p>
@ -262,7 +272,12 @@ $settings = $session->get('settings');
</div>
</div>
<div class="row mb-2">
<div class="section-title">LOGISTICA</div>
<div class="d-flex flex-row justify-content-start w-100 gap-2">
<div class="section-title">LOGISTICA</div>
<?php if ($pedido->fecha_entrega_real): ?>
<div class="section-title "><?= Time::createFromFormat("Y-m-d H:i:s", $pedido->fecha_entrega_real)->format('d/m/Y') ?></div>
<?php endif; ?>
</div>
<div class="col-12">
<table>
<tr>
@ -276,7 +291,7 @@ $settings = $session->get('settings');
<td>-</td>
</tr>
</table>
<div class="comments <?=$ot->comment_logistica ? '' : 'd-none' ?>">
<div class="comments <?= $ot->comment_logistica ? '' : 'd-none' ?>">
<div class="flex-row">Comentarios logistica:</div>
<div class="comment-content">
<p>

View File

@ -48,21 +48,19 @@ $settings = $session->get('settings');
<img class="portada-img border-secondary img-thumbnail img-fluid" src="<?= $ot->full_path ? "data:image/png;base64," . base64_encode(file_get_contents($ot->full_path)) : '/assets/img/portada_not_found.png' ?>" />
<?php else: ?>
<img class="portada-img border-secondary img-thumbnail img-fluid" src="/assets/img/portada_not_found.png" />
<?php endif; ?>
</div>
<div class="col-10 py-2 rounded border-1 border-secondary" style="background-color: <?= $colors["general"]["bg"] ?>;color:<?= $colors["general"]["color"] ?>;">
<div class="row">
<div class="col-8">
<div class="px-2 d-flex flex justify-content-between align-items-center" style="background-color: <?= $colors["week_day"]["bg"] ?>;color:<?= $colors["week_day"]["color"] ?>;">
<span><strong><?= $pedido->fecha_encuadernado ? week_day_humanize(Time::createFromFormat("Y-m-d H:i:s", $pedido->fecha_encuadernado)->getDayOfWeek() - 1, true) : "" ?></strong></span>
<span><strong>Comercial:</strong> <?= $cliente->first_name . " " . $cliente->comercial()->last_name ?> </span>
<span class="fs-large"><?= $pedido->fecha_encuadernado ? week_day_humanize(Time::createFromFormat("Y-m-d H:i:s", $pedido->fecha_encuadernado)->getDayOfWeek() - 1, true) : "" ?></span>
<span class="fs-large">Comercial: <?= $cliente->first_name . " " . $cliente->comercial()->last_name ?> </span>
</div>
</div>
<div class="col-4">
<div class="px-2 d-flex flex justify-content-center align-items-center w-100">
<span class="w-100 text-center" style="background-color: <?= $colors["impresion_interior_ppal"]["bg"] ?>;color:<?= $colors["impresion_interior_ppal"]["color"] ?>;">
<span class="w-100 text-center code-title" style="background-color: <?= $colors["impresion_interior_ppal"]["bg"] ?>;color:<?= $colors["impresion_interior_ppal"]["color"] ?>;">
<?php if ($isPOD): ?>
<strong>POD</strong>
<?php elseif ($presupuesto->presupuestoLineaImpresion()->isRotativa()): ?>
@ -80,12 +78,12 @@ $settings = $session->get('settings');
<div class="row p-2">
<div class="col-3 h-100">
<div class="row px-2 d-flex flex justify-content-between align-items-center">
<div class="col-6 w-100 text-center">
<span id="fecha_encuadernado_at" style="color:<?= $colors["general"]["color"] ?>;"><strong><?= $pedido->fecha_encuadernado ? Time::createFromFormat("Y-m-d H:i:s", $pedido->fecha_encuadernado)->format('d/m/Y') : "" ?></strong></span>
<div class="col-6 w-100 text-center code-title">
<span id="fecha_encuadernado_at" class="code-title fw-bold" style="color:<?= $colors["general"]["color"] ?>;"><?= $pedido->fecha_encuadernado ? Time::createFromFormat("Y-m-d H:i:s", $pedido->fecha_encuadernado)->format('d/m/Y') : "" ?></span>
</div>
</div>
<div class="row px-2 mt-2 h-100">
<table class="h-100 bg-white">
<table class="h-100 bg-white" style="font-size: small;">
<tr>
<th class="bg-white">IN</th>
<td class="t-cell bg-white"><?= $ubicacion ?></td>
@ -110,23 +108,23 @@ $settings = $session->get('settings');
</div>
</div>
<div class="col-5">
<div class="col-5 h-100">
<div class="row">
<div class="col-12 w-50 text-center" style="background-color: <?= $colors["ot"]["bg"] ?>;color:<?= $colors["ot"]["color"] ?>;">
<strong><?= $encuadernacionCode ?></strong>
<div class="col-12 w-50 text-center code-title fw-bold" style="background-color: <?= $colors["ot"]["bg"] ?>;color:<?= $colors["ot"]["color"] ?>;">
<?= $encuadernacionCode ?>
</div>
</div>
<div class="row h-75">
<div class="col-6 square text-center" style="background-color: <?= $colors["papel_interior"]["bg"] ?>;color:<?= $colors["papel_interior"]["color"] ?>;">
<div class="row h-100">
<div class="col-6 square text-center code-title" style="background-color: <?= $colors["papel_interior"]["bg"] ?>;color:<?= $colors["papel_interior"]["color"] ?>;">
<?= $linea_impresion?->papel_impresion()->papel_code_ot ?>
</div>
<div class="col-6 square text-center <?= $linea_impresion->isColor() ? "cmyk" : "bn" ?>">
<div class="col-6 square text-center code-title <?= $linea_impresion->isColor() ? "cmyk" : "bn" ?>">
<?= $tiempo_impresion ?>
</div>
<div class="col-6 square text-center" style="background-color: <?= $colors["papel_cubierta"]["bg"] ?>;color:<?= $colors["papel_cubierta"]["color"] ?>;">
<div class="col-6 square text-center code-title" style="background-color: <?= $colors["papel_cubierta"]["bg"] ?>;color:<?= $colors["papel_cubierta"]["color"] ?>;">
<?= $linea_cubierta?->papel_impresion()->papel_code_ot ?>
</div>
<div class="col-6 square text-center" style="background-color: <?= $colors["plastificado"]["bg"] ?>;color:<?= $colors["plastificado"]["color"] ?>;">
<div class="col-6 square text-center code-title" style="background-color: <?= $colors["plastificado"]["bg"] ?>;color:<?= $colors["plastificado"]["color"] ?>;">
<?= isset($acabados[0]) ? $acabados[0]->tarifa()->code : "" ?>
</div>
<?php foreach ($acabados as $key => $acabado): ?>
@ -141,7 +139,7 @@ $settings = $session->get('settings');
<div class="col-4" style="background-color: <?= $colors["ot"]["bg"] ?>">
<div class="row h-100">
<div class="col-12 h-50 d-flex flex align-items-center justify-content-center">
<span class="fs-large" style="color:<?= $colors["ot"]["color"] ?>;"><strong><?= $ot->id ?></strong></span>
<span class="ot-code" style="color:<?= $colors["ot"]["color"] ?>;"><?= $ot->id ?></span>
</div>
<div class="col-12 h-50 d-flex flex align-items-center justify-content-center bg-white">
<img class="img-fluid" src="data:image/png;base64,<?= $ot->bar_code ?>" alt="barcode" />
@ -155,32 +153,32 @@ $settings = $session->get('settings');
</div>
<div class="row">
<div class="col-8">
<table class="h-50">
<table class="h-100">
<tr>
<th>IDSK</th>
<td class="t-cell">
<th class="al">IDSK</th>
<td class="t-cell w-75">
</td>
</tr>
<tr>
<th>CLIENTE</th>
<th class="al">CLIENTE</th>
<td class="t-cell">
<?= $cliente->alias ?>
</td>
</tr>
<tr>
<th>TITULO</th>
<th class="al">TITULO</th>
<td class="t-cell">
<?= $presupuesto->titulo ?>
</td>
</tr>
<tr>
<th>ISBN</th>
<th class="al">ISBN</th>
<td class="t-cell"><?= $presupuesto->isbn ?></td>
</tr>
<tr>
<th>PEDIDO CLIENTE</th>
<th class="al">PEDIDO</th>
<td class="t-cell"><?= $pedido->id ?></td>
</tr>
</table>
@ -188,7 +186,6 @@ $settings = $session->get('settings');
<div class="col-4">
<div class="col-12 d-flex justify-content-center" style="width: 100%">
<?php if ($imposicion): ?>
<?php if ($imposicion->imposicion_esquema()): ?>
<?= $imposicion->imposicion_esquema()->svg_schema ?>
<?php endif; ?>
@ -208,19 +205,31 @@ $settings = $session->get('settings');
</div>
</div>
<div class="row mb-2">
<div class="section-title impresion">IMP. INTERIOR</div>
<div class="d-flex flex-row gap-2 justify-content-start">
<div class="section-title impresion">IMP. INTERIOR</div>
<?php if ($pedido->fecha_impresion): ?>
<div class="section-title "><?= Time::createFromFormat("Y-m-d H:i:s", $pedido->fecha_impresion)->format('d/m/Y') ?></div>
<?php endif; ?>
</div>
<div class="col-12">
<div>
<table>
<table class="">
<tr>
<th class="t-header" style="width: 10%;"><?= lang('Produccion.size') ?></th>
<td class="t-cell text-center"> <?= $papel_formato->ancho ?>x<?= $papel_formato->alto ?> </td>
<th class="t-header" style="width: 10%;"><?= lang('Produccion.ejemplares') ?></th>
<th class="t-header"><?= lang('Produccion.size') ?></th>
<th class="t-header"><?= lang('Produccion.ejemplares') ?></th>
<th class="t-header"><?= lang('Produccion.tipo') ?></th>
<th class="t-header"><?= lang('Produccion.lomo') ?></th>
</tr>
<tr>
<?php if ($presupuesto->papel_formato_personalizado): ?>
<td class="t-cell text-center"> <?= $presupuesto->papel_formato_ancho ?>x<?= $presupuesto->papel_formato_alto ?> </td>
<?php else: ?>
<td class="t-cell text-center"> <?= $papel_formato->ancho ?>x<?= $papel_formato->alto ?> </td>
<?php endif; ?>
<td class="t-cell text-center"> <?= $presupuesto->tirada ?> + <?= $presupuesto->merma ?> </td>
<th class="t-header" style="width: 10%;"><?= lang('Produccion.tipo') ?></th>
<td class="t-cell text-center"> <?= $presupuesto->tipo_presupuesto()?->codigo ?? "" ?> </td>
<th class="t-header" style="width: 10%;"><?= lang('Produccion.lomo') ?></th>
<td class="t-cell text-center"> <?= number_format($presupuesto->lomo_cubierta, 2, ',', '.') ?> </td>
</tr>
</table>
<table>
@ -235,12 +244,12 @@ $settings = $session->get('settings');
<th>Tiempo</th>
</tr>
<tr>
<td><?= $presupuesto->paginas ?></td> <!-- Páginas libro -->
<td><?= $presupuesto->tirada ?> </td>
<td><?= number_format($presupuesto->paginas, 0, ',', '.') ?></td> <!-- Páginas libro -->
<td><?= number_format($presupuesto->tirada, 0, ',', '.') ?> </td>
<td><?= $linea_impresion->tinta() ?></td>
<td><?= json_decode($linea_impresion->formas)->formas ?></td>
<td><strong><?= $linea_impresion->maquina()->nombre ?></strong></td>
<td><?= $linea_impresion->rotativa_clicks_total ?></td>
<td><?= number_format($linea_impresion->rotativa_clicks_total, 0, ',', '.') ?></td>
<td><?= float_seconds_to_hhmm_string($linea_impresion->horas_maquina * 3600) ?></td>
</tr>
<tr>
@ -255,8 +264,8 @@ $settings = $session->get('settings');
</tr>
</table>
</div>
<div class="comments <?=$ot->comment_interior ? '' : 'd-none' ?>">
<div class="flex-row impresion"><?= lang('Produccion.comentariosImpresionInterior') ?></div>
<div class="comments <?= $ot->comment_interior ? '' : 'd-none' ?>">
<div class="flex-row "><?= lang('Produccion.comentariosImpresionInterior') ?></div>
<div class=" w-100">
<p>
<?= $ot->comment_interior ?>
@ -270,7 +279,7 @@ $settings = $session->get('settings');
<div class="section-title cubierta">IMP. CUBIERTA</div>
<div class="col-12">
<table>
<table class="">
<tr>
<td rowspan="3" class="row-logo-impresion"><img src="<?= site_url($linea_cubierta->get_impresion_logo()) ?>" width="35px" height="35px"></td>
<th>Tintas</th>
@ -294,7 +303,7 @@ $settings = $session->get('settings');
</tr>
</table>
<div class="comments <?=$ot->comment_cubierta ? '' : 'd-none' ?>">
<div class="comments <?= $ot->comment_cubierta ? '' : 'd-none' ?>">
<div class="flex-row cubierta"><?= lang('Produccion.comentariosCubierta') ?></div>
<div class="">
@ -308,12 +317,19 @@ $settings = $session->get('settings');
</div>
<?php endif; ?>
<div class="row">
<div class="section-title encuadernacion">ACABADOS/ENCUADERNACIÓN</div>
<div class="d-flex flex-row justify-content-start w-100 gap-2">
<div class="section-title encuadernacion">ACABADOS/ENCUADERNACIÓN</div>
<?php if ($pedido->fecha_encuadernado): ?>
<div class="section-title "><?= Time::createFromFormat("Y-m-d H:i:s", $pedido->fecha_encuadernado)->format('d/m/Y') ?></div>
<?php endif; ?>
</div>
<div class="col-12">
<div class="col-1 w-10 mb-2 text-center" style="background-color: <?= $colors["ot"]["bg"] ?>;color:<?= $colors["ot"]["color"] ?>;">
<span class="fs-bold"><?= $encuadernacionCode ?></span>
<div class="row">
<div class="col-3 mb-2 text-center code-title fw-bold" style="background-color: <?= $colors["ot"]["bg"] ?>;color:<?= $colors["ot"]["color"] ?>;">
<?= $encuadernacionCode ?>
</div>
</div>
<table>
<table class="">
<?php foreach ($acabados as $key => $acabado): ?>
<tr>
<td class="w-10 encuadernacion">Plastificado</td>
@ -324,7 +340,7 @@ $settings = $session->get('settings');
<td class="bg-encuadernacion" style="width: 100px;"><?= $acabado->proveedor() ? $acabado->proveedor()->nombre : "" ?></td>
</tr>
<tr>
<td class="text-start" colspan="2"><?=$ot->info_solapa_guillotina?></td>
<td class="text-start" colspan="2"><?= $ot->info_solapa_guillotina ?></td>
<td></td>
<td></td>
<td class="t-header">CORTE PIE:</td>
@ -345,14 +361,15 @@ $settings = $session->get('settings');
}
} catch (\Throwable $th) {
$error_message = $th->getMessage();
echo "<span style='color:red'>No se ha podido renderizar la tabla de encuadernación</span>";
// echo view("/themes/vuexy/pdfs/encuadernados/default.php", ["encuadernacion" => $encuadernacion]);
// echo "<span style='color:red'>No se ha podido renderizar la tabla de encuadernación</span>";
// echo "<br><span style='color:red'>$error_message</span>";
}
}
?>
<?php if (count($encuadernaciones) > 0): ?>
<div class="comments <?=$ot->comment_encuadernacion ? '' : 'd-none' ?>" >
<div class="comments <?= $ot->comment_encuadernacion ? '' : 'd-none' ?>">
<div class="flex-row encuadernacion"><?= lang('Produccion.comentariosEncuadernacion') ?></div>
<div class="">
<p>
@ -366,23 +383,26 @@ $settings = $session->get('settings');
</div>
<div class="row mb-2">
<div class="section-title">LOGISTICA</div>
<div class="d-flex flex-row justify-content-start w-100 gap-2">
<div class="section-title">LOGISTICA</div>
<?php if ($pedido->fecha_entrega_real): ?>
<div class="section-title "><?= Time::createFromFormat("Y-m-d H:i:s", $pedido->fecha_entrega_real)->format('d/m/Y') ?></div>
<?php endif; ?>
</div>
<div class="col-12">
<table>
<table class="">
<tr>
<th>Peso Unidad</th>
<th>Peso Pedido</th>
<th>Cajas</th>
<th>Corte Pie</th>
</tr>
<tr>
<td><?= number_format($peso_unidad, 2, ',', '.') ?> gr</td>
<td><?= $peso_pedido > 1000 ? number_format($peso_pedido / 1000, 2, ',', '.') . " kg" : number_format($peso_pedido, 2, ',', '.') . " gr" ?> </td>
<td>-</td>
<td>-</td>
</tr>
</table>
<div class="comments <?=$ot->comment_logistica ? '' : 'd-none' ?>">
<div class="comments <?= $ot->comment_logistica ? '' : 'd-none' ?>">
<div class="flex-row logistica"><?= lang('Produccion.comentariosLogistica') ?></div>
<div class="">

View File

@ -56,13 +56,13 @@ $settings = $session->get('settings');
<div class="row">
<div class="col-8">
<div class="px-2 d-flex flex justify-content-between align-items-center" style="background-color: <?= $colors["week_day"]["bg"] ?>;color:<?= $colors["week_day"]["color"] ?>;">
<span><strong><?= $pedido->fecha_encuadernado ? week_day_humanize(Time::createFromFormat("Y-m-d H:i:s", $pedido->fecha_encuadernado)->getDayOfWeek() - 1, true) : "" ?></strong></span>
<span><strong>Comercial:</strong> <?= $cliente->first_name . " " . $cliente->comercial()->last_name ?> </span>
<span><?= $pedido->fecha_encuadernado ? week_day_humanize(Time::createFromFormat("Y-m-d H:i:s", $pedido->fecha_encuadernado)->getDayOfWeek() - 1, true) : "" ?></span>
<span>Comercial: <?= $cliente->first_name . " " . $cliente->comercial()->last_name ?> </span>
</div>
</div>
<div class="col-4">
<div class="px-2 d-flex flex justify-content-center align-items-center w-100">
<span class="w-100 text-center" style="background-color: <?= $colors["impresion_interior_ppal"]["bg"] ?>;color:<?= $colors["impresion_interior_ppal"]["color"] ?>;">
<span class="w-100 text-center code-title" style="background-color: <?= $colors["impresion_interior_ppal"]["bg"] ?>;color:<?= $colors["impresion_interior_ppal"]["color"] ?>;">
<?php if ($isPOD): ?>
<strong>POD</strong>
<?php elseif ($presupuesto->presupuestoLineaImpresion()->isRotativa()): ?>
@ -70,22 +70,19 @@ $settings = $session->get('settings');
<?php else: ?>
<strong>GENERAL</strong>
<?php endif; ?>
</span>
</div>
</div>
</div>
<div class="row p-2">
<div class="col-3 h-100">
<div class="row px-2 d-flex flex justify-content-between align-items-center">
<div class="col-6 w-100 text-center">
<span id="fecha_encuadernado_at" style="color:<?= $colors["general"]["color"] ?>;"><strong><?= $pedido->fecha_encuadernado ? Time::createFromFormat("Y-m-d H:i:s", $pedido->fecha_encuadernado)->format('d/m/Y') : "" ?></strong></span>
<div class="col-6 w-100 text-center code-title">
<span id="fecha_encuadernado_at" class="code-title fw-bold" style="color:<?= $colors["general"]["color"] ?>;"><?= $pedido->fecha_encuadernado ? Time::createFromFormat("Y-m-d H:i:s", $pedido->fecha_encuadernado)->format('d/m/Y') : "" ?></span>
</div>
</div>
<div class="row px-2 mt-2 h-100">
<table class="h-100 bg-white">
<table class="h-100 bg-white" style="font-size: small;">
<tr>
<th class="bg-white">IN</th>
<td class="t-cell bg-white"><?= $ubicacion ?></td>
@ -107,26 +104,27 @@ $settings = $session->get('settings');
<td class="t-cell bg-white"><?= $ubicacion ?></td>
</tr>
</table>
</div>
</div>
<div class="col-5">
<div class="col-5 h-100">
<div class="row">
<div class="col-12 w-50 text-center" style="background-color: <?= $colors["ot"]["bg"] ?>;color:<?= $colors["ot"]["color"] ?>;">
<strong><?= $encuadernacionCode ?></strong>
<div class="col-12 w-50 text-center code-title fw-bold" style="background-color: <?= $colors["ot"]["bg"] ?>;color:<?= $colors["ot"]["color"] ?>;">
<?= $encuadernacionCode ?>
</div>
</div>
<div class="row h-75">
<div class="col-6 square text-center" style="background-color: <?= $colors["papel_interior"]["bg"] ?>;color:<?= $colors["papel_interior"]["color"] ?>;">
<div class="col-6 square text-center code-title" style="background-color: <?= $colors["papel_interior"]["bg"] ?>;color:<?= $colors["papel_interior"]["color"] ?>;">
<?= $linea_impresion?->papel_impresion()->papel_code_ot ?>
</div>
<div class="col-6 square text-center <?= $linea_impresion->isColor() ? "cmyk" : "bn" ?>">
<div class="col-6 square text-center code-title <?= $linea_impresion->isColor() ? "cmyk" : "bn" ?>">
<?= $tiempo_impresion ?>
</div>
<div class="col-6 square text-center" style="background-color: <?= $colors["papel_cubierta"]["bg"] ?>;color:<?= $colors["papel_cubierta"]["color"] ?>;">
<div class="col-6 square text-center code-title" style="background-color: <?= $colors["papel_cubierta"]["bg"] ?>;color:<?= $colors["papel_cubierta"]["color"] ?>;">
<?= $linea_cubierta?->papel_impresion()->papel_code_ot ?>
</div>
<div class="col-6 square text-center" style="background-color: <?= $colors["plastificado"]["bg"] ?>;color:<?= $colors["plastificado"]["color"] ?>;">
<div class="col-6 square text-center code-title" style="background-color: <?= $colors["plastificado"]["bg"] ?>;color:<?= $colors["plastificado"]["color"] ?>;">
<?= isset($acabados[0]) ? $acabados[0]->tarifa()->code : "" ?>
</div>
<?php foreach ($acabados as $key => $acabado): ?>
@ -141,7 +139,7 @@ $settings = $session->get('settings');
<div class="col-4" style="background-color: <?= $colors["ot"]["bg"] ?>">
<div class="row h-100">
<div class="col-12 h-50 d-flex flex align-items-center justify-content-center">
<span class="fs-large" style="color:<?= $colors["ot"]["color"] ?>;"><strong><?= $ot->id ?></strong></span>
<span class="ot-code" style="color:<?= $colors["ot"]["color"] ?>;"><?= $ot->id ?></span>
</div>
<div class="col-12 h-50 d-flex flex align-items-center justify-content-center bg-white">
<img class="img-fluid" src="data:image/png;base64,<?= $ot->bar_code ?>" alt="barcode" />
@ -155,32 +153,30 @@ $settings = $session->get('settings');
</div>
<div class="row">
<div class="col-8">
<table class="h-50">
<table class="h-100">
<tr>
<th>IDSK</th>
<td class="t-cell">
</td>
<th class="al">IDSK</th>
<td class="t-cell"></td>
</tr>
<tr>
<th>CLIENTE</th>
<th class="al">CLIENTE</th>
<td class="t-cell">
<?= $cliente->alias ?>
</td>
</tr>
<tr>
<th>TITULO</th>
<th class="al">TITULO</th>
<td class="t-cell">
<?= $presupuesto->titulo ?>
</td>
</tr>
<tr>
<th>ISBN</th>
<th class="al">ISBN</th>
<td class="t-cell"><?= $presupuesto->isbn ?></td>
</tr>
<tr>
<th>PEDIDO CLIENTE</th>
<th class="al">PEDIDO</th>
<td class="t-cell"><?= $pedido->id ?></td>
</tr>
</table>
@ -188,12 +184,10 @@ $settings = $session->get('settings');
<div class="col-4">
<div class="col-12 d-flex justify-content-center" style="width: 100%">
<?php if ($imposicion): ?>
<?php if ($imposicion->imposicion_esquema()): ?>
<?= $imposicion->imposicion_esquema()->svg_schema ?>
<?php endif; ?>
<?php endif; ?>
</div>
<div class="col-12">
<div class="imposicion">
@ -208,19 +202,31 @@ $settings = $session->get('settings');
</div>
</div>
<div class="row mb-2">
<div class="section-title impresion">IMP. INTERIOR</div>
<div class="d-flex flex-row gap-2 justify-content-start">
<div class="section-title impresion">IMP. INTERIOR</div>
<?php if ($pedido->fecha_impresion): ?>
<div class="section-title "><?= Time::createFromFormat("Y-m-d H:i:s", $pedido->fecha_impresion)->format('d/m/Y') ?></div>
<?php endif; ?>
</div>
<div class="col-12">
<div>
<table>
<table class="">
<tr>
<th class="t-header" style="width: 10%;"><?= lang('Produccion.size') ?></th>
<td class="t-cell text-center"> <?= $papel_formato->ancho ?>x<?= $papel_formato->alto ?> </td>
<th class="t-header" style="width: 10%;"><?= lang('Produccion.ejemplares') ?></th>
<td class="t-cell text-center"> <?= $presupuesto->tirada/$presupuesto->tirada ?> </td>
<th class="t-header" style="width: 10%;"><?= lang('Produccion.tipo') ?></th>
<th class="t-header"><?= lang('Produccion.size') ?></th>
<th class="t-header"><?= lang('Produccion.ejemplares') ?></th>
<th class="t-header"><?= lang('Produccion.tipo') ?></th>
<th class="t-header"><?= lang('Produccion.lomo') ?></th>
</tr>
<tr>
<?php if ($presupuesto->papel_formato_personalizado): ?>
<td class="t-cell text-center"> <?= $presupuesto->papel_formato_ancho ?>x<?= $presupuesto->papel_formato_alto ?> </td>
<?php else: ?>
<td class="t-cell text-center"> <?= $papel_formato->ancho ?>x<?= $papel_formato->alto ?> </td>
<?php endif; ?>
<td class="t-cell text-center"> 1 </td>
<td class="t-cell text-center"> <?= $presupuesto->tipo_presupuesto()?->codigo ?? "" ?> </td>
<th class="t-header" style="width: 10%;"><?= lang('Produccion.lomo') ?></th>
<td class="t-cell text-center"> <?= number_format($presupuesto->lomo_cubierta, 2, ',', '.') ?> </td>
</tr>
</table>
<table>
@ -236,7 +242,7 @@ $settings = $session->get('settings');
</tr>
<tr>
<td><?= $presupuesto->paginas ?></td> <!-- Páginas libro -->
<td><?= $presupuesto->tirada / $presupuesto->tirada ?> </td>
<td> 1 </td>
<td><?= $linea_impresion->tinta() ?></td>
<td><?= json_decode($linea_impresion->formas)->formas ?></td>
<td><strong><?= $linea_impresion->maquina()->nombre ?></strong></td>
@ -255,8 +261,8 @@ $settings = $session->get('settings');
</tr>
</table>
</div>
<div class="comments <?=$ot->comment_interior ? '' : 'd-none' ?>">
<div class="flex-row impresion"><?= lang('Produccion.comentariosImpresionInterior') ?></div>
<div class="comments <?= $ot->comment_interior ? '' : 'd-none' ?>">
<div class="flex-row impresion">Comentarios impresión interior</div>
<div class="comment-content w-100">
<p>
<?= $ot->comment_interior ?>
@ -281,10 +287,10 @@ $settings = $session->get('settings');
</tr>
<tr>
<td><?= $linea_cubierta->tinta() ?></td>
<td><?= $presupuesto->tirada/$presupuesto->tirada ?></td>
<td><?= $presupuesto->tirada / $presupuesto->tirada ?></td>
<td><strong><?= $linea_cubierta->maquina()->nombre ?></strong></td>
<td><?= $presupuesto->marcapaginas ? "SI" : "NO" ?></td>
<td><?= float_seconds_to_hhmm_string($linea_cubierta->horas_maquina * 3600/$presupuesto->tirada) ?></td>
<td><?= float_seconds_to_hhmm_string($linea_cubierta->horas_maquina * 3600 / $presupuesto->tirada) ?></td>
</tr>
<tr>
<td colspan="1"><?= json_decode($linea_cubierta->formas)->maquina_ancho ?>x<?= json_decode($linea_cubierta->formas)->maquina_alto ?></td>
@ -294,7 +300,7 @@ $settings = $session->get('settings');
</tr>
</table>
<div class="comments <?=$ot->comment_cubierta ? '' : 'd-none' ?>">
<div class="comments <?= $ot->comment_cubierta ? '' : 'd-none' ?>">
<div class="flex-row cubierta"><?= lang('Produccion.comentariosCubierta') ?></div>
<div class="comment-content">
@ -308,10 +314,17 @@ $settings = $session->get('settings');
</div>
<?php endif; ?>
<div class="row mb-2">
<div class="section-title encuadernacion">ACABADOS/ENCUADERNACIÓN</div>
<div class="d-flex flex-row justify-content-start w-100 gap-2">
<div class="section-title encuadernacion">ACABADOS/ENCUADERNACIÓN</div>
<?php if ($pedido->fecha_encuadernado): ?>
<div class="section-title "><?= Time::createFromFormat("Y-m-d H:i:s", $pedido->fecha_encuadernado)->format('d/m/Y') ?></div>
<?php endif; ?>
</div>
<div class="col-12">
<div class="col-1 w-10 mb-2 text-center" style="background-color: <?= $colors["ot"]["bg"] ?>;color:<?= $colors["ot"]["color"] ?>;">
<span class="fs-bold"><?= $encuadernacionCode ?></span>
<div class="row">
<div class="col-3 mb-2 text-center code-title fw-bold" style="background-color: <?= $colors["ot"]["bg"] ?>;color:<?= $colors["ot"]["color"] ?>;">
<?= $encuadernacionCode ?>
</div>
</div>
<table>
<?php foreach ($acabados as $key => $acabado): ?>
@ -324,7 +337,7 @@ $settings = $session->get('settings');
<td class="bg-encuadernacion" style="width: 100px;"><?= $acabado->proveedor() ? $acabado->proveedor()->nombre : "" ?></td>
</tr>
<tr>
<td class="text-start" colspan="2"><?=$ot->info_solapa_guillotina?></td>
<td class="text-start" colspan="2"><?= $ot->info_solapa_guillotina ?></td>
<td></td>
<td></td>
<td class="t-header">CORTE PIE:</td>
@ -345,14 +358,15 @@ $settings = $session->get('settings');
}
} catch (\Throwable $th) {
$error_message = $th->getMessage();
echo "<span style='color:red'>No se ha podido renderizar la tabla de encuadernación</span>";
// echo view("/themes/vuexy/pdfs/encuadernados/default.php", ["encuadernacion" => $encuadernacion]);
// echo "<span style='color:red'>No se ha podido renderizar la tabla de encuadernación</span>";
// echo "<br><span style='color:red'>$error_message</span>";
}
}
?>
<?php if (count($encuadernaciones) > 0): ?>
<div class="comments <?=$ot->comment_encuadernacion ? '' : 'd-none' ?>">
<div class="comments <?= $ot->comment_encuadernacion ? '' : 'd-none' ?>">
<div class="flex-row encuadernacion"><?= lang('Produccion.comentariosEncuadernacion') ?></div>
<div class="comment-content">
<p>
@ -366,7 +380,12 @@ $settings = $session->get('settings');
</div>
<div class="row mb-2">
<div class="section-title">LOGISTICA</div>
<div class="d-flex flex-row justify-content-start w-100 gap-2">
<div class="section-title">LOGISTICA</div>
<?php if ($pedido->fecha_entrega_real): ?>
<div class="section-title "><?= Time::createFromFormat("Y-m-d H:i:s", $pedido->fecha_entrega_real)->format('d/m/Y') ?></div>
<?php endif; ?>
</div>
<div class="col-12">
<table>
<tr>
@ -380,9 +399,8 @@ $settings = $session->get('settings');
<td>-</td>
</tr>
</table>
<div class="comments">
<div class="flex-row logistica"><?= lang('Produccion.comentariosLogistica') ?></div>
<div class="comments <?= $ot->comment_logistica ? '' : 'd-none' ?>">
<div class="flex-row">Comentarios logistica:</div>
<div class="comment-content">
<p>
<?= $ot->comment_logistica ?>