src/Aviatur/MpaBundle/Entity/Provider.php line 13

Open in your IDE?
  1. <?php
  2. namespace Aviatur\MpaBundle\Entity;
  3. use Doctrine\ORM\Mapping as ORM;
  4. /**
  5.  * Provider.
  6.  *
  7.  * @ORM\Table(name="provider", indexes={@ORM\Index(name="IDX_6BB211CA91BE1328", columns={"product_type_id"})})
  8.  * @ORM\Entity(repositoryClass="Aviatur\MpaBundle\Entity\ProviderRepository")
  9.  */
  10. class Provider
  11. {
  12.     /**
  13.      * @var int
  14.      *
  15.      * @ORM\Column(name="id", type="integer", nullable=false)
  16.      * @ORM\Id
  17.      * @ORM\GeneratedValue(strategy="NONE")
  18.      */
  19.     private $id;
  20.     /**
  21.      * @var int
  22.      *
  23.      * @ORM\Column(name="providerIdentifier", type="integer", precision=10, scale=0, nullable=false)
  24.      */
  25.     private $provideridentifier;
  26.     /**
  27.      * @var string
  28.      *
  29.      * @ORM\Column(name="name", type="string", length=500, nullable=false)
  30.      */
  31.     private $name;
  32.     /**
  33.      *
  34.      * @ORM\ManyToOne(targetEntity="Aviatur\GeneralBundle\Entity\PaymentType", inversedBy="provider")
  35.      * @ORM\JoinColumns({
  36.      *   @ORM\JoinColumn(name="payment_type_id", referencedColumnName="id")
  37.      * })
  38.      */
  39.     private ?\Aviatur\GeneralBundle\Entity\PaymentType $paymentType null;
  40.     /**
  41.      *
  42.      * @ORM\ManyToOne(targetEntity="ProductType", inversedBy="provider")
  43.      * @ORM\JoinColumns({
  44.      *   @ORM\JoinColumn(name="product_type_id", referencedColumnName="id")
  45.      * })
  46.      */
  47.     private ?\Aviatur\MpaBundle\Entity\ProductType $productType null;
  48.     /**
  49.      * @ORM\OneToMany(targetEntity="Aviatur\CarBundle\Entity\ConfigCarAgency", mappedBy="provider", cascade={"all"})
  50.      */
  51.     private $configCarAgency;
  52.     /**
  53.      * @ORM\OneToMany(targetEntity="Aviatur\FlightBundle\Entity\ConfigFlightAgency", mappedBy="provider", cascade={"all"})
  54.      */
  55.     private $configFlightAgency;
  56.     /**
  57.      * @ORM\OneToMany(targetEntity="Aviatur\FlightBundle\Entity\ConfigFlightCalendarAgency", mappedBy="provider", cascade={"all"})
  58.      */
  59.     private $configFlightCalendarAgency;
  60.     /**
  61.      * @ORM\OneToMany(targetEntity="Aviatur\HotelBundle\Entity\ConfigHotelAgency", mappedBy="provider", cascade={"all"})
  62.      */
  63.     private $configHotelAgency;
  64.     /**
  65.      * @ORM\OneToMany(targetEntity="Aviatur\PackageBundle\Entity\ConfigPackageAgency", mappedBy="provider", cascade={"all"})
  66.      */
  67.     private $configPackageAgency;
  68.     /**
  69.      * @ORM\OneToMany(targetEntity="Aviatur\InsuranceBundle\Entity\ConfigInsuranceAgency", mappedBy="provider", cascade={"all"})
  70.      */
  71.     private $configInsuranceAgency;
  72.     /**
  73.      * @ORM\OneToMany(targetEntity="Aviatur\BusBundle\Entity\ConfigBusAgency", mappedBy="provider", cascade={"all"})
  74.      */
  75.     private $configBusAgency;
  76.     /**
  77.      * @ORM\OneToMany(targetEntity="Aviatur\GeneralBundle\Entity\OrderProduct", mappedBy="provider", cascade={"all"})
  78.      */
  79.     private $orderProduct;
  80.     /**
  81.      * @ORM\OneToMany(targetEntity="Aviatur\CruiserBundle\Entity\ConfigCruiserAgency", mappedBy="provider", cascade={"all"})
  82.      */
  83.     private $configCruiserAgency;
  84.     /**
  85.      * @ORM\OneToMany(targetEntity="Aviatur\HelicopterBundle\Entity\ConfigHelicopterAgency", mappedBy="provider", cascade={"all"})
  86.      */
  87.     private $configHelicopterAgency;
  88.     /**
  89.      * @ORM\OneToMany(targetEntity="Aviatur\FlightBundle\Entity\ConfigFlightAgencyActivityLog", mappedBy="provider", cascade={"all"})
  90.      */
  91.     private $configFlightAgencyActivityLog;
  92.     public function __toString()
  93.     {
  94.         $return $this->getName().'('.$this->getProvideridentifier().')';
  95.         return $return;
  96.     }
  97.     /**
  98.      * Constructor.
  99.      */
  100.     public function __construct()
  101.     {
  102.         $this->orderProduct = new \Doctrine\Common\Collections\ArrayCollection();
  103.         $this->configCarAgency = new \Doctrine\Common\Collections\ArrayCollection();
  104.         $this->configFlightAgency = new \Doctrine\Common\Collections\ArrayCollection();
  105.         $this->configFlightCalendarAgency = new \Doctrine\Common\Collections\ArrayCollection();
  106.         $this->configHotelAgency = new \Doctrine\Common\Collections\ArrayCollection();
  107.         $this->configPackageAgency = new \Doctrine\Common\Collections\ArrayCollection();
  108.         $this->configInsuranceAgency = new \Doctrine\Common\Collections\ArrayCollection();
  109.         $this->configBusAgency = new \Doctrine\Common\Collections\ArrayCollection();
  110.         $this->configCruiserAgency = new \Doctrine\Common\Collections\ArrayCollection();
  111.         $this->configHelicopterAgency = new \Doctrine\Common\Collections\ArrayCollection();
  112.         $this->configFlightAgencyActivityLog = new \Doctrine\Common\Collections\ArrayCollection();
  113.     }
  114.     /**
  115.      * Set id.
  116.      *
  117.      * @param int $id
  118.      *
  119.      * @return Provider
  120.      */
  121.     public function setId($id)
  122.     {
  123.         $this->id $id;
  124.         return $this;
  125.     }
  126.     /**
  127.      * Get id.
  128.      *
  129.      * @return int
  130.      */
  131.     public function getId()
  132.     {
  133.         return $this->id;
  134.     }
  135.     /**
  136.      * Set provideridentifier.
  137.      *
  138.      * @param int $providerIdentifier
  139.      *
  140.      * @return Provider
  141.      */
  142.     public function setProvideridentifier($provideridentifier)
  143.     {
  144.         $this->provideridentifier $provideridentifier;
  145.         return $this;
  146.     }
  147.     /**
  148.      * Get provideridentifier.
  149.      *
  150.      * @return int
  151.      */
  152.     public function getProvideridentifier()
  153.     {
  154.         return $this->provideridentifier;
  155.     }
  156.     /**
  157.      * Set name.
  158.      *
  159.      * @param string $name
  160.      *
  161.      * @return Provider
  162.      */
  163.     public function setName($name)
  164.     {
  165.         $this->name $name;
  166.         return $this;
  167.     }
  168.     /**
  169.      * Get name.
  170.      *
  171.      * @return string
  172.      */
  173.     public function getName()
  174.     {
  175.         return $this->name;
  176.     }
  177.     /**
  178.      * Set paymentType.
  179.      *
  180.      * @param \Aviatur\GeneralBundle\Entity\PaymentType $paymentType
  181.      *
  182.      * @return Provider
  183.      */
  184.     public function setPaymentType(\Aviatur\GeneralBundle\Entity\PaymentType $paymentType null)
  185.     {
  186.         $this->paymentType $paymentType;
  187.         return $this;
  188.     }
  189.     /**
  190.      * Get paymentType.
  191.      *
  192.      * @return \Aviatur\GeneralBundle\Entity\PaymentType
  193.      */
  194.     public function getPaymentType()
  195.     {
  196.         return $this->paymentType;
  197.     }
  198.     /**
  199.      * Set productType.
  200.      *
  201.      * @param \Aviatur\MpaBundle\Entity\ProductType $productType
  202.      *
  203.      * @return Provider
  204.      */
  205.     public function setProductType(\Aviatur\MpaBundle\Entity\ProductType $productType null)
  206.     {
  207.         $this->productType $productType;
  208.         return $this;
  209.     }
  210.     /**
  211.      * Get productType.
  212.      *
  213.      * @return \Aviatur\MpaBundle\Entity\ProductType
  214.      */
  215.     public function getProductType()
  216.     {
  217.         return $this->productType;
  218.     }
  219.     /**
  220.      * Add configCarAgency.
  221.      *
  222.      * @return Provider
  223.      */
  224.     public function addConfigCarAgency(\Aviatur\CarBundle\Entity\ConfigCarAgency $configCarAgency)
  225.     {
  226.         $this->configCarAgency[] = $configCarAgency;
  227.         return $this;
  228.     }
  229.     /**
  230.      * Remove configCarAgency.
  231.      */
  232.     public function removeConfigCarAgency(\Aviatur\CarBundle\Entity\ConfigCarAgency $configCarAgency)
  233.     {
  234.         $this->configCarAgency->removeElement($configCarAgency);
  235.     }
  236.     /**
  237.      * Get configCarAgency.
  238.      *
  239.      * @return \Doctrine\Common\Collections\Collection
  240.      */
  241.     public function getConfigCarAgency()
  242.     {
  243.         return $this->configCarAgency;
  244.     }
  245.     /**
  246.      * Add configFlightAgency.
  247.      *
  248.      * @return Provider
  249.      */
  250.     public function addConfigFlightAgency(\Aviatur\FlightBundle\Entity\ConfigFlightAgency $configFlightAgency)
  251.     {
  252.         $this->configFlightAgency[] = $configFlightAgency;
  253.         return $this;
  254.     }
  255.     /**
  256.      * Remove configFlightAgency.
  257.      */
  258.     public function removeConfigFlightAgency(\Aviatur\FlightBundle\Entity\ConfigFlightAgency $configFlightAgency)
  259.     {
  260.         $this->configFlightAgency->removeElement($configFlightAgency);
  261.     }
  262.     /**
  263.      * Get configFlightAgency.
  264.      *
  265.      * @return \Doctrine\Common\Collections\Collection
  266.      */
  267.     public function getConfigFlightAgency()
  268.     {
  269.         return $this->configFlightAgency;
  270.     }
  271.     /**
  272.      * Add configFlightCalendarAgency.
  273.      *
  274.      * @return Provider
  275.      */
  276.     public function addConfigFlightCalendarAgency(\Aviatur\FlightBundle\Entity\ConfigFlightCalendarAgency $configFlightCalendarAgency)
  277.     {
  278.         $this->configFlightCalendarAgency[] = $configFlightCalendarAgency;
  279.         return $this;
  280.     }
  281.     /**
  282.      * Remove configFlightCalendarAgency.
  283.      */
  284.     public function removeConfigFlightCalendarAgency(\Aviatur\FlightBundle\Entity\ConfigFlightCalendarAgency $configFlightCalendarAgency)
  285.     {
  286.         $this->configFlightCalendarAgency->removeElement($configFlightCalendarAgency);
  287.     }
  288.     /**
  289.      * Get configFlightCalendarAgency.
  290.      *
  291.      * @return \Doctrine\Common\Collections\Collection
  292.      */
  293.     public function getConfigFlightCalendarAgency()
  294.     {
  295.         return $this->configFlightCalendarAgency;
  296.     }
  297.     /**
  298.      * Add configHotelAgency.
  299.      *
  300.      * @return Provider
  301.      */
  302.     public function addConfigHotelAgency(\Aviatur\HotelBundle\Entity\ConfigHotelAgency $configHotelAgency)
  303.     {
  304.         $this->configHotelAgency[] = $configHotelAgency;
  305.         return $this;
  306.     }
  307.     /**
  308.      * Remove configHotelAgency.
  309.      */
  310.     public function removeConfigHotelAgency(\Aviatur\HotelBundle\Entity\ConfigHotelAgency $configHotelAgency)
  311.     {
  312.         $this->configHotelAgency->removeElement($configHotelAgency);
  313.     }
  314.     /**
  315.      * Get configHotelAgency.
  316.      *
  317.      * @return \Doctrine\Common\Collections\Collection
  318.      */
  319.     public function getConfigHotelAgency()
  320.     {
  321.         return $this->configHotelAgency;
  322.     }
  323.     /**
  324.      * Add configPackageAgency.
  325.      *
  326.      * @return Agency
  327.      */
  328.     public function addConfigPackageAgency(\Aviatur\PackageBundle\Entity\ConfigPackageAgency $configPackageAgency)
  329.     {
  330.         $this->configPackageAgency[] = $configPackageAgency;
  331.         return $this;
  332.     }
  333.     /**
  334.      * Remove configPackageAgency.
  335.      */
  336.     public function removeConfigPackageAgency(\Aviatur\PackageBundle\Entity\ConfigPackageAgency $configPackageAgency)
  337.     {
  338.         $this->configPackageAgency->removeElement($configPackageAgency);
  339.     }
  340.     /**
  341.      * Get configPackageAgency.
  342.      *
  343.      * @return \Doctrine\Common\Collections\Collection
  344.      */
  345.     public function getConfigPackageAgency()
  346.     {
  347.         return $this->configPackageAgency;
  348.     }
  349.     /**
  350.      * Add configInsuranceAgency.
  351.      *
  352.      * @return Agency
  353.      */
  354.     public function addConfigInsuranceAgency(\Aviatur\InsuranceBundle\Entity\ConfigInsuranceAgency $configInsuranceAgency)
  355.     {
  356.         $this->configInsuranceAgency[] = $configInsuranceAgency;
  357.         return $this;
  358.     }
  359.     /**
  360.      * Remove configInsuranceAgency.
  361.      */
  362.     public function removeConfigInsuranceAgency(\Aviatur\InsuranceBundle\Entity\ConfigInsuranceAgency $configInsuranceAgency)
  363.     {
  364.         $this->configInsuranceAgency->removeElement($configInsuranceAgency);
  365.     }
  366.     /**
  367.      * Get configInsuranceAgency.
  368.      *
  369.      * @return \Doctrine\Common\Collections\Collection
  370.      */
  371.     public function getConfigInsuranceAgency()
  372.     {
  373.         return $this->configInsuranceAgency;
  374.     }
  375.     /**
  376.      * Add configBusAgency
  377.      *
  378.      * @param \Aviatur\BusBundle\Entity\configBusAgency $configBusAgency
  379.      * @return Agency
  380.      */
  381.     public function addConfigBusAgency(\Aviatur\BusBundle\Entity\ConfigBusAgency $configBusAgency)
  382.     {
  383.         $this->configBusAgency[] = $configBusAgency;
  384.         return $this;
  385.     }
  386.     /**
  387.      * Remove configBusAgency
  388.      *
  389.      * @param \Aviatur\BusBundle\Entity\configBusAgency $configBusAgency
  390.      */
  391.     public function removeConfigBusAgency(\Aviatur\BusBundle\Entity\ConfigBusAgency $configBusAgency)
  392.     {
  393.         $this->configBusAgency->removeElement($configBusAgency);
  394.     }
  395.     /**
  396.      * Get configBusAgency
  397.      *
  398.      * @return \Doctrine\Common\Collections\Collection
  399.      */
  400.     public function getConfigBusAgency()
  401.     {
  402.         return $this->configBusAgency;
  403.     }
  404.     /**
  405.      * Add orderProduct.
  406.      *
  407.      * @return Provider
  408.      */
  409.     public function addOrderProduct(\Aviatur\GeneralBundle\Entity\OrderProduct $orderProduct)
  410.     {
  411.         $this->orderProduct[] = $orderProduct;
  412.         return $this;
  413.     }
  414.     /**
  415.      * Remove orderProduct.
  416.      */
  417.     public function removeOrderProduct(\Aviatur\GeneralBundle\Entity\OrderProduct $orderProduct)
  418.     {
  419.         $this->orderProduct->removeElement($orderProduct);
  420.     }
  421.     /**
  422.      * Get orderProduct.
  423.      *
  424.      * @return \Doctrine\Common\Collections\Collection
  425.      */
  426.     public function getOrderProduct()
  427.     {
  428.         return $this->orderProduct;
  429.     }
  430.     /**
  431.      * Add configCruiserAgency.
  432.      *
  433.      * @return Provider
  434.      */
  435.     public function addConfigCruiserAgency(\Aviatur\CruiserBundle\Entity\ConfigCruiserAgency $configCruiserAgency)
  436.     {
  437.         $this->configCruiserAgency[] = $configCruiserAgency;
  438.         return $this;
  439.     }
  440.     /**
  441.      * Remove configCruiserAgency.
  442.      */
  443.     public function removeConfigCruiserAgency(\Aviatur\CruiserBundle\Entity\ConfigCruiserAgency $configCruiserAgency)
  444.     {
  445.         $this->configCruiserAgency->removeElement($configCruiserAgency);
  446.     }
  447.     /**
  448.      * Get configCruiserAgency.
  449.      *
  450.      * @return \Doctrine\Common\Collections\Collection
  451.      */
  452.     public function getConfigCruiserAgency()
  453.     {
  454.         return $this->configCruiserAgency;
  455.     }
  456.     /**
  457.      * Add configHelicopterAgency.
  458.      *
  459.      * @return Provider
  460.      */
  461.     public function addConfigHelicopterAgency(\Aviatur\HelicopterBundle\Entity\ConfigHelicopterAgency $configHelicopterAgency)
  462.     {
  463.         $this->configHelicopterAgency[] = $configHelicopterAgency;
  464.         return $this;
  465.     }
  466.     /**
  467.      * Remove configHelicopterAgency.
  468.      */
  469.     public function removeConfigHelicopterAgency(\Aviatur\HelicopterBundle\Entity\ConfigHelicopterAgency $configHelicopterAgency)
  470.     {
  471.         $this->configHelicopterAgency->removeElement($configHelicopterAgency);
  472.     }
  473.     /**
  474.      * Get configHelicopterAgency.
  475.      *
  476.      * @return \Doctrine\Common\Collections\Collection
  477.      */
  478.     public function getConfigHelicopterAgency()
  479.     {
  480.         return $this->configHelicopterAgency;
  481.     }
  482.     /**
  483.      * Add ConfigFlightAgencyActivityLog.
  484.      *
  485.      * @return ConfigFlightAgencyActivityLog
  486.      */
  487.     public function addConfigFlightAgencyActivityLog(\Aviatur\FlightBundle\Entity\ConfigFlightAgencyActivityLog $configFlightAgencyActivityLog)
  488.     {
  489.         $this->configFlightAgencyActivityLog[] = $configFlightAgencyActivityLog;
  490.         return $this;
  491.     }
  492.     /**
  493.      * Remove ConfigFlightAgencyActivityLog.
  494.      */
  495.     public function removeConfigFlightAgencyActivityLog(\Aviatur\FlightBundle\Entity\ConfigFlightAgencyActivityLog $configFlightAgencyActivityLog)
  496.     {
  497.         $this->configFlightAgencyActivityLog->removeElement($configFlightAgencyActivityLog);
  498.     }
  499.     /**
  500.      * Get ConfigFlightAgencyActivityLog.
  501.      *
  502.      * @return \Doctrine\Common\Collections\Collection
  503.      */
  504.     public function getConfigFlightAgencyActivityLog()
  505.     {
  506.         return $this->configFlightAgencyActivityLog;
  507.     }
  508. }