@@ -10,15 +10,17 @@ |
||
10 | 10 | use TextFieldsTrait,FieldTrait; |
11 | 11 | |
12 | 12 | public function __construct($identifier, $label=NULL,$type="text",$value=NULL,$placeholder=NULL) { |
13 | - if(!isset($placeholder) && $type==="text") |
|
14 | - $placeholder=$label; |
|
13 | + if(!isset($placeholder) && $type==="text") { |
|
14 | + $placeholder=$label; |
|
15 | + } |
|
15 | 16 | parent::__construct("field-".$identifier, new HtmlInput($identifier,$type,$value,$placeholder), $label); |
16 | 17 | } |
17 | 18 | |
18 | 19 | public function getDataField(){ |
19 | 20 | $field= $this->getField(); |
20 | - if($field instanceof HtmlInput) |
|
21 | - $field=$field->getField(); |
|
21 | + if($field instanceof HtmlInput) { |
|
22 | + $field=$field->getField(); |
|
23 | + } |
|
22 | 24 | return $field; |
23 | 25 | } |
24 | 26 | } |
25 | 27 | \ No newline at end of file |