Custom Link Column Sort #8459

Closed
opened 2025-12-29 20:37:01 +01:00 by adam · 1 comment
Owner

Originally created by @abahney on GitHub (Aug 11, 2023).

Originally assigned to: @jeremystretch on GitHub.

NetBox version

v3.5.7

Python version

3.10

Steps to Reproduce

  1. Create custom link for Site that only applies to specific region
    Link Text:{% if object.region.slug =='us-ny' %} Test Link {% endif %}
    Link URL: https://www.google.com
  2. Add custom link as column in Site table
  3. Sort by custom link

Expected Behavior

Sort by those that have a custom link vs not.

Observed Behavior

Doesn't sort by custom link.
custom_link_sort

Originally created by @abahney on GitHub (Aug 11, 2023). Originally assigned to: @jeremystretch on GitHub. ### NetBox version v3.5.7 ### Python version 3.10 ### Steps to Reproduce 1. Create custom link for Site that only applies to specific region `Link Text:{% if object.region.slug =='us-ny' %} Test Link {% endif %}` `Link URL: https://www.google.com` 2. Add custom link as column in Site table 3. Sort by custom link ### Expected Behavior Sort by those that have a custom link vs not. ### Observed Behavior Doesn't sort by custom link. ![custom_link_sort](https://github.com/netbox-community/netbox/assets/123212781/4411dd0f-b2c1-426f-b886-5564d7e4ad87)
adam added the type: bugstatus: accepted labels 2025-12-29 20:37:01 +01:00
adam closed this issue 2025-12-29 20:37:02 +01:00
Author
Owner

@jeremystretch commented on GitHub (Aug 14, 2023):

Sort by those that have a custom link vs not.

Custom links are assigned per model, not per object. And we cannot order by rendered text. All we can really do is disable ordering for the column.

@jeremystretch commented on GitHub (Aug 14, 2023): > Sort by those that have a custom link vs not. Custom links are assigned per model, not per object. And we cannot order by rendered text. All we can really do is disable ordering for the column.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/netbox#8459