From 4eafb1679290824a6c00f638fd25e90c4e1f37d9 Mon Sep 17 00:00:00 2001 From: Eugeny Galkovskiy Date: Thu, 27 Jul 2017 10:58:52 +0300 Subject: [PATCH] карта2 --- frontend/views/site/index.php | 13 +++++++++++++ 1 file changed, 13 insertions(+), 0 deletions(-) diff --git a/frontend/views/site/index.php b/frontend/views/site/index.php index 11b74d5..41f200a 100644 --- a/frontend/views/site/index.php +++ b/frontend/views/site/index.php @@ -2,7 +2,20 @@ /* @var $this yii\web\View */ +use common\models\Settings; +use frontend\assets\MapAsset; +use yii\web\View; + +MapAsset::register($this); +$settings = Settings::getInstance(); $this->title = 'My Yii Application'; + +$js = <<< JS +window.lat = {$settings->lat}; +window.lon = {$settings->lon}; +JS; + +$this->registerJs($js, View::POS_END); ?> -- libgit2 0.21.4