Page MenuHomePhabricator

D10823.diff
No OneTemporary

D10823.diff

diff --git a/src/applications/project/conduit/ProjectConduitAPIMethod.php b/src/applications/project/conduit/ProjectConduitAPIMethod.php
--- a/src/applications/project/conduit/ProjectConduitAPIMethod.php
+++ b/src/applications/project/conduit/ProjectConduitAPIMethod.php
@@ -26,14 +26,19 @@
$project_slugs = $project->getSlugs();
$project_slugs = array_values(mpull($project_slugs, 'getSlug'));
+ $project_icon = PhabricatorProjectIcon::getAPIName($project->getIcon());
+
$result[$project->getPHID()] = array(
- 'id' => $project->getID(),
- 'phid' => $project->getPHID(),
- 'name' => $project->getName(),
- 'members' => $member_phids,
- 'slugs' => $project_slugs,
- 'dateCreated' => $project->getDateCreated(),
- 'dateModified' => $project->getDateModified(),
+ 'id' => $project->getID(),
+ 'phid' => $project->getPHID(),
+ 'name' => $project->getName(),
+ 'profileImagePHID' => $project->getProfileImagePHID(),
+ 'icon' => $project_icon,
+ 'color' => $project->getColor(),
+ 'members' => $member_phids,
+ 'slugs' => $project_slugs,
+ 'dateCreated' => $project->getDateCreated(),
+ 'dateModified' => $project->getDateModified(),
);
}
diff --git a/src/applications/project/icon/PhabricatorProjectIcon.php b/src/applications/project/icon/PhabricatorProjectIcon.php
--- a/src/applications/project/icon/PhabricatorProjectIcon.php
+++ b/src/applications/project/icon/PhabricatorProjectIcon.php
@@ -39,6 +39,10 @@
return $map[$key];
}
+ public static function getAPIName($key) {
+ return substr($key, 3);
+ }
+
public static function renderIconForChooser($icon) {
$project_icons = PhabricatorProjectIcon::getIconMap();

File Metadata

Mime Type
text/plain
Expires
Sun, Nov 24, 10:33 PM (21 h, 18 m)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
6784110
Default Alt Text
D10823.diff (1 KB)

Event Timeline