From e9f4931a5eb5caf5e0155e3f8530a8f0f31dbf89 Mon Sep 17 00:00:00 2001 From: Kevin Frantz Date: Sat, 5 Jan 2019 09:50:47 +0100 Subject: [PATCH] Removed deprecated node parts --- application/src/Controller/NodeController.php | 70 ------------------- application/templates/node/node.html.twig | 9 --- .../templates/node/structure/_list.html.twig | 13 ---- .../templates/node/view/standard.html.twig | 34 --------- 4 files changed, 126 deletions(-) delete mode 100644 application/src/Controller/NodeController.php delete mode 100644 application/templates/node/node.html.twig delete mode 100644 application/templates/node/structure/_list.html.twig delete mode 100644 application/templates/node/view/standard.html.twig diff --git a/application/src/Controller/NodeController.php b/application/src/Controller/NodeController.php deleted file mode 100644 index 9542866..0000000 --- a/application/src/Controller/NodeController.php +++ /dev/null @@ -1,70 +0,0 @@ -loadEntityById($id); - $view = $this->view($relation, 200) - ->setTemplate('node/view/standard.html.twig') - ->setTemplateVar('node'); - - return $this->handleView($view); - } - - /** - * @Route("/node/{id}/law.{_format}", defaults={"_format"="html"}) - */ - public function law(int $id): RedirectResponse - { - $lawId = $this->loadEntityById($id)->getLaw()->getId(); - - return $this->redirectToRouteById('app_law_show', $lawId); - } - - /** - * @Route("/node/{id}/parents.{_format}", defaults={"_format"="html"}) - */ - public function parents(int $id): Response - { - /* - * @todo Implement - */ - } - - /** - * @Route("/node/{id}/childs.{_format}", defaults={"_format"="html"}) - */ - public function childs(int $id): Response - { - /* - * @todo Implement - */ - } - - protected function setEntityName(): void - { - $this->entityName = Relation::class; - } -} diff --git a/application/templates/node/node.html.twig b/application/templates/node/node.html.twig deleted file mode 100644 index 775430b..0000000 --- a/application/templates/node/node.html.twig +++ /dev/null @@ -1,9 +0,0 @@ -{% extends "frames/default.html.twig" %} -{% block title %} - {% trans %} - Node - {% endtrans %} -{% endblock %} -{% block sub_navigation %} - {% include 'frames/structure/navbar/node_sub.html.twig'%} -{% endblock %} \ No newline at end of file diff --git a/application/templates/node/structure/_list.html.twig b/application/templates/node/structure/_list.html.twig deleted file mode 100644 index 8f75ea5..0000000 --- a/application/templates/node/structure/_list.html.twig +++ /dev/null @@ -1,13 +0,0 @@ -{% if nodeList.isEmpty %} -{% trans %} -This list doesn't contain elements. -{% endtrans %} -{% else %} - -{% endif %} \ No newline at end of file diff --git a/application/templates/node/view/standard.html.twig b/application/templates/node/view/standard.html.twig deleted file mode 100644 index a8d440d..0000000 --- a/application/templates/node/view/standard.html.twig +++ /dev/null @@ -1,34 +0,0 @@ -{% extends "node/node.html.twig" %} -{% block content %} -

- {% trans %} - Node - {% endtrans %} - # - {{ node.id }} -

-{% trans %} -Manages -{% endtrans %} - {% trans with {'%node.source.id%':node.source.id}%} - source #%node.source.id% {% endtrans %} - -. -

- {% trans %} - Relatives - {% endtrans %} -

-

- {% trans %} - First Generation Parents - {% endtrans %} -

-{% include "node/structure/_list.html.twig" with {'nodeList':node.parents}%} -

- {% trans %} - First Generation Childs - {% endtrans %} -

-{% include "node/structure/_list.html.twig" with {'nodeList':node.childs}%} -{% endblock %}