Code doc improvements

This commit is contained in:
Samuel Georges 2017-07-27 17:35:14 +10:00
parent 06f4b44878
commit 9cadea9b19
20 changed files with 246 additions and 41 deletions

View File

@ -10,18 +10,29 @@ use System\Classes\SettingsManager;
*
* @package october\system
* @author Alexey Bobkov, Samuel Georges
*
*/
class AccessLogs extends Controller
{
/**
* @var array Extensions implemented by this controller.
*/
public $implement = [
'Backend.Behaviors.ListController'
\Backend\Behaviors\ListController::class
];
public $requiredPermissions = ['system.access_logs'];
/**
* @var array `ListController` configuration.
*/
public $listConfig = 'config_list.yaml';
/**
* @var array Permissions required to view this page.
*/
public $requiredPermissions = ['system.access_logs'];
/**
* Constructor.
*/
public function __construct()
{
parent::__construct();

View File

@ -21,8 +21,14 @@ use Exception;
*/
class Auth extends Controller
{
/**
* @var array Public controller actions
*/
protected $publicActions = ['index', 'signin', 'signout', 'restore', 'reset'];
/**
* Constructor.
*/
public function __construct()
{
parent::__construct();

View File

@ -18,6 +18,7 @@ class Index extends Controller
use \Backend\Traits\InspectableContainer;
/**
* @var array Permissions required to view this page.
* @see checkPermissionRedirect()
*/
public $requiredPermissions = [];

View File

@ -18,11 +18,17 @@ use Backend\Models\Preference as PreferenceModel;
class Preferences extends Controller
{
public $implement = [
'Backend.Behaviors.FormController',
\Backend\Behaviors\FormController::class
];
/**
* @var array `FormController` configuration.
*/
public $formConfig = 'config_form.yaml';
/**
* @var array Permissions required to view this page.
*/
public $requiredPermissions = ['backend.manage_preferences'];
/**

View File

@ -14,16 +14,32 @@ use System\Classes\SettingsManager;
*/
class UserGroups extends Controller
{
/**
* @var array Extensions implemented by this controller.
*/
public $implement = [
'Backend.Behaviors.FormController',
'Backend.Behaviors.ListController'
\Backend\Behaviors\FormController::class,
\Backend\Behaviors\ListController::class
];
/**
* @var array `FormController` configuration.
*/
public $formConfig = 'config_form.yaml';
/**
* @var array `ListController` configuration.
*/
public $listConfig = 'config_list.yaml';
/**
* @var array Permissions required to view this page.
*/
public $requiredPermissions = ['backend.manage_users'];
/**
* Constructor.
*/
public function __construct()
{
parent::__construct();

View File

@ -16,16 +16,32 @@ use System\Classes\SettingsManager;
*/
class UserRoles extends Controller
{
/**
* @var array Extensions implemented by this controller.
*/
public $implement = [
'Backend.Behaviors.FormController',
'Backend.Behaviors.ListController'
\Backend\Behaviors\FormController::class,
\Backend\Behaviors\ListController::class
];
/**
* @var array `FormController` configuration.
*/
public $formConfig = 'config_form.yaml';
/**
* @var array `ListController` configuration.
*/
public $listConfig = 'config_list.yaml';
/**
* @var array Permissions required to view this page.
*/
public $requiredPermissions = ['backend.manage_users'];
/**
* Constructor.
*/
public function __construct()
{
parent::__construct();

View File

@ -16,18 +16,32 @@ use System\Classes\SettingsManager;
*/
class Users extends Controller
{
/**
* @var array Extensions implemented by this controller.
*/
public $implement = [
'Backend.Behaviors.FormController',
'Backend.Behaviors.ListController'
\Backend\Behaviors\FormController::class,
\Backend\Behaviors\ListController::class
];
/**
* @var array `FormController` configuration.
*/
public $formConfig = 'config_form.yaml';
/**
* @var array `ListController` configuration.
*/
public $listConfig = 'config_list.yaml';
public $requiredPermissions = ['backend.manage_users'];
/**
* @var array Permissions required to view this page.
*/
public $bodyClass = 'compact-container';
/**
* Constructor.
*/
public function __construct()
{
parent::__construct();

View File

@ -35,8 +35,14 @@ class Index extends Controller
{
use \Backend\Traits\InspectableContainer;
/**
* @var Cms\Classes\Theme
*/
protected $theme;
/**
* @var array Permissions required to view this page.
*/
public $requiredPermissions = [
'cms.manage_content',
'cms.manage_assets',

View File

@ -12,6 +12,9 @@ use Cms\Widgets\MediaManager;
*/
class Media extends Controller
{
/**
* @var array Permissions required to view this page.
*/
public $requiredPermissions = ['media.*'];
/**

View File

@ -21,17 +21,32 @@ use Exception;
*/
class ThemeLogs extends Controller
{
/**
* @var array Extensions implemented by this controller.
*/
public $implement = [
'Backend.Behaviors.FormController',
'Backend.Behaviors.ListController'
\Backend\Behaviors\FormController::class,
\Backend\Behaviors\ListController::class
];
public $requiredPermissions = ['system.access_logs'];
/**
* @var array `FormController` configuration.
*/
public $formConfig = 'config_form.yaml';
/**
* @var array `ListController` configuration.
*/
public $listConfig = 'config_list.yaml';
/**
* @var array Permissions required to view this page.
*/
public $requiredPermissions = ['system.access_logs'];
/**
* Constructor.
*/
public function __construct()
{
parent::__construct();

View File

@ -19,12 +19,21 @@ use Exception;
*/
class ThemeOptions extends Controller
{
/**
* @var array Extensions implemented by this controller.
*/
public $implement = [
'Backend.Behaviors.FormController'
\Backend\Behaviors\FormController::class
];
/**
* @var array `FormController` configuration.
*/
public $formConfig = 'config_form.yaml';
/**
* @var array Permissions required to view this page.
*/
public $requiredPermissions = ['cms.manage_themes', 'cms.manage_theme_options'];
/**

View File

@ -27,6 +27,9 @@ use Exception;
*/
class Themes extends Controller
{
/**
* @var array Permissions required to view this page.
*/
public $requiredPermissions = ['cms.manage_themes'];
/**

View File

@ -22,17 +22,32 @@ use Exception;
*/
class EventLogs extends Controller
{
/**
* @var array Extensions implemented by this controller.
*/
public $implement = [
'Backend.Behaviors.FormController',
'Backend.Behaviors.ListController'
\Backend\Behaviors\FormController::class,
\Backend\Behaviors\ListController::class
];
public $requiredPermissions = ['system.access_logs'];
/**
* @var array `FormController` configuration.
*/
public $formConfig = 'config_form.yaml';
/**
* @var array `ListController` configuration.
*/
public $listConfig = 'config_list.yaml';
/**
* @var array Permissions required to view this page.
*/
public $requiredPermissions = ['system.access_logs'];
/**
* Constructor.
*/
public function __construct()
{
parent::__construct();

View File

@ -25,14 +25,26 @@ use Exception;
*/
class MailBrandSettings extends Controller
{
/**
* @var array Extensions implemented by this controller.
*/
public $implement = [
\Backend\Behaviors\FormController::class
];
/**
* @var array `FormController` configuration.
*/
public $formConfig = 'config_form.yaml';
/**
* @var array Permissions required to view this page.
*/
public $requiredPermissions = ['system.manage_mail_templates'];
/**
* @var string HTML body tag class
*/
public $bodyClass = 'compact-container';
/**

View File

@ -20,14 +20,26 @@ use Exception;
*/
class MailLayouts extends Controller
{
/**
* @var array Extensions implemented by this controller.
*/
public $implement = [
'Backend.Behaviors.FormController',
\Backend\Behaviors\FormController::class,
];
public $requiredPermissions = ['system.manage_mail_templates'];
/**
* @var array `FormController` configuration.
*/
public $formConfig = 'config_form.yaml';
/**
* @var array Permissions required to view this page.
*/
public $requiredPermissions = ['system.manage_mail_templates'];
/**
* Constructor.
*/
public function __construct()
{
parent::__construct();

View File

@ -20,14 +20,26 @@ use Exception;
*/
class MailPartials extends Controller
{
/**
* @var array Extensions implemented by this controller.
*/
public $implement = [
'Backend.Behaviors.FormController',
\Backend\Behaviors\FormController::class,
];
public $requiredPermissions = ['system.manage_mail_templates'];
/**
* @var array `FormController` configuration.
*/
public $formConfig = 'config_form.yaml';
/**
* @var array Permissions required to view this page.
*/
public $requiredPermissions = ['system.manage_mail_templates'];
/**
* Constructor.
*/
public function __construct()
{
parent::__construct();

View File

@ -22,21 +22,36 @@ use Exception;
*/
class MailTemplates extends Controller
{
/**
* @var array Extensions implemented by this controller.
*/
public $implement = [
'Backend.Behaviors.FormController',
'Backend.Behaviors.ListController'
\Backend\Behaviors\FormController::class,
\Backend\Behaviors\ListController::class
];
public $requiredPermissions = ['system.manage_mail_templates'];
/**
* @var array `FormController` configuration.
*/
public $formConfig = 'config_form.yaml';
/**
* @var array `ListController` configuration.
*/
public $listConfig = [
'templates' => 'config_templates_list.yaml',
'layouts' => 'config_layouts_list.yaml',
'partials' => 'config_partials_list.yaml'
];
public $formConfig = 'config_form.yaml';
/**
* @var array Permissions required to view this page.
*/
public $requiredPermissions = ['system.manage_mail_templates'];
/**
* Constructor.
*/
public function __construct()
{
parent::__construct();

View File

@ -21,17 +21,31 @@ use Exception;
*/
class RequestLogs extends Controller
{
/**
* @var array Extensions implemented by this controller.
*/
public $implement = [
'Backend.Behaviors.FormController',
'Backend.Behaviors.ListController'
\Backend\Behaviors\FormController::class,
\Backend\Behaviors\ListController::class
];
public $requiredPermissions = ['system.access_logs'];
/**
* @var array `FormController` configuration.
*/
public $formConfig = 'config_form.yaml';
/**
* @var array `ListController` configuration.
*/
public $listConfig = 'config_list.yaml';
/**
* @var array Permissions required to view this page.
*/
public $requiredPermissions = ['system.access_logs'];
/**
* Constructor.
*/
public function __construct()
{
parent::__construct();

View File

@ -31,12 +31,29 @@ use Exception;
*/
class Updates extends Controller
{
public $implement = ['Backend.Behaviors.ListController'];
/**
* @var array Extensions implemented by this controller.
*/
public $implement = [
\Backend\Behaviors\ListController::class
];
/**
* @var array `ListController` configuration.
*/
public $listConfig = [
'list' => 'config_list.yaml',
'manage' => 'config_manage_list.yaml'
];
/**
* @var array Permissions required to view this page.
*/
public $requiredPermissions = ['system.manage_updates'];
public $listConfig = ['list' => 'config_list.yaml', 'manage' => 'config_manage_list.yaml'];
/**
* Constructor.
*/
public function __construct()
{
parent::__construct();

View File

@ -24,7 +24,9 @@ class MailSetting extends Model
/**
* @var array Behaviors implemented by this model.
*/
public $implement = ['System.Behaviors.SettingsModel'];
public $implement = [
\System\Behaviors\SettingsModel::class
];
/**
* @var string Unique code