poky/bitbake/lib/toaster/toastergui/templates/package_included_reverse_dependencies.html
Dave Lerner 7fa51314bd bitbake: toaster: format packages with size = -1
Packages that have a size of -1 are virtual packages with limited
information.  Such packages should be suppressed from the package
list page for an image.  On dependency and reverse dependency lists of
package, such packages should appear in muted rows, without links,
and with help information.

The formatting rules are encapsulated into projecttags filters when
possible to minimize tests on size==-1 in the templates.

Testing the relevant pages with an HTML5 validator found a stray end
tag in package_detail_base which has been fixed in this commit.

[YOCTO #5966]

(Bitbake rev: 6cdd4067f766ef5680076c33a32b2dc5d622362c)

Signed-off-by: Dave Lerner <dave.lerner@windriver.com>
Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-03-25 21:32:17 +00:00

55 lines
2.2 KiB
HTML

{% extends "package_detail_base.html" %}
{% load projecttags %}
{% block title %}
{% with fullPackageSpec=package.name|add:"_"|add:package.version|add:"-"|add:package.revision|filtered_packagespec %}
<h1>{{fullPackageSpec}} <small>({{target.target}})</small></h1>
{% endwith %}
{% endblock title %}
{% block tabcontent %}
{% with fullPackageSpec=package.name|add:"_"|add:package.version|add:"-"|add:package.revision|filtered_packagespec packageFileCount=package.buildfilelist_package.count %}
{% include "package_included_tabs.html" with active_tab="reverse" %}
<div class="tab-content">
<div class="tab-pane active" id="brought-in-by">
{% ifequal reverse_deps|length 0 %}
<div class="alert alert-info">
<strong>{{fullPackageSpec}}</strong> has no reverse runtime dependencies.
</div>
{% else %}
<table class="table table-bordered table-hover">
<thead>
<tr>
<th>Package</th>
<th>Version</th>
<th>Size</th>
</tr>
</thead>
<tbody>
{% for reverse_dep in reverse_deps|dictsort:"name" %}
<tr {{reverse_dep.size|format_vpackage_rowclass}} >
{% if reverse_dep.size != -1 %}
<td>
<a href="{% url 'package_included_detail' build.id target.id reverse_dep.dependent_id %}">
{{reverse_dep.name}}
</a>
</td>
{% else %}
<td>
{{reverse_dep.name|format_vpackage_namehelp}}
</td>
{% endif %}
<td>{{reverse_dep.version}}</td>
<td>{{reverse_dep.size|filtered_filesizeformat}}</td>
</tr>
{% endfor %}
</tbody>
</table>
{% endifequal %}
</div> <!-- end tab-pane -->
</div> <!-- end tab content -->
{% endwith %}
{% endblock tabcontent %}