File tree Expand file tree Collapse file tree 2 files changed +7
-5
lines changed Expand file tree Collapse file tree 2 files changed +7
-5
lines changed Original file line number Diff line number Diff line change @@ -30,6 +30,13 @@ public function init()
30
30
// 'baseUrl' => '@web/themes/adminlte',
31
31
]);
32
32
33
+ if ($ this ->theme == 'adminlteiframe ' ) {
34
+ $ this ->defaultRoute = 'adminlteiframe/layout ' ; // for adminlteiframe theme
35
+ $ this ->controllerMap ['adminlteiframe ' ] = [ // for adminlteiframe theme
36
+ 'class ' => 'myzero1\adminlteiframe\controllers\SiteController '
37
+ ];
38
+ }
39
+
33
40
// \Yii::$app->layoutPath = '@vendor/myzero1/yii2-theme-adminlteiframe/src/views/'.$this->theme.'/layouts';
34
41
// \Yii::$app->layout = 'main'; // default
35
42
Original file line number Diff line number Diff line change @@ -15,12 +15,7 @@ class DefaultController extends Controller
15
15
*/
16
16
public function actionIndex ()
17
17
{
18
- // $this->layout = 'layout'; // using the view of module
19
- if ($ this ->module ->theme == 'adminlteiframe ' ) {
20
- $ this ->layout = '//layout ' ; // using the view of app
21
- }
22
18
return $ this ->render ('index ' ); // using the view of module
23
- // return $this->render('//index'); // using the view of app
24
19
}
25
20
26
21
/**
You can’t perform that action at this time.
0 commit comments