我在我的 Yii 应用程序中使用ejuidatetimepicker 。它提供日期和时间选择器。我只想要时间选择器,我尝试了两个选项mode => 'time'
和timeOnly=>true
. 它不工作。
请找到我的以下代码。
$this->widget( 'application.extensions.timepicker.EJuiDateTimePicker', array(
'model' => $model, // Your model
'attribute' => 'starttime', // Attribute for input
//'mode'=>'time', //Not working Error Message is "Property "EJuiDateTimePicker.mode" is not defined. "
//timeOnly - Default: false - Hide the datepicker and only provide a time interface.
'timeOnly' => true, // Not working Error Message is "Property "EJuiDateTimePicker.timeOnly" is not defined."
'options' => array(
'showOn'=>'focus',
'timeFormat'=>'hh:mm:ss',
'showSecond'=>true,
//'timeOnly' => true, // Not working Error Message is "Property "EJuiDateTimePicker.timeOnly" is not defined."
) ,
'htmlOptions' => array(
'autocomplete' => 'off',
'size' => 10,
'maxlength' => 10,
),
));