wip: functionality for new role 'management'
This commit is contained in:
1 parent
f32cfcd9f2
commit
2c02415056
14 files changed
+90
-54
No files matched your search
@@ -32,7 +32,7 @@ class DeleteController extends AbstractController
|
||||
'teamer' => (string) $application->getTeamer(),
|
||||
]);
|
||||
|
||||
return $this->redirectToRoute('app_admin_assignment_detail', [
|
||||
return $this->redirectToRoute('app_administrative_assignment_detail', [
|
||||
'uuid' => $application->getAssignment()->getUuid(),
|
||||
]);
|
||||
}
|
||||
|
||||
@@ -44,7 +44,7 @@ class DisposeController extends AbstractController
|
||||
'teamer' => (string) $application->getTeamer(),
|
||||
]);
|
||||
|
||||
$redirectUrl = $this->generateUrl('app_admin_assignment_detail', [
|
||||
$redirectUrl = $this->generateUrl('app_administrative_assignment_detail', [
|
||||
'uuid' => $application->getAssignment()->getUuid(),
|
||||
]);
|
||||
|
||||
|
||||
@@ -51,7 +51,7 @@ class StatusController extends AbstractController
|
||||
'teamer' => (string) $application->getTeamer(),
|
||||
]);
|
||||
|
||||
return new HxRedirectResponse($this->generateUrl('app_admin_assignment_detail', [
|
||||
return new HxRedirectResponse($this->generateUrl('app_administrative_assignment_detail', [
|
||||
'uuid' => $application->getAssignment()->getUuid(),
|
||||
]));
|
||||
}
|
||||
|
||||
@@ -54,7 +54,7 @@ class DeleteController extends AbstractController
|
||||
$this->entityManager->remove($disposition);
|
||||
$this->entityManager->flush();
|
||||
|
||||
return new HxRedirectResponse($this->generateUrl('app_admin_assignment_detail', [
|
||||
return new HxRedirectResponse($this->generateUrl('app_administrative_assignment_detail', [
|
||||
'uuid' => $disposition->getAssignment()->getUuid(),
|
||||
]));
|
||||
}
|
||||
|
||||
@@ -1,28 +0,0 @@
|
||||
<?php
|
||||
|
||||
namespace App\Controller\Admin\Teamer;
|
||||
|
||||
use App\Entity\Teamer;
|
||||
use App\Repository\DispositionRepository;
|
||||
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
|
||||
use Symfony\Component\HttpFoundation\Response;
|
||||
use Symfony\Component\Routing\Attribute\Route;
|
||||
use Symfony\Component\Security\Http\Attribute\IsGranted;
|
||||
|
||||
class InfoController extends AbstractController
|
||||
{
|
||||
public function __construct(private readonly DispositionRepository $dispositionRepository)
|
||||
{}
|
||||
|
||||
#[Route('/admin/teamer/info/{uuid}', name: 'app_admin_teamer_info')]
|
||||
#[IsGranted('ROLE_ADMIN')]
|
||||
public function index(Teamer $teamer): Response
|
||||
{
|
||||
$recentDispositions = $this->dispositionRepository->findRecentDispositionsByTeamer($teamer);
|
||||
|
||||
return $this->render('admin/teamer/modal_info.html.twig', [
|
||||
'teamer' => $teamer,
|
||||
'recentDispositions' => $recentDispositions,
|
||||
]);
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user