Explorar el Código

Script d'import

packProduct
Fab hace 3 años
padre
commit
cefea6e520
Se han modificado 2 ficheros con 22 adiciones y 1 borrados
  1. +1
    -0
      CaracoleBundle
  2. +21
    -1
      Model/Product/ProductCategoryModel.php

+ 1
- 0
CaracoleBundle Ver fichero

@@ -0,0 +1 @@
CaracoleBundle

+ 21
- 1
Model/Product/ProductCategoryModel.php Ver fichero

@@ -9,11 +9,13 @@ use Lc\CaracoleBundle\Doctrine\Extension\FilterSectionInterface;
use Lc\CaracoleBundle\Model\Section\SectionInterface;
use Lc\SovBundle\Doctrine\Extension\TreeInterface;
use Lc\SovBundle\Doctrine\Pattern\AbstractFullEntity;
use Lc\SovBundle\Model\File\FileInterface;

/**
* @ORM\MappedSuperclass()
*/
abstract class ProductCategoryModel extends AbstractFullEntity implements TreeInterface, FilterSectionInterface, ProductCategoryInterface
abstract class ProductCategoryModel extends AbstractFullEntity implements TreeInterface, FilterSectionInterface,
ProductCategoryInterface
{
/**
* @ORM\ManyToOne(targetEntity="Lc\CaracoleBundle\Model\Section\SectionInterface")
@@ -42,6 +44,12 @@ abstract class ProductCategoryModel extends AbstractFullEntity implements TreeIn
*/
protected $saleStatus;

/**
* @ORM\ManyToOne(targetEntity="Lc\SovBundle\Model\File\FileInterface", cascade={"persist", "remove"})
*/
protected $image;


public function __construct()
{
$this->childrens = new ArrayCollection();
@@ -181,4 +189,16 @@ abstract class ProductCategoryModel extends AbstractFullEntity implements TreeIn
return $this;
}

public function getImage(): ?FileInterface
{
return $this->image;
}

public function setImage(?FileInterface $image): self
{
$this->image = $image;

return $this;
}

}

Cargando…
Cancelar
Guardar