Plugin feature 1: remove column
This commit is contained in:
29
Plugin.php
29
Plugin.php
@@ -1,6 +1,6 @@
|
||||
<?php
|
||||
|
||||
namespace Kanboard\Plugin\Skeleton;
|
||||
namespace Kanboard\Plugin\OrganonTweaks;
|
||||
|
||||
use Kanboard\Core\Plugin\Base;
|
||||
|
||||
@@ -8,28 +8,31 @@ class Plugin extends Base
|
||||
{
|
||||
public function initialize()
|
||||
{
|
||||
// 1. Render a visible word at the top of every page (the demo output).
|
||||
$this->template->hook->attach('template:layout:top', 'skeleton:layout/header');
|
||||
// "Remove this Column" entry in the board column header dropdown. The only
|
||||
// column hook renders outside the native menu <ul>, so the item is rendered
|
||||
// hidden and relocate.js moves it into the menu (like BulkMoveTasks).
|
||||
$this->template->hook->attach('template:board:column:dropdown', 'organonTweaks:board/column_dropdown');
|
||||
|
||||
// 2. Load the plugin stylesheet (currently empty -- proves the CSS hook fires).
|
||||
$this->hook->on('template:layout:css', array(
|
||||
'template' => 'plugins/Skeleton/Asset/css/skeleton.css',
|
||||
));
|
||||
|
||||
// 3. Load the plugin script (currently empty -- proves the JS hook fires).
|
||||
$this->hook->on('template:layout:js', array(
|
||||
'template' => 'plugins/Skeleton/Asset/js/skeleton.js',
|
||||
'template' => 'plugins/OrganonTweaks/Asset/js/relocate.js',
|
||||
));
|
||||
}
|
||||
|
||||
public function getHelpers()
|
||||
{
|
||||
return array(
|
||||
'Plugin\OrganonTweaks\Helper' => array('OrganonColumnHelper'),
|
||||
);
|
||||
}
|
||||
|
||||
public function getPluginName()
|
||||
{
|
||||
return 'Skeleton';
|
||||
return 'OrganonTweaks';
|
||||
}
|
||||
|
||||
public function getPluginDescription()
|
||||
{
|
||||
return t('Reusable skeleton/template for building Kanboard plugins.');
|
||||
return t('Umbrella plugin for small Kanboard tweaks. First tweak: remove an empty board column from its header menu.');
|
||||
}
|
||||
|
||||
public function getPluginAuthor()
|
||||
@@ -44,7 +47,7 @@ class Plugin extends Base
|
||||
|
||||
public function getPluginHomepage()
|
||||
{
|
||||
return 'https://code.beco.cc/beco/kanboard-plugin-skeleton';
|
||||
return 'https://code.beco.cc/beco/OrganonTweaks';
|
||||
}
|
||||
|
||||
public function getCompatibleVersion()
|
||||
|
||||
Reference in New Issue
Block a user