mirror of
https://github.com/netbox-community/netbox.git
synced 2024-05-10 07:54:54 +00:00
@@ -178,6 +178,11 @@ class WebhookBulkEditForm(NetBoxModelBulkEditForm):
|
||||
queryset=Webhook.objects.all(),
|
||||
widget=forms.MultipleHiddenInput
|
||||
)
|
||||
description = forms.CharField(
|
||||
label=_('Description'),
|
||||
max_length=200,
|
||||
required=False
|
||||
)
|
||||
http_method = forms.ChoiceField(
|
||||
choices=add_blank_choice(WebhookHttpMethodChoices),
|
||||
required=False,
|
||||
@@ -242,7 +247,7 @@ class EventRuleBulkEditForm(NetBoxModelBulkEditForm):
|
||||
widget=BulkEditNullBooleanSelect()
|
||||
)
|
||||
|
||||
nullable_fields = ('conditions',)
|
||||
nullable_fields = ('description', 'conditions',)
|
||||
|
||||
|
||||
class TagBulkEditForm(BulkEditForm):
|
||||
|
||||
@@ -150,7 +150,7 @@ class WebhookImportForm(NetBoxModelImportForm):
|
||||
model = Webhook
|
||||
fields = (
|
||||
'name', 'payload_url', 'http_method', 'http_content_type', 'additional_headers', 'body_template',
|
||||
'secret', 'ssl_verification', 'ca_file_path', 'tags'
|
||||
'secret', 'ssl_verification', 'ca_file_path', 'description', 'tags'
|
||||
)
|
||||
|
||||
|
||||
|
||||
@@ -215,7 +215,7 @@ class BookmarkForm(BootstrapMixin, forms.ModelForm):
|
||||
class WebhookForm(NetBoxModelForm):
|
||||
|
||||
fieldsets = (
|
||||
(_('Webhook'), ('name', 'tags',)),
|
||||
(_('Webhook'), ('name', 'description', 'tags',)),
|
||||
(_('HTTP Request'), (
|
||||
'payload_url', 'http_method', 'http_content_type', 'additional_headers', 'body_template', 'secret',
|
||||
)),
|
||||
|
||||
Reference in New Issue
Block a user