1
0
mirror of https://github.com/netbox-community/netbox.git synced 2024-05-10 07:54:54 +00:00

Closes #6715: Add tenant assignment for cables

This commit is contained in:
jeremystretch
2021-10-19 12:33:17 -04:00
parent ba7361bdc7
commit 0afd3e6189
15 changed files with 79 additions and 44 deletions

View File

@ -468,6 +468,10 @@ class CableBulkEditForm(BootstrapMixin, AddRemoveTagsForm, CustomFieldModelBulkE
widget=StaticSelect(),
initial=''
)
tenant = DynamicModelChoiceField(
queryset=Tenant.objects.all(),
required=False
)
label = forms.CharField(
max_length=100,
required=False
@ -488,7 +492,7 @@ class CableBulkEditForm(BootstrapMixin, AddRemoveTagsForm, CustomFieldModelBulkE
class Meta:
nullable_fields = [
'type', 'status', 'label', 'color', 'length',
'type', 'status', 'tenant', 'label', 'color', 'length',
]
def clean(self):