Closes #14134: Display additional object attributes in global search results (#14154)

* WIP

* Add display_attrs for all indexers

* Linkify object attributes

* Clean up prefetch logic

* Use tooltips for display attributes

* Simplify template code

* Introduce get_indexer() utility function

* Add  to examples in docs

* Use tooltips to display long strings
This commit is contained in:
Jeremy Stretch
2023-11-09 16:21:09 -05:00
committed by GitHub
parent e6c07607d6
commit 1778437eb7
15 changed files with 165 additions and 7 deletions

View File

@@ -11,6 +11,7 @@ class WirelessLANIndex(SearchIndex):
('auth_psk', 2000),
('comments', 5000),
)
display_attrs = ('group', 'status', 'vlan', 'tenant', 'description')
@register_search
@@ -21,6 +22,7 @@ class WirelessLANGroupIndex(SearchIndex):
('slug', 110),
('description', 500),
)
display_attrs = ('description',)
@register_search
@@ -32,3 +34,4 @@ class WirelessLinkIndex(SearchIndex):
('auth_psk', 2000),
('comments', 5000),
)
display_attrs = ('status', 'tenant', 'description')