Unable to set layout for gii and debug

Hi.

I’m using AdminLTE template for my backend site (an advanced app). I’m trying to use my template’s layout for all my module, in order to keep the menu on the backend. I added this to backend/config/main.php:




     'modules' => [

+        'translatemanager' => [

+            'layout' => '@backend/views/layouts/main',

+        ],

+        'gii' => [

+            'layout' => '@backend/views/layouts/main', // fixme

+        ],

+        'debug' => [

+            'layout' => '@backend/views/layouts/main', // fixme

+        ],




Now the translatemanager module uses the correct layout, while the other two are not!

So I checked backend/web/index.php and main.php comes obviously before main-local.php, where the [‘modules’][‘gii’] array gets overwritten (instead of merged). Ok, so I add it there so that it becomes




    $config['bootstrap'][] = 'gii';

    $config['modules']['gii'] = [ 

        'class' => 'yii\gii\Module',

        'layout' => '@backend/views/layouts/main', // fixme

    ];  



but still nothing.

Am I doing something wrong or is this not supported? thanks