diff options
author | Elliot Smith <elliot.smith@intel.com> | 2016-01-15 13:01:04 +0200 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2016-01-15 16:30:01 +0000 |
commit | 88a262cbd231b452f0b50cc37bec7189e5796710 (patch) | |
tree | 768eed3f481a70a7cd2fd571e5e79d0832c5be78 /bitbake/lib/toaster/toastergui/templates | |
parent | 059a274aa96ced872156806936f887969980dda6 (diff) | |
download | poky-88a262cbd231b452f0b50cc37bec7189e5796710.tar.gz |
bitbake: toastergui: remove unused views and template code
The code in views.py for setting up the template context for
old non-ToasterTable views is no longer necessary, as this
is now implemented in tables.py.
The template files for these views have also been removed.
[YOCTO #8738]
(Bitbake rev: 2b5a13afb068c85466436914d8d4ac3b31bc5c02)
Signed-off-by: Elliot Smith <elliot.smith@intel.com>
Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.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/builds.html | 125 | ||||
-rw-r--r-- | bitbake/lib/toaster/toastergui/templates/projects.html | 92 |
2 files changed, 0 insertions, 217 deletions
diff --git a/bitbake/lib/toaster/toastergui/templates/builds.html b/bitbake/lib/toaster/toastergui/templates/builds.html deleted file mode 100644 index c3cc266daf..0000000000 --- a/bitbake/lib/toaster/toastergui/templates/builds.html +++ /dev/null | |||
@@ -1,125 +0,0 @@ | |||
1 | {% extends "base.html" %} | ||
2 | |||
3 | {% load static %} | ||
4 | {% load projecttags %} | ||
5 | {% load project_url_tag %} | ||
6 | {% load humanize %} | ||
7 | |||
8 | {% block title %} All builds - Toaster {% endblock %} | ||
9 | {% block extraheadcontent %} | ||
10 | <link rel="stylesheet" href="/static/css/jquery-ui.min.css" type='text/css'> | ||
11 | <link rel="stylesheet" href="/static/css/jquery-ui.structure.min.css" type='text/css'> | ||
12 | <link rel="stylesheet" href="/static/css/jquery-ui.theme.min.css" type='text/css'> | ||
13 | <script src="/static/js/jquery-ui.min.js"></script> | ||
14 | <script src="/static/js/filtersnippet.js"></script> | ||
15 | {% endblock %} | ||
16 | |||
17 | {% block pagecontent %} | ||
18 | |||
19 | {% if last_date_from and last_date_to %} | ||
20 | <script> | ||
21 | // initialize the date range controls | ||
22 | $(document).ready(function () { | ||
23 | date_init('started_on','{{last_date_from}}','{{last_date_to}}','{{dateMin_started_on}}','{{dateMax_started_on}}','{{daterange_selected}}'); | ||
24 | date_init('completed_on','{{last_date_from}}','{{last_date_to}}','{{dateMin_completed_on}}','{{dateMax_completed_on}}','{{daterange_selected}}'); | ||
25 | }); | ||
26 | </script> | ||
27 | {%endif%} {# last_date_from and last_date_to #} | ||
28 | |||
29 | <div class="row-fluid"> | ||
30 | |||
31 | {% include "mrb_section.html" %} | ||
32 | |||
33 | <div class="page-header top-air"> | ||
34 | <h1> | ||
35 | {% if request.GET.filter and objects.paginator.count > 0 or request.GET.search and objects.paginator.count > 0 %} | ||
36 | {{objects.paginator.count}} build{{objects.paginator.count|pluralize}} found | ||
37 | {%elif request.GET.filter and objects.paginator.count == 0 or request.GET.search and objects.paginator.count == 0 %} | ||
38 | No builds found | ||
39 | {%else%} | ||
40 | All builds | ||
41 | {%endif%} | ||
42 | </h1> | ||
43 | </div> | ||
44 | |||
45 | {% if objects.paginator.count == 0 %} | ||
46 | <div class="row-fluid"> | ||
47 | <div class="alert"> | ||
48 | <form class="no-results input-append" id="searchform"> | ||
49 | <input id="search" name="search" class="input-xxlarge" type="text" value=" | ||
50 | {% if request.GET.search %} | ||
51 | {{request.GET.search}} | ||
52 | {% endif %}"/> | ||
53 | {% if request.GET.search %}<a href="javascript:$('#search').val('');searchform.submit()" class="add-on btn" tabindex="-1"><i class="icon-remove"></i></a>{% endif %} | ||
54 | <button class="btn" type="submit" value="Search">Search</button> | ||
55 | <button class="btn btn-link" onclick="javascript:$('#search').val('');searchform.submit()">Show all builds</button> | ||
56 | </form> | ||
57 | </div> | ||
58 | </div> | ||
59 | {% else %} | ||
60 | {% include "basetable_top.html" %} | ||
61 | <!-- Table data rows; the order needs to match the order of "tablecols" definitions; and the <td class value needs to match the tablecols clclass value for show/hide buttons to work --> | ||
62 | {% for build in objects %} | ||
63 | <tr class="data" data-table-build-result="{{ build.id }}"> | ||
64 | <td class="outcome"> | ||
65 | <a href="{% url "builddashboard" build.id %}">{%if build.outcome == build.SUCCEEDED%}<i class="icon-ok-sign success"></i>{%elif build.outcome == build.FAILED%}<i class="icon-minus-sign error"></i>{%else%}{%endif%}</a> | ||
66 | {% if build.cooker_log_path %} | ||
67 | | ||
68 | <a href="{% url 'build_artifact' build.id "cookerlog" build.id %}"> | ||
69 | <i class="icon-download-alt" title="Download build log"></i> | ||
70 | </a> | ||
71 | {% endif %} | ||
72 | </td> | ||
73 | <td class="target"> | ||
74 | {% for t in build.target_set.all %} | ||
75 | <a href="{% url "builddashboard" build.id %}"> | ||
76 | {% if t.task %} | ||
77 | {{t.target}}:{{t.task}} | ||
78 | {% else %} | ||
79 | {{t.target}} | ||
80 | {% endif %} | ||
81 | </a> <br /> | ||
82 | {% endfor %} | ||
83 | </td> | ||
84 | <td class="machine"><a href="{% url "builddashboard" build.id %}">{{build.machine}}</a></td> | ||
85 | <td class="started_on"><a href="{% url "builddashboard" build.id %}">{{build.started_on|date:"d/m/y H:i"}}</a></td> | ||
86 | <td class="completed_on"><a href="{% url "builddashboard" build.id %}">{{build.completed_on|date:"d/m/y H:i"}}</a></td> | ||
87 | <td class="failed_tasks error"> | ||
88 | {% query build.task_build outcome=4 order__gt=0 as exectask%} | ||
89 | {% if exectask.count == 1 %} | ||
90 | <a href="{% url "task" build.id exectask.0.id %}">{{exectask.0.recipe.name}}.{{exectask.0.task_name}}</a> | ||
91 | <a href="{% url 'build_artifact' build.id "tasklogfile" exectask.0.id %}"> | ||
92 | <i class="icon-download-alt" title="" data-original-title="Download task log file"></i> | ||
93 | </a> | ||
94 | {% elif exectask.count > 1%} | ||
95 | <a href="{% url "tasks" build.id %}?filter=outcome%3A4">{{exectask.count}} task{{exectask.count|pluralize}}</a> | ||
96 | {%endif%} | ||
97 | </td> | ||
98 | <td class="errors.count errors_no"> | ||
99 | {% if build.errors.count %} | ||
100 | <a class="errors.count error" href="{% url "builddashboard" build.id %}#errors">{{build.errors.count}} error{{build.errors.count|pluralize}}</a> | ||
101 | {%endif%} | ||
102 | </td> | ||
103 | <td class="warnings.count warnings_no">{% if build.warnings.count %}<a class="warnings.count warning" href="{% url "builddashboard" build.id %}#warnings">{{build.warnings.count}} warning{{build.warnings.count|pluralize}}</a>{%endif%}</td> | ||
104 | <td class="time"><a href="{% url "buildtime" build.id %}">{{build.timespent_seconds|sectohms}}</a></td> | ||
105 | <td class="output"> | ||
106 | {% if build.outcome == build.SUCCEEDED %} | ||
107 | <a href="{%url "builddashboard" build.id%}#images">{{fstypes|get_dict_value:build.id}}</a> | ||
108 | {% endif %} | ||
109 | </td> | ||
110 | <td class="project-name"> | ||
111 | <a href="{% project_url build.project %}">{{build.project.name}}</a> | ||
112 | {% if build.project.is_default %} | ||
113 | <i class="icon-question-sign get-help hover-help" title="" data-original-title="This project shows information about the builds you start from the command line while Toaster is running" style="visibility: hidden;"></i> | ||
114 | {% endif %} | ||
115 | </td> | ||
116 | </tr> | ||
117 | |||
118 | {% endfor %} | ||
119 | |||
120 | |||
121 | {% include "basetable_bottom.html" %} | ||
122 | {% endif %} {# objects.paginator.count #} | ||
123 | </div><!-- end row-fluid--> | ||
124 | |||
125 | {% endblock %} | ||
diff --git a/bitbake/lib/toaster/toastergui/templates/projects.html b/bitbake/lib/toaster/toastergui/templates/projects.html deleted file mode 100644 index 678a7963b7..0000000000 --- a/bitbake/lib/toaster/toastergui/templates/projects.html +++ /dev/null | |||
@@ -1,92 +0,0 @@ | |||
1 | {% extends "base.html" %} | ||
2 | |||
3 | {% load static %} | ||
4 | {% load projecttags %} | ||
5 | {% load project_url_tag %} | ||
6 | {% load humanize %} | ||
7 | |||
8 | {% block title %} All projects - Toaster {% endblock %} | ||
9 | |||
10 | {% block pagecontent %} | ||
11 | |||
12 | |||
13 | <div class="page-header top-air"> | ||
14 | <h1> | ||
15 | {% if request.GET.filter and objects.paginator.count > 0 or request.GET.search and objects.paginator.count > 0 %} | ||
16 | {{objects.paginator.count}} project{{objects.paginator.count|pluralize}} found | ||
17 | {%elif request.GET.filter and objects.paginator.count == 0 or request.GET.search and objects.paginator.count == 0 %} | ||
18 | No projects found | ||
19 | {%else%} | ||
20 | All projects | ||
21 | {%endif%} | ||
22 | </h1> | ||
23 | </div> | ||
24 | |||
25 | {% if objects.paginator.count == 0 %} | ||
26 | <div class="row-fluid"> | ||
27 | <div class="alert"> | ||
28 | <form class="no-results input-append" id="searchform"> | ||
29 | <input id="search" name="search" class="input-xxlarge" type="text" value=" | ||
30 | {% if request.GET.search %} | ||
31 | {{request.GET.search}} | ||
32 | {% endif %}"/>{% if request.GET.search %}<a href="javascript:$('#search').val('');searchform.submit()" class="add-on btn" tabindex="-1"><i class="icon-remove"></i></a>{% endif %} | ||
33 | <button class="btn" type="submit" value="Search">Search</button> | ||
34 | <button class="btn btn-link" onclick="javascript:$('#search').val('');searchform.submit()">Show all projects</button> | ||
35 | </form> | ||
36 | </div> | ||
37 | </div> | ||
38 | |||
39 | {% else %} {# We have builds to display #} | ||
40 | {% include "basetable_top.html" %} | ||
41 | {% for o in objects %} | ||
42 | <tr class="data" data-project="{{ o.id }}"> | ||
43 | <td data-project-field="name"> | ||
44 | <a href="{% project_url o %}">{{o.name}}</a> | ||
45 | </td> | ||
46 | <td class="updated"><a href="{% project_url o %}">{{o.updated|date:"d/m/y H:i"}}</a></td> | ||
47 | <td data-project-field="release"> | ||
48 | {% if o.release %} | ||
49 | <a href="{% url 'project' o.id %}#project-details">{{o.release.name}}</a> | ||
50 | {% elif o.is_default %} | ||
51 | <span class="muted">Not applicable</span> | ||
52 | <i class="icon-question-sign get-help hover-help" title="" data-original-title="This project does not have a release set. It simply collects information about the builds you start from the command line while Toaster is running" style="visibility: hidden;"></i> | ||
53 | {% else %} | ||
54 | No release available | ||
55 | {% endif %} | ||
56 | </td> | ||
57 | <td data-project-field="machine"> | ||
58 | {% if o.is_default %} | ||
59 | <span class="muted">Not applicable</span> | ||
60 | <i class="icon-question-sign get-help hover-help" title="" data-original-title="This project does not have a machine set. It simply collects information about the builds you start from the command line while Toaster is running" style="visibility: hidden;"></i> | ||
61 | {% else %} | ||
62 | <a href="{% url 'project' o.id %}#machine-distro">{{o.get_current_machine_name}}</a> | ||
63 | {% endif %} | ||
64 | </td> | ||
65 | {% if o.get_number_of_builds == 0 %} | ||
66 | <td class="muted">{{o.get_number_of_builds}}</td> | ||
67 | <td class="loutcome"></td> | ||
68 | <td class="ltarget"></td> | ||
69 | <td class="lerrors"></td> | ||
70 | <td class="lwarnings"></td> | ||
71 | <td class="limagefiles"></td> | ||
72 | {% else %} | ||
73 | <td><a href="{% url 'projectbuilds' o.id %}">{{o.get_number_of_builds}}</a></td> | ||
74 | <td class="loutcome"><a href="{% url "builddashboard" o.get_last_build_id %}">{%if o.get_last_outcome == build_SUCCEEDED%}<i class="icon-ok-sign success"></i>{%elif o.get_last_outcome == build_FAILED%}<i class="icon-minus-sign error"></i>{%else%}{%endif%}</a></td> | ||
75 | <td class="ltarget"><a href="{% url "builddashboard" o.get_last_build_id %}">{{o.get_last_target}} </a></td> | ||
76 | <td class="lerrors">{% if o.get_last_errors %}<a class="errors.count error" href="{% url "builddashboard" o.get_last_build_id %}#errors">{{o.get_last_errors}} error{{o.get_last_errors|pluralize}}</a>{%endif%}</td> | ||
77 | <td class="lwarnings">{% if o.get_last_warnings %}<a class="warnings.count warning" href="{% url "builddashboard" o.get_last_build_id %}#warnings">{{o.get_last_warnings}} warning{{o.get_last_warnings|pluralize}}</a>{%endif%}</td> | ||
78 | <td class="limagefiles"> | ||
79 | {% if o.get_last_outcome == build_SUCCEEDED %} | ||
80 | <a href="{%url "builddashboard" o.get_last_build_id %}#images">{{fstypes|get_dict_value:o.id}}</a> | ||
81 | {% endif %} | ||
82 | </td> | ||
83 | |||
84 | {% endif %} | ||
85 | </tr> | ||
86 | {% endfor %} | ||
87 | {% include "basetable_bottom.html" %} | ||
88 | {% endif %} {# empty #} | ||
89 | |||
90 | {% endblock %} | ||
91 | |||
92 | |||