netbox-bgp icon indicating copy to clipboard operation
netbox-bgp copied to clipboard

Searching for custom field values doesn't work

Open jwbensley opened this issue 1 year ago • 1 comments

NetBox version NetBox v3.7.8 with BGP plugin v0.12.1.

Describe the bug When searching BGP sessions for a value stored in a custom field, now BGP sessions are found with this value (custom fields aren't being searched). Searching for a value stored in a native field works fine.

To Reproduce

Below I search for a partial value stored in a custom field called "AS-SET", but as you can see, no BGP sessions are found:

grafik

Below I search for the name of the BGP session, the sessions are found and you can see the value I was searching for exists in the custom field:

grafik

Expected behavior

I would expect the search to search values in custom fields.

jwbensley avatar Dec 02 '24 13:12 jwbensley

Hi james, I need to do some testing around this in terms of auto including custom fields - however one way to do this is to specify the custom fields and type of search in configuration.py - would this suit your needs -

eg: {'as_set': ['icontains', 'exact']}

cruse1977 avatar Dec 02 '24 16:12 cruse1977