@@ -29,7 +29,7 @@ class DateInput extends Nette\Forms\Controls\BaseControl
29
29
public function __construct ($ label = null )
30
30
{
31
31
parent ::__construct ($ label );
32
- $ this ->addRule ([__CLASS__ , 'validateDate ' ], 'Date is invalid. ' );
32
+ $ this ->addRule ([self ::class , 'validateDate ' ], 'Date is invalid. ' );
33
33
}
34
34
35
35
@@ -76,20 +76,20 @@ public function getControl()
76
76
{
77
77
$ name = $ this ->getHtmlName ();
78
78
return Html::el ('input ' , [
79
- 'name ' => $ name . '[day] ' ,
80
- 'id ' => $ this ->getHtmlId (),
81
- 'value ' => $ this ->day ,
82
- 'type ' => 'number ' ,
83
- 'min ' => 1 ,
84
- 'max ' => 31 ,
85
- 'data-nette-rules ' => Helpers::exportRules ($ this ->getRules ()) ?: null ,
86
- ])
79
+ 'name ' => $ name . '[day] ' ,
80
+ 'id ' => $ this ->getHtmlId (),
81
+ 'value ' => $ this ->day ,
82
+ 'type ' => 'number ' ,
83
+ 'min ' => 1 ,
84
+ 'max ' => 31 ,
85
+ 'data-nette-rules ' => Helpers::exportRules ($ this ->getRules ()) ?: null ,
86
+ ])
87
87
88
88
. Helpers::createSelectBox (
89
- [1 => 1 , 2 , 3 , 4 , 5 , 6 , 7 , 8 , 9 , 10 , 11 , 12 ],
90
- [],
91
- $ this ->month
92
- )->name ($ name . '[month] ' )
89
+ [1 => 1 , 2 , 3 , 4 , 5 , 6 , 7 , 8 , 9 , 10 , 11 , 12 ],
90
+ [],
91
+ $ this ->month
92
+ )->name ($ name . '[month] ' )
93
93
94
94
. Html::el ('input ' , [
95
95
'name ' => $ name . '[year] ' ,
0 commit comments