mirror of
https://github.com/Part-DB/Part-DB-server.git
synced 2026-01-13 13:49:33 +00:00
Allow to import attachments and parameters via entity import
This fixes issue #363
This commit is contained in:
parent
bbf7222a6a
commit
06c8e584a4
19 changed files with 73 additions and 58 deletions
|
|
@ -105,7 +105,7 @@ class Project extends AbstractStructuralDBElement
|
|||
* @var Collection<int, ProjectBOMEntry>
|
||||
*/
|
||||
#[Assert\Valid]
|
||||
#[Groups(['extended', 'full'])]
|
||||
#[Groups(['extended', 'full', 'import'])]
|
||||
#[ORM\OneToMany(mappedBy: 'project', targetEntity: ProjectBOMEntry::class, cascade: ['persist', 'remove'], orphanRemoval: true)]
|
||||
#[UniqueObjectCollection(message: 'project.bom_entry.part_already_in_bom', fields: ['part'])]
|
||||
#[UniqueObjectCollection(message: 'project.bom_entry.name_already_in_bom', fields: ['name'])]
|
||||
|
|
@ -118,7 +118,7 @@ class Project extends AbstractStructuralDBElement
|
|||
* @var string|null The current status of the project
|
||||
*/
|
||||
#[Assert\Choice(['draft', 'planning', 'in_production', 'finished', 'archived'])]
|
||||
#[Groups(['extended', 'full', 'project:read', 'project:write'])]
|
||||
#[Groups(['extended', 'full', 'project:read', 'project:write', 'import'])]
|
||||
#[ORM\Column(type: Types::STRING, length: 64, nullable: true)]
|
||||
protected ?string $status = null;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue