Fixes nette3
This commit is contained in:
@@ -4,6 +4,8 @@ namespace App\Model\Database\Entity;
|
||||
|
||||
use Doctrine\ORM\Mapping as ORM;
|
||||
use App\Model\Database\Entity\Attributes\TId;
|
||||
use Doctrine\Common\Collections\ArrayCollection;
|
||||
use Doctrine\Common\Collections\Collection;
|
||||
|
||||
/**
|
||||
* @ORM\Entity
|
||||
@@ -17,14 +19,14 @@ class Dictionary extends AbstractEntity
|
||||
{
|
||||
$this->name = $name;
|
||||
$this->fullName = $fullname;
|
||||
$this->translations = new \Doctrine\Common\Collections\ArrayCollection();
|
||||
$this->translations = new ArrayCollection();
|
||||
}
|
||||
|
||||
/**
|
||||
* @ORM\OneToMany(targetEntity="App\Model\Database\Entity\Translation", mappedBy="dictionary", cascade={"persist"})
|
||||
* @var Article[]|\Doctrine\Common\Collections\ArrayCollection
|
||||
* @var Collection&iterable<Translation>
|
||||
*/
|
||||
protected $translations;
|
||||
protected Collection $translations;
|
||||
|
||||
public function getTranslations()
|
||||
{
|
||||
@@ -33,14 +35,16 @@ class Dictionary extends AbstractEntity
|
||||
|
||||
|
||||
/**
|
||||
* @ORM\ManyToOne(targetEntity="Language", inversedBy="lang1_dicionaries")
|
||||
* @ORM\ManyToOne(targetEntity="Language", inversedBy="dictionaries1")
|
||||
* @ORM\JoinColumn(name="lang1_id", referencedColumnName="id")
|
||||
*/
|
||||
protected $lang1;
|
||||
protected ?Language $lang1;
|
||||
|
||||
/**
|
||||
* @ORM\ManyToOne(targetEntity="Language", inversedBy="lang2_dicionaries")
|
||||
* @ORM\ManyToOne(targetEntity="Language", inversedBy="dictionaries2")
|
||||
* @ORM\JoinColumn(name="lang2_id", referencedColumnName="id")
|
||||
*/
|
||||
protected $lang2;
|
||||
protected ?Language $lang2;
|
||||
|
||||
/**
|
||||
* @ORM\Column(type="string")
|
||||
|
||||
@@ -4,6 +4,7 @@ namespace App\Model\Database\Entity;
|
||||
|
||||
use Doctrine\ORM\Mapping as ORM;
|
||||
use App\Model\Database\Entity\Attributes\TId;
|
||||
use Doctrine\Common\Collections\Collection;
|
||||
|
||||
/**
|
||||
* @ORM\Entity
|
||||
@@ -40,14 +41,16 @@ class Language extends AbstractEntity
|
||||
}
|
||||
|
||||
/*
|
||||
* @var Collection&iterable<Dictionary>
|
||||
* @ORM\OneToMany(targetEntity="Dictionary", mappedBy="language")
|
||||
*/
|
||||
protected $dictionaries1;
|
||||
protected Collection $dictionaries1;
|
||||
|
||||
/*
|
||||
* @var Collection&iterable<Dictionary>
|
||||
* @ORM\OneToMany(targetEntity="Dictionary", mappedBy="language")
|
||||
*/
|
||||
protected $dictionaries2;
|
||||
protected Collection $dictionaries2;
|
||||
|
||||
}
|
||||
|
||||
|
||||
@@ -26,16 +26,94 @@ class Term extends AbstractEntity
|
||||
*/
|
||||
protected $dictionary;
|
||||
|
||||
/**
|
||||
* Get id
|
||||
*
|
||||
* @return integer
|
||||
/**
|
||||
* @ORM\Column(type="string")
|
||||
*/
|
||||
public function getId()
|
||||
protected $string1;
|
||||
|
||||
/**
|
||||
* @ORM\Column(type="string")
|
||||
*/
|
||||
protected $string2;
|
||||
|
||||
|
||||
/**
|
||||
* @ORM\ManyToOne(targetEntity="Suffix")
|
||||
*/
|
||||
protected $suffix1;
|
||||
|
||||
/**
|
||||
* @ORM\ManyToOne(targetEntity="Suffix")
|
||||
*/
|
||||
protected $suffix2;
|
||||
|
||||
|
||||
/**
|
||||
* @ORM\ManyToOne(targetEntity="DictType")
|
||||
*/
|
||||
protected $type;
|
||||
|
||||
/**
|
||||
* @ORM\ManyToMany(targetEntity="Pronunciation", inversedBy="terms")
|
||||
* @ORM\JoinTable(name="terms_pronunciations")
|
||||
*/
|
||||
protected $pronunciations;
|
||||
|
||||
public function setType(DictType $type)
|
||||
{
|
||||
return $this->id;
|
||||
$this->type = $type;
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* @ORM\Column(type="string",nullable=true)
|
||||
*/
|
||||
protected $member;
|
||||
|
||||
public function setMember($member)
|
||||
{
|
||||
$this->member = $member;
|
||||
return $this;
|
||||
}
|
||||
|
||||
public function getMember()
|
||||
{
|
||||
return $this->member;
|
||||
}
|
||||
|
||||
/**
|
||||
* @ORM\Column(type="smallint",nullable=true)
|
||||
*/
|
||||
protected $order2;
|
||||
|
||||
/**
|
||||
* @ORM\Column(type="json_array",nullable=true)
|
||||
*/
|
||||
protected $flags;
|
||||
|
||||
public function getFlags()
|
||||
{
|
||||
return $this->flags;
|
||||
}
|
||||
|
||||
public function setFlags($flags)
|
||||
{
|
||||
$this->flags = $flags;
|
||||
return $this;
|
||||
}
|
||||
|
||||
public function getOrder2()
|
||||
{
|
||||
return $this->order2;
|
||||
}
|
||||
|
||||
public function setOrder2($order2)
|
||||
{
|
||||
$this->order2 = $order2;
|
||||
return $this;
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user