mirror of
https://github.com/netbox-community/netbox.git
synced 2025-08-25 08:46:10 -06:00
Specify fieldsets for additional models
This commit is contained in:
parent
c9db424913
commit
858f8ea623
@ -170,6 +170,12 @@ class ASNForm(TenancyForm, NetBoxModelForm):
|
|||||||
class RoleForm(NetBoxModelForm):
|
class RoleForm(NetBoxModelForm):
|
||||||
slug = SlugField()
|
slug = SlugField()
|
||||||
|
|
||||||
|
fieldsets = (
|
||||||
|
('Role', (
|
||||||
|
'name', 'slug', 'weight', 'description', 'tags',
|
||||||
|
)),
|
||||||
|
)
|
||||||
|
|
||||||
class Meta:
|
class Meta:
|
||||||
model = Role
|
model = Role
|
||||||
fields = [
|
fields = [
|
||||||
@ -790,6 +796,12 @@ class ServiceTemplateForm(NetBoxModelForm):
|
|||||||
help_text="Comma-separated list of one or more port numbers. A range may be specified using a hyphen."
|
help_text="Comma-separated list of one or more port numbers. A range may be specified using a hyphen."
|
||||||
)
|
)
|
||||||
|
|
||||||
|
fieldsets = (
|
||||||
|
('Service Template', (
|
||||||
|
'name', 'protocol', 'ports', 'description', 'tags',
|
||||||
|
)),
|
||||||
|
)
|
||||||
|
|
||||||
class Meta:
|
class Meta:
|
||||||
model = ServiceTemplate
|
model = ServiceTemplate
|
||||||
fields = ('name', 'protocol', 'ports', 'description', 'tags')
|
fields = ('name', 'protocol', 'ports', 'description', 'tags')
|
||||||
|
@ -84,6 +84,12 @@ class ContactGroupForm(NetBoxModelForm):
|
|||||||
class ContactRoleForm(NetBoxModelForm):
|
class ContactRoleForm(NetBoxModelForm):
|
||||||
slug = SlugField()
|
slug = SlugField()
|
||||||
|
|
||||||
|
fieldsets = (
|
||||||
|
('Contact Role', (
|
||||||
|
'name', 'slug', 'description', 'tags',
|
||||||
|
)),
|
||||||
|
)
|
||||||
|
|
||||||
class Meta:
|
class Meta:
|
||||||
model = ContactRole
|
model = ContactRole
|
||||||
fields = ('name', 'slug', 'description', 'tags')
|
fields = ('name', 'slug', 'description', 'tags')
|
||||||
|
Loading…
Reference in New Issue
Block a user