diff --git a/layerindex/views.py b/layerindex/views.py index 1cd7eea..6c7a919 100644 --- a/layerindex/views.py +++ b/layerindex/views.py @@ -974,6 +974,7 @@ class RecipeDetailView(DetailView): if dep.path.endswith('.inc'): extrafiles.append(dep) context['extrafiles'] = extrafiles + context['otherbranch_recipes'] = Recipe.objects.filter(layerbranch__layer=recipe.layerbranch.layer, layerbranch__branch__comparison=False, pn=recipe.pn).order_by('layerbranch__branch__sort_priority') return context diff --git a/rrs/views.py b/rrs/views.py index 57340b9..f3f1553 100644 --- a/rrs/views.py +++ b/rrs/views.py @@ -740,6 +740,8 @@ class RecipeDetailView(DetailView): context['recipe_distros'] = RecipeDistro.get_distros_by_recipe(recipe) + context['otherbranch_recipes'] = Recipe.objects.filter(layerbranch__layer=recipe.layerbranch.layer, layerbranch__branch__comparison=False, pn=recipe.pn).order_by('layerbranch__branch__sort_priority') + return context class MaintainerList(): diff --git a/templates/layerindex/recipedetail.html b/templates/layerindex/recipedetail.html index df85e2f..c3b841e 100644 --- a/templates/layerindex/recipedetail.html +++ b/templates/layerindex/recipedetail.html @@ -222,6 +222,33 @@ {% endfor %} {% endif %} + + {% if otherbranch_recipes %} +
This recipe in other branches of {{ recipe.layerbranch.layer.name }}:
+Branch | +Recipe | +
---|---|
+ {{ other.layerbranch.branch }} + | ++ {% if other == recipe %} + {{ other.pn }} {{ other.pv }} (this recipe) + {% else %} + {{ other.pn }} {{ other.pv }} + {% endif %} + | +
None
{% endif %} + + {% if otherbranch_recipes %} +This recipe in other branches of {{ recipe.layerbranch.layer.name }}:
+Branch | +Recipe | +
---|---|
+ {{ other.layerbranch.branch }} + | ++ {% if other == recipe %} + {{ other.pn }} {{ other.pv }} (this recipe) + {% else %} + {{ other.pn }} {{ other.pv }} + {% endif %} + | +