Exemplo n.º 1
0
     $creator_info = $creator_hrn;
     if (isset($creator_urn)) {
         $creator_info = "{$creator_urn}";
     }
     if ($destroyed) {
         $url = "<a href='showslicelogs.php?slice_uuid={$slice_uuid}'>";
     } else {
         $url = "<a href='showslice.php?slice_idx={$slice_idx}&showtype=cm'>";
     }
     $url .= "{$slice_info}</a>";
     $tablerow = array("idx" => $idx, "hrn" => $url, "creator" => $creator_info, "created" => $created, "destroyed" => $destroyed);
     $manifest_result = DBQueryFatal("select * from manifest_history " . "where aggregate_uuid='{$uuid}' " . "order by idx desc limit 1", $dblink);
     if (mysql_num_rows($manifest_result)) {
         $mrow = mysql_fetch_array($manifest_result);
         $manifest = $mrow["manifest"];
         $stuff = GeneratePopupDiv("manifest{$idx}", $manifest);
         $popups[] = $stuff;
         $tablerow["manifest"] = "<a href='#' title='' " . "onclick='PopUpWindowFromDiv(\"manifest{$idx}\");'" . ">manifest</a>\n";
     } else {
         $tablerow["Manifest"] = "Unknown";
     }
     $rows[] = $tablerow;
     $myindex = $idx;
 }
 list($html, $button) = TableRender($table, $rows);
 echo $html;
 foreach ($popups as $i => $popup) {
     echo "{$popup}\n";
 }
 $query_result = DBQueryFatal("select count(*) from aggregate_history as a " . "where `type`='Aggregate' and a.idx<{$myindex} {$clause} ", $dblink);
 $row = mysql_fetch_array($query_result);
Exemplo n.º 2
0
    if ($cmslice) {
        $cmidx = $cmslice->idx();
        $url = CreateURL("showslice", "slice_idx", $cmidx, "showtype", "cm");
        $rows[] = array("CM Slice" => "<a href='{$url}'>{$cmidx}</a>");
    }
}
list($html, $button) = TableRender($table, $rows);
echo $html;
$clientslivers = ClientSliver::SliverList($slice);
if ($clientslivers && count($clientslivers)) {
    $table = array('#id' => 'clientslivers', '#title' => "Client Slivers", '#headings' => array("idx" => "ID", "urn" => "URN", "manager" => "Manager URN", "created" => "Created", "manifest" => "Manifest"));
    $rows = array();
    foreach ($clientslivers as $clientsliver) {
        $row = array("idx" => $clientsliver->idx(), "urn" => $clientsliver->urn(), "manager" => $clientsliver->manager_urn(), "created" => $clientsliver->created());
        if ($clientsliver->manifest()) {
            $popups[] = GeneratePopupDiv("manifest{$manifestidx}", $clientsliver->manifest());
            $row["manifest"] = "<a href='#' title='' " . "onclick='PopUpWindowFromDiv(\"manifest{$manifestidx}\");'>" . "Manifest</a>";
            $manifestidx++;
        } else {
            $row["manifest"] = "Unknown";
        }
        $rows[] = $row;
    }
    list($html, $button) = TableRender($table, $rows);
    echo $html;
}
foreach ($popups as $i => $popup) {
    echo "{$popup}\n";
}
#
# Find all logs associated with this slice.
Exemplo n.º 3
0
$rows = array();
$popups = array();
$rows[] = array("idx" => $slice->idx());
$rows[] = array("hrn" => $slice->hrn());
$urn = $slice->urn();
if ($urn) {
    $rows[] = array("urn" => $slice->urn());
}
$rows[] = array("uuid" => $slice->uuid());
$rows[] = array("created" => $slice->created());
$rows[] = array("expires" => $slice->expires());
if ($slice->locked()) {
    $rows[] = array("locked" => $slice->locked());
}
if ($manifest = $slice->GetManifest()) {
    $popups[] = GeneratePopupDiv("manifest{$manifestidx}", $manifest);
    $rows[] = array("manifest" => "<a href='#' title='' " . "onclick='PopUpWindowFromDiv(\"manifest{$manifestidx}\");'" . ">manifest</a>\n");
    $manifestidx++;
}
$geniuser = GeniUser::Lookup("cm", $slice->creator_uuid());
if ($geniuser) {
    $rows[] = array("Creator" => $geniuser->urn());
} else {
    $user = User::LookupByUUID($slice->creator_uuid());
    if ($user) {
        $rows[] = array("Creator" => $user->uid());
    }
}
list($html, $button) = TableRender($table, $rows);
echo $html;
foreach ($popups as $i => $popup) {