<?php
namespace App\Entity;
use App\Repository\RecommendContactRepository;
use Cofondateur\SocleTechniqueBundle\Annotation\CrudField;
use Doctrine\ORM\Mapping as ORM;
/**
* @ORM\Entity(repositoryClass=RecommendContactRepository::class)
*/
class RecommendContact
{
/**
* @ORM\Id
* @ORM\GeneratedValue
* @ORM\Column(type="integer")
*/
private $id;
/**
* @ORM\Column(type="string", length=255, nullable=true)
* @CrudField(label="Code partenaire")
*/
private $partnerCode;
/**
* @ORM\Column(type="string", length=255)
* @CrudField(label="Raison sociale")
*/
private $socialReason;
/**
* @ORM\Column(type="string", length=255)
* @CrudField(tab="Informations du client", index=true, label="Nom")
*/
private $name;
/**
* @ORM\Column(type="string", length=255, nullable=true)
* @CrudField(tab="Informations du client", index=true, label="Prénom")
*/
private $firstname;
/**
* @ORM\Column(type="string", length=255)
* @CrudField(tab="Informations du client", label="Téléphone")
*/
private $phone;
/**
* @ORM\Column(type="string", length=255)
* @CrudField(tab="Informations du client", label="Email")
*/
private $email;
/**
* @ORM\Column(type="string", length=255, nullable=true)
* @CrudField(tab="Informations du client", label="Code postal")
*/
private $postalCode;
/**
* @ORM\Column(type="string", length=255, nullable=true)
* @CrudField(tab="Informations du client", label="Ville")
*/
private $city;
/**
* @ORM\Column(type="string", length=255, nullable=true)
* @CrudField(tab="Informations du client", label="Adresse")
*/
private $address;
/**
* @ORM\Column(type="date")
* @CrudField(index=true, label="Date")
*/
private $date;
public function __construct() {
$this->date = new \DateTime();
}
public function __toString(): string
{
return $this->getId() ?? "N/A";
}
public function getId(): ?int
{
return $this->id;
}
public function getPartnerCode(): ?string
{
return $this->partnerCode;
}
public function setPartnerCode(?string $partnerCode): self
{
$this->partnerCode = $partnerCode;
return $this;
}
public function getSocialReason(): ?string
{
return $this->socialReason;
}
public function setSocialReason(string $socialReason): self
{
$this->socialReason = $socialReason;
return $this;
}
public function getName(): ?string
{
return $this->name;
}
public function setName(string $name): self
{
$this->name = $name;
return $this;
}
public function getFirstname(): ?string
{
return $this->firstname;
}
public function setFirstname(?string $firstname): self
{
$this->firstname = $firstname;
return $this;
}
public function getPhone(): ?string
{
return $this->phone;
}
public function setPhone(string $phone): self
{
$this->phone = $phone;
return $this;
}
public function getEmail(): ?string
{
return $this->email;
}
public function setEmail(string $email): self
{
$this->email = $email;
return $this;
}
public function getPostalCode(): ?string
{
return $this->postalCode;
}
public function setPostalCode(?string $postalCode): self
{
$this->postalCode = $postalCode;
return $this;
}
public function getCity(): ?string
{
return $this->city;
}
public function setCity(?string $city): self
{
$this->city = $city;
return $this;
}
public function getAddress(): ?string
{
return $this->address;
}
public function setAddress(string $address): self
{
$this->address = $address;
return $this;
}
public function getDate(): ?\DateTimeInterface
{
return $this->date;
}
public function setDate(\DateTimeInterface $date): self
{
$this->date = $date;
return $this;
}
}