mirror of
https://github.com/kevinveenbirkenbach/infinito.git
synced 2024-12-04 23:17:19 +01:00
Substituted controllers through general layer controller
This commit is contained in:
parent
724ff63880
commit
baf14680fe
@ -1,35 +0,0 @@
|
||||
<?php
|
||||
|
||||
namespace Infinito\Controller\API\Rest;
|
||||
|
||||
use Infinito\Controller\API\AbstractAPIController;
|
||||
use Symfony\Component\HttpFoundation\Request;
|
||||
use Symfony\Component\HttpFoundation\Response;
|
||||
|
||||
/**
|
||||
* @author kevinfrantz
|
||||
*
|
||||
* @todo Implement!
|
||||
*/
|
||||
final class HeredityController extends AbstractAPIController
|
||||
{
|
||||
// public function read(Request $request, $identifier): Response
|
||||
// {
|
||||
// }
|
||||
|
||||
// public function create(Request $request, SecureCRUDFactoryService $crudFactory): Response
|
||||
// {
|
||||
// }
|
||||
|
||||
// public function update(Request $request, $identifier): Response
|
||||
// {
|
||||
// }
|
||||
|
||||
// public function list(Request $request): Response
|
||||
// {
|
||||
// }
|
||||
|
||||
// public function delete(Request $request, $identifier): Response
|
||||
// {
|
||||
// }
|
||||
}
|
@ -1,35 +0,0 @@
|
||||
<?php
|
||||
|
||||
namespace Infinito\Controller\API\Rest;
|
||||
|
||||
use Infinito\Controller\API\AbstractAPIController;
|
||||
use Symfony\Component\HttpFoundation\Request;
|
||||
use Symfony\Component\HttpFoundation\Response;
|
||||
|
||||
/**
|
||||
* @author kevinfrantz
|
||||
*
|
||||
* @todo Implement!
|
||||
*/
|
||||
final class LawController extends AbstractAPIController
|
||||
{
|
||||
// public function read(Request $request, $identifier): Response
|
||||
// {
|
||||
// }
|
||||
|
||||
// public function create(Request $request, SecureCRUDFactoryService $crudFactory): Response
|
||||
// {
|
||||
// }
|
||||
|
||||
// public function update(Request $request, $identifier): Response
|
||||
// {
|
||||
// }
|
||||
|
||||
// public function list(Request $request): Response
|
||||
// {
|
||||
// }
|
||||
|
||||
// public function delete(Request $request, $identifier): Response
|
||||
// {
|
||||
// }
|
||||
}
|
@ -9,7 +9,6 @@ use Infinito\Controller\API\AbstractAPIController;
|
||||
use Infinito\Domain\RequestManagement\Action\RequestedActionServiceInterface;
|
||||
use Infinito\Domain\MVCManagement\MVCRoutineServiceInterface;
|
||||
use Infinito\DBAL\Types\ActionType;
|
||||
use Infinito\DBAL\Types\Meta\Right\LayerType;
|
||||
|
||||
/**
|
||||
* @author kevinfrantz
|
||||
@ -18,11 +17,7 @@ use Infinito\DBAL\Types\Meta\Right\LayerType;
|
||||
* @see https://symfony.com/blog/new-in-symfony-4-1-internationalized-routing
|
||||
* @Route(
|
||||
* {
|
||||
* "en":"/api/rest/source/{identity}.{_format}",
|
||||
* "de":"/api/rest/quelle/{identity}.{_format}",
|
||||
* "eo":"/api/rest/fonto/{identity}.{_format}",
|
||||
* "es":"/api/rest/fontanar/{identity}.{_format}",
|
||||
* "nl":"/api/rest/bron/{identity}.{_format}"
|
||||
* "en":"/api/rest/{layer}/{identity}.{_format}",
|
||||
* },
|
||||
* defaults={
|
||||
* "identity"="",
|
||||
@ -30,7 +25,7 @@ use Infinito\DBAL\Types\Meta\Right\LayerType;
|
||||
* }
|
||||
* )
|
||||
*/
|
||||
final class SourceController extends AbstractAPIController
|
||||
final class LayerController extends AbstractAPIController
|
||||
{
|
||||
/**
|
||||
* @Route(
|
||||
@ -40,10 +35,10 @@ final class SourceController extends AbstractAPIController
|
||||
*
|
||||
* @see \Infinito\Controller\API\AbstractAPIController::read()
|
||||
*/
|
||||
public function read(MVCRoutineServiceInterface $mvcRoutineService, RequestedActionServiceInterface $requestedActionService, $identity): Response
|
||||
public function read(MVCRoutineServiceInterface $mvcRoutineService, RequestedActionServiceInterface $requestedActionService, $layer, $identity): Response
|
||||
{
|
||||
$requestedActionService->setActionType(ActionType::READ);
|
||||
$requestedActionService->setLayer(LayerType::SOURCE);
|
||||
$requestedActionService->setLayer($layer);
|
||||
$requestedActionService->getRequestedEntity()->setIdentity($identity);
|
||||
$view = $mvcRoutineService->process();
|
||||
|
@ -1,35 +0,0 @@
|
||||
<?php
|
||||
|
||||
namespace Infinito\Controller\API\Rest;
|
||||
|
||||
use Infinito\Controller\API\AbstractAPIController;
|
||||
use Symfony\Component\HttpFoundation\Request;
|
||||
use Symfony\Component\HttpFoundation\Response;
|
||||
|
||||
/**
|
||||
* @author kevinfrantz
|
||||
*
|
||||
* @todo Implement!
|
||||
*/
|
||||
final class MemberController extends AbstractAPIController
|
||||
{
|
||||
// public function read(Request $request, $identifier): Response
|
||||
// {
|
||||
// }
|
||||
|
||||
// public function create(Request $request, SecureCRUDFactoryService $crudFactory): Response
|
||||
// {
|
||||
// }
|
||||
|
||||
// public function update(Request $request, $identifier): Response
|
||||
// {
|
||||
// }
|
||||
|
||||
// public function list(Request $request): Response
|
||||
// {
|
||||
// }
|
||||
|
||||
// public function delete(Request $request, $identifier): Response
|
||||
// {
|
||||
// }
|
||||
}
|
@ -1,35 +0,0 @@
|
||||
<?php
|
||||
|
||||
namespace Infinito\Controller\API\Rest;
|
||||
|
||||
use Infinito\Controller\API\AbstractAPIController;
|
||||
use Symfony\Component\HttpFoundation\Request;
|
||||
use Symfony\Component\HttpFoundation\Response;
|
||||
|
||||
/**
|
||||
* @author kevinfrantz
|
||||
*
|
||||
* @todo Implement!
|
||||
*/
|
||||
final class RightController extends AbstractAPIController
|
||||
{
|
||||
// public function read(Request $request, $identifier): Response
|
||||
// {
|
||||
// }
|
||||
|
||||
// public function create(Request $request, SecureCRUDFactoryService $crudFactory): Response
|
||||
// {
|
||||
// }
|
||||
|
||||
// public function update(Request $request, $identifier): Response
|
||||
// {
|
||||
// }
|
||||
|
||||
// public function list(Request $request): Response
|
||||
// {
|
||||
// }
|
||||
|
||||
// public function delete(Request $request, $identifier): Response
|
||||
// {
|
||||
// }
|
||||
}
|
@ -133,7 +133,7 @@ final class EntityDomService implements EntityDomServiceInterface
|
||||
/**
|
||||
* {@inheritdoc}
|
||||
*
|
||||
* @see \Infinito\Domain\HtmlManagement\EntityDomServiceInterface::getDomDocument()
|
||||
* @see \Infinito\Domain\DomManagement\EntityDomServiceInterface::getDomDocument()
|
||||
*/
|
||||
public function getDomDocument(EntityInterface $entity): \DOMDocument
|
||||
{
|
||||
@ -147,7 +147,7 @@ final class EntityDomService implements EntityDomServiceInterface
|
||||
if ($value instanceof Collection) {
|
||||
foreach ($value as $valueElement) {
|
||||
$domSubElement = $domElement->createElement('list-element');
|
||||
$this->mappValue($value, $domSubElement);
|
||||
$this->mappValue($valueElement, $domSubElement);
|
||||
}
|
||||
} else {
|
||||
$this->mappValue($value, $domElement);
|
||||
|
Loading…
Reference in New Issue
Block a user