diff options
author | Paul Eggleton <paul.eggleton@linux.intel.com> | 2013-03-20 12:04:54 +0000 |
---|---|---|
committer | Paul Eggleton <paul.eggleton@linux.intel.com> | 2013-03-20 17:04:56 +0000 |
commit | 342ff28648d01e783aed4013f9c20fa016c99833 (patch) | |
tree | c210a08dd99609135027979b8315f6d286cce362 /templates | |
parent | 42d710b640b421f5a66922755d0ddc8d73a0ab03 (diff) | |
download | openembedded-core-contrib-342ff28648d01e783aed4013f9c20fa016c99833.tar.gz |
De-emphasise recipes where there is a more preferred version available
If another recipe exists with the same name in a different layer and
that other layer is "older" (by layer ID) and is a software or base
layer then lighten the recipe entry in the search results as it may
not be the preferred version (e.g. recipes in BSP or distro layers may
have been customised specifically for the machine or distro).
This has had a performance impact on the recipes list; as a result
showing all recipes by default has been disabled. If the user really
wants to see all recipes they can just leave the search box blank and
hit the search button.
Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Diffstat (limited to 'templates')
-rw-r--r-- | templates/layerindex/recipes.html | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/templates/layerindex/recipes.html b/templates/layerindex/recipes.html index 36749de38e..f400442467 100644 --- a/templates/layerindex/recipes.html +++ b/templates/layerindex/recipes.html @@ -50,7 +50,7 @@ <tbody> {% for recipe in recipe_list %} - <tr> + <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> @@ -77,3 +77,14 @@ {% endautoescape %} {% endblock %} + + +{% block scripts %} +<script> + $(document).ready(function() { + firstfield = $("#filter-form input:text").first() + if( ! firstfield.val() ) + firstfield.focus() + }); +</script> +{% endblock %} |