Page MenuHomePhabricator

D19016.diff
No OneTemporary

D19016.diff

diff --git a/src/applications/metamta/controller/PhabricatorMetaMTAMailViewController.php b/src/applications/metamta/controller/PhabricatorMetaMTAMailViewController.php
--- a/src/applications/metamta/controller/PhabricatorMetaMTAMailViewController.php
+++ b/src/applications/metamta/controller/PhabricatorMetaMTAMailViewController.php
@@ -75,8 +75,26 @@
->setKey('metadata')
->appendChild($this->buildMetadataProperties($mail)));
+ $header_view = id(new PHUIHeaderView())
+ ->setHeader(pht('Mail'));
+
+ $object_phid = $mail->getRelatedPHID();
+ if ($object_phid) {
+ $handles = $viewer->loadHandles(array($object_phid));
+ $handle = $handles[$object_phid];
+ if ($handle->isComplete() && $handle->getURI()) {
+ $view_button = id(new PHUIButtonView())
+ ->setTag('a')
+ ->setText(pht('View Object'))
+ ->setIcon('fa-chevron-right')
+ ->setHref($handle->getURI());
+
+ $header_view->addActionLink($view_button);
+ }
+ }
+
$object_box = id(new PHUIObjectBoxView())
- ->setHeaderText(pht('Mail'))
+ ->setHeader($header_view)
->setBackground(PHUIObjectBoxView::BLUE_PROPERTY)
->addTabGroup($tab_group);

File Metadata

Mime Type
text/plain
Expires
Sat, Nov 16, 8:01 PM (15 h, 29 m ago)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
6712818
Default Alt Text
D19016.diff (1 KB)

Event Timeline