102 lines
1.8 KiB
PHP
102 lines
1.8 KiB
PHP
<?php
|
|
|
|
namespace App\Entity;
|
|
|
|
use Doctrine\ORM\Mapping as ORM;
|
|
|
|
use DateTime;
|
|
|
|
/**
|
|
* @ORM\Entity
|
|
* @ORM\Table(name="warranty_serial_upload_log")
|
|
*/
|
|
class WarrantySerialUploadLog
|
|
{
|
|
// unique id
|
|
/**
|
|
* @ORM\Id
|
|
* @ORM\Column(type="integer")
|
|
* @ORM\GeneratedValue(strategy="AUTO")
|
|
*/
|
|
protected $id;
|
|
|
|
// date created
|
|
/**
|
|
* @ORM\Column(type="datetime")
|
|
*/
|
|
protected $date_create;
|
|
|
|
// user that uploaded the file
|
|
/**
|
|
* @ORM\Column(type="string", length=32)
|
|
*/
|
|
protected $api_user;
|
|
|
|
// flag if uploaded
|
|
/**
|
|
* @ORM\Column(type="boolean")
|
|
*/
|
|
protected $flag_uploaded;
|
|
|
|
/**
|
|
* @ORM\Column(type="string", length=30, nullable=true)
|
|
*/
|
|
protected $error;
|
|
|
|
public function __construct()
|
|
{
|
|
$this->date_create = new DateTime();
|
|
$this->api_user = '';
|
|
$this->flag_uploaded = false;
|
|
$this->error = null;
|
|
}
|
|
|
|
public function getID()
|
|
{
|
|
return $this->id;
|
|
}
|
|
|
|
public function setDateCreate(DateTime $date_create)
|
|
{
|
|
$this->date_create = $date_create;
|
|
return $this;
|
|
}
|
|
|
|
public function getDateCreate()
|
|
{
|
|
return $this->date_create;
|
|
}
|
|
|
|
public function setApiUser($api_user)
|
|
{
|
|
$this->api_user = $api_user;
|
|
return $this;
|
|
}
|
|
|
|
public function getApiUser()
|
|
{
|
|
return $this->api_user;
|
|
}
|
|
|
|
public function setUploaded($flag_uploaded = true)
|
|
{
|
|
$this->flag_uploaded = $flag_uploaded;
|
|
return $this;
|
|
}
|
|
|
|
public function isUploaded()
|
|
{
|
|
return $this->flag_uploaded;
|
|
}
|
|
|
|
public function setError($error)
|
|
{
|
|
$this->error = $error;
|
|
return $this;
|
|
}
|
|
|
|
public function getError()
|
|
{
|
|
return $this->error;
|
|
}
|
|
}
|