Skip to content

Commit

Permalink
Merge branch 'release/1.0.0' into develop
Browse files Browse the repository at this point in the history
  • Loading branch information
APalhood committed Oct 30, 2024
2 parents 59e8930 + b466979 commit be1e4f9
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion admin_toolkit/admin_mixins.py
Original file line number Diff line number Diff line change
Expand Up @@ -326,7 +326,9 @@ def display_devices(self, obj):
related_name = related_manager.field.name
related_model = related_manager.model
if show_generic_link:
url = "{}?{}__id__exact={}".format(related_model.admin_changelist_url(), related_name, obj.pk)
url = "{}?{}__id__exact={}".format(
related_model.admin_changelist_url(), related_name, obj.pk
)
elements_count = related_manager.count()
return '<a href="{url}" target="_blank">Display {elements_count} {label}</a>' "".format(
url=url, elements_count=elements_count, label=label
Expand Down

0 comments on commit be1e4f9

Please sign in to comment.