%PDF-1.5 %���� ºaâÚÎΞ-ÌE1ÍØÄ÷{òò2ÿ ÛÖ^ÔÀá TÎ{¦?§®¥kuµùÕ5sLOšuY
Server IP : 49.231.201.246 / Your IP : 216.73.216.149 Web Server : Apache/2.4.18 (Ubuntu) System : Linux 246 4.4.0-210-generic #242-Ubuntu SMP Fri Apr 16 09:57:56 UTC 2021 x86_64 User : root ( 0) PHP Version : 7.0.33-0ubuntu0.16.04.16 Disable Function : exec,passthru,shell_exec,system,proc_open,popen,pcntl_exec MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : ON | Pkexec : ON Directory : /proc/11585/cwd/html/ppaobm/vendor/zhuravljov/yii2-datetime-widgets/src/ |
Upload File : |
<?php /** * @link https://github.com/zhuravljov/yii2-datetime-widgets * @copyright Copyright (c) 2017 Roman Zhuravlev * @license http://opensource.org/licenses/BSD-3-Clause */ namespace zhuravljov\yii\widgets; use yii\helpers\Json; /** * Class DatePicker * * @author Roman Zhuravlev <zhuravljov@gmail.com> */ class DatePicker extends DateWidget { /** * @var array options for datepicker */ public $clientOptions = []; /** * @var array events for datepicker */ public $clientEvents = []; /** * @inheritdoc */ protected function registerPlugin() { $asset = DatePickerAsset::register($this->view); if (isset($this->clientOptions['language'])) { $lang = $this->clientOptions['language']; $this->view->registerJsFile($asset->baseUrl . "/locales/bootstrap-datepicker.$lang.min.js", [ 'depends' => DatePickerAsset::class, ]); } $id = $this->options['id']; $options = empty($this->clientOptions) ? '' : Json::encode($this->clientOptions); $js = "jQuery('#$id').datepicker($options)"; foreach ($this->clientEvents as $event => $handler) { $js .= ".on('$event', $handler)"; } $this->view->registerJs($js . ';'); } }