mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-09-27 17:15:02 +00:00
Run symfonysetlist up to symfony_70
This commit is contained in:
@@ -21,7 +21,7 @@ class AdminController extends AbstractController
|
||||
/**
|
||||
* @return \Symfony\Component\HttpFoundation\Response
|
||||
*/
|
||||
#[\Symfony\Component\Routing\Annotation\Route(path: '/{_locale}/admin/document', name: 'chill_docstore_admin', options: [null])]
|
||||
#[\Symfony\Component\Routing\Attribute\Route(path: '/{_locale}/admin/document', name: 'chill_docstore_admin', options: [null])]
|
||||
public function indexAction(): \Symfony\Component\HttpFoundation\Response
|
||||
{
|
||||
return $this->render('@ChillDocStore/Admin/layout.html.twig');
|
||||
@@ -30,7 +30,7 @@ class AdminController extends AbstractController
|
||||
/**
|
||||
* @return \Symfony\Component\HttpFoundation\RedirectResponse
|
||||
*/
|
||||
#[\Symfony\Component\Routing\Annotation\Route(path: '/{_locale}/admin/document_redirect_to_main', name: 'chill_docstore_admin_redirect_to_admin_index', options: [null])]
|
||||
#[\Symfony\Component\Routing\Attribute\Route(path: '/{_locale}/admin/document_redirect_to_main', name: 'chill_docstore_admin_redirect_to_admin_index', options: [null])]
|
||||
public function redirectToAdminIndexAction(): \Symfony\Component\HttpFoundation\RedirectResponse
|
||||
{
|
||||
return $this->redirectToRoute('chill_main_admin_central');
|
||||
|
@@ -35,7 +35,7 @@ final readonly class AsyncUploadController
|
||||
private LoggerInterface $chillLogger,
|
||||
) {}
|
||||
|
||||
#[Route(path: '/api/1.0/doc-store/async-upload/temp_url/{uuid}/generate/post', name: 'chill_docstore_asyncupload_getsignedurlpost')]
|
||||
#[\Symfony\Component\Routing\Attribute\Route(path: '/api/1.0/doc-store/async-upload/temp_url/{uuid}/generate/post', name: 'chill_docstore_asyncupload_getsignedurlpost')]
|
||||
public function getSignedUrlPost(Request $request, StoredObject $storedObject): JsonResponse
|
||||
{
|
||||
if (!$this->security->isGranted(StoredObjectRoleEnum::EDIT->value, $storedObject)) {
|
||||
@@ -64,7 +64,7 @@ final readonly class AsyncUploadController
|
||||
);
|
||||
}
|
||||
|
||||
#[Route(path: '/api/1.0/doc-store/async-upload/temp_url/{uuid}/generate/{method}', name: 'chill_docstore_asyncupload_getsignedurlget', requirements: ['method' => 'get|head'])]
|
||||
#[\Symfony\Component\Routing\Attribute\Route(path: '/api/1.0/doc-store/async-upload/temp_url/{uuid}/generate/{method}', name: 'chill_docstore_asyncupload_getsignedurlget', requirements: ['method' => 'get|head'])]
|
||||
public function getSignedUrlGet(Request $request, StoredObject $storedObject, string $method): JsonResponse
|
||||
{
|
||||
if (!$this->security->isGranted(StoredObjectRoleEnum::SEE->value, $storedObject)) {
|
||||
|
@@ -25,7 +25,7 @@ use Symfony\Component\HttpFoundation\Response;
|
||||
use Symfony\Component\Routing\Annotation\Route;
|
||||
use Symfony\Contracts\Translation\TranslatorInterface;
|
||||
|
||||
#[Route(path: '/{_locale}/parcours/{course}/document')]
|
||||
#[\Symfony\Component\Routing\Attribute\Route(path: '/{_locale}/parcours/{course}/document')]
|
||||
class DocumentAccompanyingCourseController extends AbstractController
|
||||
{
|
||||
/**
|
||||
@@ -38,7 +38,7 @@ class DocumentAccompanyingCourseController extends AbstractController
|
||||
private readonly \Doctrine\Persistence\ManagerRegistry $managerRegistry,
|
||||
) {}
|
||||
|
||||
#[Route(path: '/{id}/delete', name: 'chill_docstore_accompanying_course_document_delete')]
|
||||
#[\Symfony\Component\Routing\Attribute\Route(path: '/{id}/delete', name: 'chill_docstore_accompanying_course_document_delete')]
|
||||
public function delete(Request $request, AccompanyingPeriod $course, AccompanyingCourseDocument $document): Response
|
||||
{
|
||||
$this->denyAccessUnlessGranted(AccompanyingCourseDocumentVoter::DELETE, $document);
|
||||
@@ -65,13 +65,13 @@ class DocumentAccompanyingCourseController extends AbstractController
|
||||
'@ChillDocStore/AccompanyingCourseDocument/delete.html.twig',
|
||||
[
|
||||
'document' => $document,
|
||||
'delete_form' => $form->createView(),
|
||||
'delete_form' => $form,
|
||||
'accompanyingCourse' => $course,
|
||||
]
|
||||
);
|
||||
}
|
||||
|
||||
#[Route(path: '/{id}/edit', name: 'accompanying_course_document_edit', methods: 'GET|POST')]
|
||||
#[\Symfony\Component\Routing\Attribute\Route(path: '/{id}/edit', name: 'accompanying_course_document_edit', methods: 'GET|POST')]
|
||||
public function edit(Request $request, AccompanyingPeriod $course, AccompanyingCourseDocument $document): Response
|
||||
{
|
||||
$this->denyAccessUnlessGranted(AccompanyingCourseDocumentVoter::UPDATE, $document);
|
||||
@@ -104,13 +104,13 @@ class DocumentAccompanyingCourseController extends AbstractController
|
||||
'@ChillDocStore/AccompanyingCourseDocument/edit.html.twig',
|
||||
[
|
||||
'document' => $document,
|
||||
'form' => $form->createView(),
|
||||
'form' => $form,
|
||||
'accompanyingCourse' => $course,
|
||||
]
|
||||
);
|
||||
}
|
||||
|
||||
#[Route(path: '/new', name: 'accompanying_course_document_new', methods: 'GET|POST')]
|
||||
#[\Symfony\Component\Routing\Attribute\Route(path: '/new', name: 'accompanying_course_document_new', methods: 'GET|POST')]
|
||||
public function new(Request $request, AccompanyingPeriod $course): Response
|
||||
{
|
||||
if (null === $course) {
|
||||
@@ -149,12 +149,12 @@ class DocumentAccompanyingCourseController extends AbstractController
|
||||
|
||||
return $this->render('@ChillDocStore/AccompanyingCourseDocument/new.html.twig', [
|
||||
'document' => $document,
|
||||
'form' => $form->createView(),
|
||||
'form' => $form,
|
||||
'accompanyingCourse' => $course,
|
||||
]);
|
||||
}
|
||||
|
||||
#[Route(path: '/{id}', name: 'accompanying_course_document_show', methods: 'GET')]
|
||||
#[\Symfony\Component\Routing\Attribute\Route(path: '/{id}', name: 'accompanying_course_document_show', methods: 'GET')]
|
||||
public function show(AccompanyingPeriod $course, AccompanyingCourseDocument $document): Response
|
||||
{
|
||||
$this->denyAccessUnlessGranted(AccompanyingCourseDocumentVoter::SEE_DETAILS, $document);
|
||||
|
@@ -33,7 +33,7 @@ final readonly class DocumentAccompanyingCourseDuplicateController
|
||||
private UrlGeneratorInterface $urlGenerator,
|
||||
) {}
|
||||
|
||||
#[Route('/{_locale}/doc-store/accompanying-course-document/{id}/duplicate', name: 'chill_doc_store_accompanying_course_document_duplicate')]
|
||||
#[\Symfony\Component\Routing\Attribute\Route('/{_locale}/doc-store/accompanying-course-document/{id}/duplicate', name: 'chill_doc_store_accompanying_course_document_duplicate')]
|
||||
public function __invoke(AccompanyingCourseDocument $document, Request $request, Session $session): Response
|
||||
{
|
||||
if (!$this->security->isGranted(AccompanyingCourseDocumentVoter::SEE, $document)) {
|
||||
|
@@ -20,12 +20,12 @@ use Symfony\Component\HttpFoundation\Request;
|
||||
use Symfony\Component\HttpFoundation\Response;
|
||||
use Symfony\Component\Routing\Annotation\Route;
|
||||
|
||||
#[Route(path: '/{_locale}/admin/document/category')]
|
||||
#[\Symfony\Component\Routing\Attribute\Route(path: '/{_locale}/admin/document/category')]
|
||||
class DocumentCategoryController extends AbstractController
|
||||
{
|
||||
public function __construct(private readonly \Doctrine\Persistence\ManagerRegistry $managerRegistry) {}
|
||||
|
||||
#[Route(path: '/{bundleId}/{idInsideBundle}', name: 'document_category_delete', methods: 'DELETE')]
|
||||
#[\Symfony\Component\Routing\Attribute\Route(path: '/{bundleId}/{idInsideBundle}', name: 'document_category_delete', methods: 'DELETE')]
|
||||
public function delete(Request $request, mixed $bundleId, mixed $idInsideBundle): Response
|
||||
{
|
||||
$em = $this->managerRegistry->getManager();
|
||||
@@ -43,7 +43,7 @@ class DocumentCategoryController extends AbstractController
|
||||
return $this->redirectToRoute('document_category_index');
|
||||
}
|
||||
|
||||
#[Route(path: '/{bundleId}/{idInsideBundle}/edit', name: 'document_category_edit', methods: 'GET|POST')]
|
||||
#[\Symfony\Component\Routing\Attribute\Route(path: '/{bundleId}/{idInsideBundle}/edit', name: 'document_category_edit', methods: 'GET|POST')]
|
||||
public function edit(Request $request, mixed $bundleId, mixed $idInsideBundle): Response
|
||||
{
|
||||
$em = $this->managerRegistry->getManager();
|
||||
@@ -66,12 +66,12 @@ class DocumentCategoryController extends AbstractController
|
||||
|
||||
return $this->render('@ChillDocStore/DocumentCategory/edit.html.twig', [
|
||||
'document_category' => $documentCategory,
|
||||
'form' => $form->createView(),
|
||||
'form' => $form,
|
||||
]);
|
||||
}
|
||||
|
||||
#[Route(path: '/', name: 'document_category_index', methods: 'GET')]
|
||||
#[Route(path: '/', name: 'chill_docstore_category_admin', methods: 'GET')]
|
||||
#[\Symfony\Component\Routing\Attribute\Route(path: '/', name: 'document_category_index', methods: 'GET')]
|
||||
#[\Symfony\Component\Routing\Attribute\Route(path: '/', name: 'chill_docstore_category_admin', methods: 'GET')]
|
||||
public function index(): Response
|
||||
{
|
||||
$em = $this->managerRegistry->getManager();
|
||||
@@ -85,7 +85,7 @@ class DocumentCategoryController extends AbstractController
|
||||
);
|
||||
}
|
||||
|
||||
#[Route(path: '/new', name: 'document_category_new', methods: 'GET|POST')]
|
||||
#[\Symfony\Component\Routing\Attribute\Route(path: '/new', name: 'document_category_new', methods: 'GET|POST')]
|
||||
public function new(Request $request): Response
|
||||
{
|
||||
$em = $this->managerRegistry->getManager();
|
||||
@@ -118,11 +118,11 @@ class DocumentCategoryController extends AbstractController
|
||||
|
||||
return $this->render('@ChillDocStore/DocumentCategory/new.html.twig', [
|
||||
'document_category' => $documentCategory,
|
||||
'form' => $form->createView(),
|
||||
'form' => $form,
|
||||
]);
|
||||
}
|
||||
|
||||
#[Route(path: '/{bundleId}/{idInsideBundle}', name: 'document_category_show', methods: 'GET')]
|
||||
#[\Symfony\Component\Routing\Attribute\Route(path: '/{bundleId}/{idInsideBundle}', name: 'document_category_show', methods: 'GET')]
|
||||
public function show(mixed $bundleId, mixed $idInsideBundle): Response
|
||||
{
|
||||
$em = $this->managerRegistry->getManager();
|
||||
|
@@ -32,7 +32,7 @@ use Chill\DocStoreBundle\Service\StoredObjectManagerInterface;
|
||||
/**
|
||||
* Class DocumentPersonController.
|
||||
*/
|
||||
#[Route(path: '/{_locale}/person/{person}/document')] // TODO faire un controller abstrait ?
|
||||
#[\Symfony\Component\Routing\Attribute\Route(path: '/{_locale}/person/{person}/document')] // TODO faire un controller abstrait ?
|
||||
class DocumentPersonController extends AbstractController
|
||||
{
|
||||
/**
|
||||
@@ -47,7 +47,7 @@ class DocumentPersonController extends AbstractController
|
||||
private readonly \Doctrine\Persistence\ManagerRegistry $managerRegistry,
|
||||
) {}
|
||||
|
||||
#[Route(path: '/{id}/delete', name: 'chill_docstore_person_document_delete')]
|
||||
#[\Symfony\Component\Routing\Attribute\Route(path: '/{id}/delete', name: 'chill_docstore_person_document_delete')]
|
||||
public function delete(Request $request, Person $person, PersonDocument $document): Response
|
||||
{
|
||||
$this->denyAccessUnlessGranted(PersonDocumentVoter::DELETE, $document);
|
||||
@@ -74,13 +74,13 @@ class DocumentPersonController extends AbstractController
|
||||
'@ChillDocStore/PersonDocument/delete.html.twig',
|
||||
[
|
||||
'document' => $document,
|
||||
'delete_form' => $form->createView(),
|
||||
'delete_form' => $form,
|
||||
'person' => $person,
|
||||
]
|
||||
);
|
||||
}
|
||||
|
||||
#[Route(path: '/{id}/edit', name: 'person_document_edit', methods: 'GET|POST')]
|
||||
#[\Symfony\Component\Routing\Attribute\Route(path: '/{id}/edit', name: 'person_document_edit', methods: 'GET|POST')]
|
||||
public function edit(Request $request, Person $person, PersonDocument $document): Response
|
||||
{
|
||||
$this->denyAccessUnlessGranted('CHILL_PERSON_SEE', $person);
|
||||
@@ -131,13 +131,13 @@ class DocumentPersonController extends AbstractController
|
||||
'@ChillDocStore/PersonDocument/edit.html.twig',
|
||||
[
|
||||
'document' => $document,
|
||||
'form' => $form->createView(),
|
||||
'form' => $form,
|
||||
'person' => $person,
|
||||
]
|
||||
);
|
||||
}
|
||||
|
||||
#[Route(path: '/new', name: 'person_document_new', methods: 'GET|POST')]
|
||||
#[\Symfony\Component\Routing\Attribute\Route(path: '/new', name: 'person_document_new', methods: 'GET|POST')]
|
||||
public function new(Request $request, Person $person): Response
|
||||
{
|
||||
if (null === $person) {
|
||||
@@ -178,12 +178,12 @@ class DocumentPersonController extends AbstractController
|
||||
|
||||
return $this->render('@ChillDocStore/PersonDocument/new.html.twig', [
|
||||
'document' => $document,
|
||||
'form' => $form->createView(),
|
||||
'form' => $form,
|
||||
'person' => $person,
|
||||
]);
|
||||
}
|
||||
|
||||
#[Route(path: '/{id}', name: 'person_document_show', methods: 'GET')]
|
||||
#[\Symfony\Component\Routing\Attribute\Route(path: '/{id}', name: 'person_document_show', methods: 'GET')]
|
||||
public function show(Person $person, PersonDocument $document): Response
|
||||
{
|
||||
$this->denyAccessUnlessGranted('CHILL_PERSON_SEE', $person);
|
||||
|
@@ -34,7 +34,7 @@ final readonly class GenericDocForAccompanyingPeriodController
|
||||
/**
|
||||
* @throws \Doctrine\DBAL\Exception
|
||||
*/
|
||||
#[Route(path: '/{_locale}/doc-store/generic-doc/by-period/{id}/index', name: 'chill_docstore_generic-doc_by-period_index')]
|
||||
#[\Symfony\Component\Routing\Attribute\Route(path: '/{_locale}/doc-store/generic-doc/by-period/{id}/index', name: 'chill_docstore_generic-doc_by-period_index')]
|
||||
public function list(AccompanyingPeriod $accompanyingPeriod): Response
|
||||
{
|
||||
if (!$this->security->isGranted(AccompanyingCourseDocumentVoter::SEE, $accompanyingPeriod)) {
|
||||
|
@@ -35,7 +35,7 @@ final readonly class GenericDocForAccompanyingPeriodListApiController
|
||||
private SerializerInterface $serializer,
|
||||
) {}
|
||||
|
||||
#[Route('/api/1.0/doc-store/generic-doc/by-period/{id}/index', methods: ['GET'])]
|
||||
#[\Symfony\Component\Routing\Attribute\Route('/api/1.0/doc-store/generic-doc/by-period/{id}/index', methods: ['GET'])]
|
||||
public function __invoke(AccompanyingPeriod $accompanyingPeriod): JsonResponse
|
||||
{
|
||||
if (!$this->security->isGranted(AccompanyingCourseDocumentVoter::SEE, $accompanyingPeriod)) {
|
||||
|
@@ -34,7 +34,7 @@ final readonly class GenericDocForPerson
|
||||
/**
|
||||
* @throws \Doctrine\DBAL\Exception
|
||||
*/
|
||||
#[Route(path: '/{_locale}/doc-store/generic-doc/by-person/{id}/index', name: 'chill_docstore_generic-doc_by-person_index')]
|
||||
#[\Symfony\Component\Routing\Attribute\Route(path: '/{_locale}/doc-store/generic-doc/by-person/{id}/index', name: 'chill_docstore_generic-doc_by-person_index')]
|
||||
public function list(Person $person): Response
|
||||
{
|
||||
if (!$this->security->isGranted(PersonDocumentVoter::SEE, $person)) {
|
||||
|
@@ -45,7 +45,7 @@ class SignatureRequestController
|
||||
private readonly EntityManagerInterface $entityManager,
|
||||
) {}
|
||||
|
||||
#[Route('/api/1.0/document/workflow/{id}/signature-request', name: 'chill_docstore_signature_request')]
|
||||
#[\Symfony\Component\Routing\Attribute\Route('/api/1.0/document/workflow/{id}/signature-request', name: 'chill_docstore_signature_request')]
|
||||
public function processSignature(EntityWorkflowStepSignature $signature, Request $request): JsonResponse
|
||||
{
|
||||
if (!$this->security->isGranted(EntityWorkflowStepSignatureVoter::SIGN, $signature)) {
|
||||
@@ -96,7 +96,7 @@ class SignatureRequestController
|
||||
return new JsonResponse(null, JsonResponse::HTTP_OK, []);
|
||||
}
|
||||
|
||||
#[Route('/api/1.0/document/workflow/{id}/check-signature', name: 'chill_docstore_check_signature')]
|
||||
#[\Symfony\Component\Routing\Attribute\Route('/api/1.0/document/workflow/{id}/check-signature', name: 'chill_docstore_check_signature')]
|
||||
public function checkSignature(EntityWorkflowStepSignature $signature): JsonResponse
|
||||
{
|
||||
$entityWorkflow = $signature->getStep()->getEntityWorkflow();
|
||||
|
@@ -40,7 +40,7 @@ class StoredObjectApiController extends ApiController
|
||||
*
|
||||
* @throws AccessDeniedHttpException if the user does not have the necessary role to create a stored object
|
||||
*/
|
||||
#[Route('/api/1.0/doc-store/stored-object/create', methods: ['POST'])]
|
||||
#[\Symfony\Component\Routing\Attribute\Route('/api/1.0/doc-store/stored-object/create', methods: ['POST'])]
|
||||
public function createStoredObject(): JsonResponse
|
||||
{
|
||||
if (!($this->security->isGranted('ROLE_ADMIN') || $this->security->isGranted('ROLE_USER'))) {
|
||||
|
@@ -31,7 +31,7 @@ final readonly class StoredObjectContentToLocalStorageController
|
||||
private TempUrlLocalStorageGenerator $tempUrlLocalStorageGenerator,
|
||||
) {}
|
||||
|
||||
#[Route('/public/stored-object/post', name: 'chill_docstore_storedobject_post', methods: ['POST'])]
|
||||
#[\Symfony\Component\Routing\Attribute\Route('/public/stored-object/post', name: 'chill_docstore_storedobject_post', methods: ['POST'])]
|
||||
public function postContent(Request $request): Response
|
||||
{
|
||||
$prefix = $request->query->get('prefix', '');
|
||||
@@ -88,7 +88,7 @@ final readonly class StoredObjectContentToLocalStorageController
|
||||
return new Response(status: Response::HTTP_NO_CONTENT);
|
||||
}
|
||||
|
||||
#[Route('/public/stored-object/operate', name: 'chill_docstore_stored_object_operate', methods: ['GET', 'HEAD'])]
|
||||
#[\Symfony\Component\Routing\Attribute\Route('/public/stored-object/operate', name: 'chill_docstore_stored_object_operate', methods: ['GET', 'HEAD'])]
|
||||
public function contentOperate(Request $request): Response
|
||||
{
|
||||
if ('' === $objectName = $request->query->get('object_name', '')) {
|
||||
|
@@ -27,7 +27,7 @@ final readonly class StoredObjectRestoreVersionApiController
|
||||
{
|
||||
public function __construct(private Security $security, private StoredObjectRestoreInterface $storedObjectRestore, private EntityManagerInterface $entityManager, private SerializerInterface $serializer) {}
|
||||
|
||||
#[Route('/api/1.0/doc-store/stored-object/restore-from-version/{id}', methods: ['POST'])]
|
||||
#[\Symfony\Component\Routing\Attribute\Route('/api/1.0/doc-store/stored-object/restore-from-version/{id}', methods: ['POST'])]
|
||||
public function restoreStoredObjectVersion(StoredObjectVersion $storedObjectVersion): JsonResponse
|
||||
{
|
||||
if (!$this->security->isGranted(StoredObjectRoleEnum::EDIT->value, $storedObjectVersion->getStoredObject())) {
|
||||
|
@@ -22,7 +22,7 @@ class StoredObjectStatusApiController
|
||||
{
|
||||
public function __construct(private readonly Security $security) {}
|
||||
|
||||
#[Route(path: '/api/1.0/doc-store/stored-object/{uuid}/is-ready')]
|
||||
#[\Symfony\Component\Routing\Attribute\Route(path: '/api/1.0/doc-store/stored-object/{uuid}/is-ready')]
|
||||
public function isDocumentReady(StoredObject $storedObject): Response
|
||||
{
|
||||
if (!$this->security->isGranted('ROLE_USER')) {
|
||||
|
@@ -42,7 +42,7 @@ final readonly class StoredObjectVersionApiController
|
||||
*
|
||||
* @throws AccessDeniedHttpException if the user is not allowed to see the stored object
|
||||
*/
|
||||
#[Route('/api/1.0/doc-store/stored-object/{uuid}/versions', name: 'chill_doc_store_stored_object_versions_list')]
|
||||
#[\Symfony\Component\Routing\Attribute\Route('/api/1.0/doc-store/stored-object/{uuid}/versions', name: 'chill_doc_store_stored_object_versions_list')]
|
||||
public function listVersions(StoredObject $storedObject): JsonResponse
|
||||
{
|
||||
if (!$this->security->isGranted(StoredObjectRoleEnum::SEE->value, $storedObject)) {
|
||||
|
@@ -48,7 +48,7 @@ final readonly class WebdavController
|
||||
$this->requestAnalyzer = new PropfindRequestAnalyzer();
|
||||
}
|
||||
|
||||
#[Route(path: '/dav/{access_token}/get/{uuid}/', methods: ['GET', 'HEAD'], name: 'chill_docstore_dav_directory_get')]
|
||||
#[\Symfony\Component\Routing\Attribute\Route(path: '/dav/{access_token}/get/{uuid}/', methods: ['GET', 'HEAD'], name: 'chill_docstore_dav_directory_get')]
|
||||
public function getDirectory(StoredObject $storedObject, string $access_token): Response
|
||||
{
|
||||
if (!$this->security->isGranted(StoredObjectRoleEnum::SEE->value, $storedObject)) {
|
||||
@@ -63,7 +63,7 @@ final readonly class WebdavController
|
||||
);
|
||||
}
|
||||
|
||||
#[Route(path: '/dav/{access_token}/get/{uuid}/', methods: ['OPTIONS'])]
|
||||
#[\Symfony\Component\Routing\Attribute\Route(path: '/dav/{access_token}/get/{uuid}/', methods: ['OPTIONS'])]
|
||||
public function optionsDirectory(StoredObject $storedObject): Response
|
||||
{
|
||||
if (!$this->security->isGranted(StoredObjectRoleEnum::SEE->value, $storedObject)) {
|
||||
@@ -80,7 +80,7 @@ final readonly class WebdavController
|
||||
return $response;
|
||||
}
|
||||
|
||||
#[Route(path: '/dav/{access_token}/get/{uuid}/', methods: ['PROPFIND'])]
|
||||
#[\Symfony\Component\Routing\Attribute\Route(path: '/dav/{access_token}/get/{uuid}/', methods: ['PROPFIND'])]
|
||||
public function propfindDirectory(StoredObject $storedObject, string $access_token, Request $request): Response
|
||||
{
|
||||
if (!$this->security->isGranted(StoredObjectRoleEnum::SEE->value, $storedObject)) {
|
||||
@@ -115,7 +115,7 @@ final readonly class WebdavController
|
||||
return $response;
|
||||
}
|
||||
|
||||
#[Route(path: '/dav/{access_token}/get/{uuid}/d', name: 'chill_docstore_dav_document_get', methods: ['GET'])]
|
||||
#[\Symfony\Component\Routing\Attribute\Route(path: '/dav/{access_token}/get/{uuid}/d', name: 'chill_docstore_dav_document_get', methods: ['GET'])]
|
||||
public function getDocument(StoredObject $storedObject): Response
|
||||
{
|
||||
if (!$this->security->isGranted(StoredObjectRoleEnum::SEE->value, $storedObject)) {
|
||||
@@ -126,7 +126,7 @@ final readonly class WebdavController
|
||||
->setEtag($this->storedObjectManager->etag($storedObject));
|
||||
}
|
||||
|
||||
#[Route(path: '/dav/{access_token}/get/{uuid}/d', methods: ['HEAD'])]
|
||||
#[\Symfony\Component\Routing\Attribute\Route(path: '/dav/{access_token}/get/{uuid}/d', methods: ['HEAD'])]
|
||||
public function headDocument(StoredObject $storedObject): Response
|
||||
{
|
||||
if (!$this->security->isGranted(StoredObjectRoleEnum::SEE->value, $storedObject)) {
|
||||
@@ -146,7 +146,7 @@ final readonly class WebdavController
|
||||
return $response;
|
||||
}
|
||||
|
||||
#[Route(path: '/dav/{access_token}/get/{uuid}/d', methods: ['OPTIONS'])]
|
||||
#[\Symfony\Component\Routing\Attribute\Route(path: '/dav/{access_token}/get/{uuid}/d', methods: ['OPTIONS'])]
|
||||
public function optionsDocument(StoredObject $storedObject): Response
|
||||
{
|
||||
if (!$this->security->isGranted(StoredObjectRoleEnum::SEE->value, $storedObject)) {
|
||||
@@ -162,7 +162,7 @@ final readonly class WebdavController
|
||||
return $response;
|
||||
}
|
||||
|
||||
#[Route(path: '/dav/{access_token}/get/{uuid}/d', methods: ['PROPFIND'])]
|
||||
#[\Symfony\Component\Routing\Attribute\Route(path: '/dav/{access_token}/get/{uuid}/d', methods: ['PROPFIND'])]
|
||||
public function propfindDocument(StoredObject $storedObject, string $access_token, Request $request): Response
|
||||
{
|
||||
if (!$this->security->isGranted(StoredObjectRoleEnum::SEE->value, $storedObject)) {
|
||||
@@ -194,7 +194,7 @@ final readonly class WebdavController
|
||||
return $response;
|
||||
}
|
||||
|
||||
#[Route(path: '/dav/{access_token}/get/{uuid}/d', methods: ['PUT'])]
|
||||
#[\Symfony\Component\Routing\Attribute\Route(path: '/dav/{access_token}/get/{uuid}/d', methods: ['PUT'])]
|
||||
public function putDocument(StoredObject $storedObject, Request $request): Response
|
||||
{
|
||||
if (!$this->security->isGranted(StoredObjectRoleEnum::EDIT->value, $storedObject)) {
|
||||
|
Reference in New Issue
Block a user