Added clientOutput partition field

pull/8/head
Manuel Aranda Rosales 2024-08-05 11:13:25 +02:00
parent a182291936
commit a256e6c92c
1 changed files with 4 additions and 1 deletions

View File

@ -48,6 +48,9 @@ final class ClientOutput extends AbstractOutput
#[ApiProperty(readableLink: true )]
public ?HardwareProfileOutput $hardwareProfile = null;
#[Groups(['client:read'])]
public ?array $position = ['x' => 0, 'y' => 0];
#[Groups(['client:read'])]
public \DateTime $createdAt;
@ -74,8 +77,8 @@ final class ClientOutput extends AbstractOutput
)->toArray();
$this->menu = $client->getMenu() ? new MenuOutput($client->getMenu()) : null;
$this->position = $client->getPosition();
$this->hardwareProfile = $client->getHardwareProfile() ? new HardwareProfileOutput($client->getHardwareProfile()) : null;
$this->createdAt = $client->getCreatedAt();
$this->createdBy = $client->getCreatedBy();
}