mirror of
https://we.phorge.it/source/phorge.git
synced 2025-04-10 11:28:35 +02:00
Make editing project images redirect to "Manage" more consistently
Summary: Ref T12732. Currently, different ways of setting a profile image can leave you in different places. Instead, always send the user back to the "Manage" page. Test Plan: Used "Current Picture", "use picture", "Build picture" and "upload picture", always ended up in the same spot. Reviewers: chad, amckinley Reviewed By: amckinley Maniphest Tasks: T12732 Differential Revision: https://secure.phabricator.com/D17967
This commit is contained in:
parent
10b3879232
commit
789d57522b
1 changed files with 3 additions and 4 deletions
|
@ -23,8 +23,7 @@ final class PhabricatorProjectEditPictureController
|
||||||
|
|
||||||
$this->setProject($project);
|
$this->setProject($project);
|
||||||
|
|
||||||
$edit_uri = $this->getApplicationURI('profile/'.$project->getID().'/');
|
$manage_uri = $this->getApplicationURI('manage/'.$project->getID().'/');
|
||||||
$view_uri = $this->getApplicationURI('profile/'.$project->getID().'/');
|
|
||||||
|
|
||||||
$supported_formats = PhabricatorFile::getTransformableImageFormats();
|
$supported_formats = PhabricatorFile::getTransformableImageFormats();
|
||||||
$e_file = true;
|
$e_file = true;
|
||||||
|
@ -90,7 +89,7 @@ final class PhabricatorProjectEditPictureController
|
||||||
|
|
||||||
$editor->applyTransactions($project, $xactions);
|
$editor->applyTransactions($project, $xactions);
|
||||||
|
|
||||||
return id(new AphrontRedirectResponse())->setURI($edit_uri);
|
return id(new AphrontRedirectResponse())->setURI($manage_uri);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -243,7 +242,7 @@ final class PhabricatorProjectEditPictureController
|
||||||
pht('Supported formats: %s', implode(', ', $supported_formats))))
|
pht('Supported formats: %s', implode(', ', $supported_formats))))
|
||||||
->appendChild(
|
->appendChild(
|
||||||
id(new AphrontFormSubmitControl())
|
id(new AphrontFormSubmitControl())
|
||||||
->addCancelButton($edit_uri)
|
->addCancelButton($manage_uri)
|
||||||
->setValue(pht('Upload Picture')));
|
->setValue(pht('Upload Picture')));
|
||||||
|
|
||||||
$form_box = id(new PHUIObjectBoxView())
|
$form_box = id(new PHUIObjectBoxView())
|
||||||
|
|
Loading…
Add table
Reference in a new issue