<?php
namespace App\AtechNet\CoreBundle\Entity;
use App\AtechNet\CoreBundle\Repository\CustomerContactPersonRepository;
use Doctrine\ORM\Mapping as ORM;
use Doctrine\ORM\Mapping\Entity;
use Doctrine\ORM\Mapping\JoinColumn;
use Doctrine\ORM\Mapping\ManyToOne;
use Doctrine\ORM\Mapping\Table as Table;
/**
* CustomerContactPerson
*
* @Table(name="customers__contact_persons")
* @Entity(repositoryClass=CustomerContactPersonRepository::class)
*/
class CustomerContactPerson extends AbstractEntity
{
/**
* @var Customer
*
* @ManyToOne(targetEntity="Customer", inversedBy="contactPersons")
* @JoinColumn(name="customer_id", referencedColumnName="id")
*/
private $customer;
/**
* @var string
*
* @ORM\Column(name="first_name", type="string", length=255)
*/
private $firstName;
/**
* @var string
*
* @ORM\Column(name="last_name", type="string", length=255)
*/
private $lastName;
/**
* @var string
*
* @ORM\Column(name="phone_number", type="string", length=255, nullable=true)
*/
private $phone;
/**
* @var string
*
* @ORM\Column(name="email", type="string", length=255, nullable=true)
*/
private $email;
/**
* @return Customer
*/
public function getCustomer()
{
return $this->customer;
}
/**
* @param Customer $customer
*/
public function setCustomer($customer)
{
$this->customer = $customer;
}
/**
* Set firstName
*
* @param string $firstName
* @return CustomerContactPerson
*/
public function setFirstName($firstName)
{
$this->firstName = $firstName;
return $this;
}
/**
* Get firstName
*
* @return string
*/
public function getFirstName()
{
return $this->firstName;
}
/**
* Set lastName
*
* @param string $lastName
* @return CustomerContactPerson
*/
public function setLastName($lastName)
{
$this->lastName = $lastName;
return $this;
}
/**
* Get lastName
*
* @return string
*/
public function getLastName()
{
return $this->lastName;
}
/**
* @return string
*/
public function getPhone()
{
return $this->phone;
}
/**
* @param string $phone
*/
public function setPhone($phone)
{
$this->phone = $phone;
}
/**
* Set email
*
* @param string $email
* @return CustomerContactPerson
*/
public function setEmail($email)
{
$this->email = $email;
return $this;
}
/**
* Get email
*
* @return string
*/
public function getEmail()
{
return $this->email;
}
}