From ee6b4c409d9ddc93529a486065998508cda79ecc Mon Sep 17 00:00:00 2001 From: Brion Vibber Date: Tue, 28 Sep 2010 15:54:44 -0700 Subject: [PATCH] YammerImport admin UI now auto-refreshes during running BG progress, whee --- plugins/YammerImport/lib/yammerprogressform.php | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/plugins/YammerImport/lib/yammerprogressform.php b/plugins/YammerImport/lib/yammerprogressform.php index add8d9ab2f..9bf8332261 100644 --- a/plugins/YammerImport/lib/yammerprogressform.php +++ b/plugins/YammerImport/lib/yammerprogressform.php @@ -19,7 +19,16 @@ class YammerProgressForm extends Form */ function formClass() { - return 'form_settings'; + $classes = array('form_settings'); + $runner = YammerRunner::init(); + if ($runner->lastError()) { + $classes[] = 'import-error'; + } else if ($runner->state() == 'done') { + $classes[] = 'import-done'; + } else { + $classes[] = 'import-progress'; + } + return implode(' ', $classes); } /**