]> git.ipfire.org Git - thirdparty/openembedded/openembedded-core-contrib.git/commitdiff
toaster: Fix for task_color tag
authorBelen Barros Pena <belen.barros.pena@intel.com>
Fri, 31 Jan 2014 07:08:40 +0000 (07:08 +0000)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Mon, 17 Feb 2014 15:38:26 +0000 (15:38 +0000)
This patch changes the task_color tag in
projecttags.py to make sure it adds the error
class to the rows corresponding to failed tasks
in the tasks table.

Signed-off-by: Belen Barros Pena <belen.barros.pena@intel.com>
lib/toaster/toastergui/templatetags/projecttags.py

index 667bc3842042618e5fdcdf0c69f088ebd863aefd..042d6927c51caf54f696725d87074922cba1714e 100644 (file)
@@ -75,7 +75,7 @@ def task_color(task_object):
     """
     if not task_object.task_executed:
         return 'class=muted'
-    elif task_object.get_outcome_display == 'Failed':
+    elif task_object.outcome == task_object.OUTCOME_FAILED:
         return 'class=error'
     else:
         return ''