src/CoreBundle/Entity/Forms.php line 14

Open in your IDE?
  1. <?php
  2. namespace CoreBundle\Entity;
  3. use CoreBundle\Entity\Vehicles\Vehicle;
  4. use CoreBundle\Entity\Vehicles\InStock;
  5. use DateTime;
  6. use CoreBundle\Component\FormManager;
  7. use DcSiteBundle\Entity\Accessories;
  8. /**
  9.  * Forms
  10.  */
  11. class Forms
  12. {
  13.     /**
  14.      * @var int
  15.      */
  16.     private $id;
  17.     /**
  18.      * @var Dealer
  19.      */
  20.     private $dealer;
  21.     /**
  22.      * @var int
  23.      */
  24.     private $type;
  25.     /**
  26.      * @var string
  27.      */
  28.     private $name;
  29.     /**
  30.      * @var string
  31.      */
  32.     private $second_name;
  33.     /**
  34.      * @var string
  35.      */
  36.     private $phone;
  37.     /**
  38.      * @var string
  39.      */
  40.     private $email;
  41.     /**
  42.      * @var bool
  43.      */
  44.     private $is_send;
  45.     /**
  46.      * @var bool
  47.      */
  48.     private $in_crm;
  49.     /**
  50.      * @var int
  51.      */
  52.     private $in_pcu_code;
  53.     /**
  54.      * @var DateTime
  55.      */
  56.     private $date_create;
  57.     /**
  58.      * @var Accessories
  59.      */
  60.     private $accessory;
  61.     /**
  62.      * @var string
  63.      */
  64.     private $data;
  65.     public function __construct()
  66.     {
  67.         $this->is_autocreated 0;
  68.     }
  69.     public function __toString()
  70.     {
  71.         return (string)FormManager::getFormTypeName($this->getType());
  72.     }
  73.     /**
  74.      * Get id
  75.      *
  76.      * @return int
  77.      */
  78.     public function getId()
  79.     {
  80.         return $this->id;
  81.     }
  82.     /**
  83.      * Set dealer
  84.      *
  85.      * @param Dealer $dealer
  86.      *
  87.      * @return Forms
  88.      */
  89.     public function setDealer($dealer)
  90.     {
  91.         $this->dealer $dealer;
  92.         return $this;
  93.     }
  94.     /**
  95.      * Get dealer
  96.      *
  97.      * @return Dealer
  98.      */
  99.     public function getDealer()
  100.     {
  101.         return $this->dealer;
  102.     }
  103.     /**
  104.      * @return bool
  105.      */
  106.     public function isDealer()
  107.     {
  108.         return isset($this->dealer);
  109.     }
  110.     /**
  111.      * Set type
  112.      *
  113.      * @param integer $type
  114.      *
  115.      * @return Forms
  116.      */
  117.     public function setType($type)
  118.     {
  119.         $this->type $type;
  120.         return $this;
  121.     }
  122.     /**
  123.      * Get type
  124.      *
  125.      * @return int
  126.      */
  127.     public function getType()
  128.     {
  129.         return $this->type;
  130.     }
  131.     /**
  132.      * Set name
  133.      *
  134.      * @param string $name
  135.      *
  136.      * @return Forms
  137.      */
  138.     public function setName($name)
  139.     {
  140.         $this->name $name;
  141.         return $this;
  142.     }
  143.     /**
  144.      * Get name
  145.      *
  146.      * @return string
  147.      */
  148.     public function getName()
  149.     {
  150.         return $this->name;
  151.     }
  152.     /**
  153.      * Set second_name
  154.      *
  155.      * @param string $second_name
  156.      *
  157.      * @return Forms
  158.      */
  159.     public function setSecondName($second_name)
  160.     {
  161.         $this->second_name $second_name;
  162.         return $this;
  163.     }
  164.     /**
  165.      * Get name
  166.      *
  167.      * @return string
  168.      */
  169.     public function getSecondName()
  170.     {
  171.         return $this->second_name;
  172.     }
  173.     /**
  174.      * Set phone
  175.      *
  176.      * @param string $phone
  177.      *
  178.      * @return Forms
  179.      */
  180.     public function setPhone($phone)
  181.     {
  182.         $this->phone $phone;
  183.         return $this;
  184.     }
  185.     /**
  186.      * Get phone
  187.      *
  188.      * @return string
  189.      */
  190.     public function getPhone()
  191.     {
  192.         return $this->phone;
  193.     }
  194.     /**
  195.      * Set email
  196.      *
  197.      * @param string $email
  198.      *
  199.      * @return Forms
  200.      */
  201.     public function setEmail($email)
  202.     {
  203.         $this->email $email;
  204.         return $this;
  205.     }
  206.     /**
  207.      * Get email
  208.      *
  209.      * @return string
  210.      */
  211.     public function getEmail()
  212.     {
  213.         return $this->email;
  214.     }
  215.     /**
  216.      * Set is_send
  217.      *
  218.      * @param boolean $is_send
  219.      *
  220.      * @return Forms
  221.      */
  222.     public function setIsSend($is_send)
  223.     {
  224.         $this->is_send $is_send;
  225.         return $this;
  226.     }
  227.     /**
  228.      * Get is_send
  229.      *
  230.      * @return bool
  231.      */
  232.     public function getIsSend()
  233.     {
  234.         return $this->is_send;
  235.     }
  236.     /**
  237.      * Set in_crm
  238.      *
  239.      * @param boolean $in_crm
  240.      *
  241.      * @return Forms
  242.      */
  243.     public function setInCrm($in_crm)
  244.     {
  245.         $this->in_crm $in_crm;
  246.         return $this;
  247.     }
  248.     /**
  249.      * Get in_crm
  250.      *
  251.      * @return bool
  252.      */
  253.     public function getInCrm()
  254.     {
  255.         return $this->in_crm;
  256.     }
  257.     /**
  258.      * Set date_create
  259.      *
  260.      * @param DateTime $date_create
  261.      *
  262.      * @return Forms
  263.      */
  264.     public function setDateCreate($date_create)
  265.     {
  266.         $this->date_create $date_create;
  267.         return $this;
  268.     }
  269.     /**
  270.      * Get date_create
  271.      *
  272.      * @return DateTime
  273.      */
  274.     public function getDateCreate()
  275.     {
  276.         return $this->date_create;
  277.     }
  278.     /**
  279.      * Set accessory
  280.      *
  281.      * @param Accessories $accessory
  282.      *
  283.      * @return Forms
  284.      */
  285.     public function setAccessory(Accessories $accessory null)
  286.     {
  287.         $this->accessory $accessory;
  288.         return $this;
  289.     }
  290.     /**
  291.      * Get accessory
  292.      *
  293.      * @return Accessories
  294.      */
  295.     public function getAccessory()
  296.     {
  297.         return $this->accessory;
  298.     }
  299.     /**
  300.      * Set data
  301.      *
  302.      * @param string $data
  303.      *
  304.      * @return Forms
  305.      */
  306.     public function setData($data)
  307.     {
  308.         $this->data $data;
  309.         return $this;
  310.     }
  311.     /**
  312.      * Get data
  313.      *
  314.      * @return string
  315.      */
  316.     public function getData()
  317.     {
  318.         if (is_array($this->data)) {
  319.             return json_encode($this->data);
  320.         }
  321.         return $this->data;
  322.     }
  323.     /**
  324.      * @var string
  325.      */
  326.     private $ga_client_id;
  327.     /**
  328.      * Set gaClientId
  329.      *
  330.      * @param string $gaClientId
  331.      *
  332.      * @return Forms
  333.      */
  334.     public function setGaClientId($gaClientId)
  335.     {
  336.         $this->ga_client_id $gaClientId;
  337.         return $this;
  338.     }
  339.     /**
  340.      * Get gaClientId
  341.      *
  342.      * @return string
  343.      */
  344.     public function getGaClientId()
  345.     {
  346.         return $this->ga_client_id;
  347.     }
  348.     /**
  349.      * @var integer
  350.      */
  351.     private $in_ga;
  352.     /**
  353.      * Set inGa
  354.      *
  355.      * @param integer $inGa
  356.      *
  357.      * @return Forms
  358.      */
  359.     public function setInGa($inGa)
  360.     {
  361.         $this->in_ga $inGa;
  362.         return $this;
  363.     }
  364.     /**
  365.      * Get inGa
  366.      *
  367.      * @return integer
  368.      */
  369.     public function getInGa()
  370.     {
  371.         return $this->in_ga;
  372.     }
  373.     /**
  374.      * @var string
  375.      */
  376.     private $referrer;
  377.     /**
  378.      * @var string
  379.      */
  380.     private $href;
  381.     /**
  382.      * @var string
  383.      */
  384.     private $utm;
  385.     /**
  386.      * Set referrer
  387.      *
  388.      * @param string $referrer
  389.      *
  390.      * @return Forms
  391.      */
  392.     public function setReferrer($referrer)
  393.     {
  394.         $this->referrer $referrer;
  395.         return $this;
  396.     }
  397.     /**
  398.      * Get referrer
  399.      *
  400.      * @return string
  401.      */
  402.     public function getReferrer()
  403.     {
  404.         return $this->referrer;
  405.     }
  406.     /**
  407.      * Set href
  408.      *
  409.      * @param string $href
  410.      *
  411.      * @return Forms
  412.      */
  413.     public function setHref($href)
  414.     {
  415.         $this->href $href;
  416.         return $this;
  417.     }
  418.     /**
  419.      * Get href
  420.      *
  421.      * @return string
  422.      */
  423.     public function getHref()
  424.     {
  425.         return $this->href;
  426.     }
  427.     /**
  428.      * Set utm
  429.      *
  430.      * @param string $utm
  431.      *
  432.      * @return Forms
  433.      */
  434.     public function setUtm($utm)
  435.     {
  436.         $this->utm $utm;
  437.         return $this;
  438.     }
  439.     /**
  440.      * Get utm
  441.      *
  442.      * @return string
  443.      */
  444.     public function getUtm()
  445.     {
  446.         return $this->utm;
  447.     }
  448.     /**
  449.      * @var string
  450.      */
  451.     private $crm_lead_id;
  452.     /**
  453.      * Set crmLeadId
  454.      *
  455.      * @param string $crmLeadId
  456.      *
  457.      * @return Forms
  458.      */
  459.     public function setCrmLeadId($crmLeadId)
  460.     {
  461.         $this->crm_lead_id $crmLeadId;
  462.         return $this;
  463.     }
  464.     /**
  465.      * Get crmLeadId
  466.      *
  467.      * @return string
  468.      */
  469.     public function getCrmLeadId()
  470.     {
  471.         return $this->crm_lead_id;
  472.     }
  473.     /**
  474.      * @var ViDiDepartment
  475.      */
  476.     private $department;
  477.     /**
  478.      * Set department
  479.      *
  480.      * @param ViDiDepartment $department
  481.      *
  482.      * @return Forms
  483.      */
  484.     public function setDepartment(ViDiDepartment $department null)
  485.     {
  486.         $this->department $department;
  487.         return $this;
  488.     }
  489.     /**
  490.      * Get department
  491.      *
  492.      * @return ViDiDepartment
  493.      */
  494.     public function getDepartment()
  495.     {
  496.         return $this->department;
  497.     }
  498.     /**
  499.      * @var string
  500.      */
  501.     private $gcl_id;
  502.     /**
  503.      * Set gclId
  504.      *
  505.      * @param string $gclId
  506.      *
  507.      * @return Forms
  508.      */
  509.     public function setGclId($gclId)
  510.     {
  511.         $this->gcl_id $gclId;
  512.         return $this;
  513.     }
  514.     /**
  515.      * Get gclId
  516.      *
  517.      * @return string
  518.      */
  519.     public function getGclId()
  520.     {
  521.         return $this->gcl_id;
  522.     }
  523.     /**
  524.      * @var string
  525.      */
  526.     private $domain;
  527.     /**
  528.      * Set domain
  529.      *
  530.      * @param string $domain
  531.      *
  532.      * @return Forms
  533.      */
  534.     public function setDomain($domain)
  535.     {
  536.         $this->domain $domain;
  537.         return $this;
  538.     }
  539.     /**
  540.      * Get domain
  541.      *
  542.      * @return string
  543.      */
  544.     public function getDomain()
  545.     {
  546.         return $this->domain;
  547.     }
  548.     /**
  549.      * @param int $id
  550.      */
  551.     public function setId($id)
  552.     {
  553.         $this->id $id;
  554.     }
  555.     public function getTypeName()
  556.     {
  557.         return FormManager::getTypeName($this->getType());
  558.     }
  559.     /**
  560.      * @var integer
  561.      */
  562.     private $notify_send;
  563.     /**
  564.      * Set notifySend
  565.      *
  566.      * @param integer $notifySend
  567.      *
  568.      * @return Forms
  569.      */
  570.     public function setNotifySend($notifySend)
  571.     {
  572.         $this->notify_send $notifySend;
  573.         return $this;
  574.     }
  575.     /**
  576.      * Get notifySend
  577.      *
  578.      * @return integer
  579.      */
  580.     public function getNotifySend()
  581.     {
  582.         return $this->notify_send;
  583.     }
  584.     /**
  585.      * @var Vehicle
  586.      */
  587.     private $vehicle;
  588.     /**
  589.      * @var InStock
  590.      */
  591.     private $vehicle_in_stock;
  592.     /**
  593.      * Set vehicle
  594.      *
  595.      * @param Vehicle $vehicle
  596.      *
  597.      * @return Forms
  598.      */
  599.     public function setVehicle(Vehicle $vehicle null)
  600.     {
  601.         $this->vehicle $vehicle;
  602.         return $this;
  603.     }
  604.     /**
  605.      * Get vehicle
  606.      *
  607.      * @return Vehicle
  608.      */
  609.     public function getVehicle()
  610.     {
  611.         return $this->vehicle;
  612.     }
  613.     /**
  614.      * Set vehicleInStock
  615.      *
  616.      * @param InStock $vehicleInStock
  617.      *
  618.      * @return Forms
  619.      */
  620.     public function setVehicleInStock(InStock $vehicleInStock null)
  621.     {
  622.         $this->vehicle_in_stock $vehicleInStock;
  623.         return $this;
  624.     }
  625.     /**
  626.      * Get vehicleInStock
  627.      *
  628.      * @return InStock
  629.      */
  630.     public function getVehicleInStock()
  631.     {
  632.         return $this->vehicle_in_stock;
  633.     }
  634.     /**
  635.      * @var User
  636.      */
  637.     private $user;
  638.     /**
  639.      * Set user
  640.      *
  641.      * @param User $user
  642.      *
  643.      * @return Forms
  644.      */
  645.     public function setUser(User $user null)
  646.     {
  647.         $this->user $user;
  648.         return $this;
  649.     }
  650.     /**
  651.      * Get user
  652.      *
  653.      * @return User
  654.      */
  655.     public function getUser()
  656.     {
  657.         return $this->user;
  658.     }
  659.     /**
  660.      * @return int
  661.      */
  662.     public function getInPcuCode()
  663.     {
  664.         return $this->in_pcu_code;
  665.     }
  666.     /**
  667.      * @param int $in_pcu_code
  668.      */
  669.     public function setInPcuCode($in_pcu_code)
  670.     {
  671.         $this->in_pcu_code $in_pcu_code;
  672.     }
  673.     /**
  674.      * @var string
  675.      */
  676.     private $model;
  677.     /**
  678.      * Set model
  679.      *
  680.      * @param string $model
  681.      *
  682.      * @return Forms
  683.      */
  684.     public function setModel($model)
  685.     {
  686.         $this->model $model;
  687.         return $this;
  688.     }
  689.     /**
  690.      * Get model
  691.      *
  692.      * @return string
  693.      */
  694.     public function getModel()
  695.     {
  696.         return $this->model;
  697.     }
  698.     /**
  699.      * @var integer
  700.      */
  701.     private $is_preorder;
  702.     /**
  703.      * @var integer
  704.      */
  705.     private $is_autocreated;
  706.     /**
  707.      * Set isPreorder
  708.      *
  709.      * @param integer $isPreorder
  710.      *
  711.      * @return Forms
  712.      */
  713.     public function setIsPreorder($isPreorder)
  714.     {
  715.         $this->is_preorder $isPreorder;
  716.         return $this;
  717.     }
  718.     /**
  719.      * Get isPreorder
  720.      *
  721.      * @return integer
  722.      */
  723.     public function getIsPreorder()
  724.     {
  725.         return $this->is_preorder;
  726.     }
  727.     public function setIsAutocreated($isAutocreated)
  728.     {
  729.         $this->is_autocreated $isAutocreated;
  730.         return $this;
  731.     }
  732.     public function getIsAutocreated()
  733.     {
  734.         return $this->is_autocreated;
  735.     }
  736. }