Move "Archive Project" to a standard, separate action

Summary:
Ref T4379. Projects currently include their "delete/disable" function as part of edit, which is atypical. Instead, provide it as a first-class action. This is primarily for consistency between applications.

(The action list on projects is getting pretty huge, but we can deal with that separately; I have some ideas.)

Test Plan: Archived/unarchived a project. Edited a project.

Reviewers: btrahan

Reviewed By: btrahan

CC: aran

Maniphest Tasks: T4379

Differential Revision: https://secure.phabricator.com/D8177
This commit is contained in:
epriestley
2014-02-10 14:30:47 -08:00
parent a035d3d528
commit c3544f8862
6 changed files with 101 additions and 11 deletions

View File

@@ -29,7 +29,6 @@ final class PhabricatorProjectProfileEditController
}
$profile = $project->getProfile();
$options = PhabricatorProjectStatus::getStatusMap();
$e_name = true;
@@ -41,10 +40,6 @@ final class PhabricatorProjectProfileEditController
->setTransactionType(PhabricatorProjectTransaction::TYPE_NAME)
->setNewValue($request->getStr('name'));
$xactions[] = id(new PhabricatorProjectTransaction())
->setTransactionType(PhabricatorProjectTransaction::TYPE_STATUS)
->setNewValue($request->getStr('status'));
$xactions[] = id(new PhabricatorProjectTransaction())
->setTransactionType(PhabricatorTransactions::TYPE_VIEW_POLICY)
->setNewValue($request->getStr('can_view'));
@@ -101,12 +96,6 @@ final class PhabricatorProjectProfileEditController
->setName('name')
->setValue($project->getName())
->setError($e_name))
->appendChild(
id(new AphrontFormSelectControl())
->setLabel(pht('Project Status'))
->setName('status')
->setOptions($options)
->setValue($project->getStatus()))
->appendChild(
id(new PhabricatorRemarkupControl())
->setLabel(pht('Description'))