summaryrefslogtreecommitdiff
path: root/app/Api
diff options
context:
space:
mode:
authorTimo Litzbarski <tili2@gmx.de>2015-09-18 14:18:34 +0000
committerTimo Litzbarski <tili2@gmx.de>2015-09-18 14:18:34 +0000
commit1fa72295f20aa9794f1b33dfde95960c34d85366 (patch)
tree01727142fb5196192c468d1ec3970c92e3a063be /app/Api
parent55ca46ad754b87991e5cc4c4bc26657b19d37830 (diff)
User-Api: add getMyPorjects (#1233)
Diffstat (limited to 'app/Api')
-rw-r--r--app/Api/Base.php1
-rw-r--r--app/Api/Me.php5
2 files changed, 6 insertions, 0 deletions
diff --git a/app/Api/Base.php b/app/Api/Base.php
index fe78d99d..c1be1878 100644
--- a/app/Api/Base.php
+++ b/app/Api/Base.php
@@ -20,6 +20,7 @@ abstract class Base extends \Core\Base
'createMyPrivateProject',
'getMyProjectsList',
'getMyOverdueTasks',
+ 'getMyProjects',
);
private $both_allowed_procedures = array(
diff --git a/app/Api/Me.php b/app/Api/Me.php
index bc721c09..ff317557 100644
--- a/app/Api/Me.php
+++ b/app/Api/Me.php
@@ -57,4 +57,9 @@ class Me extends Base
{
return $this->taskFinder->getOverdueTasksByUser($this->userSession->getId());
}
+
+ public function getMyProjects()
+ {
+ return $this->formatProjects($this->project->getAllByIds($this->projectPermission->getActiveMemberProjectIds($this->userSession->getId())));
+ }
}