javascript - How to Hide Date Menu from Datepicker in yii2 -
basically in datetimepicker widget date choose first time, how can hide date option widget , filter according time. tried not working want hide remove button
[ 'attribute'=>'time', 'label'=>'time', 'format'=>'raw', 'value'=>function($data){ return date('h:i:s',strtotime($data->time)); }, 'filter'=> datetimepicker::widget([ 'model' => $searchmodel, 'attribute' => 'time', 'clientoptions' => [ 'autoclose' => true, 'format' => 'hh:ii', 'showon' => 'button', ], ]), 'headeroptions' => ['width' => '10%', 'style' => 'text-align:center'], ],
assuming using nkovacs/yii2-datetimepicker, here can display time selector.
... 'filter'=> datetimepicker::widget([ 'model' => $searchmodel, 'attribute' => 'time', 'type' => datetimepicker::type_time, 'clientoptions' => [ 'autoclose' => true, 'format' => 'hh:ii', 'showon' => 'button', ], ]), ...
note 'type' => datetimepicker::type_time,
Comments
Post a Comment