<?php
namespace App\Entity\Vetoadom;
use Doctrine\Common\Collections\ArrayCollection;
use Doctrine\Common\Collections\Collection;
use Doctrine\ORM\Mapping as ORM;
use Symfony\Component\Validator\Constraints as Assert;
use Symfony\Bridge\Doctrine\Validator\Constraints\UniqueEntity;
/**
* Secteur
*
* @ORM\Table(name="secteur", uniqueConstraints={@ORM\UniqueConstraint(name="nom_raccourci", columns={"nom_raccourci"}), @ORM\UniqueConstraint(name="nom_short", columns={"nom_short"}), @ORM\UniqueConstraint(name="nom", columns={"nom"})}, indexes={@ORM\Index(name="FK_secteur_langue2", columns={"langue2_id"}), @ORM\Index(name="FK_secteur_fonctionnement", columns={"fonctionnement_id"}), @ORM\Index(name="FK_secteur_langue1", columns={"langue1_id"}), @ORM\Index(name="FK_secteur_secteur_delai_defaut", columns={"secteur_delai_defaut_id"}), @ORM\Index(name="FK_secteur_referant", columns={"referant_id"})})
* @ORM\Entity(repositoryClass="App\Repository\Vetoadom\SecteurRepository")
* @UniqueEntity(
* groups={"nom"},
* fields={"nom"},
* errorPath="nom",
* message="page_admin_params_secteur.secteur_nom_exist"
* )
* @UniqueEntity(
* groups={"nomRaccourci"},
* fields={"nomRaccourci"},
* errorPath="nomRaccourci",
* message="page_admin_params_secteur.secteur_nom_raccourci_exist"
* )
* @UniqueEntity(
* groups={"nomShort"},
* fields={"nomShort"},
* errorPath="nomShort",
* message="page_admin_params_secteur.secteur_nom_short_exist"
* )
*/
class Secteur
{
/**
* @var int
*
* @ORM\Column(name="id", type="integer", nullable=false)
* @ORM\Id
* @ORM\GeneratedValue(strategy="IDENTITY")
*/
private $id;
/**
* @var int|null
*
* @ORM\Column(name="site_id", type="integer", nullable=true)
*/
private $siteId;
/**
* @var string
*
* @ORM\Column(name="nom", type="string", length=190, nullable=false)
* @Assert\NotBlank(
* groups={"nom"},
* message="common.blank"
* )
* @Assert\Length(
* groups={"nom"},
* max=190,
* maxMessage="common.too_long"
* )
*/
private $nom;
/**
* @var string|null
*
* @ORM\Column(name="nom_raccourci", type="string", length=50, nullable=true)
* @Assert\NotBlank(
* groups={"nomRaccourci"},
* message="common.blank"
* )
* @Assert\Length(
* groups={"nomRaccourci"},
* max=50,
* maxMessage="common.too_long"
* )
*/
private $nomRaccourci;
/**
* @var string|null
*
* @ORM\Column(name="nom_short", type="string", length=30, nullable=true)
* @Assert\NotBlank(
* groups={"nomShort"},
* message="common.blank"
* )
* @Assert\Length(
* groups={"nomShort"},
* max=50,
* maxMessage="common.too_long"
* )
*/
private $nomShort;
/**
* @var string
*
* @ORM\Column(name="email_from", type="string", length=75, nullable=false)
* @Assert\NotBlank(
* groups={"emailFrom"},
* message="common.blank"
* )
* @Assert\Email(
* groups={"emailFrom"},
* message="common.email"
* )
*/
private $emailFrom;
/**
* @var string|null
*
* @ORM\Column(name="email_to_test", type="string", length=75, nullable=true)
* @Assert\Email(
* groups={"emailToTest"},
* message="common.email"
* )
*/
private $emailToTest;
/**
* @var string|null
*
* @ORM\Column(name="couleur", type="string", length=7, nullable=true, options={"fixed"=true})
* @Assert\NotBlank(
* groups={"couleur"},
* message="common.blank"
* )
*/
private $couleur;
/**
* @var int|null
*
* @ORM\Column(name="ordre", type="smallint", nullable=false, options={"unsigned"=true})
* @Assert\NotBlank(
* groups={"ordre"},
* message="common.blank"
* )
*/
private $ordre = '0';
/**
* @var int|null
*
* @ORM\Column(name="planning1_id", type="integer", nullable=true)
* @Assert\NotBlank(
* groups={"planning1Id"},
* message="common.blank"
* )
*/
private $planning1Id;
/**
* @var int|null
*
* @ORM\Column(name="planning2_id", type="integer", nullable=true)
* @Assert\NotBlank(
* groups={"planning2Id"},
* message="common.blank"
* )
*/
private $planning2Id;
/**
* @var int|null
*
* @ORM\Column(name="supervision_planning_id", type="integer", nullable=true)
* @Assert\NotBlank(
* groups={"supervisionPlanningId"},
* message="common.blank"
* )
*/
private $supervisionPlanningId;
/**
* @var int|null
*
* @ORM\Column(name="vetcoach_planning_id", type="integer", nullable=true)
* @Assert\NotBlank(
* groups={"vetcoachPlanningId"},
* message="common.blank"
* )
*/
private $vetcoachPlanningId;
/**
* @var int|null
*
* @ORM\Column(name="asv_planning_id", type="integer", nullable=true)
* @Assert\NotBlank(
* groups={"asvPlanningId"},
* message="common.blank"
* )
*/
private $asvPlanningId;
/**
* @var int|null
*
* @ORM\Column(name="astreinte_chirurgie_planning_id", type="integer", nullable=true)
* @Assert\NotBlank(
* groups={"astreinteChirurgiePlanningId"},
* message="common.blank"
* )
*/
private $astreinteChirurgiePlanningId;
/**
* @var string|null
*
* @ORM\Column(name="adresse1", type="string", length=38, nullable=true)
* @Assert\NotBlank(
* groups={"adresse1"},
* message="common.blank"
* )
* @Assert\Length(
* groups={"adresse1"},
* max=38,
* maxMessage="common.too_long"
* )
*/
private $adresse1;
/**
* @var string|null
*
* @ORM\Column(name="adresse2", type="string", length=38, nullable=true)
* @Assert\Length(
* groups={"adresse2"},
* max=38,
* maxMessage="common.too_long"
* )
*/
private $adresse2;
/**
* @var \Ville
*
* @ORM\ManyToOne(targetEntity="Ville")
* @ORM\JoinColumns({
* @ORM\JoinColumn(name="ville_id", referencedColumnName="id")
* })
* @Assert\NotBlank(
* groups={"ville"},
* message="common.blank"
* )
*/
private $ville;
/**
* @var string|null
*
* @ORM\Column(name="texte_mono_langue1", type="text", length=65535, nullable=true)
* @Assert\NotBlank(
* groups={"texteMonoLangue1"},
* message="common.blank"
* )
*/
private $texteMonoLangue1;
/**
* @var string|null
*
* @ORM\Column(name="texte_mono_langue2", type="text", length=65535, nullable=true)
* @Assert\NotBlank(
* groups={"texteMonoLangue2"},
* message="common.blank"
* )
*/
private $texteMonoLangue2;
/**
* @var string|null
*
* @ORM\Column(name="texte_multi_langue1", type="text", length=65535, nullable=true)
* @Assert\NotBlank(
* groups={"texteMultiLangue1"},
* message="common.blank"
* )
*/
private $texteMultiLangue1;
/**
* @var string|null
*
* @ORM\Column(name="texte_multi_langue2", type="text", length=65535, nullable=true)
* @Assert\NotBlank(
* groups={"texteMultiLangue2"},
* message="common.blank"
* )
*/
private $texteMultiLangue2;
/**
* @var string|null
*
* @ORM\Column(name="texte_sans_langue1", type="text", length=65535, nullable=true)
* @Assert\NotBlank(
* groups={"texteSansLangue1"},
* message="common.blank"
* )
*/
private $texteSansLangue1;
/**
* @var string|null
*
* @ORM\Column(name="texte_sans_langue2", type="text", length=65535, nullable=true)
* @Assert\NotBlank(
* groups={"texteSansLangue2"},
* message="common.blank"
* )
*/
private $texteSansLangue2;
/**
* @var string|null
*
* @ORM\Column(name="coeff_feux", type="string", precision=10, scale=2, nullable=true, options={"unsigned"=true})
* @Assert\NotBlank(
* groups={"coeffFeux"},
* message="common.blank"
* )
*/
private $coeffFeux;
/**
* @var string|null
*
* @ORM\Column(name="lien_externe_message", type="string", length=180, nullable=true)
* @Assert\NotBlank(
* groups={"lienExterneMessage"},
* message="common.blank"
* )
* @Assert\Length(
* groups={"lienExterneMessage"},
* max=180,
* maxMessage="common.too_long"
* )
*/
private $lienExterneMessage;
/**
* @var string|null
*
* @ORM\Column(name="lien_externe_prise_appel", type="string", length=180, nullable=true)
* @Assert\NotBlank(
* groups={"lienExternePriseAppel"},
* message="common.blank"
* )
* @Assert\Length(
* groups={"lienExternePriseAppel"},
* max=180,
* maxMessage="common.too_long"
* )
*/
private $lienExternePriseAppel;
/**
* @var string|null
*
* @ORM\Column(name="lien_externe_veterinaire_planning", type="string", length=180, nullable=true)
* @Assert\NotBlank(
* groups={"lienExterneVeterinairePlanning"},
* message="common.blank"
* )
* @Assert\Length(
* groups={"lienExterneVeterinairePlanning"},
* max=180,
* maxMessage="common.too_long"
* )
*/
private $lienExterneVeterinairePlanning;
/**
* @var string|null
*
* @ORM\Column(name="url_root", type="string", length=180, nullable=true)
* @Assert\NotBlank(
* groups={"urlRoot"},
* message="common.blank"
* )
* @Assert\Length(
* groups={"urlRoot"},
* max=180,
* maxMessage="common.too_long"
* )
*/
private $urlRoot;
/**
* @var string|null
*
* @ORM\Column(name="email_manager_service_regulation", type="string", length=75, nullable=true)
* @Assert\NotBlank(
* groups={"emailManagerServiceRegulation"},
* message="common.blank"
* )
* @Assert\Email(
* groups={"emailManagerServiceRegulation"},
* message="common.email"
* )
*/
private $emailManagerServiceRegulation;
/**
* @var string|null
*
* @ORM\Column(name="content_estimatif_tarifs", type="text", length=65535, nullable=true)
* @Assert\NotBlank(
* groups={"contentEstimatifTarifs"},
* message="common.blank"
* )
*/
private $contentEstimatifTarifs;
/**
* @var string|null
*
* @ORM\Column(name="content_infos_secteur", type="text", length=65535, nullable=true)
* @Assert\NotBlank(
* groups={"contentInfosSecteur"},
* message="common.blank"
* )
*/
private $contentInfosSecteur;
/**
* @var string|null
*
* @ORM\Column(name="content_infos_admin", type="text", length=65535, nullable=true)
* @Assert\NotBlank(
* groups={"contentInfosAdmin"},
* message="common.blank"
* )
*/
private $contentInfosAdmin;
/**
* @var string|null
*
* @ORM\Column(name="content_contacts_utiles", type="text", length=65535, nullable=true)
* @Assert\NotBlank(
* groups={"contentContactsUtiles"},
* message="common.blank"
* )
*/
private $contentContactsUtiles;
/**
* @var string|null
*
* @ORM\Column(name="content_processus", type="text", length=65535, nullable=true)
* @Assert\NotBlank(
* groups={"contentProcessus"},
* message="common.blank"
* )
*/
private $contentProcessus;
/**
* @var string|null
*
* @ORM\Column(name="sms_expediteur", type="string", length=20, nullable=true)
* @Assert\NotBlank(
* groups={"smsExpediteur"},
* message="common.blank"
* )
* @Assert\Length(
* groups={"smsExpediteur"},
* max=20,
* maxMessage="common.too_long"
* )
*/
private $smsExpediteur;
/**
* @var string|null
*
* @ORM\Column(name="sms_contenue_langue1", type="text", length=65535, nullable=true)
* @Assert\NotBlank(
* groups={"smsContenueLangue1"},
* message="common.blank"
* )
*/
private $smsContenueLangue1;
/**
* @var string|null
*
* @ORM\Column(name="sms_contenue_langue2", type="text", length=65535, nullable=true)
* @Assert\NotBlank(
* groups={"smsContenueLangue2"},
* message="common.blank"
* )
*/
private $smsContenueLangue2;
/**
* @var bool
*
* @ORM\Column(name="chat_consultation_acces_restreint", type="boolean", nullable=false, options={"default"="0"})
*/
private $chatConsultationAccesRestreint = false;
/**
* @var string|null
*
* @ORM\Column(name="chat_consultation_creation_mono_langue1", type="text", length=65535, nullable=true)
* @Assert\NotBlank(
* groups={"chatConsultationCreationMonoLangue1"},
* message="common.blank"
* )
*/
private $chatConsultationCreationMonoLangue1;
/**
* @var string|null
*
* @ORM\Column(name="chat_consultation_creation_mono_langue2", type="text", length=65535, nullable=true)
* @Assert\NotBlank(
* groups={"chatConsultationCreationMonoLangue2"},
* message="common.blank"
* )
*/
private $chatConsultationCreationMonoLangue2;
/**
* @var string|null
*
* @ORM\Column(name="chat_consultation_creation_multi_langue1", type="text", length=65535, nullable=true)
* @Assert\NotBlank(
* groups={"chatConsultationCreationMultiLangue1"},
* message="common.blank"
* )
*/
private $chatConsultationCreationMultiLangue1;
/**
* @var string|null
*
* @ORM\Column(name="chat_consultation_creation_multi_langue2", type="text", length=65535, nullable=true)
* @Assert\NotBlank(
* groups={"chatConsultationCreationMultiLangue2"},
* message="common.blank"
* )
*/
private $chatConsultationCreationMultiLangue2;
/**
* @var string|null
*
* @ORM\Column(name="chat_consultation_creation_sans_langue1", type="text", length=65535, nullable=true)
* @Assert\NotBlank(
* groups={"chatConsultationCreationSansLangue1"},
* message="common.blank"
* )
*/
private $chatConsultationCreationSansLangue1;
/**
* @var string|null
*
* @ORM\Column(name="chat_consultation_creation_sans_langue2", type="text", length=65535, nullable=true)
* @Assert\NotBlank(
* groups={"chatConsultationCreationSansLangue2"},
* message="common.blank"
* )
*/
private $chatConsultationCreationSansLangue2;
/**
* @var \DateTime
*
* @ORM\Column(name="date_creation", type="datetime", nullable=false)
*/
private $dateCreation;
/**
* @var \DateTime
*
* @ORM\Column(name="date_modification", type="datetime", nullable=false, options={"default"="CURRENT_TIMESTAMP"})
*/
private $dateModification;
/**
* @var \Fonctionnement
*
* @ORM\ManyToOne(targetEntity="Fonctionnement")
* @ORM\JoinColumns({
* @ORM\JoinColumn(name="fonctionnement_id", referencedColumnName="id")
* })
* @Assert\NotBlank(
* groups={"fonctionnement"},
* message="common.blank"
* )
*/
private $fonctionnement;
/**
* @var \Langue
*
* @ORM\ManyToOne(targetEntity="Langue")
* @ORM\JoinColumns({
* @ORM\JoinColumn(name="langue1_id", referencedColumnName="id")
* })
* @Assert\NotBlank(
* groups={"langue1"},
* message="common.blank"
* )
*/
private $langue1;
/**
* @var \Langue
*
* @ORM\ManyToOne(targetEntity="Langue")
* @ORM\JoinColumns({
* @ORM\JoinColumn(name="langue2_id", referencedColumnName="id")
* })
* @Assert\NotBlank(
* groups={"langue2"},
* message="common.blank"
* )
*/
private $langue2;
/**
* @var \SecteurDelaiDefaut
*
* @ORM\ManyToOne(targetEntity="SecteurDelaiDefaut")
* @ORM\JoinColumns({
* @ORM\JoinColumn(name="secteur_delai_defaut_id", referencedColumnName="id")
* })
* @Assert\NotBlank(
* groups={"secteurDelaiDefaut"},
* message="common.blank"
* )
*/
private $secteurDelaiDefaut;
/**
* @var \Referant
*
* @ORM\ManyToOne(targetEntity="Referant")
* @ORM\JoinColumns({
* @ORM\JoinColumn(name="referant_id", referencedColumnName="id")
* })
* @Assert\NotBlank(
* groups={"referant"},
* message="common.blank"
* )
*/
private $referant;
/**
* @var \ChatCanal
*
* One Secteur has one ChatCanal. This is the inverse side.
* @ORM\OneToOne(targetEntity="ChatCanal", mappedBy="secteur")
*/
private $chatCanal;
/**
* @var Collection
*
* One Secteur has many SecteurCategoriePoidsEspece. This is the inverse side.
* @ORM\OneToMany(targetEntity="SecteurCategoriePoidsEspece", mappedBy="secteur")
*/
private $secteurCategoriePoidsEspece;
/**
* @var Collection
*
* One Secteur has many SecteurCliniqueSecondaire. This is the inverse side.
* @ORM\OneToMany(targetEntity="SecteurCliniqueSecondaire", mappedBy="secteur")
*/
private $secteurCliniqueSecondaire;
/**
* @var Collection
*
* One Secteur has many SecteurConsigne. This is the inverse side.
* @ORM\OneToMany(targetEntity="SecteurConsigne", mappedBy="secteur")
*/
private $secteurConsigne;
/**
* @var Collection
*
* One Secteur has many SecteurGammeTarif. This is the inverse side.
* @ORM\OneToMany(targetEntity="SecteurGammeTarif", mappedBy="secteur")
*/
private $secteurGammeTarif;
/**
* @var Collection
*
* One Secteur has many SecteurPays. This is the inverse side.
* @ORM\OneToMany(targetEntity="SecteurPays", mappedBy="secteur")
*/
private $secteurPays;
/**
* @var Collection
*
* One Secteur has many SecteurPlanningRegulation. This is the inverse side.
* @ORM\OneToMany(targetEntity="SecteurPlanningRegulation", mappedBy="secteur")
* @ORM\OrderBy({"planningId" = "ASC", "jourType" = "ASC", "debutHeure" = "ASC"})
*/
private $secteurPlanningRegulation;
/**
* @var Collection
*
* One Secteur has many SecteurTexteMail. This is the inverse side.
* @ORM\OneToMany(targetEntity="SecteurTexteMail", mappedBy="secteur")
*/
private $secteurTexteMail;
/**
* @var Collection
*
* One Secteur has many SecteurTextePredefini. This is the inverse side.
* @ORM\OneToMany(targetEntity="SecteurTextePredefini", mappedBy="secteur")
*/
private $secteurTextePredefini;
/**
* @var Collection
*
* One Secteur has many SecteurZone. This is the inverse side.
* @ORM\OneToMany(targetEntity="SecteurZone", mappedBy="secteur")
*/
private $secteurZone;
/**
* @var Collection
*
* One Secteur has many SousSecteur. This is the inverse side.
* @ORM\OneToMany(targetEntity="SousSecteur", mappedBy="secteur")
*/
private $sousSecteur;
/**
* Constructor
*/
public function __construct()
{
$this->secteurCategoriePoidsEspece = new ArrayCollection();
$this->secteurCliniqueSecondaire = new ArrayCollection();
$this->secteurConsigne = new ArrayCollection();
$this->secteurGammeTarif = new ArrayCollection();
$this->secteurPays = new ArrayCollection();
$this->secteurPlanningRegulation = new ArrayCollection();
$this->secteurTexteMail = new ArrayCollection();
$this->secteurTextePredefini = new ArrayCollection();
$this->secteurZone = new ArrayCollection();
$this->sousSecteur = new ArrayCollection();
}
public function getId(): ?int
{
return $this->id;
}
public function getSiteId(): ?int
{
return $this->siteId;
}
public function setSiteId(?int $siteId): self
{
$this->siteId = $siteId;
return $this;
}
public function getNom(): ?string
{
return $this->nom;
}
public function setNom(string $nom): self
{
$this->nom = $nom;
return $this;
}
public function getNomRaccourci(): ?string
{
return $this->nomRaccourci;
}
public function setNomRaccourci(?string $nomRaccourci): self
{
$this->nomRaccourci = $nomRaccourci;
return $this;
}
public function getNomShort(): ?string
{
return $this->nomShort;
}
public function setNomShort(?string $nomShort): self
{
$this->nomShort = $nomShort;
return $this;
}
public function getEmailFrom(): ?string
{
return $this->emailFrom;
}
public function setEmailFrom(string $emailFrom): self
{
$this->emailFrom = $emailFrom;
return $this;
}
public function getEmailToTest(): ?string
{
return $this->emailToTest;
}
public function setEmailToTest(?string $emailToTest): self
{
if ($emailToTest === '') $emailToTest = null;
$this->emailToTest = $emailToTest;
return $this;
}
public function getCouleur(): ?string
{
return $this->couleur;
}
public function setCouleur(?string $couleur): self
{
$this->couleur = $couleur;
return $this;
}
public function getOrdre(): ?int
{
return $this->ordre;
}
public function setOrdre(int $ordre): self
{
$this->ordre = $ordre;
return $this;
}
public function getPlanning1Id(): ?int
{
return $this->planning1Id;
}
public function setPlanning1Id(?int $planning1Id): self
{
$this->planning1Id = $planning1Id;
return $this;
}
public function getPlanning2Id(): ?int
{
return $this->planning2Id;
}
public function setPlanning2Id(?int $planning2Id): self
{
$this->planning2Id = $planning2Id;
return $this;
}
public function getSupervisionPlanningId(): ?int
{
return $this->supervisionPlanningId;
}
public function setSupervisionPlanningId(?int $supervisionPlanningId): self
{
$this->supervisionPlanningId = $supervisionPlanningId;
return $this;
}
public function getVetcoachPlanningId(): ?int
{
return $this->vetcoachPlanningId;
}
public function setVetcoachPlanningId(?int $vetcoachPlanningId): self
{
$this->vetcoachPlanningId = $vetcoachPlanningId;
return $this;
}
public function getAsvPlanningId(): ?int
{
return $this->asvPlanningId;
}
public function setAsvPlanningId(?int $asvPlanningId): self
{
$this->asvPlanningId = $asvPlanningId;
return $this;
}
public function getAstreinteChirurgiePlanningId(): ?int
{
return $this->astreinteChirurgiePlanningId;
}
public function setAstreinteChirurgiePlanningId(?int $astreinteChirurgiePlanningId): self
{
$this->astreinteChirurgiePlanningId = $astreinteChirurgiePlanningId;
return $this;
}
public function getAdresse1(): ?string
{
return $this->adresse1;
}
public function setAdresse1(?string $adresse1): self
{
$this->adresse1 = $adresse1;
return $this;
}
public function getAdresse2(): ?string
{
return $this->adresse2;
}
public function setAdresse2(?string $adresse2): self
{
if ($adresse2 === '') $adresse2 = null;
$this->adresse2 = $adresse2;
return $this;
}
public function getTexteMonoLangue1(): ?string
{
return $this->texteMonoLangue1;
}
public function setTexteMonoLangue1(?string $texteMonoLangue1): self
{
if ($texteMonoLangue1 === '') $texteMonoLangue1 = null;
$this->texteMonoLangue1 = $texteMonoLangue1;
return $this;
}
public function getTexteMonoLangue2(): ?string
{
return $this->texteMonoLangue2;
}
public function setTexteMonoLangue2(?string $texteMonoLangue2): self
{
if ($texteMonoLangue2 === '') $texteMonoLangue2 = null;
$this->texteMonoLangue2 = $texteMonoLangue2;
return $this;
}
public function getTexteMultiLangue1(): ?string
{
return $this->texteMultiLangue1;
}
public function setTexteMultiLangue1(?string $texteMultiLangue1): self
{
if ($texteMultiLangue1 === '') $texteMultiLangue1 = null;
$this->texteMultiLangue1 = $texteMultiLangue1;
return $this;
}
public function getTexteMultiLangue2(): ?string
{
return $this->texteMultiLangue2;
}
public function setTexteMultiLangue2(?string $texteMultiLangue2): self
{
if ($texteMultiLangue2 === '') $texteMultiLangue2 = null;
$this->texteMultiLangue2 = $texteMultiLangue2;
return $this;
}
public function getTexteSansLangue1(): ?string
{
return $this->texteSansLangue1;
}
public function setTexteSansLangue1(?string $texteSansLangue1): self
{
if ($texteSansLangue1 === '') $texteSansLangue1 = null;
$this->texteSansLangue1 = $texteSansLangue1;
return $this;
}
public function getTexteSansLangue2(): ?string
{
return $this->texteSansLangue2;
}
public function setTexteSansLangue2(?string $texteSansLangue2): self
{
if ($texteSansLangue2 === '') $texteSansLangue2 = null;
$this->texteSansLangue2 = $texteSansLangue2;
return $this;
}
public function getCoeffFeux(): ?string
{
return $this->coeffFeux;
}
public function setCoeffFeux(?string $coeffFeux): self
{
if ($coeffFeux === '') $coeffFeux = null;
$this->coeffFeux = $coeffFeux;
return $this;
}
public function getLienExterneMessage(): ?string
{
return $this->lienExterneMessage;
}
public function setLienExterneMessage(?string $lienExterneMessage): self
{
if ($lienExterneMessage === '') $lienExterneMessage = null;
$this->lienExterneMessage = $lienExterneMessage;
return $this;
}
public function getLienExternePriseAppel(): ?string
{
return $this->lienExternePriseAppel;
}
public function setLienExternePriseAppel(?string $lienExternePriseAppel): self
{
if ($lienExternePriseAppel === '') $lienExternePriseAppel = null;
$this->lienExternePriseAppel = $lienExternePriseAppel;
return $this;
}
public function getLienExterneVeterinairePlanning(): ?string
{
return $this->lienExterneVeterinairePlanning;
}
public function setLienExterneVeterinairePlanning(?string $lienExterneVeterinairePlanning): self
{
if ($lienExterneVeterinairePlanning === '') $lienExterneVeterinairePlanning = null;
$this->lienExterneVeterinairePlanning = $lienExterneVeterinairePlanning;
return $this;
}
public function getUrlRoot(): ?string
{
return $this->urlRoot;
}
public function setUrlRoot(?string $urlRoot): self
{
if ($urlRoot === '') $urlRoot = null;
$this->urlRoot = $urlRoot;
return $this;
}
public function getEmailManagerServiceRegulation(): ?string
{
return $this->emailManagerServiceRegulation;
}
public function setEmailManagerServiceRegulation(?string $emailManagerServiceRegulation): self
{
if ($emailManagerServiceRegulation === '') $emailManagerServiceRegulation = null;
$this->emailManagerServiceRegulation = $emailManagerServiceRegulation;
return $this;
}
public function getContentEstimatifTarifs(): ?string
{
return $this->contentEstimatifTarifs;
}
public function setContentEstimatifTarifs(?string $contentEstimatifTarifs): self
{
if ($contentEstimatifTarifs === '') $contentEstimatifTarifs = null;
$this->contentEstimatifTarifs = $contentEstimatifTarifs;
return $this;
}
public function getContentInfosSecteur(): ?string
{
return $this->contentInfosSecteur;
}
public function setContentInfosSecteur(?string $contentInfosSecteur): self
{
if ($contentInfosSecteur === '') $contentInfosSecteur = null;
$this->contentInfosSecteur = $contentInfosSecteur;
return $this;
}
public function getContentInfosAdmin(): ?string
{
return $this->contentInfosAdmin;
}
public function setContentInfosAdmin(?string $contentInfosAdmin): self
{
if ($contentInfosAdmin === '') $contentInfosAdmin = null;
$this->contentInfosAdmin = $contentInfosAdmin;
return $this;
}
public function getContentContactsUtiles(): ?string
{
return $this->contentContactsUtiles;
}
public function setContentContactsUtiles(?string $contentContactsUtiles): self
{
if ($contentContactsUtiles === '') $contentContactsUtiles = null;
$this->contentContactsUtiles = $contentContactsUtiles;
return $this;
}
public function getContentProcessus(): ?string
{
return $this->contentProcessus;
}
public function setContentProcessus(?string $contentProcessus): self
{
if ($contentProcessus === '') $contentProcessus = null;
$this->contentProcessus = $contentProcessus;
return $this;
}
public function getSmsExpediteur(): ?string
{
return $this->smsExpediteur;
}
public function setSmsExpediteur(?string $smsExpediteur): self
{
if ($smsExpediteur === '') $smsExpediteur = null;
$this->smsExpediteur = $smsExpediteur;
return $this;
}
public function getSmsContenueLangue1(): ?string
{
return $this->smsContenueLangue1;
}
public function setSmsContenueLangue1(?string $smsContenueLangue1): self
{
if ($smsContenueLangue1 === '') $smsContenueLangue1 = null;
$this->smsContenueLangue1 = $smsContenueLangue1;
return $this;
}
public function getSmsContenueLangue2(): ?string
{
return $this->smsContenueLangue2;
}
public function setSmsContenueLangue2(?string $smsContenueLangue2): self
{
if ($smsContenueLangue2 === '') $smsContenueLangue2 = null;
$this->smsContenueLangue2 = $smsContenueLangue2;
return $this;
}
public function getChatConsultationAccesRestreint(): ?bool
{
return $this->chatConsultationAccesRestreint;
}
public function setChatConsultationAccesRestreint(bool $chatConsultationAccesRestreint): self
{
$this->chatConsultationAccesRestreint = $chatConsultationAccesRestreint;
return $this;
}
public function getChatConsultationCreationMonoLangue1(): ?string
{
return $this->chatConsultationCreationMonoLangue1;
}
public function setChatConsultationCreationMonoLangue1(?string $chatConsultationCreationMonoLangue1): self
{
if ($chatConsultationCreationMonoLangue1 === '') $chatConsultationCreationMonoLangue1 = null;
$this->chatConsultationCreationMonoLangue1 = $chatConsultationCreationMonoLangue1;
return $this;
}
public function getChatConsultationCreationMonoLangue2(): ?string
{
return $this->chatConsultationCreationMonoLangue2;
}
public function setChatConsultationCreationMonoLangue2(?string $chatConsultationCreationMonoLangue2): self
{
if ($chatConsultationCreationMonoLangue2 === '') $chatConsultationCreationMonoLangue2 = null;
$this->chatConsultationCreationMonoLangue2 = $chatConsultationCreationMonoLangue2;
return $this;
}
public function getChatConsultationCreationMultiLangue1(): ?string
{
return $this->chatConsultationCreationMultiLangue1;
}
public function setChatConsultationCreationMultiLangue1(?string $chatConsultationCreationMultiLangue1): self
{
if ($chatConsultationCreationMultiLangue1 === '') $chatConsultationCreationMultiLangue1 = null;
$this->chatConsultationCreationMultiLangue1 = $chatConsultationCreationMultiLangue1;
return $this;
}
public function getChatConsultationCreationMultiLangue2(): ?string
{
return $this->chatConsultationCreationMultiLangue2;
}
public function setChatConsultationCreationMultiLangue2(?string $chatConsultationCreationMultiLangue2): self
{
if ($chatConsultationCreationMultiLangue2 === '') $chatConsultationCreationMultiLangue2 = null;
$this->chatConsultationCreationMultiLangue2 = $chatConsultationCreationMultiLangue2;
return $this;
}
public function getChatConsultationCreationSansLangue1(): ?string
{
return $this->chatConsultationCreationSansLangue1;
}
public function setChatConsultationCreationSansLangue1(?string $chatConsultationCreationSansLangue1): self
{
if ($chatConsultationCreationSansLangue1 === '') $chatConsultationCreationSansLangue1 = null;
$this->chatConsultationCreationSansLangue1 = $chatConsultationCreationSansLangue1;
return $this;
}
public function getChatConsultationCreationSansLangue2(): ?string
{
return $this->chatConsultationCreationSansLangue2;
}
public function setChatConsultationCreationSansLangue2(?string $chatConsultationCreationSansLangue2): self
{
if ($chatConsultationCreationSansLangue2 === '') $chatConsultationCreationSansLangue2 = null;
$this->chatConsultationCreationSansLangue2 = $chatConsultationCreationSansLangue2;
return $this;
}
public function getDateCreation(): ?\DateTimeInterface
{
return $this->dateCreation;
}
public function setDateCreation(\DateTimeInterface $dateCreation): self
{
$this->dateCreation = $dateCreation;
return $this;
}
public function getDateModification(): ?\DateTimeInterface
{
return $this->dateModification;
}
public function setDateModification(\DateTimeInterface $dateModification): self
{
$this->dateModification = $dateModification;
return $this;
}
public function getFonctionnement(): ?Fonctionnement
{
return $this->fonctionnement;
}
public function setFonctionnement(?Fonctionnement $fonctionnement): self
{
$this->fonctionnement = $fonctionnement;
return $this;
}
public function getLangue1(): ?Langue
{
return $this->langue1;
}
public function setLangue1(?Langue $langue1): self
{
$this->langue1 = $langue1;
return $this;
}
public function getLangue2(): ?Langue
{
return $this->langue2;
}
public function setLangue2(?Langue $langue2): self
{
$this->langue2 = $langue2;
return $this;
}
public function getSecteurDelaiDefaut(): ?SecteurDelaiDefaut
{
return $this->secteurDelaiDefaut;
}
public function setSecteurDelaiDefaut(?SecteurDelaiDefaut $secteurDelaiDefaut): self
{
$this->secteurDelaiDefaut = $secteurDelaiDefaut;
return $this;
}
public function getReferant(): ?Referant
{
return $this->referant;
}
public function setReferant(?Referant $referant): self
{
$this->referant = $referant;
return $this;
}
public function getVille(): ?Ville
{
return $this->ville;
}
public function setVille(?Ville $ville): self
{
$this->ville = $ville;
return $this;
}
/**
* Helpers
*/
/**
* @return ChatCanal|null
*/
public function getChatCanal(): ?ChatCanal
{
return $this->chatCanal;
}
/**
* @return array
*/
public function getLanguesArray() :array
{
$langues = [];
if ($this->getLangue1()) {
$langues[] = [
'id' => $this->getLangue1()->getId(),
'nom' => $this->getLangue1()->getNom(),
'locale' => $this->getLangue1()->getLocale()
];
}
if ($this->getLangue2()) {
$langues[] = [
'id' => $this->getLangue2()->getId(),
'nom' => $this->getLangue2()->getNom(),
'locale' => $this->getLangue2()->getLocale()
];
}
return $langues;
}
/**
* @return array
*/
public function getLanguesIdsArray() :array
{
$langues = [];
if ($this->getLangue1()) {
$langues[] = $this->getLangue1()->getId();
}
if ($this->getLangue2()) {
$langues[] = $this->getLangue2()->getId();
}
return $langues;
}
/**
* @return Collection|SecteurCategoriePoidsEspece[]
*/
public function getSecteurCategoriePoidsEspeceCollection(): Collection
{
$iterator = $this->secteurCategoriePoidsEspece->getIterator();
$iterator->uasort(function (SecteurCategoriePoidsEspece $first, SecteurCategoriePoidsEspece $second) {
# sort by ordre
if ($first->getSecteurEspece()->getOrdre() !== $second->getSecteurEspece()->getOrdre()) {
return $first->getSecteurEspece()->getOrdre() <=> $second->getSecteurEspece()->getOrdre();
}
# sort by min
return $first->getMin() <=> $second->getMin();
});
return new ArrayCollection(iterator_to_array($iterator));
}
/**
* @param int $id
* @return bool
*/
public function hasSecteurCategoriePoidsEspeceById(int $id): bool
{
return $this->getSecteurCategoriePoidsEspeceCollection()->filter(function (SecteurCategoriePoidsEspece $secteurCategoriePoidsEspece) use ($id){
return $secteurCategoriePoidsEspece->getId() == $id;
})->count() == 1;
}
/**
* @param int $id
* @return SecteurCategoriePoidsEspece
* @throws \Exception
*/
public function getSecteurCategoriePoidsEspeceById(int $id): SecteurCategoriePoidsEspece
{
return $this->getSecteurCategoriePoidsEspeceCollection()->filter(function (SecteurCategoriePoidsEspece $secteurCategoriePoidsEspece) use ($id){
return $secteurCategoriePoidsEspece->getId() == $id;
})->first();
}
/**
* @return Collection|SecteurCliniqueSecondaire[]
*/
public function getSecteurCliniqueSecondaireCollection(): Collection
{
return $this->secteurCliniqueSecondaire;
}
/**
* @param int $id
* @return bool
*/
public function hasSecteurCliniqueSecondaireById(int $id): bool
{
return $this->getSecteurCliniqueSecondaireCollection()->filter(function (SecteurCliniqueSecondaire $secteurCliniqueSecondaire) use ($id){
return $secteurCliniqueSecondaire->getId() == $id;
})->count() == 1;
}
/**
* @param int $id
* @return SecteurCliniqueSecondaire
* @throws \Exception
*/
public function getSecteurCliniqueSecondaireById(int $id): SecteurCliniqueSecondaire
{
return $this->getSecteurCliniqueSecondaireCollection()->filter(function (SecteurCliniqueSecondaire $secteurCliniqueSecondaire) use ($id){
return $secteurCliniqueSecondaire->getId() == $id;
})->first();
}
/**
* @return Collection|SecteurConsigne[]
*/
public function getSecteurConsigneCollection(): Collection
{
return $this->secteurConsigne;
}
/**
* @return Collection|SecteurGammeTarif[]
*/
public function getSecteurGammeTarifCollection(): Collection
{
return $this->secteurGammeTarif;
}
/**
* @param int $jourTypeId
* @param \DateTimeInterface $debutHeure
* @param \DateTimeInterface $finHeure
* @param int $tarifId
* @return bool
*/
public function hasSecteurGammeTarif(int $jourTypeId, \DateTimeInterface $debutHeure, \DateTimeInterface $finHeure, int $tarifId): bool
{
return $this->getSecteurGammeTarifCollection()->filter(function (SecteurGammeTarif $secteurGammeTarif) use ($jourTypeId,$debutHeure,$finHeure,$tarifId){
return $secteurGammeTarif->getJourType()->getId() == $jourTypeId
&& $secteurGammeTarif->getDebutHeure() == $debutHeure
&& $secteurGammeTarif->getFinHeure() == $finHeure
&& $secteurGammeTarif->getTarif()->getId() == $tarifId;
})->count() == 1;
}
/**
* @param int $jourTypeId
* @return Collection|SecteurGammeTarif[]
* @throws \Exception
*/
public function getSecteurGammeTarifByJourType(int $jourTypeId): Collection
{
return $this->getSecteurGammeTarifCollection()->filter(function (SecteurGammeTarif $secteurGammeTarif) use ($jourTypeId){
return $secteurGammeTarif->getJourType()->getId() == $jourTypeId;
});
}
/**
* @return Collection|SecteurPays[]
*/
public function getSecteurPaysCollection(): Collection
{
return $this->secteurPays;
}
/**
* @param int $paysId
* @return SecteurPays
* @throws \Exception
*/
public function getSecteurPaysById(int $paysId): SecteurPays
{
return $this->getSecteurPaysCollection()->filter(function (SecteurPays $secteurPays) use ($paysId){
return $secteurPays->getPays()->getId() == $paysId;
})->first();
}
/**
* @param int $paysId
* @return bool
* @throws \Exception
*/
public function hasPays(int $paysId): bool
{
return $this->getSecteurPaysCollection()->filter(function (SecteurPays $secteurPays) use ($paysId){
return $secteurPays->getPays()->getId() == $paysId;
})->count() == 1;
}
/**
* @return array
* @throws \Exception
*/
public function getSecteurPaysIds(): array
{
$paysIds = [];
foreach ($this->getSecteurPaysCollection() as $secteurPays) {
$paysIds[] = $secteurPays->getPays()->getId();
}
return $paysIds;
}
/**
* @return array
* @throws \Exception
*/
public function getSecteurPaysArray(): array
{
$pays = [];
foreach ($this->getSecteurPaysCollection() as $secteurPays) {
$pays[] = [
'id' => $secteurPays->getPays()->getId(),
'nom' => $secteurPays->getPays()->getNom(),
'indicatif' => $secteurPays->getPays()->getIndicatif(),
];
}
return $pays;
}
/**
* @return array
* @throws \Exception
*/
public function getSecteurPaysPrefixPhonesArray(): array
{
$prefixPhones = [];
foreach ($this->getSecteurPaysCollection() as $secteurPays) {
$prefixPhones[$secteurPays->getPays()->getId()] = $secteurPays->getPrefixPhone() ?? '';
}
return $prefixPhones;
}
/**
* @return Collection|SecteurPlanningRegulation[]
*/
public function getSecteurPlanningRegulationCollection(): Collection
{
return $this->secteurPlanningRegulation;
}
/**
* @param int $planningId
* @param int $jourTypeId
* @param \DateTimeInterface $debutHeure
* @param \DateTimeInterface $finHeure
* @return bool
*/
public function hasSecteurPlanningRegulation(int $planningId, int $jourTypeId, \DateTimeInterface $debutHeure, \DateTimeInterface $finHeure): bool
{
return $this->getSecteurPlanningRegulationCollection()->filter(function (SecteurPlanningRegulation $secteurPlanningRegulation) use ($planningId,$jourTypeId,$debutHeure,$finHeure){
return $secteurPlanningRegulation->getPlanningId() == $planningId
&& $secteurPlanningRegulation->getJourType()->getId() == $jourTypeId
&& $secteurPlanningRegulation->getDebutHeure() == $debutHeure
&& $secteurPlanningRegulation->getFinHeure() == $finHeure;
})->count() == 1;
}
/**
* @return Collection|SecteurTexteMail[]
*/
public function getSecteurTexteMailCollection(): Collection
{
return $this->secteurTexteMail;
}
/**
* @return Collection|SecteurTextePredefini[]
*/
public function getSecteurTextePredefiniCollection(): Collection
{
return $this->secteurTextePredefini;
}
/**
* @return Collection|SecteurZone[]
*/
public function getSecteurZoneCollection(): Collection
{
return $this->secteurZone;
}
/**
* @param int $id
* @return bool
*/
public function hasSecteurZoneById(int $id): bool
{
return $this->getSecteurZoneCollection()->filter(function (SecteurZone $secteurZone) use ($id){
return $secteurZone->getId() == $id;
})->count() == 1;
}
/**
* @param int $id
* @return SecteurZone
* @throws \Exception
*/
public function getSecteurZoneById(int $id): SecteurZone
{
return $this->getSecteurZoneCollection()->filter(function (SecteurZone $secteurZone) use ($id){
return $secteurZone->getId() == $id;
})->first();
}
/**
* @return Collection|SousSecteur[]
*/
public function getSousSecteurCollection(): Collection
{
return $this->sousSecteur;
}
/**
* @param string $nom
* @return SousSecteur
* @throws \Exception
*/
public function getSousSecteurByNom(string $nom): SousSecteur
{
return $this->getSousSecteurCollection()->filter(function (SousSecteur $sousSecteur) use ($nom){
return $sousSecteur->getNom() == $nom;
})->first();
}
/**
* @param string $nom
* @return bool
* @throws \Exception
*/
public function hasSousSecteurByNom(string $nom): bool
{
return $this->getSousSecteurCollection()->filter(function (SousSecteur $sousSecteur) use ($nom){
return $sousSecteur->getNom() == $nom;
})->count() == 1;
}
/**
* @param int $id
* @return bool
* @throws \Exception
*/
public function hasSousSecteurById(int $id): bool
{
return $this->getSousSecteurCollection()->filter(function (SousSecteur $sousSecteur) use ($id){
return $sousSecteur->getId() == $id;
})->count() == 1;
}
/**
* @param int $id
* @return SousSecteur
* @throws \Exception
*/
public function getSousSecteurById(int $id): SousSecteur
{
return $this->getSousSecteurCollection()->filter(function (SousSecteur $sousSecteur) use ($id){
return $sousSecteur->getId() == $id;
})->first();
}
}