Closed dmdb closed 7 years ago
Can't figure out how clear button works. Using simple configuration of widget in GridView filter:
<?php Pjax::begin(); ?> <?= GridView::widget([ 'dataProvider' => $dataProvider, 'filterModel' => $searchModel, 'columns' => [ ['class' => 'yii\grid\SerialColumn'], 'id', 'username', 'email:email', 'created_at:datetime', [ 'attribute' => 'last_login', 'format' => 'datetime', 'filter' => DatePicker::widget([ 'model' => $searchModel, 'attribute' => 'last_login', 'template' => '{addon}{input}', 'clientOptions' => [ 'autoclose' => true, 'format' => 'yyyy-mm-dd', 'clearBtn' => true, ], ]) ], ['class' => 'yii\grid\ActionColumn'], ], ]); ?> <?php Pjax::end(); ?>
Pushing clear does'nt reload GridView. Inputs val() clears, but actual attribute value - not. It seems that none of change event is firing also. Am I miss something simple? In other parts widget works just great.
Iam sorry it seems, that is DatePicker Issue, not DateTimePicker.
Can't figure out how clear button works. Using simple configuration of widget in GridView filter:
Pushing clear does'nt reload GridView. Inputs val() clears, but actual attribute value - not. It seems that none of change event is firing also. Am I miss something simple? In other parts widget works just great.