refs #955. Updates Partition/SW-P/SW
testing/ogcore-api/pipeline/head This commit looks good Details

develop-jenkins
Manuel Aranda Rosales 2024-10-18 09:21:44 +02:00
parent a2171ceb47
commit de5f719111
5 changed files with 7 additions and 5 deletions

View File

@ -16,6 +16,8 @@ resources:
ApiPlatform\Metadata\Get: ApiPlatform\Metadata\Get:
provider: App\State\Provider\SoftwareProfileProvider provider: App\State\Provider\SoftwareProfileProvider
normalizationContext:
groups: ['software-profile:item:get', 'software-profile:read:collection:short']
ApiPlatform\Metadata\Put: ApiPlatform\Metadata\Put:
provider: App\State\Provider\SoftwareProfileProvider provider: App\State\Provider\SoftwareProfileProvider
ApiPlatform\Metadata\Patch: ApiPlatform\Metadata\Patch:

View File

@ -93,7 +93,7 @@ final class PartitionInput
$partition->setDiskNumber($this->diskNumber); $partition->setDiskNumber($this->diskNumber);
$partition->setPartitionNumber($this->partitionNumber); $partition->setPartitionNumber($this->partitionNumber);
$partition->setPartitionCode($this->partitionCode); $partition->setPartitionCode($this->partitionCode);
$partition->setSize($this->size * 100); $partition->setSize($this->size * 1024);
$partition->setCacheContent($this->cacheContent); $partition->setCacheContent($this->cacheContent);
$partition->setFilesystem($this->filesystem); $partition->setFilesystem($this->filesystem);

View File

@ -10,7 +10,7 @@ use Symfony\Component\Serializer\Annotation\Groups;
#[Get(shortName: 'OgLive')] #[Get(shortName: 'OgLive')]
final class OgLiveOutput extends AbstractOutput final class OgLiveOutput extends AbstractOutput
{ {
#[Groups(['og-live:read'])] #[Groups(['og-live:read', 'client:read'])]
public string $name; public string $name;
#[Groups(['og-live:read'])] #[Groups(['og-live:read'])]

View File

@ -40,7 +40,7 @@ class PartitionOutput extends AbstractOutput
$this->diskNumber = $partition->getDiskNumber(); $this->diskNumber = $partition->getDiskNumber();
$this->partitionNumber = $partition->getPartitionNumber(); $this->partitionNumber = $partition->getPartitionNumber();
$this->partitionCode = $partition->getPartitionCode(); $this->partitionCode = $partition->getPartitionCode();
$this->size = $partition->getSize() / 100; $this->size = $partition->getSize() / 1024 ;
$this->cacheContent = $partition->getCacheContent(); $this->cacheContent = $partition->getCacheContent();
$this->filesystem = $partition->getFilesystem(); $this->filesystem = $partition->getFilesystem();
if ($partition->getOperativeSystem()) { if ($partition->getOperativeSystem()) {

View File

@ -11,7 +11,7 @@ use Symfony\Component\Serializer\Annotation\Groups;
#[Get(shortName: 'SoftwareProfile')] #[Get(shortName: 'SoftwareProfile')]
final class SoftwareProfileOutput extends AbstractOutput final class SoftwareProfileOutput extends AbstractOutput
{ {
#[Groups(['software-profile:read'])] #[Groups(['software-profile:read', 'image:read'])]
public ?string $description = ''; public ?string $description = '';
#[Groups(['software-profile:read'])] #[Groups(['software-profile:read'])]
@ -23,7 +23,7 @@ final class SoftwareProfileOutput extends AbstractOutput
#[Groups(['software-profile:read'])] #[Groups(['software-profile:read'])]
public ?OperativeSystemOutput $operativeSystem = null; public ?OperativeSystemOutput $operativeSystem = null;
#[Groups(['software-profile:read'])] #[Groups(['software-profile:item:get'])]
public ?array $softwareCollection = []; public ?array $softwareCollection = [];
#[Groups(['software-profile:read'])] #[Groups(['software-profile:read'])]