Quantcast
Channel: Yii Framework Forum
Viewing all articles
Browse latest Browse all 18717

Yiistrap - How To Render Whdatetimepicker Inside Tbactiveform

$
0
0
Hi,

I am playing with yiistrap and yiiwheels. I want to use WhDateTimePicker inside of TbActiveForm. I want to render also its label and validation errors, so I used method TbHtml::customActiveControlGroup:

<?php $form = $this->beginWidget('bootstrap.widgets.TbActiveForm'); ?>

// ...

    <?php $datePicker = $this->widget('yiiwheels.widgets.datetimepicker.WhDateTimePicker', array(
        'model' => $model,
        'attribute' => 'date_',
    ), true); ?>

    <?php echo TbHtml::customActiveControlGroup($datePicker, $model, 'date_'); ?>

// ...

<?php $this->endWidget(); ?>



Widget itself works fine and also label is rendered. But validation error is not shown. I would expect so, because all others methods named *ControlGroup render also errors. How to do it? Thanks.

Viewing all articles
Browse latest Browse all 18717

Latest Images

Trending Articles



Latest Images

<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>