Fixed some exceptions introduced earlier.

This commit is contained in:
Jan Böhmer 2022-09-21 12:31:32 +02:00
parent 58ada496e4
commit c2c768b151
5 changed files with 6 additions and 10 deletions

View file

@ -78,12 +78,12 @@ class DevicePart extends AbstractDBElement
* @ORM\ManyToOne(targetEntity="Device", inversedBy="parts")
* @ORM\JoinColumn(name="id_device", referencedColumnName="id")
*/
protected Device $device;
protected ?Device $device = null;
/**
* @var Part
* @ORM\ManyToOne(targetEntity="App\Entity\Parts\Part")
* @ORM\JoinColumn(name="id_part", referencedColumnName="id")
*/
protected Part $part;
protected ?Part $part = null;
}

View file

@ -66,7 +66,7 @@ class MeasurementUnit extends AbstractPartsContainingDBElement
* @ORM\Column(type="string", name="unit", nullable=true)
* @Assert\Length(max=10)
*/
protected string $unit;
protected ?string $unit = null;
/**
* @var bool Determines if the amount value associated with this unit should be treated as integer.

View file

@ -85,7 +85,7 @@ trait OrderTrait
*
* @ColumnSecurity(prefix="order", type="object")
*/
protected Orderdetail $order_orderdetail;
protected ?Orderdetail $order_orderdetail = null;
/**
* Get the selected order orderdetails of this part.

View file

@ -78,7 +78,7 @@ class Currency extends AbstractStructuralDBElement
* @ORM\Column(type="string")
* @Assert\Currency()
*/
protected string $iso_code;
protected string $iso_code = "";
/**
* @ORM\OneToMany(targetEntity="Currency", mappedBy="parent", cascade={"persist"})