File tree Expand file tree Collapse file tree 2 files changed +9
-0
lines changed
src/netbox_initializers/initializers Expand file tree Collapse file tree 2 files changed +9
-0
lines changed Original file line number Diff line number Diff line change @@ -55,6 +55,12 @@ def load_data(self):
5555 if cf_details .get ("ui_visibility" , False ):
5656 custom_field .ui_visibility = cf_details ["ui_visibility" ]
5757
58+ if cf_details .get ("search_weight" , - 1 ) >= 0 :
59+ custom_field .search_weight = cf_details ["search_weight" ]
60+
61+ if cf_details .get ("is_cloneable" , None ) is not None :
62+ custom_field .is_cloneable = cf_details ["is_cloneable" ]
63+
5864 # object_type should only be applied when type is object, multiobject
5965 if cf_details .get ("object_type" ):
6066 if cf_details .get ("type" ) not in (
Original file line number Diff line number Diff line change 2828# weight: 0
2929# group_name: group1
3030# ui_visibility: read-only
31+ # search_weight: 100
3132# on_objects:
3233# - dcim.models.Device
3334# - dcim.models.Rack
4748# validation_maximum: 255
4849# weight: 10
4950# group_name: group1
51+ # is_cloneable: false
5052# on_objects:
5153# - tenancy.models.Tenant
5254# select_field:
5658# filter_logic: exact
5759# weight: 30
5860# default: First Item
61+ # is_cloneable: true
5962# on_objects:
6063# - dcim.models.Device
6164# choices:
You can’t perform that action at this time.
0 commit comments