<?php
/*
* This file is part of ProductSort
*
* Copyright(c) Akira Kurozumi <info@a-zumi.net>
*
* https://a-zumi.net
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace Plugin\ProductSort42\Entity;
use Doctrine\ORM\Mapping as ORM;
if (!class_exists(Config::class)) {
/**
* @ORM\Table(name="plg_product_sort4_config")
*
* @ORM\HasLifecycleCallbacks()
*
* @ORM\Entity(repositoryClass="Plugin\ProductSort42\Repository\ConfigRepository")
*/
class Config
{
public const ID = 1;
/**
* @var int
*
* @ORM\Column(name="id", type="integer", options={"unsigned":true})
*
* @ORM\Id
*
* @ORM\GeneratedValue(strategy="IDENTITY")
*/
private $id;
/**
* @var booloan
*
* @ORM\Column(name="status", type="boolean", options={"default":false})
*/
private $status = false;
/**
* @return int
*/
public function getId(): int
{
return $this->id;
}
/**
* @return bool
*/
public function getStatus(): bool
{
return $this->status;
}
/**
* @param bool $status
*
* @return $this
*/
public function setStatus(bool $status): self
{
$this->status = $status;
return $this;
}
/**
* @return bool
*/
public function isEnable(): bool
{
return $this->getStatus();
}
}
}