Add hosting, serving, and push policy options to repository edit

Summary:
Basically straight from D7391. The differences are basically:

  - Policy stuff is all application-scope instead of global-scope.
  - Made a few strings a little nicer.
  - Deleted a bit of dead code.
  - Added a big "THIS DOESN'T WORK YET" warning.

Test Plan: See screenshots.

Reviewers: hach-que, btrahan

Reviewed By: hach-que

CC: aran

Maniphest Tasks: T2230

Differential Revision: https://secure.phabricator.com/D7416
This commit is contained in:
epriestley
2013-10-25 20:13:38 -07:00
parent 86fe020a97
commit bb35f8ec9f
9 changed files with 458 additions and 6 deletions

View File

@@ -75,6 +75,8 @@ final class PhabricatorApplicationDiffusion extends PhabricatorApplication {
'(?P<edit>remote)/' => 'DiffusionRepositoryCreateController',
'local/' => 'DiffusionRepositoryEditLocalController',
'delete/' => 'DiffusionRepositoryEditDeleteController',
'hosting/' => 'DiffusionRepositoryEditHostingController',
'(?P<serve>serve)/' => 'DiffusionRepositoryEditHostingController',
),
),
'inline/' => array(
@@ -110,6 +112,8 @@ final class PhabricatorApplicationDiffusion extends PhabricatorApplication {
DiffusionCapabilityDefaultEdit::CAPABILITY => array(
'default' => PhabricatorPolicies::POLICY_ADMIN,
),
DiffusionCapabilityDefaultPush::CAPABILITY => array(
),
DiffusionCapabilityCreateRepositories::CAPABILITY => array(
'default' => PhabricatorPolicies::POLICY_ADMIN,
),