From faf93d0768c57e6108ea45fd547a9efcf5834990 Mon Sep 17 00:00:00 2001 From: Eric Bollengier Date: Sun, 9 Mar 2008 22:01:28 +0000 Subject: [PATCH] ebl Use OK status by default on graph screen Add progress bar to backup screen (on files and bytes) git-svn-id: https://bacula.svn.sourceforge.net/svnroot/bacula/trunk@6570 91ce42f0-d328-0410-95d8-f526ca767f89 --- gui/bweb/html/bweb.css | 11 +++- gui/bweb/html/bweb.js | 25 ++++++++ gui/bweb/lang/en/tpl/client_job_status.tpl | 22 +++++-- gui/bweb/lang/en/tpl/graph.tpl | 2 +- gui/bweb/lang/es/tpl/client_job_status.tpl | 21 ++++-- gui/bweb/lang/es/tpl/graph.tpl | 2 +- gui/bweb/lang/fr/tpl/client_job_status.tpl | 21 ++++-- gui/bweb/lang/fr/tpl/graph.tpl | 2 +- gui/bweb/lib/Bweb.pm | 75 +++++++++++++++------- gui/bweb/technotes-2.3 | 3 + gui/bweb/tpl/client_job_status.tpl | 21 ++++-- gui/bweb/tpl/graph.tpl | 2 +- 12 files changed, 160 insertions(+), 47 deletions(-) diff --git a/gui/bweb/html/bweb.css b/gui/bweb/html/bweb.css index d02a4ed965..0009dec5ab 100644 --- a/gui/bweb/html/bweb.css +++ b/gui/bweb/html/bweb.css @@ -23,6 +23,15 @@ td.joberr { background-color: red; color: white;} background-color: #E6E6E6; } +.pSliceFinished,.pSliceNotFinished + { + height: 9px; + margin-right: 1px; + margin-bottom: 1px; + border: solid 1px #CCCCCC; + background-color: #E6E6E6; +} + .pSliceFull, .pSliceRead_Only,.pSliceArchive, .pSliceUsed, .pSliceDisabled, .pSliceCrit { border: solid 1px #BD0C10; @@ -39,7 +48,7 @@ td.joberr { background-color: red; color: white;} background-color: #FFCE00; } -.pSlicePurged, .pSliceRecycle, .pSliceOk { +.pSliceFinished, .pSlicePurged, .pSliceRecycle, .pSliceOk { border: solid 1px #009900; background-color: #00FF00; } diff --git a/gui/bweb/html/bweb.js b/gui/bweb/html/bweb.js index 1f8ae07562..c42fc3e626 100644 --- a/gui/bweb/html/bweb.js +++ b/gui/bweb/html/bweb.js @@ -230,6 +230,31 @@ function percent_display(hash_values, parent) return parent; } +function percent_finish(value, parent) +{ + var type; + + var nb = parseInt(value*300/100, 10); + parent.title = parseInt(value*100,10)/100 + "% finished (approximate)"; + + var img=document.createElement('img'); + img.className="pSliceFinished"; + img.src="/bweb/pix.png"; + img.width=nb; + parent.appendChild(img); + + if (value >= 100) { + return; + } + + nb = parseInt((100-value)*300/100, 10); + img=document.createElement('img'); + img.className="pSliceNotFinished"; + img.src="/bweb/pix.png"; + img.width=nb; + parent.appendChild(img); +} + function percent_usage(value, parent) { var nb_elt=percent_usage_nb_slice; diff --git a/gui/bweb/lang/en/tpl/client_job_status.tpl b/gui/bweb/lang/en/tpl/client_job_status.tpl index ffc06147d0..c209c994f9 100644 --- a/gui/bweb/lang/en/tpl/client_job_status.tpl +++ b/gui/bweb/lang/en/tpl/client_job_status.tpl @@ -8,20 +8,28 @@ - - + - + - + - + + + + + + +
Job Name: () + Job Name: ()
Processing file: Processing file:
Speed: B/s Speed: B/s
Files Examined: Files Examined:
Bytes: Bytes:
Bytes done
+
Files done
+