Esempio n. 1
0
 /**
  * Sestavý validní HTML kód
  */
 public function build()
 {
     if ($this->label !== null && $this->label instanceof LabelControl) {
         $this->html .= $this->label->render();
     }
     if (!empty($this->value) && $this->showValue) {
         $this->addAttribute(new KeyPairValue('value', $this->value));
     }
     foreach ($this->rules as $rule) {
         $this->addAttribute($rule);
     }
     parent::build();
     return $this;
 }
Esempio n. 2
0
 /**
  * Sestaví formulář
  *
  * @return $this
  */
 public function build()
 {
     $this->addAttribute(new KeyPairValue('method', $this->method));
     return parent::build();
 }