From: Eric Bollengier Date: Sat, 8 Aug 2009 20:12:22 +0000 (+0200) Subject: bat: display a Warning symbole when having Errors>0 and Status=T X-Git-Tag: Release-5.0.0~333^2~13^2~12 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=daa053f53f7d593c9cc6dd4d824edeadf142f8c7;p=bacula%2Fbacula bat: display a Warning symbole when having Errors>0 and Status=T --- diff --git a/bacula/src/qt-console/images/W.png b/bacula/src/qt-console/images/W.png new file mode 100644 index 0000000000..6d7dbadd8e Binary files /dev/null and b/bacula/src/qt-console/images/W.png differ diff --git a/bacula/src/qt-console/job/job.cpp b/bacula/src/qt-console/job/job.cpp index ec9ef8d122..3b170323e0 100644 --- a/bacula/src/qt-console/job/job.cpp +++ b/bacula/src/qt-console/job/job.cpp @@ -202,7 +202,7 @@ void Job::populateText() */ void Job::populateForm() { - QString stat; + QString stat, err; char buf[256]; QString query = "SELECT JobId, Job.Name, Level, Client.Name, Pool.Name, FileSet, SchedTime, StartTime, EndTime, " @@ -233,9 +233,13 @@ void Job::populateForm() label_JobBytes->setText(convertBytesSI(fld.next().toULongLong())); label_JobFiles->setText(fld.next()); - label_JobErrors->setText(fld.next()); + err = fld.next(); + label_JobErrors->setText(err); stat=fld.next(); + if (stat == "T" && err.toInt() > 0) { + stat = "W"; + } label_JobStatus->setPixmap(QPixmap(":/images/" + stat + ".png")); jobstatus_to_ascii_gui(stat[0].toAscii(), buf, sizeof(buf)); stat = buf; diff --git a/bacula/src/qt-console/main.qrc b/bacula/src/qt-console/main.qrc index 0f9d56ea16..b4058f7101 100644 --- a/bacula/src/qt-console/main.qrc +++ b/bacula/src/qt-console/main.qrc @@ -1,5 +1,6 @@ + images/W.png images/edit.png images/extern.png images/intern.png