Files
SIRH/src/ApiResource/AbsencePrint.php
tristan 76f1363457
All checks were successful
Auto Tag Develop / tag (push) Successful in 6s
[#321] Gestion des rôles dans l'application (#2)
| Numéro du ticket | Titre du ticket |
|------------------|-----------------|
|        #321          |        Gestion des rôles dans l'application         |

## Description de la PR
[#321] Gestion des rôles dans l'application

## Modification du .env

## Check list

- [x] Pas de régression
- [ ] TU/TI/TF rédigée
- [x] TU/TI/TF OK
- [ ] CHANGELOG modifié

Reviewed-on: #2
Co-authored-by: tristan <tristan@yuno.malio.fr>
Co-committed-by: tristan <tristan@yuno.malio.fr>
2026-02-16 07:19:05 +00:00

27 lines
685 B
PHP

<?php
declare(strict_types=1);
namespace App\ApiResource;
use ApiPlatform\Metadata\ApiResource;
use ApiPlatform\Metadata\Get;
use ApiPlatform\Metadata\QueryParameter;
use App\State\AbsencePrintProvider;
#[ApiResource(
operations: [
new Get(
uriTemplate: '/absences/print',
provider: AbsencePrintProvider::class,
parameters: [
new QueryParameter(key: 'from', required: true),
new QueryParameter(key: 'to', required: true),
new QueryParameter(key: 'sites', required: false),
],
security: "is_granted('ROLE_ADMIN')"
),
]
)]
final class AbsencePrint {}