mirror of
https://git.imnavajas.es/jjimenez/safekat.git
synced 2025-07-25 22:52:08 +00:00
32 lines
791 B
PHP
Executable File
32 lines
791 B
PHP
Executable File
<?php
|
|
namespace App\Entities\Configuracion;
|
|
|
|
use CodeIgniter\Entity;
|
|
|
|
class Imposicion extends \CodeIgniter\Entity\Entity
|
|
{
|
|
protected $attributes = [
|
|
"id" => null,
|
|
"ancho" => null,
|
|
"alto" => null,
|
|
"unidades" => null,
|
|
"orientacion" => null,
|
|
"maquina" => null,
|
|
"etiqueta" => null,
|
|
];
|
|
protected $casts = [
|
|
"ancho" => "int",
|
|
"alto" => "int",
|
|
"unidades" => "?int",
|
|
];
|
|
|
|
public function getFullName() : string
|
|
{
|
|
$ancho_x_alto = $this->attributes["ancho"] ."x". $this->attributes["alto"];
|
|
$unidades = $this->attributes["unidades"] ?? "";
|
|
$orientacion = $this->attributes["orientacion"] ?? "";
|
|
return implode("_",[$ancho_x_alto,$unidades,$orientacion]);
|
|
|
|
}
|
|
}
|