Added Doctrine Entities.

This commit is contained in:
Jan Böhmer 2019-02-23 22:41:13 +01:00
parent a0801afdbd
commit 160e826b51
20 changed files with 3400 additions and 1 deletions

View file

@ -0,0 +1,30 @@
<?php
namespace App\Controller;
use App\Entity\Attachment;
use App\Entity\AttachmentType;
use App\Entity\Category;
use App\Entity\StructuralDBElement;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\HttpFoundation\Response;
use Symfony\Component\Routing\Annotation\Route;
class HomepageController extends AbstractController
{
/**
* @Route("/")
*/
function homepage()
{
$repo = $this->getDoctrine()->getRepository(Category::class);
/** @var StructuralDBElement $attachment */
$attachment = $repo->find(1);
dump($attachment, $attachment->getSubelements(false)->toArray());
$response = "";
return $this->render('base.html.twig');
}
}