summaryrefslogtreecommitdiff
path: root/app/Controller/Base.php
diff options
context:
space:
mode:
Diffstat (limited to 'app/Controller/Base.php')
-rw-r--r--app/Controller/Base.php85
1 files changed, 3 insertions, 82 deletions
diff --git a/app/Controller/Base.php b/app/Controller/Base.php
index 30d0b4e4..19de6a93 100644
--- a/app/Controller/Base.php
+++ b/app/Controller/Base.php
@@ -16,67 +16,8 @@ use Symfony\Component\EventDispatcher\Event;
*
* @package controller
* @author Frederic Guillot
- *
- * @property \Core\Helper $helper
- * @property \Core\Session $session
- * @property \Core\Template $template
- * @property \Core\Paginator $paginator
- * @property \Integration\GithubWebhook $githubWebhook
- * @property \Integration\GitlabWebhook $gitlabWebhook
- * @property \Integration\BitbucketWebhook $bitbucketWebhook
- * @property \Integration\PostmarkWebhook $postmarkWebhook
- * @property \Integration\SendgridWebhook $sendgridWebhook
- * @property \Integration\MailgunWebhook $mailgunWebhook
- * @property \Model\Acl $acl
- * @property \Model\Authentication $authentication
- * @property \Model\Action $action
- * @property \Model\Board $board
- * @property \Model\Category $category
- * @property \Model\Color $color
- * @property \Model\Comment $comment
- * @property \Model\Config $config
- * @property \Model\DateParser $dateParser
- * @property \Model\File $file
- * @property \Model\HourlyRate $hourlyRate
- * @property \Model\LastLogin $lastLogin
- * @property \Model\Notification $notification
- * @property \Model\Project $project
- * @property \Model\ProjectPermission $projectPermission
- * @property \Model\ProjectDuplication $projectDuplication
- * @property \Model\ProjectAnalytic $projectAnalytic
- * @property \Model\ProjectActivity $projectActivity
- * @property \Model\ProjectDailySummary $projectDailySummary
- * @property \Model\ProjectIntegration $projectIntegration
- * @property \Model\Subtask $subtask
- * @property \Model\SubtaskForecast $subtaskForecast
- * @property \Model\Swimlane $swimlane
- * @property \Model\Task $task
- * @property \Model\Link $link
- * @property \Model\TaskCreation $taskCreation
- * @property \Model\TaskModification $taskModification
- * @property \Model\TaskDuplication $taskDuplication
- * @property \Model\TaskHistory $taskHistory
- * @property \Model\TaskExport $taskExport
- * @property \Model\TaskFinder $taskFinder
- * @property \Model\TaskFilter $taskFilter
- * @property \Model\TaskPosition $taskPosition
- * @property \Model\TaskPermission $taskPermission
- * @property \Model\TaskStatus $taskStatus
- * @property \Model\Timetable $timetable
- * @property \Model\TimetableDay $timetableDay
- * @property \Model\TimetableWeek $timetableWeek
- * @property \Model\TimetableExtra $timetableExtra
- * @property \Model\TimetableOff $timetableOff
- * @property \Model\TaskValidator $taskValidator
- * @property \Model\TaskLink $taskLink
- * @property \Model\CommentHistory $commentHistory
- * @property \Model\SubtaskHistory $subtaskHistory
- * @property \Model\SubtaskTimeTracking $subtaskTimeTracking
- * @property \Model\User $user
- * @property \Model\UserSession $userSession
- * @property \Model\Webhook $webhook
*/
-abstract class Base
+abstract class Base extends \Core\Base
{
/**
* Request instance
@@ -95,14 +36,6 @@ abstract class Base
protected $response;
/**
- * Container instance
- *
- * @access private
- * @var \Pimple\Container
- */
- private $container;
-
- /**
* Constructor
*
* @access public
@@ -134,18 +67,6 @@ abstract class Base
}
/**
- * Load automatically models
- *
- * @access public
- * @param string $name Model name
- * @return mixed
- */
- public function __get($name)
- {
- return $this->container[$name];
- }
-
- /**
* Send HTTP headers
*
* @access private
@@ -201,7 +122,7 @@ abstract class Base
$this->response->text('Not Authorized', 401);
}
- $this->response->redirect($this->helper->url('auth', 'login', array('redirect_query' => urlencode($this->request->getQueryString()))));
+ $this->response->redirect($this->helper->url->to('auth', 'login', array('redirect_query' => urlencode($this->request->getQueryString()))));
}
}
@@ -220,7 +141,7 @@ abstract class Base
$this->response->text('Not Authorized', 401);
}
- $this->response->redirect($this->helper->url('twofactor', 'code'));
+ $this->response->redirect($this->helper->url->to('twofactor', 'code'));
}
}