116 lines
2.7 KiB
PHP
116 lines
2.7 KiB
PHP
<?php
|
|
|
|
namespace Zoomyboy\Event;
|
|
|
|
use Backend;
|
|
use System\Classes\PluginBase;
|
|
|
|
/**
|
|
* event Plugin Information File.
|
|
*/
|
|
class Plugin extends PluginBase
|
|
{
|
|
/**
|
|
* Returns information about this plugin.
|
|
*
|
|
* @return array
|
|
*/
|
|
public function pluginDetails()
|
|
{
|
|
return [
|
|
'name' => 'event',
|
|
'description' => 'No description provided yet...',
|
|
'author' => 'zoomyboy',
|
|
'icon' => 'icon-leaf',
|
|
];
|
|
}
|
|
|
|
/**
|
|
* Register method, called when the plugin is first registered.
|
|
*
|
|
* @return void
|
|
*/
|
|
public function register()
|
|
{
|
|
}
|
|
|
|
/**
|
|
* Boot method, called right before the request route.
|
|
*
|
|
* @return array
|
|
*/
|
|
public function boot()
|
|
{
|
|
}
|
|
|
|
/**
|
|
* Registers any front-end components implemented in this plugin.
|
|
*
|
|
* @return array
|
|
*/
|
|
public function registerComponents()
|
|
{
|
|
return [
|
|
'Zoomyboy\Event\Components\EventForm' => 'event_form',
|
|
];
|
|
}
|
|
|
|
/**
|
|
* Registers any back-end permissions used by this plugin.
|
|
*
|
|
* @return array
|
|
*/
|
|
public function registerPermissions()
|
|
{
|
|
return []; // Remove this line to activate
|
|
|
|
return [
|
|
'zoomyboy.event.some_permission' => [
|
|
'tab' => 'event',
|
|
'label' => 'Some permission',
|
|
],
|
|
];
|
|
}
|
|
|
|
/**
|
|
* Registers back-end navigation items for this plugin.
|
|
*
|
|
* @return array
|
|
*/
|
|
public function registerNavigation()
|
|
{
|
|
return [
|
|
'event' => [
|
|
'label' => 'Teilnehmer',
|
|
'url' => Backend::url('zoomyboy/event/participant'),
|
|
'icon' => 'icon-leaf',
|
|
'permissions' => ['zoomyboy.event.*'],
|
|
'order' => 500,
|
|
'sideMenu' => [
|
|
'event' => [
|
|
'label' => 'Veranstaltungen',
|
|
'url' => Backend::url('zoomyboy/event/event'),
|
|
'icon' => 'icon-leaf',
|
|
'permissions' => ['zoomyboy.event.*'],
|
|
'order' => 500,
|
|
],
|
|
'participant' => [
|
|
'label' => 'Teilnehmer',
|
|
'url' => Backend::url('zoomyboy/event/participant'),
|
|
'icon' => 'icon-leaf',
|
|
'permissions' => ['zoomyboy.event.*'],
|
|
'order' => 500,
|
|
],
|
|
],
|
|
],
|
|
];
|
|
}
|
|
|
|
public function registerMailTemplates()
|
|
{
|
|
return [
|
|
'zoomyboy.event::mail.confirm',
|
|
];
|
|
}
|
|
}
|