src/Entity/System/Warehouse.php line 14

Open in your IDE?
  1. <?php
  2. namespace App\Entity\System;
  3. use Doctrine\ORM\Mapping as ORM;
  4. /**
  5.  * Warehouse
  6.  *
  7.  * @ORM\Table(name="ps_warehouse")
  8.  *
  9.  * @ORM\Entity(repositoryClass="App\Repository\System\WarehouseRepository")
  10.  */
  11. class Warehouse
  12. {
  13.     public const DEFAULT_WAREHOUSE_ID 1;
  14.     public const TELLMEGEN_WAREHOUSE_ID 2;
  15.     public const FR_001 3// S71 Octopia
  16.     public const ES_003 4// S74 tyres
  17.     public const IT_001 5// S72 watches
  18.     public const CZ_001 6// S83 Parfums 2
  19.     public const PL_001 7// S91 informatica 4
  20.     public const ES_004 8// D06 Jamones Linaje negro
  21.     public const ES_005 9// D13 Zapatillas Timpers
  22.     public const NL_001 10// S94
  23.     public const ES_006 11// D07 Soportes Meollo
  24.     public const ES_007 12// LG
  25.     public const ES_008 13// M01 Perfumes 5
  26.     public const ES_009 14// D20
  27.     public const DE_001 15// M02
  28.     public const ES_010 16// M06
  29.     public const ES_011 17// M08
  30.     public const ES_012 18// M07
  31.     public const ES_013 19// M10_PAE_2 Aigostar
  32.     public const ES_015 20;
  33.     public const ES_016 21// 2core
  34.     public const ES_014 22// M12
  35.     public const CN_001 23// D25 - Kerry
  36.     public const REF_BY_ID = [
  37.         self::DEFAULT_WAREHOUSE_ID => 'ES_001',
  38.         self::TELLMEGEN_WAREHOUSE_ID => 'ES_002',
  39.         self::FR_001 => 'FR_001',
  40.         self::ES_003 => 'ES_003',
  41.         self::IT_001 => 'IT_001',
  42.         self::CZ_001 => 'CZ_001',
  43.         self::PL_001 => 'PL_001',
  44.         self::ES_004 => 'ES_004',
  45.         self::ES_005 => 'ES_005',
  46.         self::ES_006 => 'ES_006',
  47.         self::ES_007 => 'ES_007',
  48.         self::ES_008 => 'ES_008',
  49.         self::ES_009 => 'ES_009',
  50.         self::DE_001 => 'DE_001',
  51.         self::NL_001 => 'NL_001',
  52.         self::ES_010 => 'ES_010',
  53.         self::ES_011 => 'ES_011',
  54.         self::ES_012 => 'ES_012',
  55.         self::ES_013 => 'ES_013',
  56.         self::ES_015 => 'ES_015',
  57.         self::ES_016 => 'ES_016',
  58.         self::ES_014 => 'ES_014',
  59.         self::CN_001 => 'CN_001',
  60.     ];
  61.     /**
  62.      * @var int
  63.      *
  64.      * @ORM\Column(name="id", type="integer")
  65.      *
  66.      * @ORM\Id
  67.      *
  68.      * @ORM\GeneratedValue(strategy="AUTO")
  69.      */
  70.     private $id;
  71.     /**
  72.      * @var string
  73.      *
  74.      * @ORM\Column(type="string", length=100)
  75.      */
  76.     private $name;
  77.     /**
  78.      * @var string
  79.      *
  80.      * @ORM\Column(type="string")
  81.      */
  82.     private $reference;
  83.     /**
  84.      * @var string
  85.      *
  86.      * @ORM\Column(type="string", length=2)
  87.      */
  88.     private $country;
  89.     /**
  90.      * @var bool
  91.      *
  92.      * @ORM\Column(type="boolean", options={"default": 0})
  93.      */
  94.     private $orderCancellationAllowed;
  95.     /**
  96.      * @return int
  97.      */
  98.     public function getId(): int
  99.     {
  100.         return $this->id;
  101.     }
  102.     /**
  103.      * @param int $id
  104.      *
  105.      * @return Warehouse
  106.      */
  107.     public function setId(int $id): self
  108.     {
  109.         $this->id $id;
  110.         return $this;
  111.     }
  112.     /**
  113.      * @return string
  114.      */
  115.     public function getName(): string
  116.     {
  117.         return $this->name;
  118.     }
  119.     /**
  120.      * @param string $name
  121.      *
  122.      * @return Warehouse
  123.      */
  124.     public function setName(string $name): self
  125.     {
  126.         $this->name $name;
  127.         return $this;
  128.     }
  129.     /**
  130.      * @return string
  131.      */
  132.     public function getReference(): string
  133.     {
  134.         return $this->reference;
  135.     }
  136.     /**
  137.      * @param string $reference
  138.      *
  139.      * @return Warehouse
  140.      */
  141.     public function setReference(string $reference): self
  142.     {
  143.         $this->reference $reference;
  144.         return $this;
  145.     }
  146.     /**
  147.      * @return string
  148.      */
  149.     public function getCountry(): string
  150.     {
  151.         return $this->country;
  152.     }
  153.     /**
  154.      * @param string $country
  155.      *
  156.      * @return Warehouse
  157.      */
  158.     public function setCountry(string $country): self
  159.     {
  160.         $this->country $country;
  161.         return $this;
  162.     }
  163.     public function isOrderCancellationAllowed(): bool
  164.     {
  165.         return $this->orderCancellationAllowed;
  166.     }
  167.     public function setOrderCancellationAllowed(bool $orderCancellationAllowed): Warehouse
  168.     {
  169.         $this->orderCancellationAllowed $orderCancellationAllowed;
  170.         return $this;
  171.     }
  172. }