diff --git a/Admin/Installer.php b/Admin/Installer.php index 9ea9245..7396cb4 100644 --- a/Admin/Installer.php +++ b/Admin/Installer.php @@ -87,6 +87,7 @@ class Installer extends InstallerAbstract ADD CONSTRAINT `' . $dbPool->get()->prefix . 'task_media_ibfk_2` FOREIGN KEY (`task_media_dst`) REFERENCES `' . $dbPool->get()->prefix . 'media` (`media_id`);' )->execute(); + // type = to, cc, bcc $dbPool->get()->con->prepare( 'CREATE TABLE if NOT EXISTS `' . $dbPool->get()->prefix . 'task_account` ( `task_account_id` int(11) NOT NULL AUTO_INCREMENT, diff --git a/Models/Task.php b/Models/Task.php index 18bb1b1..d616679 100644 --- a/Models/Task.php +++ b/Models/Task.php @@ -138,6 +138,8 @@ class Task implements \JsonSerializable protected $media = []; + protected $acc = []; + /** * Constructor. * diff --git a/Models/TaskMapper.php b/Models/TaskMapper.php index 5a73b51..ab9d035 100644 --- a/Models/TaskMapper.php +++ b/Models/TaskMapper.php @@ -77,6 +77,12 @@ class TaskMapper extends DataMapperAbstract 'dst' => 'task_media_src', 'src' => 'task_media_dst', ], + 'acc' => [ // todo: maybe make this a has one and then link to collection instead of single media files! + 'mapper' => AccountMapper::class, + 'table' => 'task_account', + 'dst' => 'task_account_account', + 'src' => 'task_account_task', + ], ]; protected static $belongsTo = [ diff --git a/Models/TaskPriority.php b/Models/TaskPriority.php index 06211eb..200fec4 100644 --- a/Models/TaskPriority.php +++ b/Models/TaskPriority.php @@ -27,13 +27,10 @@ use phpOMS\Stdlib\Base\Enum; */ abstract class TaskPriority extends Enum { + /* public */ const NONE = 0; /* public */ const VLOW = 1; - /* public */ const LOW = 2; - /* public */ const MEDIUM = 3; - /* public */ const HIGH = 4; - /* public */ const VHIGH = 5; } diff --git a/Theme/Backend/Lang/en.lang.php b/Theme/Backend/Lang/en.lang.php index 47852d1..25b8458 100644 --- a/Theme/Backend/Lang/en.lang.php +++ b/Theme/Backend/Lang/en.lang.php @@ -63,6 +63,7 @@ return ['Tasks' => [ 'S4' => 'Canceled', 'S5' => 'Done', 'S6' => 'Closed', + 'P0' => 'None', 'P1' => 'Very Low', 'P2' => 'Low', 'P3' => 'Medium', diff --git a/Theme/Backend/task-create.tpl.php b/Theme/Backend/task-create.tpl.php index 1baae08..e3abcb5 100644 --- a/Theme/Backend/task-create.tpl.php +++ b/Theme/Backend/task-create.tpl.php @@ -31,9 +31,10 @@ echo $this->getData('nav')->render(); ?>