Open mbischof opened 5 years ago
in your application/config/config.php add the following line:
application/config/config.php
'preload' => array('pluginManager'),
then it is possible to place a yii module in your plugin:
class TestModule extends PluginBase { static protected $description = 'TestModule Plugin'; static protected $name = 'TestModule'; protected $storage = 'DbStorage'; /** * subscribe to all events */ public function init() { $this->subscribe('afterPluginLoad'); } public function afterPluginLoad() { Yii:app()->setModules(array( 'report' => array( 'class' => 'webroot.plugins.TestModule.report.ReportModule', ) ), true); } }
now, after activating the plugin, you can call: http://limesurvey/index.php/report/module/index
http://limesurvey/index.php/report/module/index
TestModule.zip
this does not work, if the preload is declared in application/config/internal.php because installation process fails due to a CDbConnection Exception
application/config/internal.php
in your
application/config/config.php
add the following line:then it is possible to place a yii module in your plugin:
now, after activating the plugin, you can call:
http://limesurvey/index.php/report/module/index
TestModule.zip