From c060dff87337c95a891e99ca2f9779e7c2aaf4d7 Mon Sep 17 00:00:00 2001 From: Kevin Frantz Date: Sun, 4 Nov 2018 12:00:35 +0100 Subject: [PATCH] Optimized database schema --- application/src/Entity/Source/AbstractSource.php | 3 +-- .../src/Entity/Source/Data/AbstractDataSource.php | 13 +++++++++++-- application/src/Entity/Source/Data/NameSource.php | 2 +- application/src/Entity/Source/Data/UserSource.php | 2 +- application/src/Entity/User.php | 6 +++--- 5 files changed, 17 insertions(+), 9 deletions(-) diff --git a/application/src/Entity/Source/AbstractSource.php b/application/src/Entity/Source/AbstractSource.php index 96c5d93..cbec1ba 100644 --- a/application/src/Entity/Source/AbstractSource.php +++ b/application/src/Entity/Source/AbstractSource.php @@ -19,12 +19,11 @@ use App\Entity\Source\Collection\TreeCollectionSourceInterface; /** * @author kevinfrantz * - * @see https://www.doctrine-project.org/projects/doctrine-orm/en/2.6/reference/inheritance-mapping.html * @ORM\Entity * @ORM\Table(name="source") * @ORM\InheritanceType("JOINED") * @ORM\DiscriminatorColumn(name="discr", type="string") - * @ORM\DiscriminatorMap({"user" = "UserSource","name" = "NameSource","collection" = "App\Entity\Source\Collection\AbstractCollectionSource","operation"="App\Entity\Source\Operation\AbstractOperation"}) + * @ORM\DiscriminatorMap({"data" = "App\Entity\Source\Data\AbstractDataSource", "collection" = "App\Entity\Source\Collection\AbstractCollectionSource","operation"="App\Entity\Source\Operation\AbstractOperation"}) */ abstract class AbstractSource extends AbstractEntity implements SourceInterface { diff --git a/application/src/Entity/Source/Data/AbstractDataSource.php b/application/src/Entity/Source/Data/AbstractDataSource.php index 176ca44..1b137d7 100644 --- a/application/src/Entity/Source/Data/AbstractDataSource.php +++ b/application/src/Entity/Source/Data/AbstractDataSource.php @@ -1,9 +1,18 @@