snappymail/plugins/custom-admin-settings-tab/index.php

35 lines
630 B
PHP
Raw Normal View History

2016-06-05 04:26:50 +08:00
<?php
class CustomAdminSettingsTabPlugin extends \RainLoop\Plugins\AbstractPlugin
{
const
NAME = '',
CATEGORY = 'General',
DESCRIPTION = '';
2016-06-05 04:26:50 +08:00
/**
* @return void
*/
2020-08-31 00:04:54 +08:00
public function Init() : void
2016-06-05 04:26:50 +08:00
{
$this->UseLangs(true); // start use langs folder
$this->addJs('js/CustomAdminSettings.js', true); // add js file
$this->addJsonHook('JsonAdminGetData', 'JsonAdminGetData');
2016-06-05 04:26:50 +08:00
2020-11-25 21:39:46 +08:00
$this->addTemplate('templates/PluginCustomAdminSettingsTab.html', true);
2016-06-05 04:26:50 +08:00
}
/**
* @return array
*/
public function JsonAdminGetData()
2016-06-05 04:26:50 +08:00
{
return $this->jsonResponse(__FUNCTION__, array(
2016-06-05 04:26:50 +08:00
'PHP' => phpversion()
));
}
}