diff options
author | Ravi Chintakunta <ravi.chintakunta@timesys.com> | 2014-01-10 16:43:24 -0500 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2014-01-27 21:01:06 +0000 |
commit | 47d19237ef6c492f7c2226952f8094d853893754 (patch) | |
tree | 5cbb90139b6bbd56638bfa8c3978c2a048868e4d /bitbake/lib/toaster/toastergui/templates | |
parent | 84b239086dbd53c59d51f4e0779767a72af02d2b (diff) | |
download | poky-47d19237ef6c492f7c2226952f8094d853893754.tar.gz |
bitbake: toaster: All Tasks Feature with sorting and filtering
- Fixed the all tasks view and template to match the UI design and use
the new basetable code.
- Added a method to views to add sort order icon to the view context.
- Default sort order when the page is loaded is displayed with the sort icon
- Filtering of columns
(Bitbake rev: b2f8de082c3ae41eb44e6ccdc283849b64d0b0f2)
Signed-off-by: Ravi Chintakunta <ravi.chintakunta@timesys.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake/lib/toaster/toastergui/templates')
-rw-r--r-- | bitbake/lib/toaster/toastergui/templates/task.html | 74 | ||||
-rw-r--r-- | bitbake/lib/toaster/toastergui/templates/tasks.html | 67 |
2 files changed, 67 insertions, 74 deletions
diff --git a/bitbake/lib/toaster/toastergui/templates/task.html b/bitbake/lib/toaster/toastergui/templates/task.html deleted file mode 100644 index 6af2c51277..0000000000 --- a/bitbake/lib/toaster/toastergui/templates/task.html +++ /dev/null | |||
@@ -1,74 +0,0 @@ | |||
1 | {% extends "basebuildpage.html" %} | ||
2 | |||
3 | {% block localbreadcrumb %} | ||
4 | <li>Tasks</li> | ||
5 | {% endblock %} | ||
6 | |||
7 | {% block buildinfomain %} | ||
8 | {% include "basetable_top.html" %} | ||
9 | |||
10 | |||
11 | {% if not objects %} | ||
12 | <p>No tasks were executed in this build!</p> | ||
13 | {% else %} | ||
14 | |||
15 | <tr> | ||
16 | <th>Order</th> | ||
17 | <th>Task</th> | ||
18 | <th>Recipe Version</th> | ||
19 | <th>Task Type</th> | ||
20 | <th>Checksum</th> | ||
21 | <th>Outcome</th> | ||
22 | <th>Message</th> | ||
23 | <th>Time</th> | ||
24 | <th>CPU usage</th> | ||
25 | <th>Disk I/O</th> | ||
26 | <th>Script type</th> | ||
27 | <th>Filesystem</th> | ||
28 | <th>Depends</th> | ||
29 | </tr> | ||
30 | |||
31 | {% for task in objects %} | ||
32 | |||
33 | <tr class="data"> | ||
34 | <td>{{task.order}}</td> | ||
35 | <td><a name="{{task.recipe.name}}.{{task.task_name}}"> | ||
36 | <a href="{% url "layer_versions_recipes" task.recipe.layer_version_id %}#{{task.recipe.name}}">{{task.recipe.name}}</a>.{{task.task_name}}</a></td> | ||
37 | <td>{{task.recipe.version}}</td> | ||
38 | |||
39 | {% if task.task_executed %} | ||
40 | <td>Executed</td> | ||
41 | {% else %} | ||
42 | <td>Prebuilt</td> | ||
43 | {% endif %} | ||
44 | |||
45 | <td>{{task.sstate_checksum}}</td> | ||
46 | <td>{{task.get_outcome_display}}{% if task.provider %}</br>(by <a href="#{{task.provider.recipe.name}}.{{task.provider.task_name}}">{{task.provider.recipe.name}}.{{task.provider.task_name}}</a>){% endif %}</td> | ||
47 | <td><p>{{task.message}}</td> | ||
48 | <td>{{task.elapsed_time}}</td> | ||
49 | <td>{{task.cpu_usage}}</td> | ||
50 | <td>{{task.disk_io}}</td> | ||
51 | <td>{{task.get_script_type_display}}</td> | ||
52 | <td> <table> | ||
53 | <tr><td> Recipe</td><td><a target="_fileview" href="file:///{{task.recipe.file_path}}">{{task.recipe.file_path}}</a></td></tr> | ||
54 | <tr><td> Source</td><td><a target="_fileview" href="file:///{{task.file_name}}">{{task.file_name}}:{{task.line_number}}</a></td></tr> | ||
55 | <tr><td> Workdir</td><td><a target="_fileview" href="file:///{{task.work_directory}}">{{task.work_directory}}</a></td></tr> | ||
56 | <tr><td> Log</td><td><a target="_fileview" href="file:///{{task.logfile}}">{{task.logfile}}</a><br/></td></tr> | ||
57 | </table> | ||
58 | </td> | ||
59 | <td> | ||
60 | <div style="height: 3em; overflow:auto"> | ||
61 | {% for tt in task.task_dependencies_task.all %} | ||
62 | <a href="#{{tt.depends_on.recipe.name}}.{{tt.depends_on.task_name}}"> | ||
63 | {{tt.depends_on.recipe.name}}.{{tt.depends_on.task_name}}</a><br/> | ||
64 | {% endfor %} | ||
65 | </div> | ||
66 | </td> | ||
67 | </tr> | ||
68 | |||
69 | {% endfor %} | ||
70 | |||
71 | {% endif %} | ||
72 | |||
73 | {% include "basetable_bottom.html" %} | ||
74 | {% endblock %} | ||
diff --git a/bitbake/lib/toaster/toastergui/templates/tasks.html b/bitbake/lib/toaster/toastergui/templates/tasks.html new file mode 100644 index 0000000000..6831f106c0 --- /dev/null +++ b/bitbake/lib/toaster/toastergui/templates/tasks.html | |||
@@ -0,0 +1,67 @@ | |||
1 | {% extends "basebuildpage.html" %} | ||
2 | {% load projecttags %} | ||
3 | {% block localbreadcrumb %} | ||
4 | <li>All tasks</li> | ||
5 | {% endblock %} | ||
6 | |||
7 | {% block buildinfomain %} | ||
8 | <div class="span10"> | ||
9 | <div class="page-header"> | ||
10 | <h1> Tasks </h1> | ||
11 | </div> | ||
12 | {% include "basetable_top.html" %} | ||
13 | |||
14 | |||
15 | {% if not objects %} | ||
16 | <p>No tasks were executed in this build!</p> | ||
17 | {% else %} | ||
18 | {% for task in objects %} | ||
19 | <tr {{ task|task_color }} > | ||
20 | <td class="order"> | ||
21 | <a href="{%url "task" build.pk task.pk%} ">{{task.order}}</a> | ||
22 | </td> | ||
23 | <td class="recipe_name" > | ||
24 | <a href="{% url "recipe" build.pk task.recipe.pk %}">{{task.recipe.name}}</a> | ||
25 | </td> | ||
26 | <td class="recipe_version"> | ||
27 | <a href="{% url "recipe" build.pk task.recipe.pk %}">{{task.recipe.version}}</a> | ||
28 | </td> | ||
29 | <td class="task_name"> | ||
30 | <a href="{%url "task" build.pk task.pk%} ">{{task.task_name}}</a> | ||
31 | </td> | ||
32 | <td class="executed"> | ||
33 | <a href="{%url "task" build.pk task.pk%} "> | ||
34 | {% if task.task_executed %} | ||
35 | Executed | ||
36 | {% else %} | ||
37 | Not executed | ||
38 | {% endif %} | ||
39 | </a> | ||
40 | </td> | ||
41 | <td class="outcome"> | ||
42 | <a href="{%url "task" build.pk task.pk%} ">{{task.get_outcome_display}}</a> | ||
43 | </td> | ||
44 | <td class="cache_attempt"> | ||
45 | <a href="{%url "task" build.pk task.pk%} ">{{task.get_sstate_result_display|format_none_and_zero}}</a> | ||
46 | </td> | ||
47 | <td class="time_taken"> | ||
48 | {{task.elapsed_time|format_none_and_zero}} | ||
49 | </td> | ||
50 | <td class="cpu_used"> | ||
51 | {{task.cpu_usage|format_none_and_zero}} | ||
52 | </td> | ||
53 | <td class="disk_io"> | ||
54 | {{task.disk_io|format_none_and_zero}} | ||
55 | </td> | ||
56 | <td class="task_log"> | ||
57 | {{task.logfile}} | ||
58 | </td> | ||
59 | </tr> | ||
60 | |||
61 | {% endfor %} | ||
62 | |||
63 | {% endif %} | ||
64 | |||
65 | {% include "basetable_bottom.html" %} | ||
66 | </div> | ||
67 | {% endblock %} | ||