Commit 3a8a9bd9c74fee33392a9069e6af159a7827f550
1 parent
d881beaf
image size
Showing
15 changed files
with
26 additions
and
19 deletions
Show diff stats
frontend/assets/AppAsset.php
... | ... | @@ -24,14 +24,14 @@ class AppAsset extends AssetBundle |
24 | 24 | public $js = [ |
25 | 25 | ]; |
26 | 26 | public $depends = [ |
27 | - 'yii\web\JqueryAsset', | |
28 | - 'sersid\owlcarousel\Asset' | |
29 | - //'yii\web\YiiAsset', | |
27 | +// 'yii\web\JqueryAsset', | |
28 | + 'sersid\owlcarousel\Asset', | |
29 | + 'yii\web\YiiAsset', | |
30 | 30 | //'yii\bootstrap\BootstrapAsset', |
31 | 31 | ]; |
32 | 32 | |
33 | 33 | public function init() { |
34 | - $this->jsOptions['position'] = View::POS_HEAD; | |
34 | + $this->jsOptions['position'] = View::POS_END; | |
35 | 35 | parent::init(); |
36 | 36 | } |
37 | 37 | } | ... | ... |
frontend/config/main.php
... | ... | @@ -12,6 +12,13 @@ return [ |
12 | 12 | 'bootstrap' => ['log'], |
13 | 13 | 'controllerNamespace' => 'frontend\controllers', |
14 | 14 | 'components' => [ |
15 | + 'assetManager' => [ | |
16 | + 'bundles' => [ | |
17 | + 'yii\web\JqueryAsset' =>[ | |
18 | + 'jsOptions' => ['position' => \yii\web\View::POS_END] | |
19 | + ] | |
20 | + ], | |
21 | + ], | |
15 | 22 | 'authManager' => [ |
16 | 23 | 'class' => 'yii\rbac\DbManager', |
17 | 24 | ], | ... | ... |
frontend/views/basket/index.php
... | ... | @@ -11,7 +11,7 @@ $this->title = 'Корзина'; |
11 | 11 | $this->registerMetaTag(['name' => 'description', 'content' => 'Корзина']); |
12 | 12 | $this->registerMetaTag(['name' => 'keywords', 'content' => 'Корзина']); |
13 | 13 | |
14 | -$this->registerJsFile(Yii::$app->request->baseUrl.'/js/jquery.mask.js',['position'=>View::POS_HEAD,'depends'=>['yii\web\YiiAsset']]); | |
14 | +$this->registerJsFile(Yii::$app->request->baseUrl.'/js/jquery.mask.js',['position'=>View::POS_END,'depends'=>['yii\web\YiiAsset']]); | |
15 | 15 | |
16 | 16 | $this->registerJs(" |
17 | 17 | $('#orders-phone,#orders-phone2').mask('(000) 000-0000'); | ... | ... |
frontend/views/catalog/product.php
... | ... | @@ -72,7 +72,7 @@ $this->registerJs (" |
72 | 72 | ", View::POS_READY, 'nav_product'); |
73 | 73 | |
74 | 74 | $this->registerCssFile (Yii::$app->request->BaseUrl . '/js/shadowbox-3.0.3/shadowbox.css'); |
75 | -$this->registerJsFile (Yii::$app->request->baseUrl . '/js/shadowbox-3.0.3/shadowbox.js', ['position' => View::POS_HEAD, 'depends' => ['yii\web\JqueryAsset']]); | |
75 | +$this->registerJsFile (Yii::$app->request->baseUrl . '/js/shadowbox-3.0.3/shadowbox.js', ['position' => View::POS_END, 'depends' => ['yii\web\JqueryAsset']]); | |
76 | 76 | $this->registerJs (" |
77 | 77 | Shadowbox.init({ |
78 | 78 | ... | ... |
frontend/views/iam/edit_company.php
... | ... | @@ -10,7 +10,7 @@ $this->title = 'Редактирование Исполнителя - Компа |
10 | 10 | $this->params['breadcrumbs'][] = ['label'=>'Профиль','url'=>['/iam/index']]; |
11 | 11 | $this->params['breadcrumbs'][] = $this->title; |
12 | 12 | |
13 | -$this->registerJsFile(Yii::$app->request->baseUrl.'/js/jquery.mask.js',['position'=>View::POS_HEAD,'depends'=>['yii\web\YiiAsset']]); | |
13 | +$this->registerJsFile(Yii::$app->request->baseUrl.'/js/jquery.mask.js',['position'=>View::POS_END,'depends'=>['yii\web\YiiAsset']]); | |
14 | 14 | |
15 | 15 | $this->registerJs(" |
16 | 16 | $('#user-phone').mask('(000) 000-0000'); | ... | ... |
frontend/views/iam/edit_customer.php
... | ... | @@ -10,7 +10,7 @@ $this->title = 'Редактирование Заказчика'; |
10 | 10 | $this->params['breadcrumbs'][] = ['label'=>'Профиль','url'=>['/iam/index']]; |
11 | 11 | $this->params['breadcrumbs'][] = $this->title; |
12 | 12 | |
13 | -$this->registerJsFile(Yii::$app->request->baseUrl.'/js/jquery.mask.js',['position'=>View::POS_HEAD,'depends'=>['yii\web\YiiAsset']]); | |
13 | +$this->registerJsFile(Yii::$app->request->baseUrl.'/js/jquery.mask.js',['position'=>View::POS_END,'depends'=>['yii\web\YiiAsset']]); | |
14 | 14 | |
15 | 15 | $this->registerJs(" |
16 | 16 | $('#user-phone').mask('(000) 000-0000'); | ... | ... |
frontend/views/iam/edit_person.php
... | ... | @@ -12,7 +12,7 @@ $this->title = 'Редактирование профиля'; |
12 | 12 | $this->params['breadcrumbs'][] = ['label'=>'Профиль','url'=>['/iam/index']]; |
13 | 13 | $this->params['breadcrumbs'][] = $this->title; |
14 | 14 | |
15 | -$this->registerJsFile(Yii::$app->request->baseUrl.'/js/jquery.mask.js',['position'=>View::POS_HEAD,'depends'=>['yii\web\YiiAsset']]); | |
15 | +$this->registerJsFile(Yii::$app->request->baseUrl.'/js/jquery.mask.js',['position'=>View::POS_END,'depends'=>['yii\web\YiiAsset']]); | |
16 | 16 | |
17 | 17 | $this->registerJs(" |
18 | 18 | $('#user-phone').mask('(000) 000-0000'); | ... | ... |
frontend/views/layouts/main.php
... | ... | @@ -46,14 +46,14 @@ $this->registerJsFile (Yii::$app->request->baseUrl . '/js/fix_height.js', ['posi |
46 | 46 | |
47 | 47 | // jquery-migrate |
48 | 48 | $this->registerJsFile('http://code.jquery.com/jquery-migrate-1.3.0.js',[ |
49 | - 'position' => View::POS_HEAD, | |
49 | + 'position' => View::POS_END, | |
50 | 50 | 'depends' => ['yii\web\JqueryAsset'] |
51 | 51 | ]); |
52 | 52 | |
53 | 53 | // jcarousel |
54 | 54 | $this->registerCssFile(Yii::$app->request->BaseUrl.'/js/jsor-jcarousel-7bb2e0a/skins/tango/skin.css'); |
55 | 55 | $this->registerJsFile(Yii::$app->request->baseUrl.'/js/jsor-jcarousel-7bb2e0a/lib/jquery.jcarousel.min.js',[ |
56 | - 'position' => View::POS_HEAD, | |
56 | + 'position' => View::POS_END, | |
57 | 57 | 'depends' => ['yii\web\JqueryAsset'] |
58 | 58 | ]); |
59 | 59 | ... | ... |
frontend/views/products/_show.php
... | ... | @@ -27,7 +27,7 @@ $this->registerJs(" |
27 | 27 | |
28 | 28 | ", View::POS_READY, 'gallery'); |
29 | 29 | |
30 | -$this->registerJsFile(Yii::$app->request->baseUrl.'/js/jquery.sliderkit.1.9.2.pack.js',['position'=>View::POS_HEAD,'depends'=>['yii\web\YiiAsset']]); | |
30 | +$this->registerJsFile(Yii::$app->request->baseUrl.'/js/jquery.sliderkit.1.9.2.pack.js',['position'=>View::POS_END,'depends'=>['yii\web\YiiAsset']]); | |
31 | 31 | $this->registerJs(" |
32 | 32 | |
33 | 33 | $('.skit').sliderkit({ | ... | ... |
frontend/views/products/index.php
... | ... | @@ -20,8 +20,8 @@ $this->params['catalog_id'] = $catalog->id; |
20 | 20 | $this->registerMetaTag (['name' => 'description', 'content' => $catalog->meta_description]); |
21 | 21 | $this->registerMetaTag (['name' => 'keywords', 'content' => $catalog->meta_keywords]); |
22 | 22 | $this->registerCssFile (Yii::$app->request->BaseUrl . '/css/begunok.css'); |
23 | - $this->registerJsFile (Yii::$app->request->baseUrl . '/js/jquery.ui-slider.js', ['position' => View::POS_HEAD, 'depends' => ['yii\web\JqueryAsset']]); | |
24 | - $this->registerJsFile (Yii::$app->request->baseUrl . '/js/begunok.js', ['position' => View::POS_HEAD, 'depends' => ['yii\web\JqueryAsset']]); | |
23 | + $this->registerJsFile (Yii::$app->request->baseUrl . '/js/jquery.ui-slider.js', ['position' => View::POS_END, 'depends' => ['yii\web\JqueryAsset']]); | |
24 | + $this->registerJsFile (Yii::$app->request->baseUrl . '/js/begunok.js', ['position' => View::POS_END, 'depends' => ['yii\web\JqueryAsset']]); | |
25 | 25 | $this->params['breadcrumbs'][] = ['label' => 'Каталог', 'url' => ['/catalog/all']]; |
26 | 26 | if (! empty($catalog->parent)) $this->params['breadcrumbs'][] = ['label' => $catalog->parent->name, 'url' => ['products/index', 'translit' => $catalog->parent->translit]]; |
27 | 27 | $this->params['breadcrumbs'][] = ['label' => $catalog->name]; | ... | ... |
frontend/views/products/show.php
... | ... | @@ -60,7 +60,7 @@ use yii\widgets\Breadcrumbs; |
60 | 60 | ", View::POS_READY, 'nav_product'); |
61 | 61 | |
62 | 62 | $this->registerCssFile (Yii::$app->request->BaseUrl . '/js/shadowbox-3.0.3/shadowbox.css'); |
63 | - $this->registerJsFile (Yii::$app->request->baseUrl . '/js/shadowbox-3.0.3/shadowbox.js', ['position' => View::POS_HEAD, 'depends' => ['yii\web\JqueryAsset']]); | |
63 | + $this->registerJsFile (Yii::$app->request->baseUrl . '/js/shadowbox-3.0.3/shadowbox.js', ['position' => View::POS_END, 'depends' => ['yii\web\JqueryAsset']]); | |
64 | 64 | $this->registerJs (" |
65 | 65 | Shadowbox.init({ |
66 | 66 | ... | ... |
frontend/views/reg/company.php
... | ... | @@ -9,7 +9,7 @@ use yii\captcha\Captcha; |
9 | 9 | $this->title = 'Регистрация Исполнителя - Компания'; |
10 | 10 | $this->params['breadcrumbs'][] = $this->title; |
11 | 11 | |
12 | -$this->registerJsFile(Yii::$app->request->baseUrl.'/js/jquery.mask.js',['position'=>View::POS_HEAD,'depends'=>['yii\web\YiiAsset']]); | |
12 | +$this->registerJsFile(Yii::$app->request->baseUrl.'/js/jquery.mask.js',['position'=>View::POS_END,'depends'=>['yii\web\YiiAsset']]); | |
13 | 13 | |
14 | 14 | $this->registerJs(" |
15 | 15 | $('#user-phone').mask('(000) 000-0000'); | ... | ... |
frontend/views/reg/customer.php
... | ... | @@ -9,7 +9,7 @@ use yii\captcha\Captcha; |
9 | 9 | $this->title = 'Регистрация Заказчика'; |
10 | 10 | $this->params['breadcrumbs'][] = $this->title; |
11 | 11 | |
12 | -$this->registerJsFile(Yii::$app->request->baseUrl.'/js/jquery.mask.js',['position'=>View::POS_HEAD,'depends'=>['yii\web\YiiAsset']]); | |
12 | +$this->registerJsFile(Yii::$app->request->baseUrl.'/js/jquery.mask.js',['position'=>View::POS_END,'depends'=>['yii\web\YiiAsset']]); | |
13 | 13 | |
14 | 14 | $this->registerJs(" |
15 | 15 | $('#user-phone').mask('(000) 000-0000'); | ... | ... |
frontend/views/reg/person.php
... | ... | @@ -9,7 +9,7 @@ use yii\captcha\Captcha; |
9 | 9 | $this->title = 'Регистрация'; |
10 | 10 | $this->params['breadcrumbs'][] = $this->title; |
11 | 11 | |
12 | -$this->registerJsFile(Yii::$app->request->baseUrl.'/js/jquery.mask.js',['position'=>View::POS_HEAD,'depends'=>['yii\web\YiiAsset']]); | |
12 | +$this->registerJsFile(Yii::$app->request->baseUrl.'/js/jquery.mask.js',['position'=>View::POS_END,'depends'=>['yii\web\YiiAsset']]); | |
13 | 13 | |
14 | 14 | $this->registerJs(" |
15 | 15 | $('#customer-phone').mask('(000) 000-0000'); | ... | ... |
frontend/views/site/index.php
... | ... | @@ -12,7 +12,7 @@ use frontend\widgets\Seo; |
12 | 12 | $this->params['seo']['title'] = 'Купить городской рюкзак Киев | Купить рюкзаки Dakine Украина | Rukzachok.com.ua'; |
13 | 13 | $this->registerJsFile ( |
14 | 14 | Yii::$app->request->baseUrl . '/js/slides.min.jquery.js', |
15 | - ['position' => View::POS_HEAD, 'depends' => ['yii\web\JqueryAsset']]); | |
15 | + ['position' => View::POS_END, 'depends' => ['yii\web\JqueryAsset']]); | |
16 | 16 | |
17 | 17 | ?> |
18 | 18 | ... | ... |