diff --git a/bitbake/lib/toaster/toastergui/buildtables.py b/bitbake/lib/toaster/toastergui/buildtables.py index 82a8ba5378..b6485e64fd 100644 --- a/bitbake/lib/toaster/toastergui/buildtables.py +++ b/bitbake/lib/toaster/toastergui/buildtables.py @@ -109,15 +109,31 @@ class BuiltPackagesTableBase(tables.PackagesTable): hidden=True, orderable=True) + layer_branch_template = ''' + {%if not data.recipe.layer_version.layer.local_source_dir %} + {{data.recipe.layer_version.branch}} + {% else %} + Not applicable + + {% endif %} + ''' + self.add_column(title="Layer branch", field_name="recipe__layer_version__branch", hidden=True, + static_data_name="recipe__layer_version__branch", + static_data_template=layer_branch_template, orderable=True) git_rev_template = ''' + {% if not data.recipe.layer_version.layer.local_source_dir %} {% with vcs_ref=data.recipe.layer_version.commit %} {% include 'snippets/gitrev_popover.html' %} {% endwith %} + {% else %} + Not applicable + + {% endif %} ''' self.add_column(title="Layer commit", @@ -250,10 +266,24 @@ class BuiltRecipesTable(BuildTablesMixin): '{% if data.pathflags %}({{data.pathflags}})'\ '{% endif %}' + git_branch_template = ''' + {% if data.layer_version.layer.local_source_dir %} + Not applicable + + {% else %} + {{data.layer_version.branch}} + {% endif %} + ''' + git_rev_template = ''' + {% if data.layer_version.layer.local_source_dir %} + Not applicable + + {% else %} {% with vcs_ref=data.layer_version.commit %} {% include 'snippets/gitrev_popover.html' %} {% endwith %} + {% endif %} ''' depends_on_tmpl = ''' @@ -342,6 +372,8 @@ class BuiltRecipesTable(BuildTablesMixin): self.add_column(title="Layer branch", field_name="layer_version__branch", + static_data_name="layer_version__branch", + static_data_template=git_branch_template, orderable=True, hidden=True)