toaster: project pages Link to image recipes table in notifications
PATCH 1/2 toaster: project pages Link to image recipes table in notifications
From: Belen Barros Pena <[email protected]>
The project created notifications and the 'Choosea recipe to build' link in the project page are linking to the software recipes table. Changes them to link to the image recipes table instead, which is bound to be more useful.
--- lib/toaster/toastergui/templates/project.html | 2 +- lib/toaster/toastergui/templates/projecttopbar.html | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-)
lib/toaster/toastergui/templates/project.html +1 -1
@@ -68,7 +68,7 @@ <div class="alert alert-info" style="display:none" id="no-most-built"> <span class="lead">You haven't built any recipes yet</span> - <p style="margin-top: 10px;"><a href="{% url 'projectsoftwarerecipes' project.id %}">Choose a recipe to build</a></p> + <p style="margin-top: 10px;"><a href="{% url 'projectimagerecipes' project.id %}">Choose a recipe to build</a></p> </div> <ul class="unstyled configuration-list" id="freq-build-list">
lib/toaster/toastergui/templates/projecttopbar.html +1 -1
@@ -1,6 +1,6 @@ <div class="alert alert-success lead" id="project-created-notification" style="margin-top:15px; display:none"> <button type="button" class="close" data-dismiss="alert">×</button> - Your project <strong>{{project.name}}</strong> has been created. You can now <a href="{% url 'projectmachines' project.id %}">select your target machine</a> and <a href="{% url 'projectsoftwarerecipes' project.id %}">choose image recipes</a> to build. + Your project <strong>{{project.name}}</strong> has been created. You can now <a href="{% url 'projectmachines' project.id %}">select your target machine</a> and <a href="{% url 'projectimagerecipes' project.id %}">choose image recipes</a> to build. </div> <!-- project name -->
Signature · 1 line
2.5.0
PATCH 2/2 toaster: builds pages Fix the download cooker log link
From: Belen Barros Pena <[email protected]>
The 'all builds' page was missing the download icon next to the outcome icon, which allows you to download a build log from the 'all builds' page.
This patch brings it back. It also adds a check in the project builds page to make sure the download icon only appears if the build generates a cooker log, since builds that fail at the build request stage do not generate a cooker log.
--- lib/toaster/toastergui/templates/builds.html | 8 +++++++- lib/toaster/toastergui/templates/projectbuilds.html | 11 ++++++----- 2 files changed, 13 insertions(+), 6 deletions(-)
lib/toaster/toastergui/templates/builds.html +7 -1
@@ -62,7 +62,13 @@ {% for build in objects %} <tr class="data" data-table-build-result="{{ build.id }}"> <td class="outcome"> - <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> + <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> + {% if build.cooker_log_path %} + + <a href="{% url 'build_artifact' build.id "cookerlog" build.id %}"> + <i class="icon-download-alt" title="Download build log"></i> + </a> + {% endif %} </td> <td class="target"> {% for t in build.target_set.all %}
lib/toaster/toastergui/templates/projectbuilds.html +6 -5
@@ -63,11 +63,12 @@ {% for build in objects %} {# if we have a build, just display it #} <tr class="data"> <td class="outcome"><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> - {% if build.project %} - <a href="{% url 'build_artifact' build.id "cookerlog" build.id %}"> - <i class="icon-download-alt" title="" data-original-title="Download build log"></i> - </a> - {% endif %} + {% if build.cooker_log_path %} + + <a href="{% url 'build_artifact' build.id "cookerlog" build.id %}"> + <i class="icon-download-alt" title="Download build log"></i> + </a> + {% endif %} </td> <td class="target">
Signature · 1 line
2.5.0