src/Entity/System/Tag.php line 21

Open in your IDE?
  1. <?php
  2. namespace App\Entity\System;
  3. use Doctrine\ORM\Mapping as ORM;
  4. /**
  5.  * Tag
  6.  *
  7.  * @ORM\Table(name="ps_tag", indexes={
  8.  *
  9.  *     @ORM\Index(name="active", columns={"active"}),
  10.  *     @ORM\Index(name="ps_tag_deleted_active_index", columns={"deleted", "active"}),
  11.  *     @ORM\Index(name="deleted", columns={"deleted"}),
  12.  *     @ORM\Index(name="name", columns={"name"}),
  13.  *     @ORM\Index(name="id_tag", columns={"id_tag"})
  14.  * })
  15.  *
  16.  * @ORM\Entity(repositoryClass="App\Repository\System\TagRepository")
  17.  */
  18. class Tag
  19. {
  20.     public const OUTLET_TAG_ID 20;
  21.     public const TELESHOPPING_TAG_ID 28;
  22.     public const CHRISTMAS_TAG_ID 34;
  23.     public const ORIGINAL_GIFT_TAG_ID 66;
  24.     public const BLACK_FRIDAY_TAG_ID 72;
  25.     public const HOTDEAL_TAG_ID 85;
  26.     public const VALENTINES_DAY 35;
  27.     public const EURO_2024_TAG_ID 93;
  28.     public const ID_WINNING_PRODUCTS 96// TODO CAMBIAR CUANDO WINNIG PRODUCTS ESTÉ ACTIVO
  29.     public const ID_B2B_DEALS 96;
  30.     public const COVID19_TAG_ID 99;
  31.     public const RENEWED_TAG_ID 100;
  32.     public const BACK_TO_SCHOOL_TAG_ID 38;
  33.     public const TAG_BLACK_FRIDAY_TEXT 'Black Friday';
  34.     public const TAG_HOTDEALS_TEXT 'hot deals';
  35.     public const TAG_RENEWED_TEXT 'Renewed';
  36.     public const ID_TAG_ACADEMY_ECOMMERCE 10001;
  37.     public const ID_TAG_ACADEMY_MARKETPLACE 10002;
  38.     public const ID_TAG_ACADEMY_MARKETING 10003;
  39.     public const ECOMMERCE = [
  40.         'name' => 'ECOMMERCE',
  41.         'color' => '#F28800',
  42.     ];
  43.     public const MARKETPLACE = [
  44.         'name' => 'MARKETPLACE',
  45.         'color' => '#73AF00',
  46.     ];
  47.     public const MARKETING = [
  48.         'name' => 'MARKETING',
  49.         'color' => '#F6BB00',
  50.     ];
  51.     /**
  52.      * @var int
  53.      *
  54.      * @ORM\Column(name="id_tag", type="integer")
  55.      *
  56.      * @ORM\Id
  57.      */
  58.     private $id;
  59.     /**
  60.      * @ORM\Id()
  61.      *
  62.      * @var Language
  63.      *
  64.      * @ORM\ManyToOne(targetEntity="App\Entity\System\Language")
  65.      *
  66.      * @ORM\JoinColumn(name="id_lang", referencedColumnName="id_lang")
  67.      */
  68.     private $language;
  69.     /**
  70.      * @var string|null
  71.      *
  72.      * @ORM\Column(type="string", length=255)
  73.      */
  74.     private $name;
  75.     /**
  76.      * @var string|null
  77.      *
  78.      * @ORM\Column(type="string", length=255)
  79.      */
  80.     private $linkRewrite;
  81.     /**
  82.      * @var string|null
  83.      *
  84.      * @ORM\Column(type="string", length=255, nullable=true)
  85.      */
  86.     private $alt;
  87.     /**
  88.      * @var string|null
  89.      *
  90.      * @ORM\Column(type="text", nullable=true)
  91.      */
  92.     private $description;
  93.     /**
  94.      * @var int
  95.      *
  96.      * @ORM\Column(type="integer", name="Book_keeper", options={"default" : 0})
  97.      */
  98.     private $bookKeeper;
  99.     /**
  100.      * @var bool
  101.      *
  102.      * @ORM\Column(name="active", type="boolean", length=4)
  103.      */
  104.     private $active;
  105.     /**
  106.      * @var bool
  107.      *
  108.      * @ORM\Column(name="deleted", type="boolean", length=4, options={"default" : 0})
  109.      */
  110.     private $deleted;
  111.     /**
  112.      * @return mixed
  113.      */
  114.     public function getId()
  115.     {
  116.         return $this->id;
  117.     }
  118.     /**
  119.      * @param mixed $id
  120.      *
  121.      * @return Tag
  122.      */
  123.     public function setId(int $id): Tag
  124.     {
  125.         $this->id $id;
  126.         return $this;
  127.     }
  128.     /**
  129.      * @return Language
  130.      */
  131.     public function getLanguage(): Language
  132.     {
  133.         return $this->language;
  134.     }
  135.     /**
  136.      * @param Language $language
  137.      *
  138.      * @return Tag
  139.      */
  140.     public function setLanguage(Language $language): Tag
  141.     {
  142.         $this->language $language;
  143.         return $this;
  144.     }
  145.     /**
  146.      * @return string|null
  147.      */
  148.     public function getName(): ?string
  149.     {
  150.         return $this->name;
  151.     }
  152.     /**
  153.      * @param string|null $name
  154.      *
  155.      * @return Tag
  156.      */
  157.     public function setName(string $name): Tag
  158.     {
  159.         $this->name $name;
  160.         return $this;
  161.     }
  162.     /**
  163.      * @return string|null
  164.      */
  165.     public function getLinkRewrite(): ?string
  166.     {
  167.         return $this->linkRewrite;
  168.     }
  169.     /**
  170.      * @param string|null $linkRewrite
  171.      *
  172.      * @return Tag
  173.      */
  174.     public function setLinkRewrite(string $linkRewrite): Tag
  175.     {
  176.         $this->linkRewrite $linkRewrite;
  177.         return $this;
  178.     }
  179.     /**
  180.      * @return string|null
  181.      */
  182.     public function getAlt(): ?string
  183.     {
  184.         return $this->alt;
  185.     }
  186.     /**
  187.      * @param string|null $alt
  188.      *
  189.      * @return Tag
  190.      */
  191.     public function setAlt(string $alt): Tag
  192.     {
  193.         $this->alt $alt;
  194.         return $this;
  195.     }
  196.     /**
  197.      * @return string|null
  198.      */
  199.     public function getDescription(): ?string
  200.     {
  201.         return $this->description;
  202.     }
  203.     /**
  204.      * @param string|null $description
  205.      *
  206.      * @return Tag
  207.      */
  208.     public function setDescription(string $description): Tag
  209.     {
  210.         $this->description $description;
  211.         return $this;
  212.     }
  213.     /**
  214.      * @return int
  215.      */
  216.     public function getBookKeeper(): int
  217.     {
  218.         return $this->bookKeeper;
  219.     }
  220.     /**
  221.      * @param int $bookKeeper
  222.      *
  223.      * @return Tag
  224.      */
  225.     public function setBookKeeper(int $bookKeeper): Tag
  226.     {
  227.         $this->bookKeeper $bookKeeper;
  228.         return $this;
  229.     }
  230.     /**
  231.      * @return bool
  232.      */
  233.     public function isActive(): bool
  234.     {
  235.         return $this->active;
  236.     }
  237.     public function setActive(bool $active): Tag
  238.     {
  239.         $this->active $active;
  240.         return $this;
  241.     }
  242.     /**
  243.      * @return bool
  244.      */
  245.     public function isDeleted(): bool
  246.     {
  247.         return $this->deleted;
  248.     }
  249.     /**
  250.      * @param bool $deleted
  251.      *
  252.      * @return Tag
  253.      */
  254.     public function setDeleted(bool $deleted): Tag
  255.     {
  256.         $this->deleted $deleted;
  257.         return $this;
  258.     }
  259. }