summaryrefslogtreecommitdiff
path: root/app/ServiceProvider/ClassProvider.php
diff options
context:
space:
mode:
Diffstat (limited to 'app/ServiceProvider/ClassProvider.php')
-rw-r--r--app/ServiceProvider/ClassProvider.php20
1 files changed, 12 insertions, 8 deletions
diff --git a/app/ServiceProvider/ClassProvider.php b/app/ServiceProvider/ClassProvider.php
index 9df2dede..322c1a9b 100644
--- a/app/ServiceProvider/ClassProvider.php
+++ b/app/ServiceProvider/ClassProvider.php
@@ -8,9 +8,7 @@ use Kanboard\Core\ObjectStorage\FileStorage;
use Kanboard\Core\Paginator;
use Kanboard\Core\OAuth2;
use Kanboard\Core\Tool;
-use Kanboard\Model\Config;
-use Kanboard\Model\Project;
-use Kanboard\Model\Webhook;
+use Kanboard\Model\UserNotificationType;
use Pimple\Container;
use Pimple\ServiceProviderInterface;
use League\HTMLToMarkdown\HtmlConverter;
@@ -32,12 +30,7 @@ class ClassProvider implements ServiceProviderInterface
'File',
'LastLogin',
'Link',
- 'Notification',
- 'NotificationType',
- 'NotificationFilter',
'OverdueNotification',
- 'WebNotification',
- 'EmailNotification',
'Project',
'ProjectActivity',
'ProjectAnalytic',
@@ -68,6 +61,10 @@ class ClassProvider implements ServiceProviderInterface
'User',
'UserImport',
'UserSession',
+ 'UserNotification',
+ 'UserNotificationType',
+ 'UserNotificationFilter',
+ 'UserUnreadNotification',
'Webhook',
),
'Formatter' => array(
@@ -131,6 +128,13 @@ class ClassProvider implements ServiceProviderInterface
return $mailer;
};
+ $container['userNotificationType'] = function($container) {
+ $type = new UserNotificationType($container);
+ $type->setType('email', t('Email'), '\Kanboard\Notification\Mail');
+ $type->setType('web', t('Web'), '\Kanboard\Notification\Web');
+ return $type;
+ };
+
$container['pluginLoader'] = new Loader($container);
$container['cspRules'] = array('style-src' => "'self' 'unsafe-inline'", 'img-src' => '* data:');