Skip to content
This repository has been archived by the owner on Jul 27, 2023. It is now read-only.

Calendar does not pop up #41

Open
brian2453 opened this issue Jan 21, 2017 · 5 comments
Open

Calendar does not pop up #41

brian2453 opened this issue Jan 21, 2017 · 5 comments

Comments

@brian2453
Copy link

When I click on the form field nothing happens. I can see the changes to the field, but doesn't work. Not sure if I missed something but I followed the installation without any issues.

<?php $form = ActiveForm::begin(); ?>

<?=$form->field($model, 'class_name')->dropDownList(
    ArrayHelper::map(ClassTitles::find()->all(), 'class_name','class_name'), ['prompt'=>'Select a Class'])?>

<?= $form->field($model, 'price')->textInput() ?>

<?= $form->field($model, 'weeks')->textInput() ?>

<?= $form->field($model, 'starting_date')->widget(
        DatePicker::className(), [
            // inline too, not bad
             'inline' => true, 
             // modify template for custom rendering
            'template' => '<div class="well well-sm" style="background-color: #fff; width:250px">{input}</div>',
            'clientOptions' => [
                'autoclose' => true,
                'format' => 'dd-M-yyyy'
            ]
    ]);?>

<?= $form->field($model, 'ending_date')->textInput() ?>

<?= $form->field($model, 'time')->textInput() ?>

<?= $form->field($model, 'duration')->textInput() ?>

<?= $form->field($model, 'scheduled_on')->textInput() ?>


<div class="form-group">
    <?= Html::submitButton($model->isNewRecord ? Yii::t('app', 'Create') : Yii::t('app', 'Update'), ['class' => $model->isNewRecord ? 'btn btn-success' : 'btn btn-primary']) ?>
</div>

<?php ActiveForm::end(); ?>
@tonydspaniard
Copy link
Member

Thats the inline version, it should render not popup.

@zakayothuku
Copy link

I am experiencing the same issue: the calendar not popping up when i focus on the input field.
What could be the problem?

    <?php $form = ActiveForm::begin(); ?>

    <div class="col-md-6">

    <?= $form->field($model, 'event_name')->textInput(['maxlength' => true]) ?>

    <?= $form->field($model, 'event_venue')->textInput(['maxlength' => true]) ?>

    <?= $form->field($model, 'event_start_date')->widget(
        DatePicker::className(), [
            // inline too, not bad
            'inline' => false,
            'clientOptions' => [
                'autoclose' => false,
                'format' => 'yyyy-mm-dd'
            ]
        ]);
    ?>

    <?= $form->field($model, 'event_end_date')->widget(
        DatePicker::className(), [
            // inline too, not bad
            'inline' => false,
            'clientOptions' => [
                'autoclose' => false,
                'format' => 'yyyy-mm-dd'
            ]
        ]);
    ?>

    <br>
    <div class="form-group pull-right">
        <?= Html::submitButton($model->isNewRecord ? Yii::t('app', 'Create Event') : Yii::t('app', 'Update'), ['class' => $model->isNewRecord ? 'btn btn-success' : 'btn btn-primary']) ?>
    </div>

    </div>

    <?php ActiveForm::end(); ?>

</div>

@tonydspaniard
Copy link
Member

@BillionaireZ @brian2453 have you checked the developer tools if there is any javascript error? what about the css file? is it rendered?

@Riastefania15
Copy link

I am experiencing the same issue: the calendar not popping up

<?= $form->field($model, 'Id_rekap')->textInput(['maxlength' => true]) ?>

<?= $form->field($model, 'tanggal')->widget(
DatePicker::className(), [
    // inline too, not bad
     'inline' => false, 
     // modify template for custom rendering
    //'template' => '<div class="well well-sm" style="background-color: #fff; width:250px">{input}</div>',
    'clientOptions' => [
        'autoclose' => true,
        'format' => 'dd-M-yyyy'
    ]

]);?>
?>

@push32
Copy link

push32 commented May 31, 2018

    <?= $form->field($model, 'event_start_date')->widget(
        DatePicker::className(), [
            // inline too, not bad
            'inline' => false,
            'clientOptions' => [
                'autoclose' => false,
                'format' => 'yyyy-mm-dd'
            ]
        ]);
    ?>

    <?= $form->field($model, 'event_end_date')->widget(
        DatePicker::className(), [
            // inline too, not bad
            'inline' => false,
            'clientOptions' => [
                'autoclose' => false,
                'format' => 'yyyy-mm-dd'
            ]
        ]);
    ?>

i've use same widget in one form, and event_start_date its show up but event_end_date not show up any suggestion?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

5 participants