Unify task drop-down menu between different views

This commit is contained in:
Frederic Guillot
2016-05-04 21:51:38 -04:00
parent 60c8867fee
commit 6bdc25490f
15 changed files with 152 additions and 171 deletions

View File

@@ -44,7 +44,7 @@ class BoardPopover extends Base
$this->flash->failure(t('Unable to update your task.'));
}
$this->response->redirect($this->helper->url->to('board', 'show', array('project_id' => $values['project_id'])));
$this->response->redirect($this->helper->url->to('board', 'show', array('project_id' => $values['project_id'])), true);
}
/**
@@ -81,7 +81,7 @@ class BoardPopover extends Base
$this->flash->failure(t('Unable to update your task.'));
}
$this->response->redirect($this->helper->url->to('board', 'show', array('project_id' => $values['project_id'])));
$this->response->redirect($this->helper->url->to('board', 'show', array('project_id' => $values['project_id'])), true);
}
/**

View File

@@ -151,7 +151,7 @@ class Task extends Base
{
$task = $this->getTask();
if (! $this->taskPermission->canRemoveTask($task)) {
if (! $this->helper->user->canRemoveTask($task)) {
$this->forbidden();
}
@@ -164,7 +164,7 @@ class Task extends Base
$this->flash->failure(t('Unable to remove this task.'));
}
$this->response->redirect($this->helper->url->to('board', 'show', array('project_id' => $task['project_id'])));
$this->response->redirect($this->helper->url->to('board', 'show', array('project_id' => $task['project_id'])), true);
}
$this->response->html($this->template->render('task/remove', array(