Something went wrong. Try again.
@recaptime-dev's working patches + fork for Phorge, a community fork of Phabricator. (Upstream dev and stable branches are at upstream/main and upstream/stable respectively.) hq.recaptime.dev/wiki/Phorge
phorge phabricator
Something went wrong. Try again.
1.9 kB · 87 lines
PHP
12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788<?php
final class DifferentialRevisionGraph extends PhabricatorObjectGraph {
protected function getEdgeTypes() { return array( DifferentialRevisionDependsOnRevisionEdgeType::EDGECONST, DifferentialRevisionDependedOnByRevisionEdgeType::EDGECONST, ); }
protected function getParentEdgeType() { return DifferentialRevisionDependsOnRevisionEdgeType::EDGECONST; }
protected function newQuery() { return new DifferentialRevisionQuery(); }
protected function isClosed($object) { return $object->isClosed(); }
protected function newTableRow($phid, $object, $trace) { $viewer = $this->getViewer();
if ($object) { $status_icon = $object->getStatusIcon(); $status_color = $object->getStatusIconColor(); $status_name = $object->getStatusDisplayName();
$status = array( id(new PHUIIconView()) ->setIcon($status_icon, $status_color), ' ', $status_name, );
$author = $viewer->renderHandle($object->getAuthorPHID()); $link = phutil_tag( 'a', array( 'href' => $object->getURI(), ), $object->getTitle());
$link = array( $object->getMonogram(), ' ', $link, ); } else { $status = null; $author = null; $link = $viewer->renderHandle($phid); }
$link = AphrontTableView::renderSingleDisplayLine($link);
return array( $trace, $status, $author, $link, ); }
protected function newTable(AphrontTableView $table) { return $table ->setHeaders( array( null, pht('Status'), pht('Author'), pht('Revision'), )) ->setColumnClasses( array( 'threads', 'graph-status', null, 'wide pri object-link', )); }
}