1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-11-27 09:12:41 +01:00

Drop "-pro" suffix and "editpro" URIs for EditEngine in Maniphest

Summary: Ref T9908. Move all the "pro" stuff into the old locations.

Test Plan: Created/edited tasks, looked at URIs, saw non-pro ones. Grepped for `editpro`.

Reviewers: chad

Reviewed By: chad

Maniphest Tasks: T9908

Differential Revision: https://secure.phabricator.com/D14717
This commit is contained in:
epriestley 2015-12-08 16:54:46 -08:00
parent bce83bf844
commit b3fbf883e0
9 changed files with 13 additions and 18 deletions

View file

@ -1303,7 +1303,7 @@ phutil_register_library_map(array(
'ManiphestTaskDescriptionHeraldField' => 'applications/maniphest/herald/ManiphestTaskDescriptionHeraldField.php', 'ManiphestTaskDescriptionHeraldField' => 'applications/maniphest/herald/ManiphestTaskDescriptionHeraldField.php',
'ManiphestTaskDetailController' => 'applications/maniphest/controller/ManiphestTaskDetailController.php', 'ManiphestTaskDetailController' => 'applications/maniphest/controller/ManiphestTaskDetailController.php',
'ManiphestTaskEditBulkJobType' => 'applications/maniphest/bulk/ManiphestTaskEditBulkJobType.php', 'ManiphestTaskEditBulkJobType' => 'applications/maniphest/bulk/ManiphestTaskEditBulkJobType.php',
'ManiphestTaskEditProController' => 'applications/maniphest/controller/ManiphestTaskEditProController.php', 'ManiphestTaskEditController' => 'applications/maniphest/controller/ManiphestTaskEditController.php',
'ManiphestTaskHasCommitEdgeType' => 'applications/maniphest/edge/ManiphestTaskHasCommitEdgeType.php', 'ManiphestTaskHasCommitEdgeType' => 'applications/maniphest/edge/ManiphestTaskHasCommitEdgeType.php',
'ManiphestTaskHasMockEdgeType' => 'applications/maniphest/edge/ManiphestTaskHasMockEdgeType.php', 'ManiphestTaskHasMockEdgeType' => 'applications/maniphest/edge/ManiphestTaskHasMockEdgeType.php',
'ManiphestTaskHasRevisionEdgeType' => 'applications/maniphest/edge/ManiphestTaskHasRevisionEdgeType.php', 'ManiphestTaskHasRevisionEdgeType' => 'applications/maniphest/edge/ManiphestTaskHasRevisionEdgeType.php',
@ -5303,7 +5303,7 @@ phutil_register_library_map(array(
'ManiphestTaskDescriptionHeraldField' => 'ManiphestTaskHeraldField', 'ManiphestTaskDescriptionHeraldField' => 'ManiphestTaskHeraldField',
'ManiphestTaskDetailController' => 'ManiphestController', 'ManiphestTaskDetailController' => 'ManiphestController',
'ManiphestTaskEditBulkJobType' => 'PhabricatorWorkerBulkJobType', 'ManiphestTaskEditBulkJobType' => 'PhabricatorWorkerBulkJobType',
'ManiphestTaskEditProController' => 'ManiphestController', 'ManiphestTaskEditController' => 'ManiphestController',
'ManiphestTaskHasCommitEdgeType' => 'PhabricatorEdgeType', 'ManiphestTaskHasCommitEdgeType' => 'PhabricatorEdgeType',
'ManiphestTaskHasMockEdgeType' => 'PhabricatorEdgeType', 'ManiphestTaskHasMockEdgeType' => 'PhabricatorEdgeType',
'ManiphestTaskHasRevisionEdgeType' => 'PhabricatorEdgeType', 'ManiphestTaskHasRevisionEdgeType' => 'PhabricatorEdgeType',

View file

@ -265,7 +265,7 @@ final class PhabricatorConfigWelcomeController
$maniphest_uri = PhabricatorEnv::getURI('/maniphest/'); $maniphest_uri = PhabricatorEnv::getURI('/maniphest/');
$maniphest_create_uri = PhabricatorEnv::getURI('/maniphest/editpro/'); $maniphest_create_uri = PhabricatorEnv::getURI('/maniphest/task/edit/');
$maniphest_all_uri = PhabricatorEnv::getURI('/maniphest/query/all/'); $maniphest_all_uri = PhabricatorEnv::getURI('/maniphest/query/all/');
$quick[] = $this->newItem( $quick[] = $this->newItem(
$request, $request,

View file

@ -54,6 +54,8 @@ final class PhabricatorManiphestApplication extends PhabricatorApplication {
'/T(?P<id>[1-9]\d*)' => 'ManiphestTaskDetailController', '/T(?P<id>[1-9]\d*)' => 'ManiphestTaskDetailController',
'/maniphest/' => array( '/maniphest/' => array(
'(?:query/(?P<queryKey>[^/]+)/)?' => 'ManiphestTaskListController', '(?:query/(?P<queryKey>[^/]+)/)?' => 'ManiphestTaskListController',
$this->getEditRoutePattern('edit/')
=> 'ManiphestTaskEditController',
'report/(?:(?P<view>\w+)/)?' => 'ManiphestReportController', 'report/(?:(?P<view>\w+)/)?' => 'ManiphestReportController',
'batch/' => 'ManiphestBatchEditController', 'batch/' => 'ManiphestBatchEditController',
'task/' => array( 'task/' => array(
@ -67,8 +69,6 @@ final class PhabricatorManiphestApplication extends PhabricatorApplication {
), ),
'export/(?P<key>[^/]+)/' => 'ManiphestExportController', 'export/(?P<key>[^/]+)/' => 'ManiphestExportController',
'subpriority/' => 'ManiphestSubpriorityController', 'subpriority/' => 'ManiphestSubpriorityController',
$this->getEditRoutePattern('editpro/')
=> 'ManiphestTaskEditProController',
), ),
); );
} }

View file

@ -143,7 +143,7 @@ final class ManiphestTaskDetailController extends ManiphestController {
id(new PhabricatorActionView()) id(new PhabricatorActionView())
->setName(pht('Edit Task')) ->setName(pht('Edit Task'))
->setIcon('fa-pencil') ->setIcon('fa-pencil')
->setHref($this->getApplicationURI("/editpro/{$id}/")) ->setHref($this->getApplicationURI("/task/edit/{$id}/"))
->setDisabled(!$can_edit) ->setDisabled(!$can_edit)
->setWorkflow(!$can_edit)); ->setWorkflow(!$can_edit));
@ -163,12 +163,12 @@ final class ManiphestTaskDetailController extends ManiphestController {
$can_create = (bool)$edit_config; $can_create = (bool)$edit_config;
if ($can_create) { if ($can_create) {
$form_key = $edit_config->getIdentifier(); $form_key = $edit_config->getIdentifier();
$edit_uri = "/editpro/form/{$form_key}/?parent={$id}&template={$id}"; $edit_uri = "/task/edit/form/{$form_key}/?parent={$id}&template={$id}";
$edit_uri = $this->getApplicationURI($edit_uri); $edit_uri = $this->getApplicationURI($edit_uri);
} else { } else {
// TODO: This will usually give us a somewhat-reasonable error page, but // TODO: This will usually give us a somewhat-reasonable error page, but
// could be a bit cleaner. // could be a bit cleaner.
$edit_uri = "/editpro/{$id}/"; $edit_uri = "/task/edit/{$id}/";
$edit_uri = $this->getApplicationURI($edit_uri); $edit_uri = $this->getApplicationURI($edit_uri);
} }

View file

@ -1,6 +1,6 @@
<?php <?php
final class ManiphestTaskEditProController extends ManiphestController { final class ManiphestTaskEditController extends ManiphestController {
public function handleRequest(AphrontRequest $request) { public function handleRequest(AphrontRequest $request) {
return id(new ManiphestEditEngine()) return id(new ManiphestEditEngine())

View file

@ -136,11 +136,6 @@ final class ManiphestEditEngine
); );
} }
protected function getEditorURI() {
// TODO: Remove when cutting over.
return $this->getApplication()->getApplicationURI('editpro/');
}
private function getTaskStatusMap(ManiphestTask $task) { private function getTaskStatusMap(ManiphestTask $task) {
$status_map = ManiphestTaskStatus::getTaskStatusMap(); $status_map = ManiphestTaskStatus::getTaskStatusMap();

View file

@ -111,7 +111,7 @@ final class ManiphestTaskListView extends ManiphestView {
)); ));
if ($this->showBatchControls) { if ($this->showBatchControls) {
$href = new PhutilURI('/maniphest/editpro/'.$task->getID().'/'); $href = new PhutilURI('/maniphest/task/edit/'.$task->getID().'/');
if (!$this->showSubpriorityControls) { if (!$this->showSubpriorityControls) {
$href->setQueryParam('ungrippable', 'true'); $href->setQueryParam('ungrippable', 'true');
} }

View file

@ -778,9 +778,9 @@ final class PhabricatorProjectBoardViewController
->loadDefaultEditConfiguration(); ->loadDefaultEditConfiguration();
if ($edit_config) { if ($edit_config) {
$form_key = $edit_config->getIdentifier(); $form_key = $edit_config->getIdentifier();
$create_uri = "/maniphest/editpro/form/{$form_key}/"; $create_uri = "/maniphest/task/edit/form/{$form_key}/";
} else { } else {
$create_uri = '/maniphest/editpro/'; $create_uri = '/maniphest/task/edit/';
} }
return $create_uri; return $create_uri;

View file

@ -66,7 +66,7 @@ final class ProjectBoardTaskCard extends Phobject {
->setName(pht('Edit')) ->setName(pht('Edit'))
->setIcon('fa-pencil') ->setIcon('fa-pencil')
->addSigil('edit-project-card') ->addSigil('edit-project-card')
->setHref('/maniphest/editpro/'.$task->getID().'/')) ->setHref('/maniphest/task/edit/'.$task->getID().'/'))
->setBarColor($bar_color); ->setBarColor($bar_color);
if ($owner) { if ($owner) {