src/Flexy/FrontBundle/Entity/FormField.php line 11
<?php
namespace App\Flexy\FrontBundle\Entity;
use ApiPlatform\Metadata\ApiResource;
use App\Repository\Entity\FormFieldRepository;
use Doctrine\ORM\Mapping as ORM;
#[ORM\Entity(repositoryClass: FormFieldRepository::class)]
#[ApiResource]
class FormField
{
#[ORM\Id]
#[ORM\GeneratedValue]
#[ORM\Column]
private ?int $id = null;
#[ORM\ManyToOne(inversedBy: 'formFields')]
private ?Form $form = null;
#[ORM\Column(length: 255)]
private ?string $label = null;
#[ORM\Column(length: 255)]
private ?string $type = null;
#[ORM\Column(nullable: true)]
private ?bool $required = null;
#[ORM\Column(length: 255)]
private ?string $name = null;
#[ORM\Column(nullable: true)]
private ?int $gridColumns = null;
#[ORM\Column(length: 255, nullable: true)]
private ?string $cssClasses = null;
public function getId(): ?int
{
return $this->id;
}
public function getForm(): ?Form
{
return $this->form;
}
public function setForm(?Form $form): static
{
$this->form = $form;
return $this;
}
public function getLabel(): ?string
{
return $this->label;
}
public function setLabel(string $label): static
{
$this->label = $label;
return $this;
}
public function getType(): ?string
{
return $this->type;
}
public function setType(string $type): static
{
$this->type = $type;
return $this;
}
public function isRequired(): ?bool
{
return $this->required;
}
public function setRequired(?bool $required): static
{
$this->required = $required;
return $this;
}
public function getName(): ?string
{
return $this->name;
}
public function setName(string $name): static
{
$this->name = $name;
return $this;
}
public function getGridColumns(): ?int
{
return $this->gridColumns;
}
public function setGridColumns(?int $gridColumns): static
{
$this->gridColumns = $gridColumns;
return $this;
}
public function getCssClasses(): ?string
{
return $this->cssClasses;
}
public function setCssClasses(?string $cssClasses): static
{
$this->cssClasses = $cssClasses;
return $this;
}
}