2023-03-11 14:53:06 +00:00
|
|
|
<?php
|
|
|
|
/**
|
|
|
|
* @brief dcLog, a plugin for Dotclear 2
|
|
|
|
*
|
|
|
|
* @package Dotclear
|
|
|
|
* @subpackage Plugin
|
|
|
|
*
|
|
|
|
* @author Tomtom and Contributors
|
|
|
|
*
|
|
|
|
* @copyright Jean-Christian Denis
|
|
|
|
* @copyright GPL-2.0 https://www.gnu.org/licenses/gpl-2.0.html
|
|
|
|
*/
|
|
|
|
declare(strict_types=1);
|
|
|
|
|
|
|
|
namespace Dotclear\Plugin\dcLog;
|
|
|
|
|
2023-10-07 20:57:21 +00:00
|
|
|
use Dotclear\App;
|
2023-07-28 21:39:25 +00:00
|
|
|
use Dotclear\Module\MyPlugin;
|
2023-03-11 14:53:06 +00:00
|
|
|
|
2023-07-28 21:39:25 +00:00
|
|
|
class My extends MyPlugin
|
2023-03-11 14:53:06 +00:00
|
|
|
{
|
2023-05-08 08:29:26 +00:00
|
|
|
/** @var string Admin list ID */
|
2023-03-11 14:53:06 +00:00
|
|
|
public const BACKEND_LIST_ID = 'dcloglist';
|
|
|
|
|
2023-07-28 21:39:25 +00:00
|
|
|
public static function checkCustomContext(int $context): ?bool
|
2023-05-08 08:29:26 +00:00
|
|
|
{
|
2023-10-07 20:57:21 +00:00
|
|
|
return App::auth()->isSuperAdmin();
|
2023-03-11 14:53:06 +00:00
|
|
|
}
|
|
|
|
}
|