Answer the question
In order to leave comments, you need to log in
DatePicker in Yii2 GridView not working?
Hey! I made a GridView on Yii2 and installed a datepicker from a kartik use kartik\widgets\DatePicker
. Set up the display of the datepicker like this:
'attribute' => 'register_date',
'format' => ['date', 'dd.MM.Y'],
'headerOptions' => ['width'=>'120', 'style'=>'text-align:center'],
'filter' => DatePicker::widget([
'name' => 'register_date',
'language' => 'ru',
'type' => DatePicker::TYPE_INPUT,
'pluginOptions' => [
'autoclose'=>false,
'format' => 'yyyy-mm-dd',
]
])
Answer the question
In order to leave comments, you need to log in
And if you write simply
You use html5?
In theory, the calendar should be displayed anyway, although not in all browsers...
Perhaps Cyril was right, if the search in the GridView is not configured, then even this will not save. After all, the input will send data by date to nowhere))
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question