Project - add ability to select an icon for typeaheads and such

Summary: Fixes T5090. Introduced getIcon into Handle stack which allows you to specify a per handle icon. getIcon falls back ot getTypeIcon.

Test Plan: changed the icon on a project a bunch. verified transactions showed up. verified icon showed up in typeahead. verified icon showed up in tokens that were pre-generated (not typed in). units test passed.

Reviewers: chad, epriestley

Reviewed By: epriestley

Subscribers: epriestley, Korvin

Maniphest Tasks: T5090

Differential Revision: https://secure.phabricator.com/D9264
This commit is contained in:
Bob Trahan
2014-05-23 10:41:24 -07:00
parent 217e0e7fe1
commit 102befdede
16 changed files with 229 additions and 13 deletions

View File

@@ -94,6 +94,14 @@ final class PhabricatorProjectEditMainController
->setDisabled(!$can_edit)
->setWorkflow(!$can_edit));
$view->addAction(
id(new PhabricatorActionView())
->setName(pht('Edit Icon'))
->setIcon($project->getIcon())
->setHref($this->getApplicationURI("icon/{$id}/"))
->setDisabled(!$can_edit)
->setWorkflow(true));
$view->addAction(
id(new PhabricatorActionView())
->setName(pht('Edit Picture'))