Workboards - let users delete columns

Summary: Fixes T4408. I had to add a "status" to colum. I think we'll need this once we get fancier anyway but for now we have "active" and deleted.

Test Plan: deleted a column. noted reloaded workboard with all those tasks back in the default colun. loaded a task and saw the initial transaction had a "Disabled" icon next to the deleted workboard. also saw the new transaction back to the default column worked.

Reviewers: epriestley

Reviewed By: epriestley

Subscribers: epriestley, Korvin

Maniphest Tasks: T4408

Differential Revision: https://secure.phabricator.com/D8544
This commit is contained in:
Bob Trahan
2014-03-18 10:40:31 -07:00
parent 1e8ed3e5ff
commit 809e5a0389
9 changed files with 153 additions and 1 deletions

View File

@@ -30,6 +30,7 @@ final class PhabricatorProjectBoardController
$columns = id(new PhabricatorProjectColumnQuery())
->setViewer($viewer)
->withProjectPHIDs(array($project->getPHID()))
->withStatuses(array(PhabricatorProjectColumn::STATUS_ACTIVE))
->execute();
$columns = mpull($columns, null, 'getSequence');
@@ -168,6 +169,13 @@ final class PhabricatorProjectBoardController
->setHref($this->getApplicationURI('board/'.$this->id.'/edit/'))
->setIcon('create')
->setDisabled(!$can_edit)
->setWorkflow(!$can_edit))
->addAction(
id(new PhabricatorActionView())
->setName(pht('Delete Column'))
->setHref($this->getApplicationURI('board/'.$this->id.'/delete/'))
->setIcon('delete')
->setDisabled(!$can_edit)
->setWorkflow(!$can_edit));
$plist = id(new PHUIPropertyListView());