mirror of
https://github.com/symfony/recipes-contrib.git
synced 2026-09-15 00:56:29 +03:00
49 lines
894 B
PHP
49 lines
894 B
PHP
<?php
|
|
|
|
declare(strict_types=1);
|
|
|
|
namespace App\Entity;
|
|
|
|
use Doctrine\ORM\Mapping as ORM;
|
|
use JMS\Serializer\Annotation as Serializer;
|
|
use Sonata\ClassificationBundle\Entity\BaseContext;
|
|
|
|
/**
|
|
* @ORM\Entity
|
|
* @ORM\Table(name="classification__context")
|
|
* @ORM\HasLifecycleCallbacks
|
|
*/
|
|
class SonataClassificationContext extends BaseContext
|
|
{
|
|
/**
|
|
* @ORM\Id
|
|
* @ORM\Column(type="string")
|
|
* @ORM\GeneratedValue(strategy="NONE")
|
|
* // Serializer\Groups(groups={"sonata_api_read", "sonata_api_write", "sonata_search"})
|
|
*
|
|
* @var int
|
|
*/
|
|
protected $id;
|
|
|
|
public function getId()
|
|
{
|
|
return $this->id;
|
|
}
|
|
|
|
/**
|
|
* @ORM\PrePersist
|
|
*/
|
|
public function prePersist(): void
|
|
{
|
|
parent::prePersist();
|
|
}
|
|
|
|
/**
|
|
* @ORM\PreUpdate
|
|
*/
|
|
public function preUpdate(): void
|
|
{
|
|
parent::preUpdate();
|
|
}
|
|
}
|