Commit 93c2e36508f95800646dc99ad0218b926e6517b7

Authored by Administrator
1 parent 79769aa4

big commti

frontend/assets/AppAsset.php
@@ -31,13 +31,13 @@ class AppAsset extends AssetBundle @@ -31,13 +31,13 @@ class AppAsset extends AssetBundle
31 public $depends = [ 31 public $depends = [
32 'yii\web\JqueryAsset', 32 'yii\web\JqueryAsset',
33 'sersid\owlcarousel\Asset', 33 'sersid\owlcarousel\Asset',
34 - 'frontend\assets\FlipclockAsset',  
35 'yii\bootstrap\BootstrapPluginAsset', 34 'yii\bootstrap\BootstrapPluginAsset',
36 35
37 ]; 36 ];
38 -  
39 - public function init() {  
40 - $this->jsOptions['position'] = View::POS_END;  
41 - parent::init();  
42 - } 37 +
  38 + public $jsOptions = [
  39 + 'position' => View::POS_END
  40 + ];
  41 +
  42 +
43 } 43 }
frontend/assets/FlipclockAsset.php
@@ -25,4 +25,9 @@ class FlipclockAsset extends AssetBundle @@ -25,4 +25,9 @@ class FlipclockAsset extends AssetBundle
25 public $jsOptions = array( 25 public $jsOptions = array(
26 'position' => \yii\web\View::POS_END 26 'position' => \yii\web\View::POS_END
27 ); 27 );
  28 +
  29 + public $depends = [
  30 + 'yii\web\JqueryAsset'
  31 +
  32 + ];
28 } 33 }
frontend/views/event/show.php
@@ -3,9 +3,10 @@ @@ -3,9 +3,10 @@
3 * @var $this View 3 * @var $this View
4 */ 4 */
5 5
  6 +use frontend\assets\FlipclockAsset;
6 use yii\web\View; 7 use yii\web\View;
7 use yii\widgets\ListView; 8 use yii\widgets\ListView;
8 - 9 +FlipclockAsset::register($this);
9 10
10 ?> 11 ?>
11 <?php 12 <?php