first commit symfony 6
This commit is contained in:
227
src/Entity/Config.php
Normal file
227
src/Entity/Config.php
Normal file
@ -0,0 +1,227 @@
|
||||
<?php
|
||||
|
||||
namespace App\Entity;
|
||||
|
||||
use App\Repository\ConfigRepository;
|
||||
use Doctrine\DBAL\Types\Types;
|
||||
use Doctrine\ORM\Mapping as ORM;
|
||||
|
||||
/**
|
||||
* Cron
|
||||
*
|
||||
* @ORM\Table(name="config")
|
||||
* @ORM\HasLifecycleCallbacks()
|
||||
* @ORM\Entity(repositoryClass="App\Repository\ConfigRepository")
|
||||
*/
|
||||
class Config
|
||||
{ /**
|
||||
* @ORM\Id
|
||||
* @ORM\Column(type="string")
|
||||
*/
|
||||
private $id;
|
||||
|
||||
/**
|
||||
* @ORM\Column(type="string", length=250)
|
||||
*/
|
||||
private $title;
|
||||
|
||||
/**
|
||||
* @ORM\Column(type="text", nullable=true)
|
||||
*/
|
||||
private $value;
|
||||
|
||||
/**
|
||||
* @ORM\Column(name="defaultvalue", type="text")
|
||||
*/
|
||||
private $default;
|
||||
|
||||
/**
|
||||
* @ORM\Column(name="roworder", type="string")
|
||||
*/
|
||||
private $order;
|
||||
|
||||
/**
|
||||
* @ORM\Column(type="boolean")
|
||||
*/
|
||||
private $visible;
|
||||
|
||||
/**
|
||||
* @ORM\Column(type="boolean")
|
||||
*/
|
||||
private $changeable;
|
||||
|
||||
/**
|
||||
* @ORM\Column(type="boolean")
|
||||
*/
|
||||
private $required;
|
||||
|
||||
/**
|
||||
* @ORM\Column(type="string")
|
||||
*/
|
||||
private $type;
|
||||
|
||||
/**
|
||||
* @ORM\Column(type="string")
|
||||
*/
|
||||
private $grouped;
|
||||
|
||||
/**
|
||||
* @ORM\Column(type="string")
|
||||
*/
|
||||
private $category;
|
||||
|
||||
/**
|
||||
* @ORM\Column(type="text")
|
||||
*/
|
||||
private $help;
|
||||
|
||||
//== CODE A NE PAS REGENERER
|
||||
|
||||
public function setId(string $id): self
|
||||
{
|
||||
$this->id = $id;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
public function getValue(): ?string
|
||||
{
|
||||
if($this->value=="") return $this->default;
|
||||
else return $this->value;
|
||||
}
|
||||
|
||||
//== FIN DU CODE A NE PAS REGENERER
|
||||
|
||||
public function getId(): ?string
|
||||
{
|
||||
return $this->id;
|
||||
}
|
||||
|
||||
|
||||
public function getTitle(): ?string
|
||||
{
|
||||
return $this->title;
|
||||
}
|
||||
|
||||
public function setTitle(string $title): self
|
||||
{
|
||||
$this->title = $title;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
public function setValue(?string $value): self
|
||||
{
|
||||
$this->value = $value;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
public function getDefault(): ?string
|
||||
{
|
||||
return $this->default;
|
||||
}
|
||||
|
||||
public function setDefault(string $default): self
|
||||
{
|
||||
$this->default = $default;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
public function getOrder(): ?string
|
||||
{
|
||||
return $this->order;
|
||||
}
|
||||
|
||||
public function setOrder(string $order): self
|
||||
{
|
||||
$this->order = $order;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
public function isVisible(): ?bool
|
||||
{
|
||||
return $this->visible;
|
||||
}
|
||||
|
||||
public function setVisible(bool $visible): self
|
||||
{
|
||||
$this->visible = $visible;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
public function isChangeable(): ?bool
|
||||
{
|
||||
return $this->changeable;
|
||||
}
|
||||
|
||||
public function setChangeable(bool $changeable): self
|
||||
{
|
||||
$this->changeable = $changeable;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
public function isRequired(): ?bool
|
||||
{
|
||||
return $this->required;
|
||||
}
|
||||
|
||||
public function setRequired(bool $required): self
|
||||
{
|
||||
$this->required = $required;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
public function getType(): ?string
|
||||
{
|
||||
return $this->type;
|
||||
}
|
||||
|
||||
public function setType(string $type): self
|
||||
{
|
||||
$this->type = $type;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
public function getGrouped(): ?string
|
||||
{
|
||||
return $this->grouped;
|
||||
}
|
||||
|
||||
public function setGrouped(string $grouped): self
|
||||
{
|
||||
$this->grouped = $grouped;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
public function getCategory(): ?string
|
||||
{
|
||||
return $this->category;
|
||||
}
|
||||
|
||||
public function setCategory(string $category): self
|
||||
{
|
||||
$this->category = $category;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
public function getHelp(): ?string
|
||||
{
|
||||
return $this->help;
|
||||
}
|
||||
|
||||
public function setHelp(string $help): self
|
||||
{
|
||||
$this->help = $help;
|
||||
|
||||
return $this;
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user