diff options
author | Paul Eggleton <paul.eggleton@linux.intel.com> | 2013-05-13 10:59:12 +0100 |
---|---|---|
committer | Paul Eggleton <paul.eggleton@linux.intel.com> | 2013-06-17 21:11:58 +0100 |
commit | 89f9e6afe8c00ace420335aa3bb5692410b9917d (patch) | |
tree | e67ed8dd02ed2558cfbd5531c93ef22d0a4f5bbe /templates | |
parent | 9af114492887b874e44e5fd2e4b0067b447af3e4 (diff) | |
download | openembedded-core-contrib-89f9e6afe8c00ace420335aa3bb5692410b9917d.tar.gz |
Add duplicate recipes/classes page
Add page that lists recipes and classes "duplicated" across different
layers.
Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Diffstat (limited to 'templates')
-rw-r--r-- | templates/base.html | 9 | ||||
-rw-r--r-- | templates/layerindex/duplicates.html | 96 |
2 files changed, 105 insertions, 0 deletions
diff --git a/templates/base.html b/templates/base.html index fd591ad623..f11674e352 100644 --- a/templates/base.html +++ b/templates/base.html @@ -63,6 +63,15 @@ {% endif %} </a></li> {% endif %} + <li class="dropdown"> + <a href="#" class="dropdown-toggle" data-toggle="dropdown"> + Tools + <b class="caret"></b> + </a> + <ul class="dropdown-menu"> + <li><a href="{% url duplicates %}">Duplicates</a></li> + </ul> + </li> <li class="divider-vertical"></li> <li class="dropdown"> <a href="#" class="dropdown-toggle" data-toggle="dropdown"> diff --git a/templates/layerindex/duplicates.html b/templates/layerindex/duplicates.html new file mode 100644 index 0000000000..c6d06b2195 --- /dev/null +++ b/templates/layerindex/duplicates.html @@ -0,0 +1,96 @@ +{% extends "base.html" %} +{% load i18n %} + +{% comment %} + + layerindex-web - duplicates page template + + Copyright (C) 2013 Intel Corporation + Licensed under the MIT license, see COPYING.MIT for details + +{% endcomment %} + + +<!-- +{% block title_append %} - duplicates{% endblock %} +--> + +{% block content %} +{% autoescape on %} + + <div class="row-fluid"> + <div class="span9 offset1"> + <h2>Duplicate recipes</h2> +{% if recipes %} + <p>Recipes with the same name in different layers:</p> + <table class="table table-striped table-bordered recipestable"> + <thead> + <tr> + <th>Recipe name</th> + <th>Version</th> + <th class="span9">Description</th> + <th>Layer</th> + </tr> + </thead> + + <tbody> + {% for recipe in recipes %} + <tr {% if recipe.preferred_count > 0 %}class="muted"{% endif %}> + <td><a href="{% url recipe recipe.id %}">{{ recipe.name }}</a></td> + <td>{{ recipe.pv }}</td> + <td>{{ recipe.short_desc }}</td> + <td><a href="{% url layer_item recipe.layerbranch.layer.name %}">{{ recipe.layerbranch.layer.name }}</a></td> + </tr> + {% endfor %} + </tbody> + </table> +{% else %} + <p>No duplicate recipes in database.</p> +{% endif %} + </div> + </div> + + + <div class="row-fluid"> + <div class="span9 offset1"> + <h2>Duplicate classes</h2> +{% if classes %} + <p>Classes with the same name in different layers:</p> + <table class="table table-striped table-bordered recipestable"> + <thead> + <tr> + <th>Class name</th> + <th>Layer</th> + </tr> + </thead> + + <tbody> + {% for class in classes %} + <tr> + <td><a href="{% url class.vcs_web_url %}">{{ class.name }}</a></td> + <td><a href="{% url layer_item class.layerbranch.layer.name %}">{{ class.layerbranch.layer.name }}</a></td> + </tr> + {% endfor %} + </tbody> + </table> +{% else %} + <p>No duplicate classes in database.</p> +{% endif %} + </div> + </div> + + +{% endautoescape %} + +{% endblock %} + + +{% block scripts %} +<script> + $(document).ready(function() { + firstfield = $("#filter-form input:text").first() + if( ! firstfield.val() ) + firstfield.focus() + }); +</script> +{% endblock %} |