mirror of
https://github.com/lucaspalomodevelop/netbox-acls.git
synced 2026-03-12 23:27:23 +00:00
UI Standardization (#36)
* first pass of UI name capitalization * update ACL rule placeholder in UI
This commit is contained in:
parent
dac1ab9f5c
commit
c4f282ee83
@ -52,7 +52,8 @@ class AccessList(NetBoxModel):
|
||||
default_action = models.CharField(
|
||||
default=AccessListActionChoices.ACTION_DENY,
|
||||
max_length=30,
|
||||
choices=AccessListActionChoices
|
||||
choices=AccessListActionChoices,
|
||||
verbose_name='Default Action'
|
||||
)
|
||||
comments = models.TextField(
|
||||
blank=True
|
||||
@ -79,6 +80,7 @@ class AccessListRule(NetBoxModel):
|
||||
on_delete=models.CASCADE,
|
||||
related_name='rules',
|
||||
to=AccessList,
|
||||
verbose_name='Access List'
|
||||
)
|
||||
index = models.PositiveIntegerField()
|
||||
protocol = models.CharField(
|
||||
@ -92,11 +94,13 @@ class AccessListRule(NetBoxModel):
|
||||
on_delete=models.PROTECT,
|
||||
related_name='+',
|
||||
to='ipam.Prefix',
|
||||
verbose_name='Source Prefix'
|
||||
)
|
||||
source_ports = ArrayField(
|
||||
base_field=models.PositiveIntegerField(),
|
||||
blank=True,
|
||||
null=True,
|
||||
verbose_name='Soure Ports'
|
||||
)
|
||||
destination_prefix = models.ForeignKey(
|
||||
blank=True,
|
||||
@ -104,11 +108,13 @@ class AccessListRule(NetBoxModel):
|
||||
on_delete=models.PROTECT,
|
||||
related_name='+',
|
||||
to='ipam.Prefix',
|
||||
verbose_name='Destination Prefix'
|
||||
)
|
||||
destination_ports = ArrayField(
|
||||
base_field=models.PositiveIntegerField(),
|
||||
blank=True,
|
||||
null=True,
|
||||
verbose_name='Destination Ports'
|
||||
)
|
||||
action = models.CharField(
|
||||
choices=AccessListActionChoices,
|
||||
|
||||
@ -13,7 +13,9 @@ class AccessListTable(NetBoxTable):
|
||||
)
|
||||
type = ChoiceFieldColumn()
|
||||
default_action = ChoiceFieldColumn()
|
||||
rule_count = tables.Column()
|
||||
rule_count = tables.Column(
|
||||
verbose_name='Rule Count'
|
||||
)
|
||||
tags = columns.TagColumn(
|
||||
url_name='plugins:netbox_access_lists:accesslist_list'
|
||||
)
|
||||
|
||||
@ -54,7 +54,7 @@
|
||||
<td>{{ object.get_type_display }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th scope="row">Default action</th>
|
||||
<th scope="row">Default Action</th>
|
||||
<td>{{ object.get_default_action_display }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
|
||||
@ -30,11 +30,11 @@
|
||||
<table class="table table-hover attr-table">
|
||||
<tr>
|
||||
<th scope="row">Remark</th>
|
||||
<td>{{ object.get_remark_display }}</td>
|
||||
<td>{{ object.get_remark_display|placeholder }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th scope="row">Protocol</th>
|
||||
<td>{{ object.get_protocol_display }}</td>
|
||||
<td>{{ object.get_protocol_display|placeholder }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th scope="row">Source Prefix</th>
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user