mirror of
https://github.com/Part-DB/Part-DB-server.git
synced 2025-06-29 13:10:06 +02:00
Allow to import category, footprint and manufacturer by giving a string in the CSV file
This commit is contained in:
parent
85ae862381
commit
61e2dde400
12 changed files with 173 additions and 35 deletions
|
@ -92,7 +92,7 @@ abstract class AbstractStructuralDBElement extends AttachmentContainingDBElement
|
|||
/**
|
||||
* @var AbstractStructuralDBElement
|
||||
* @NoneOfItsChildren()
|
||||
* @Groups({"include_parents"})
|
||||
* @Groups({"include_parents", "import"})
|
||||
*/
|
||||
protected $parent = null;
|
||||
|
||||
|
|
|
@ -65,7 +65,7 @@ trait BasicPropertyTrait
|
|||
* @ORM\JoinColumn(name="id_category", referencedColumnName="id", nullable=false)
|
||||
* @Selectable()
|
||||
* @Assert\NotNull(message="validator.select_valid_category")
|
||||
* @Groups({"simple", "extended", "full"})
|
||||
* @Groups({"simple", "extended", "full", "import"})
|
||||
*/
|
||||
protected ?Category $category = null;
|
||||
|
||||
|
@ -74,7 +74,7 @@ trait BasicPropertyTrait
|
|||
* @ORM\ManyToOne(targetEntity="Footprint")
|
||||
* @ORM\JoinColumn(name="id_footprint", referencedColumnName="id")
|
||||
* @Selectable()
|
||||
* @Groups({"simple", "extended", "full"})
|
||||
* @Groups({"simple", "extended", "full", "import"})
|
||||
*/
|
||||
protected ?Footprint $footprint = null;
|
||||
|
||||
|
|
|
@ -56,7 +56,7 @@ trait InstockTrait
|
|||
* @var ?MeasurementUnit the unit in which the part's amount is measured
|
||||
* @ORM\ManyToOne(targetEntity="MeasurementUnit")
|
||||
* @ORM\JoinColumn(name="id_part_unit", referencedColumnName="id", nullable=true)
|
||||
* @Groups({"extended", "full"})
|
||||
* @Groups({"extended", "full", "import"})
|
||||
*/
|
||||
protected ?MeasurementUnit $partUnit = null;
|
||||
|
||||
|
|
|
@ -39,7 +39,7 @@ trait ManufacturerTrait
|
|||
* @ORM\ManyToOne(targetEntity="Manufacturer")
|
||||
* @ORM\JoinColumn(name="id_manufacturer", referencedColumnName="id")
|
||||
* @Selectable()
|
||||
* @Groups({"simple","extended", "full"})
|
||||
* @Groups({"simple","extended", "full", "import"})
|
||||
*/
|
||||
protected ?Manufacturer $manufacturer = null;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue