Issue #29 - UI improvements such as warning bar styling and texts.

This commit is contained in:
Daniel Thee Roperto
2016-09-14 10:21:23 +10:00
parent 92681c7ec4
commit aa378633f9
5 changed files with 90 additions and 91 deletions

View File

@@ -157,7 +157,7 @@ class auth_outage_renderer extends plugin_renderer_base {
$adminlinks = [];
foreach ([
'startofwarning' => -$outage->get_warning_duration(),
'1minutebefore' => -60,
'15secondsbefore' => -15,
'start' => 0,
'endofoutage' => $outage->get_duration(),
] as $title => $delta) {
@@ -191,6 +191,7 @@ class auth_outage_renderer extends plugin_renderer_base {
* @param outage $outage The outage to show in the warning bar.
* @param int|null $time Timestamp to send to the outage bar in order to render the outage. Null for current time.
* @return string HTML of the warning bar.
* @SuppressWarnings("unused") because $countdown is used inside require(...)
*/
public function renderoutagebar(outage $outage, $time = null) {
global $CFG;
@@ -211,7 +212,6 @@ class auth_outage_renderer extends plugin_renderer_base {
['start' => $start, 'stop' => $stop]
);
ob_start();
require($CFG->dirroot . '/auth/outage/views/warningbar.php');
$html = ob_get_contents();