vendor/score/cms/src/Entity/Form/WebformField.php line 14

Open in your IDE?
  1. <?php
  2. namespace Score\CmsBundle\Entity\Form;
  3. use App\Bundle\TripLogBundle\Entity\Trip;
  4. use Doctrine\ORM\Mapping as ORM;
  5. use Score\BaseBundle\Entity\BaseEntity;
  6. /**
  7.  * @ORM\Table(name="cms_form_field")
  8.  * @ORM\HasLifecycleCallbacks()
  9.  * @ORM\Entity()
  10.  */
  11. class WebformField extends BaseEntity
  12. {
  13.     /**
  14.      * Many Fields have one form. This is the owning side.
  15.      * @ORM\ManyToOne(targetEntity="Webform", inversedBy="fields")
  16.      * @ORM\JoinColumn(name="form_id", referencedColumnName="id")
  17.      */
  18.     private $form;
  19.     /**
  20.      * @ORM\Column(type="string", name="identifier", length=255)
  21.      */
  22.     private $identifier;
  23.     /**
  24.      * @ORM\Column(type="string", name="f_title", length=1000)
  25.      */
  26.     private $title;
  27.     /**
  28.      * @ORM\Column(type="string", name="f_type", length=255)
  29.      */
  30.     private $type;
  31.     /**
  32.      * @ORM\Column(type="boolean", name="f_required")
  33.      */
  34.     private $required;
  35.     /**
  36.      * @ORM\Column(type="string", name="choices", length=5000, nullable=true)
  37.      */
  38.     private $choices;
  39.     /**
  40.      * @ORM\Column(type="integer", name="sort_order")
  41.      */
  42.     private $sortOrder;
  43.     /**
  44.      * @ORM\Column(type="string", name="help_text", length=1000, nullable=true)
  45.      */
  46.     private $helpText;
  47.     /**
  48.      * @ORM\Column(type="integer", name="f_rows", nullable=true)
  49.      */
  50.     private $rows;
  51.     /**
  52.      * @ORM\Column(type="integer", name="f_length", nullable=true)
  53.      */
  54.     private $length;
  55.     /**
  56.      * @ORM\Column(type="string", name="f_min", length=1000, nullable=true)
  57.      */
  58.     private $min;
  59.     /**
  60.      * @ORM\Column(type="string", name="f_max", length=1000, nullable=true)
  61.      */
  62.     private $max;
  63.     public function getForm(): ?Webform
  64.     {
  65.         return $this->form;
  66.     }
  67.     public function setForm(?Webform $form): self
  68.     {
  69.         $this->form $form;
  70.         return $this;
  71.     }
  72.     public function getIdentifier(): ?string
  73.     {
  74.         return $this->identifier;
  75.     }
  76.     public function setIdentifier(string $identifier): self
  77.     {
  78.         $this->identifier $identifier;
  79.         return $this;
  80.     }
  81.     public function getTitle(): ?string
  82.     {
  83.         return $this->title;
  84.     }
  85.     public function setTitle(?string $title): self
  86.     {
  87.         $this->title $title;
  88.         return $this;
  89.     }
  90.     public function getType(): ?string
  91.     {
  92.         return $this->type;
  93.     }
  94.     public function setType(string $type): self
  95.     {
  96.         $this->type $type;
  97.         return $this;
  98.     }
  99.     public function getRequired(): ?bool
  100.     {
  101.         return $this->required;
  102.     }
  103.     public function setRequired(bool $required): self
  104.     {
  105.         $this->required $required;
  106.         return $this;
  107.     }
  108.     public function getChoices(): ?string
  109.     {
  110.         return $this->choices;
  111.     }
  112.     public function setChoices(?string $choices): self
  113.     {
  114.         $this->choices $choices;
  115.         return $this;
  116.     }
  117.     public function getChoicesArr(): ?array
  118.     {
  119.         return json_decode($this->choicestrue);
  120.     }
  121.     public function setChoicesArr(?array $choices): self
  122.     {
  123.         $this->choices json_encode($choices);
  124.         return $this;
  125.     }
  126.     public function getSortOrder(): ?int
  127.     {
  128.         return $this->sortOrder;
  129.     }
  130.     public function setSortOrder(int $sortOrder): self
  131.     {
  132.         $this->sortOrder $sortOrder;
  133.         return $this;
  134.     }
  135.     public function getHelpText(): ?string
  136.     {
  137.         return $this->helpText;
  138.     }
  139.     public function setHelpText(?string $helpText): self
  140.     {
  141.         $this->helpText $helpText;
  142.         return $this;
  143.     }
  144.     public function getRows(): ?int
  145.     {
  146.         return $this->rows;
  147.     }
  148.     public function setRows(?int $rows): self
  149.     {
  150.         $this->rows $rows;
  151.         return $this;
  152.     }
  153.     public function getLength(): ?int
  154.     {
  155.         return $this->length;
  156.     }
  157.     public function setLength(?int $length): self
  158.     {
  159.         $this->length $length;
  160.         return $this;
  161.     }
  162.     public function getMin(): ?string
  163.     {
  164.         return $this->min;
  165.     }
  166.     public function setMin(?string $min): self
  167.     {
  168.         $this->min $min;
  169.         return $this;
  170.     }
  171.     public function getMax(): ?string
  172.     {
  173.         return $this->max;
  174.     }
  175.     public function setMax(?string $max): self
  176.     {
  177.         $this->max $max;
  178.         return $this;
  179.     }
  180. }