Hi,
I am trying to use CJuiDateTimePicker and having the problem with editing text field directly. After I set the values in CJuiDateTimePicker it affects the text field but not vice-versa. If I focus into the text field and change for example datetime
2012-06-07 01:48
to
2010-06-07 01:48
the year should be selected also in the picker.
Maybe I have sth wrong in code (I am newbie).
Here is a snippet from my view:
<div class="row">
<?php echo $form->labelEx($model->solutionSpentTimes,'datetime_from'); ?>
<?php Yii::import('application.extensions.CJuiDateTimePicker.CJuiDateTimePicker');
$this->widget('CJuiDateTimePicker',array(
'model'=>$model->solutionSpentTimes, //Model object
'attribute'=>'datetime_from', //attribute name
'mode'=>'datetime', //use "time","date" or "datetime" (default)
'language' => '',
'options'=>array(
'showAnim'=>'fold',
'showButtonPanel'=>true,
'autoSize'=>true,
'dateFormat'=>'yy-mm-dd',
'timeFormat'=>'hh:mm',
'witdh'=>'120',
'separator'=>' ',
),
'htmlOptions' => array(
'style' => 'width:180px;',
),
));
?>
</div>
Thanks in advance.