kartik-v / yii2-widget-timepicker

Enhanced Yii2 wrapper for the bootstrap timepicker plugin (sub repo split from yii2-widgets).
Other
41 stars 12 forks source link

showMeridian => false returns always empty value #10

Closed lupoalberto closed 5 years ago

lupoalberto commented 8 years ago

Hi

I'm using Timepicker in my yii2 application as follows:

    'time' => [
        'type' => TabularForm::INPUT_WIDGET,
        'widgetClass' => \kartik\datecontrol\DateControl::classname(),
        'options' => [
            'type' => \kartik\datecontrol\DateControl::FORMAT_TIME,
            'saveFormat' => 'php:H:i:s',
            'ajaxConversion' => true,
            'options' => [
                'pluginOptions' => [
                    'placeholder' => Yii::t('app', 'Choose Time'),
                    'autoclose' => true,
                    'showSeconds' => true,
                    'showMeridian' => false,
                    'minuteStep' => 1,
                    'secondStep' => 5,
                ]
            ]
        ]
    ],

As mentioned the problem is "showMeridian". Everything works fine, when it is set to true (the default value), but when I turn it to false, the hidden input field containing the time value is not going to be updated and so the returned time is always an empty string "".

stale[bot] commented 5 years ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.