示例#1
0
 protected final function renderBuildable(HarbormasterBuildable $buildable)
 {
     $status = $buildable->getBuildableStatus();
     $icon = HarbormasterBuildable::getBuildableStatusIcon($status);
     $color = HarbormasterBuildable::getBuildableStatusColor($status);
     $name = HarbormasterBuildable::getBuildableStatusName($status);
     $icon_view = id(new PHUIIconView())->setIcon($icon . ' ' . $color);
     $tooltip_view = javelin_tag('span', array('sigil' => 'has-tooltip', 'meta' => array('tip' => $name)), $icon_view);
     Javelin::initBehavior('phabricator-tooltips');
     return phutil_tag('a', array('href' => '/' . $buildable->getMonogram()), $tooltip_view);
 }
 protected function addBuildableCrumb(PHUICrumbsView $crumbs, HarbormasterBuildable $buildable)
 {
     $monogram = $buildable->getMonogram();
     $uri = '/' . $monogram;
     $crumbs->addTextCrumb($monogram, $uri);
 }