summaryrefslogtreecommitdiffstats
path: root/bitbake/lib/toaster/toastergui/templatetags/projecttags.py
diff options
context:
space:
mode:
authorBelen Barros Pena <belen.barros.pena@intel.com>2014-02-20 07:06:51 +0000
committerRichard Purdie <richard.purdie@linuxfoundation.org>2014-03-17 13:59:37 +0000
commitd24584f89680849f2cce83cc794b319d73dd554f (patch)
treee98e018663033462cd162c2f0afbf39346f93854 /bitbake/lib/toaster/toastergui/templatetags/projecttags.py
parente3a92c12e980c34c873e21e5c7bafcd762197266 (diff)
downloadpoky-d24584f89680849f2cce83cc794b319d73dd554f.tar.gz
bitbake: toaster: Presentation fixes for task.html
Tidying up the presentation in the task.html template. The changes include: * Correct the markup for the help tooltips * Fix the help content for the outcome heading * Make sure <dt> tags do not show for empty log file, time, cpu and disk I/O values * Eliminate an extra <dl> for tasks with sstate attempts * Add <strong> tag to the sstate restored alert * Replace the .alert-info class with the .muted class for the no dependencies messages * Make sure the Executed heading does not inherit the .red class for failed tasks * Format time and cpu values to make sure they only show 2 decimal digits (Bitbake rev: bbc22958ab37dcd44c03420a7b8f842a1f4e51b1) Signed-off-by: Belen Barros Pena <belen.barros.pena@intel.com> Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake/lib/toaster/toastergui/templatetags/projecttags.py')
-rw-r--r--bitbake/lib/toaster/toastergui/templatetags/projecttags.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/bitbake/lib/toaster/toastergui/templatetags/projecttags.py b/bitbake/lib/toaster/toastergui/templatetags/projecttags.py
index 857680b350..2d339d623f 100644
--- a/bitbake/lib/toaster/toastergui/templatetags/projecttags.py
+++ b/bitbake/lib/toaster/toastergui/templatetags/projecttags.py
@@ -70,16 +70,16 @@ def sortcols(tablecols):
70 return sorted(tablecols, key = lambda t: t['name']) 70 return sorted(tablecols, key = lambda t: t['name'])
71 71
72@register.filter 72@register.filter
73def task_color(task_object, show_green=False): 73def task_color(task_object, show_colour=False):
74 """ Return css class depending on Task execution status and execution outcome. 74 """ Return css class depending on Task execution status and execution outcome.
75 By default, green is not returned for executed and successful tasks; 75 By default, green is not returned for executed and successful tasks;
76 show_green argument should be True to get green color. 76 show_green argument should be True to get green color.
77 """ 77 """
78 if not task_object.task_executed: 78 if not task_object.task_executed:
79 return 'class=muted' 79 return 'class=muted'
80 elif task_object.outcome == task_object.OUTCOME_FAILED: 80 elif task_object.outcome == task_object.OUTCOME_FAILED and show_colour:
81 return 'class=error' 81 return 'class=error'
82 elif task_object.outcome == task_object.OUTCOME_SUCCESS and show_green: 82 elif task_object.outcome == task_object.OUTCOME_SUCCESS and show_colour:
83 return 'class=green' 83 return 'class=green'
84 else: 84 else:
85 return '' 85 return ''