mirror of
https://we.phorge.it/source/phorge.git
synced 2024-12-24 14:30:56 +01:00
When a project has a custom icon, use that icon to label the project policy in the policy dropown
Summary: Fixes T8808. Currently, all project use the default ("Briefcase") project icon when they appear in a policy dropdown. Since project policies are separated out into a "Members of Projects" section of the dropdown anyway, there is no reason not to use the actual project icon, which is often more clear. Test Plan: {F6849927} Maniphest Tasks: T8808 Differential Revision: https://secure.phabricator.com/D20799
This commit is contained in:
parent
1d1a60fdda
commit
d2e1c4163a
1 changed files with 4 additions and 2 deletions
|
@ -85,8 +85,10 @@ final class PhabricatorPolicy
|
|||
$phid_type = phid_get_type($policy_identifier);
|
||||
switch ($phid_type) {
|
||||
case PhabricatorProjectProjectPHIDType::TYPECONST:
|
||||
$policy->setType(PhabricatorPolicyType::TYPE_PROJECT);
|
||||
$policy->setName($handle->getName());
|
||||
$policy
|
||||
->setType(PhabricatorPolicyType::TYPE_PROJECT)
|
||||
->setName($handle->getName())
|
||||
->setIcon($handle->getIcon());
|
||||
break;
|
||||
case PhabricatorPeopleUserPHIDType::TYPECONST:
|
||||
$policy->setType(PhabricatorPolicyType::TYPE_USER);
|
||||
|
|
Loading…
Reference in a new issue