Commit 9240d17a authored by Leigh Stoller's avatar Leigh Stoller

Minor tweaks for Rob.

parent fce73483
......@@ -108,8 +108,12 @@ SPITREQUIRE("adminextend",
"<script src='js/lib/sugar.min.js'></script>".
"<script src='js/lib/jquery.tablesorter.parser-date.js'></script>");
echo "<pre class='hidden'
id='extension_reason'>$extension_reason</pre>\n";
if ($instance->extension_reason() && $instance->extension_reason() != "") {
echo "<pre class='hidden' id='extension-reason'>";
echo CleanString($instance->extension_reason());
echo "</pre>\n";
}
if (count($extensions)) {
$foo = array();
foreach ($extensions as $extension) {
......@@ -119,9 +123,5 @@ if (count($extensions)) {
echo json_encode($foo);
echo "</script>\n";
}
if ($extension_denied_reason != "") {
echo "<pre class='hidden'
id='extension_denied_reason'>$extension_denied_reason</pre>\n";
}
SPITFOOTER();
?>
......@@ -57,6 +57,11 @@ function (_, sup, moment, mainString, waitwaitString, oopsString)
$("#history-panel-content").scrollTop(10000);
});
}
if ($('#extension-reason').length) {
$("#extension-reason-row pre").text($('#extension-reason').text());
$("#extension-reason-row").removeClass("hidden");
}
// Default number of days.
if (window.DAYS) {
$('#days').val(window.DAYS);
......
......@@ -238,7 +238,12 @@ function SPITROWS($showall, $name, $result)
echo " <tr><td>\n";
if ($all || $extend) {
if (ISADMIN() || ISFOREIGN_ADMIN()) {
echo "<a href='status.php?uuid=$uuid'>$name</a>";
if ($all) {
echo "<a href='status.php?uuid=$uuid'>$name</a>";
}
else {
echo "<a href='adminextend.php?uuid=$uuid'>$name</a>";
}
}
else {
echo $name;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment