-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
14 changed files
with
217 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
*.zip | ||
Makefile | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
.table-suboncard { | ||
margin-top: 10px; | ||
margin-bottom: 10px; | ||
border-top-style: solid; | ||
border-top-width: 12px; | ||
border-top-color: transparent; | ||
border-bottom-style: solid; | ||
border-bottom-width: 12px; | ||
border-bottom-color: transparent; | ||
} | ||
|
||
.table-suboncard td:nth-child(1) { | ||
font-size: .8em; | ||
padding-right: 25px; | ||
text-align: left; | ||
background-color: rgba(190, 190, 190, 0.1)!important; | ||
border: 0; | ||
padding-top: 0; | ||
} | ||
|
||
|
||
/* if Plugin "SubTaskDuedate is available, format date column */ | ||
.table-suboncard td:nth-child(2) { | ||
font-size: .8em; | ||
padding-right: 4px; | ||
background-color: rgba(190, 190, 190, 0.1)!important; | ||
border: 0; | ||
padding-top: 0; | ||
} | ||
|
||
/* nested html tags from Kanboard subtaskhelper are somehow complicated to format */ | ||
.table-suboncard .js-subtask-toggle-status { | ||
display: unset; | ||
} | ||
|
||
.table-suboncard .subtask-title i { | ||
display: flex; | ||
margin-left: 4px; | ||
} | ||
|
||
.table-suboncard .subtask-title a { | ||
display: -webkit-box; | ||
} |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
<?php | ||
|
||
namespace Kanboard\Plugin\SubtasksOnBoard\Helper; | ||
|
||
use Kanboard\Core\Base; | ||
use Kanboard\Model\SubtaskModel; | ||
|
||
class SubtasklistHelper extends Base | ||
{ | ||
public function subtasks($task_id) | ||
{ | ||
return $this->subtaskModel->getAll($task_id); | ||
} | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
<?php | ||
return array( | ||
'Displays the subtasks of a task on the task card on the board. One can change state of a subtask directly on the card. Supports display of subtask duedate if the plugin "Subtaskdate" is installed.' => 'Zeigt die Unteraufgaben eines Tasks direkt auf der Task-Karte auf dem Board an. Der Status der Unteraufgabe kann dort auch direkt geändert werden. Außerdem wird die Anzeige des Fälligkeitsdatums der Unteraufgabe unterstützt, wenn das PlugIn "Subtaskdate" installiert ist.', | ||
); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
<?php | ||
|
||
namespace Kanboard\Plugin\SubtasksOnBoard; | ||
|
||
use Kanboard\Core\Plugin\Base; | ||
use Kanboard\Core\Translator; | ||
|
||
class Plugin extends Base | ||
{ | ||
public function initialize() | ||
{ | ||
$this->helper->register('subtasklistHelper', '\Kanboard\Plugin\SubtasksOnBoard\Helper\SubtasklistHelper'); | ||
$this->template->hook->attach('template:board:private:task:after-title', 'SubtasksOnBoard:board/subtasklist'); | ||
$this->hook->on("template:layout:css", array("template" => "plugins/SubtasksOnBoard/Assets/css/subtasksonboard.css")); | ||
} | ||
|
||
public function onStartup() | ||
{ | ||
Translator::load($this->languageModel->getCurrentLanguage(), __DIR__.'/Locale'); | ||
} | ||
|
||
public function getPluginName() | ||
{ | ||
// Plugin Name MUST be identical to namespace for Plugin Directory to detect updated versions | ||
// Do not translate the plugin name here | ||
return 'SubtasksOnBoard'; | ||
} | ||
|
||
public function getPluginDescription() | ||
{ | ||
return t('Displays the subtasks of a task on the task card on the board. One can change state of a subtask directly on the card. Supports display of subtask duedate if the plugin "Subtaskdate" is installed.'); | ||
} | ||
|
||
public function getPluginAuthor() | ||
{ | ||
return 'JustFxDev, Till Schlueter'; | ||
} | ||
|
||
public function getPluginVersion() | ||
{ | ||
return '1.0.9'; | ||
} | ||
|
||
public function getCompatibleVersion() | ||
{ | ||
// Examples: | ||
// >=1.0.37 | ||
// <1.0.37 | ||
// <=1.0.37 | ||
return '>=1.2.20'; | ||
} | ||
|
||
public function getPluginHomepage() | ||
{ | ||
return 'https://github.com/JustFxDev/SubtaskOnBoard'; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
![north_west](./Assets/images/north_west.svg) Use the table of contents icon | ||
|
||
[![version](./Assets/images/version.svg)](https://github.com/JustFxDev/SubtasksOnBoard/releases) [![license](./Assets/images/license.svg)](https://github.com/JustFxDev/SubtasksOnBoard/blob/main/LICENSE) [![maintainedyes](./Assets/images/maintained.svg)](https://github.com/JustFxDev/SubtasksOnBoard/graphs/contributors) | ||
|
||
**:star: If you use it, you should star it on GitHub!** *It's the least you can do for all the work put into it!* | ||
|
||
|
||
# Show Subtasks on Board | ||
|
||
Displays the subtasks of a task on the task card on the board. One can change state of a subtask directly on the card. Supports display of [subtask due date](https://github.com/eSkiSo/Subtaskdate) if that plugin is installed. | ||
|
||
## Features | ||
|
||
- Set the status of a subtask directly on the card (not yet started, in progress, finished) | ||
|
||
- display due date of the sub task (needs the subtask due date plugin s. above) | ||
|
||
- Tested with [ThemeMaestro](https://github.com/JustFxDev/ThemeMaestro) | ||
|
||
## Screenshots | ||
|
||
![](./Assets/images/screenshot.png) | ||
|
||
Requirements | ||
------------ | ||
|
||
- Kanboard >= 1.2.20 | ||
|
||
## Installation | ||
|
||
Options for the installation: | ||
|
||
1. Installation via the plugin manager in Kanboard (recommended). | ||
2. Download the zip file from releases folder here in the repository and unzip it in the directory `plugins/SubtasksOnBoard` (recommended) | ||
3. Clone the repository (current master) into the directory `plugins/SubtasksOnBoard` (not recommended. Very latest code, but not yet released code) | ||
|
||
Note: All names in the plugin directory are case-sensitive | ||
|
||
## Possible further development | ||
|
||
- Provide configuration option to enable or disable the display of subtasks on cards per board | ||
|
||
## Authors & Contributors | ||
- [JustFxDev](https://github.com/JustFxDev/) - Author (since v1.0.9) | ||
- [rfde](https://github.com/rfde) - Author (until v1.0.0) | ||
- _Contributors welcome_ | ||
|
||
## License | ||
- This project is distributed under the [MIT License](../main/LICENSE "Read The MIT license") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
<?php | ||
$subtasks = $this->helper->subtasklistHelper->subtasks($task['id']); | ||
if (sizeof($subtasks) > 0): | ||
?> | ||
<table class="table-suboncard"> | ||
<?php foreach ($subtasks as $subtask): ?> | ||
<tr> | ||
<td> | ||
<?= $this->subtask->renderToggleStatus($task, $subtask) ?> | ||
</td> | ||
<?= $this->hook->render('template:board:tooltip:subtasks:rows', array('subtask' => $subtask)) ?> | ||
</tr> | ||
<?php endforeach ?> | ||
</table> | ||
<?php endif ?> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
# Changelog | ||
|
||
### What's Changed | ||
|
||
_(most recent changes are listed on top):_ | ||
|
||
## v1.0.9 | ||
|
||
- Corrected display glitches (css) | ||
- Supports "SubtaskDuedate" Plugin | ||
- Added language for plugin description | ||
- Minor changes to the plugin structure | ||
- Tested with "ThemeMaestro" | ||
- Friendly take over by JustFxDev from Till (rfde) - Thanks for that! | ||
|
||
|
||
## v1.0.0 | ||
|
||
- Initial release | ||
|
||
Read the full [**Changelog**](../main/changelog.md) or view the [**README**](../main/README.md) |