fix title size

This commit is contained in:
amazuecos
2025-05-22 18:32:48 +02:00
parent 690eaf4195
commit b775f65b3a
6 changed files with 47 additions and 42 deletions

View File

@ -707,7 +707,7 @@ class Ordentrabajo extends BaseController
$r = $this->produccionService->storeOrdenTrabajoTareaProgressDate($validatedData);
$otTareaEntity = $this->otTarea->find($validatedData['ot_tarea_id']);
$data = [
"tiempo_trabajado" => float_seconds_to_hhmm_string($otTareaEntity->tiempo_real),
"tiempo_trabajado" => float_seconds_to_hhmmss_string($otTareaEntity->tiempo_real),
"tarea" => $otTareaEntity,
"estado" => $validatedData['estado'],
];
@ -728,7 +728,7 @@ class Ordentrabajo extends BaseController
{
$otTareaEntity = $this->otTarea->find($orden_trabajo_tarea_id);
$data = [
"tiempo_trabajado" => float_seconds_to_hhmm_string($otTareaEntity->tiempo_trabajado()),
"tiempo_trabajado" => float_seconds_to_hhmmss_string($otTareaEntity->tiempo_trabajado()),
"progress_dates" => $otTareaEntity->progress_dates(),
];
return $this->response->setJSON($data);

View File

@ -248,6 +248,10 @@ class PresupuestoLineaEntity extends \CodeIgniter\Entity\Entity
return in_array($this->attributes['tipo'], ["lp_bn", "lp_bnhq", "lp_rot_bn"]);
}
public function isImpresionInteriorPlana():bool
{
return in_array($this->attributes['tipo'], ["lp_bn", "lp_bnhq", "lp_colorhq","lp_color"]);
}
public function tinta(): string
{
$tinta = "";

View File

@ -424,7 +424,7 @@ class ProductionService extends BaseService
*/
protected function storeTareaCorteFinal(): ?OrdenTrabajoTareaEntity
{
$presupuestoLineaImpresion = $this->presupuesto->presupuestoLineaImpresion();
$data = [
'orden_trabajo_id' => $this->ot->id,
@ -451,26 +451,33 @@ class ProductionService extends BaseService
protected function storeTareaCorte(PresupuestoLineaEntity $pLinea): ?OrdenTrabajoTareaEntity
{
$otCorte = null;
$presupuestoTipo = $this->presupuesto->tipo_presupuesto()->codigo;
$isRusticaFresado = str_contains($presupuestoTipo, "Fresado");
$data = [
'orden_trabajo_id' => $this->ot->id,
'presupuesto_linea_id' => $pLinea->id,
'nombre' => 'Corte',
'maquina_id' => $this->guillotinaMaquinaId ?? 20,//!REMOVE LATER
'orden' => $pLinea->maquina()->orden_planning + 1,
'maquina_id' => $this->guillotinaMaquinaId,
'orden' => $pLinea->maquina()->orden_planning + 1,
'tiempo_estimado' => $pLinea->rotativa_tiempo_corte * 60,
'tiempo_real' => 0,
'is_corte' => true,
'tipo_corte' => "guillotina",
'tipo_corte' => "prep",
];
if ($pLinea->isCubierta()) {
$data['nombre'] = lang('Produccion.cover_cut');
$tareaId = $this->otTarea->insert($data);
$otCorte = $this->otTarea->find($tareaId);
}
if($pLinea->isRotativa() ||$pLinea->isColor()||$pLinea->isBN())
{
if ($pLinea->isImpresionInteriorPlana() || $pLinea->isRotativa()) {
$data['nombre'] = lang('Produccion.interior_cut');
//* Si es rustica fresado y rotativa no se añade preparación de interior en guillotina
if (!$isRusticaFresado && !$pLinea->isRotativa()) {
$tareaId = $this->otTarea->insert($data);
$otCorte = $this->otTarea->find($tareaId);
return $otCorte;
}
}
$tareaId = $this->otTarea->insert($data);
$otCorte = $this->otTarea->find($tareaId);
return $otCorte;
}
@ -492,7 +499,7 @@ class ProductionService extends BaseService
'presupuesto_linea_id' => $pLinea->id,
'nombre' => $name,
'maquina_id' => $this->defaultMaquinaCorte->id,
'orden' => $pLinea->maquina()->orden_planning + 1,
'orden' => $pLinea->maquina()->orden_planning + 1,
'tiempo_estimado' => $pLinea->rotativa_tiempo_corte * 60,
'tiempo_real' => 0,
'is_corte' => true,
@ -1393,7 +1400,7 @@ class ProductionService extends BaseService
public function tareaUpdateMaquinaCorte($orden_trabajo_id): bool
{
$cvm = model(ConfigVariableModel::class);
$otTarea = $this->otTarea->where('orden_trabajo_id', $orden_trabajo_id)->where('is_corte', true)->first();
$otTarea = $this->otTarea->where('orden_trabajo_id', $orden_trabajo_id)->where('is_corte', true)->whereIn('tipo_corte', ['bobina', 'guillotina'])->first();
$toggleCorte = "bobina";
if ($otTarea->tipo_corte == "bobina") {
$maquina_id = $cvm->where('name', "id_maquina_guillotina_corte_ot_tarea")->first()["value"];

View File

@ -76,10 +76,8 @@ $settings = $session->get('settings');
</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 class="row text-center">
<span id="fecha_encuadernado_at" class="fs-large 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 class="row px-2 mt-2 h-100">
<table class="h-100 bg-white" style="font-size: small;">
@ -210,25 +208,25 @@ $settings = $session->get('settings');
</div>
<div class="col-12">
<div>
<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>
<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>
</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>

View File

@ -77,10 +77,8 @@ $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 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 class="row text-center">
<span id="fecha_encuadernado_at" class="fs-large 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 class="row px-2 mt-2 h-100">
<table class="h-100 bg-white" style="font-size: small;">

View File

@ -76,10 +76,8 @@ $settings = $session->get('settings');
</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 class="row text-center">
<span id="fecha_encuadernado_at" class="fs-large 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 class="row px-2 mt-2 h-100">
<table class="h-100 bg-white" style="font-size: small;">