<?php
/**
* Compte.php
* Created by Stéphane Brun
* Date: 2018-03-29 at 13:21
*/
namespace App\Entity;
use Doctrine\ORM\Mapping as ORM;
/**
* @ORM\Entity
* @ORM\Table(name="tcomptes")
*/
class Comptes
{
const COMPTE_ACCOMPTE = 30202;
/**
* @ORM\Column(type="integer")
* @ORM\Id
* @ORM\GeneratedValue(strategy="AUTO")
*/
protected $id;
/**
* @ORM\Column(name="cnom", type="string", length=50)
*/
protected $nom;
/**
* One Product has Many Features.
* @ORM\OneToMany(targetEntity="Debourse", mappedBy="compte")
*/
protected $debourse;
/**
* has one Company
*
* @ORM\ManyToOne(targetEntity="App\Entity\Company")
* @ORM\JoinColumn(name="company_id", referencedColumnName="id", nullable=true)
*/
protected $company;
public function __toString()
{
return $this->getNom();
}
/**
* @return mixed
*/
public function getId()
{
return $this->id;
}
/**
* @return mixed
*/
public function getNom()
{
return $this->nom;
}
/**
* @param mixed $nom
*/
public function setNom($nom)
{
$this->nom = $nom;
}
/**
* @return mixed
*/
public function getCompany()
{
return $this->company;
}
/**
* @param Company $company
*/
public function setCompany(Company $company)
{
$this->company = $company;
}
/**
* @return mixed
*/
public function getDebourse()
{
return $this->debourse;
}
/**
* @param mixed $debourse
*/
public function setDebourse($debourse)
{
$this->debourse = $debourse;
}
}