src/Entity/CentroCusto.php line 10

Open in your IDE?
  1. <?php
  2. namespace App\Entity;
  3. use Doctrine\ORM\Mapping as ORM;
  4. /**
  5.  * @ORM\Entity(repositoryClass="App\Repository\CentroCustoRepository")
  6.  */
  7. class CentroCusto
  8. {
  9.     /**
  10.      * @ORM\Id()
  11.      * @ORM\GeneratedValue()
  12.      * @ORM\Column(type="integer")
  13.      */
  14.     private $id;
  15.     /**
  16.      * @ORM\Column(type="string", length=155)
  17.      */
  18.     private $titulo;
  19.     /**
  20.      * @ORM\Column(type="string", length=45)
  21.      */
  22.     private $classificacao;
  23.     /**
  24.      * @ORM\Column(type="text", nullable=true)
  25.      */
  26.     private $descricao;
  27.     /**
  28.      * @ORM\Column(type="boolean", options={"default" : 0})
  29.      */
  30.     private $isReceita;
  31.     /**
  32.      * @ORM\Column(type="float", nullable=true)
  33.      */
  34.     private $metaPercentualSobreFaturamento;
  35.     public function __toString()
  36.     {
  37.         return !empty($this->titulo) ? $this->getClassificacao() . ' - ' $this->titulo 'Novo Centro de Custo';
  38.     }
  39.     public function getId(): ?int
  40.     {
  41.         return $this->id;
  42.     }
  43.     public function getTitulo(): ?string
  44.     {
  45.         return $this->titulo;
  46.     }
  47.     public function setTitulo(string $titulo): self
  48.     {
  49.         $this->titulo $titulo;
  50.         return $this;
  51.     }
  52.     public function getClassificacao(): ?string
  53.     {
  54.         return $this->classificacao;
  55.     }
  56.     public function setClassificacao(string $classificacao): self
  57.     {
  58.         $this->classificacao $classificacao;
  59.         return $this;
  60.     }
  61.     public function getDescricao(): ?string
  62.     {
  63.         return $this->descricao;
  64.     }
  65.     public function setDescricao(?string $descricao): self
  66.     {
  67.         $this->descricao $descricao;
  68.         return $this;
  69.     }
  70.     public function getIsReceita(): ?bool
  71.     {
  72.         return $this->isReceita;
  73.     }
  74.     public function setIsReceita(bool $isReceita): self
  75.     {
  76.         $this->isReceita $isReceita;
  77.         return $this;
  78.     }
  79.     public function getMetaPercentualSobreFaturamento(): ?float
  80.     {
  81.         return $this->metaPercentualSobreFaturamento;
  82.     }
  83.     public function setMetaPercentualSobreFaturamento(?float $metaPercentualSobreFaturamento): self
  84.     {
  85.         $this->metaPercentualSobreFaturamento $metaPercentualSobreFaturamento;
  86.         return $this;
  87.     }
  88. }