Custom Field of any type with default value auto select a filter #5939

Closed
opened 2025-12-29 19:34:31 +01:00 by adam · 1 comment
Owner

Originally created by @ryanmerolle on GitHub (Jan 13, 2022).

NetBox version

v3.1.5

Python version

3.9

Steps to Reproduce

1.) Create a custom field with a default value like "test", filter logic of exact or loose, and any type. customfield.png
2.) Go to the table view of the object(s) you linked said custom field to.
3.) Observe that though you set no filter a filter "1" indicator is showing up even though the url has not filter set. filter.png
4.) Click the filter tab, and do not filter anything but select the search button
5.) Observe the filters still shows a filter "1" indicator is showing up. Also observe the said customfield name is now showing as a filter with no value defined. filter2.png

Expected Behavior

No "empty value" filter to show up by default in the table

Observed Behavior

Default value set in customfield inadvertently sets an "empty value" filter to show up by default in the table

Originally created by @ryanmerolle on GitHub (Jan 13, 2022). ### NetBox version v3.1.5 ### Python version 3.9 ### Steps to Reproduce 1.) Create a custom field with a default value like "test", filter logic of exact or loose, and any type. [![customfield.png](https://i.postimg.cc/BnCxkbWY/customfield.png)](https://postimg.cc/HrVc7pkX) 2.) Go to the table view of the object(s) you linked said custom field to. 3.) Observe that though you set no filter a filter "1" indicator is showing up even though the url has not filter set. [![filter.png](https://i.postimg.cc/fbTxNsDw/filter.png)](https://postimg.cc/xXhkvWX7) 4.) Click the filter tab, and do not filter anything but select the search button 5.) Observe the filters still shows a filter "1" indicator is showing up. Also observe the said customfield name is now showing as a filter with no value defined. [![filter2.png](https://i.postimg.cc/fRsc8XPS/filter2.png)](https://postimg.cc/7fBJ6Cwq) ### Expected Behavior No "empty value" filter to show up by default in the table ### Observed Behavior Default value set in customfield inadvertently sets an "empty value" filter to show up by default in the table
adam added the type: bugstatus: duplicate labels 2025-12-29 19:34:31 +01:00
adam closed this issue 2025-12-29 19:34:31 +01:00
Author
Owner

@ryanmerolle commented on GitHub (Jan 13, 2022):

duplicate of #8314

@ryanmerolle commented on GitHub (Jan 13, 2022): duplicate of #8314
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/netbox#5939