resq/src/Entity/Dealer.php

81 lines
1.3 KiB
PHP

<?php
namespace App\Entity;
use Doctrine\ORM\Mapping as ORM;
use Symfony\Component\Validator\Constraints as Assert;
/**
* @ORM\Entity
* @ORM\Table(name="dealer")
*/
class Dealer
{
// unique id
/**
* @ORM\Id
* @ORM\Column(type="integer")
* @ORM\GeneratedValue(strategy="AUTO")
*/
protected $id;
// name of dealer
/**
* @ORM\Column(type="string", length=80)
* @Assert\NotBlank()
*/
protected $name;
// address
/**
* @ORM\Column(type="text")
* @Assert\NotBlank()
*/
protected $address;
// branch code of dealer
/**
* @ORM\Column(type="string", length=80)
* @Assert\NotBlank()
*/
protected $branch_code;
public function getId()
{
return $this->id;
}
public function setName($name)
{
$this->name = $name;
return $this;
}
public function getName()
{
return $this->name;
}
public function setAddress($address)
{
$this->address = $address;
return $this;
}
public function getAddress()
{
return $this->address;
}
public function setBranchCode($branch_code)
{
$this->branch_code = $branch_code;
return $this;
}
public function getBranchCode()
{
return $this->branch_code;
}
}