Tips.php 822 B

12345678910111213141516171819202122232425262728293031323334353637383940
  1. <?php
  2. declare(strict_types=1);
  3. namespace App\Entity\Core;
  4. //use DH\Auditor\Provider\Doctrine\Auditing\Annotation\Auditable;
  5. use ApiPlatform\Metadata\ApiResource;
  6. use ApiPlatform\Metadata\Get;
  7. use ApiPlatform\Metadata\GetCollection;
  8. use App\Repository\Core\NotificationRepository;
  9. use Doctrine\ORM\Mapping as ORM;
  10. /**
  11. * Classe ... qui ...
  12. */
  13. //#[Auditable]
  14. #[ApiResource(
  15. operations: [
  16. new Get(),
  17. new GetCollection(
  18. paginationMaximumItemsPerPage: 20,
  19. paginationClientItemsPerPage: true,
  20. order: ['id' => 'DESC']
  21. )
  22. ]
  23. )]
  24. //#[Auditable]
  25. #[ORM\Entity]
  26. class Tips extends AbstractInformation
  27. {
  28. #[ORM\Id]
  29. #[ORM\Column]
  30. #[ORM\GeneratedValue]
  31. private ?int $id = null;
  32. public function getId(): ?int
  33. {
  34. return $this->id;
  35. }
  36. }