Browse Source

Merge pull request #1715 from WouterSlob/1632

Make sure DatePicker is shown when inline and using a language. Remove not used use
tags/2.0.0-beta
Qiang Xue 11 years ago
parent
commit
978597919d
  1. 3
      extensions/yii/jui/DatePicker.php

3
extensions/yii/jui/DatePicker.php

@ -7,7 +7,6 @@
namespace yii\jui; namespace yii\jui;
use Yii;
use yii\helpers\Html; use yii\helpers\Html;
use yii\helpers\Json; use yii\helpers\Json;
@ -83,7 +82,7 @@ class DatePicker extends InputWidget
DatePickerRegionalAsset::register($view); DatePickerRegionalAsset::register($view);
$options = Json::encode($this->clientOptions); $options = Json::encode($this->clientOptions);
$view->registerJs("$('#{$this->options['id']}').datepicker($.extend({}, $.datepicker.regional['{$this->language}'], $options));"); $view->registerJs("$('#{$containerID}').datepicker($.extend({}, $.datepicker.regional['{$this->language}'], $options));");
$options = $this->clientOptions; $options = $this->clientOptions;
$this->clientOptions = false; // the datepicker js widget is already registered $this->clientOptions = false; // the datepicker js widget is already registered

Loading…
Cancel
Save