Daniel пре 1 година
родитељ
комит
df3404fe63
4 измењених фајлова са 16 додато и 1 уклоњено
  1. +1
    -1
      export/openapi.json
  2. +12
    -0
      export/openapi.yaml
  3. +1
    -0
      src/ApiResource/PostingApi.php
  4. +2
    -0
      src/Mapper/PostingEntityToApiMapper.php

+ 1
- 1
export/openapi.json
Разлика између датотеке није приказан због своје велике величине
Прегледај датотеку


+ 12
- 0
export/openapi.yaml Прегледај датотеку

@@ -5450,6 +5450,10 @@ components:
- 'null'
format: iri-reference
example: 'https://example.com/'
numComments:
type:
- integer
- 'null'
createdAt:
readOnly: true
type:
@@ -5581,6 +5585,10 @@ components:
- 'null'
format: iri-reference
example: 'https://example.com/'
numComments:
type:
- integer
- 'null'
createdAt:
readOnly: true
type:
@@ -5719,6 +5727,10 @@ components:
- 'null'
format: iri-reference
example: 'https://example.com/'
numComments:
type:
- integer
- 'null'
createdAt:
readOnly: true
type:


+ 1
- 0
src/ApiResource/PostingApi.php Прегледај датотеку

@@ -173,6 +173,7 @@ class PostingApi implements OwnerInterface
#[Groups(['posting:create'])]
public ?SaleApi $saleIri = null;

public ?int $numComments = null;

#[ApiProperty(writable: false)]
public ?\DateTimeImmutable $createdAt = null;


+ 2
- 0
src/Mapper/PostingEntityToApiMapper.php Прегледај датотеку

@@ -68,6 +68,8 @@ class PostingEntityToApiMapper implements MapperInterface
]);
}

$dto->numComments = count($entity->getComments());

$dto->createdAt = $entity->getCreatedAt();

return $dto;


Loading…
Откажи
Сачувај