Fixed orphanRemoval problem with parts collection.

Also ElementPermissionListener was improved, and multiple special cases were unified.
This commit is contained in:
Jan Böhmer 2019-09-17 13:57:40 +02:00
parent 7a9bfdf7f9
commit 3d790db559
4 changed files with 38 additions and 46 deletions

View file

@ -45,7 +45,7 @@ trait InstockTrait
{
/**
* @var ?PartLot[]|Collection A list of part lots where this part is stored
* @ORM\OneToMany(targetEntity="PartLot", mappedBy="part", cascade={"persist", "remove"}, orphanRemoval=false)
* @ORM\OneToMany(targetEntity="PartLot", mappedBy="part", cascade={"persist", "remove"}, orphanRemoval=true)
* @Assert\Valid()
* @ColumnSecurity(type="collection", prefix="lots")
*/