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

Clean up nullable fields declaration for bulk edit forms

This commit is contained in:
jeremystretch
2022-01-28 16:47:54 -05:00
parent f4776731ec
commit e4eee1cdfc
9 changed files with 120 additions and 121 deletions

View File

@@ -34,7 +34,7 @@ class CustomFieldBulkEditForm(BulkEditForm):
)
class Meta:
nullable_fields = []
nullable_fields = ('description',)
class CustomLinkBulkEditForm(BulkEditForm):
@@ -64,9 +64,6 @@ class CustomLinkBulkEditForm(BulkEditForm):
widget=StaticSelect()
)
class Meta:
nullable_fields = []
class ExportTemplateBulkEditForm(BulkEditForm):
pk = forms.ModelMultipleChoiceField(
@@ -96,7 +93,7 @@ class ExportTemplateBulkEditForm(BulkEditForm):
)
class Meta:
nullable_fields = ['description', 'mime_type', 'file_extension']
nullable_fields = ('description', 'mime_type', 'file_extension')
class WebhookBulkEditForm(BulkEditForm):
@@ -139,7 +136,7 @@ class WebhookBulkEditForm(BulkEditForm):
)
class Meta:
nullable_fields = ['secret', 'conditions', 'ca_file_path']
nullable_fields = ('secret', 'conditions', 'ca_file_path')
class TagBulkEditForm(BulkEditForm):
@@ -156,7 +153,7 @@ class TagBulkEditForm(BulkEditForm):
)
class Meta:
nullable_fields = ['description']
nullable_fields = ('description',)
class ConfigContextBulkEditForm(BulkEditForm):
@@ -178,9 +175,7 @@ class ConfigContextBulkEditForm(BulkEditForm):
)
class Meta:
nullable_fields = [
'description',
]
nullable_fields = ('description',)
class JournalEntryBulkEditForm(BulkEditForm):
@@ -196,6 +191,3 @@ class JournalEntryBulkEditForm(BulkEditForm):
required=False,
widget=forms.Textarea()
)
class Meta:
nullable_fields = []