74 lines
1.6 KiB
PHP
74 lines
1.6 KiB
PHP
<?php
|
|
|
|
declare(strict_types=1);
|
|
|
|
namespace App\Form;
|
|
|
|
use Zend\Form\Annotation;
|
|
|
|
/**
|
|
* @Annotation\Name("slide")
|
|
* @Annotation\Hydrator("doctrine.hydrator")
|
|
*/
|
|
class Slide
|
|
{
|
|
/**
|
|
* @Annotation\Type("Zend\Form\Element\Hidden")
|
|
* @Annotation\Required(false)
|
|
* @var int
|
|
*/
|
|
private $id;
|
|
|
|
/**
|
|
* @Annotation\Type("Zend\Form\Element\Text")
|
|
* @Annotation\Required(true)
|
|
* @Annotation\InputFilter("Zend\Filter\StringTrim")
|
|
* @Annotation\Options({
|
|
* "label": "Slide title"
|
|
* })
|
|
* @var string
|
|
*/
|
|
private $title;
|
|
|
|
/**
|
|
* @Annotation\Type("Zend\Form\Element\Text")
|
|
* @Annotation\Required(true)
|
|
* @Annotation\Options({
|
|
* "label": "Team",
|
|
* "target_class": "App\Entity\Team",
|
|
* "display_empty_item": false,
|
|
* "empty_item_label": "",
|
|
* "is_method": true,
|
|
* "find_method": {
|
|
* "name": "findBy",
|
|
* "params": {
|
|
* "criteria": {"isActive": true},
|
|
* "orderBy": {"name": "ASC"}
|
|
* }
|
|
* }
|
|
* })
|
|
* @var
|
|
*/
|
|
private $team;
|
|
|
|
/**
|
|
* @Annotation\Type("Zend\Form\Element\Text")
|
|
* @Annotation\Required(true)
|
|
* @Annotation\InputFilter("Zend\Filter\StringTrim")
|
|
* @Annotation\Options({
|
|
* "label": "Slide contents"
|
|
* })
|
|
* @var
|
|
*/
|
|
private $slideData;
|
|
|
|
/**
|
|
* @Annotation\Type("Zend\Form\Element\Checkbox")
|
|
* @Annotation\Options({
|
|
* "label": "Visible"
|
|
* })
|
|
* @var bool
|
|
*/
|
|
private $isVisible;
|
|
}
|