Add outletcounter entity

This commit is contained in:
Ramon Gutierrez 2018-02-04 23:40:12 +08:00
parent 884cd7b7f1
commit a6b1252f73

View file

@ -0,0 +1,74 @@
<?php
namespace App\Entity;
use Doctrine\ORM\Mapping as ORM;
use Doctrine\Common\Collections\ArrayCollection;
use Symfony\Component\Validator\Constraints as Assert;
/**
* @ORM\Entity
* @ORM\Table(name="outlet_counter")
*/
class OutletCounter
{
// identifying string
// format is "YYYYMMDD-XXX", where XXX is the outlet id
/**
* @ORM\Id
* @ORM\Column(type="string", length=15)
* @Assert\NotBlank()
*/
protected $id;
// sales counter
/**
* @ORM\Column(type="integer")
*/
protected $count_sales;
// service counter
/**
* @ORM\Column(type="integer")
*/
protected $count_service;
public function __construct()
{
$this->count_sales = 0;
$this->count_service = 0;
}
public function getID()
{
return $this->id;
}
public function setID($id)
{
$this->id = $id;
return $this;
}
public function getSalesCounter()
{
return $this->count_sales;
}
public function setSalesCounter($count_sales)
{
$this->count_sales = $count_sales;
return $this;
}
public function getServiceCounter()
{
return $this->count_service;
}
public function setServiceCounter($count_service)
{
$this->count_service = $count_service;
return $this;
}
}