Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
Gyuricska Milán
/
cloud
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
38144860
authored
Sep 09, 2013
by
Kálmán Viktor
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
network: default ordering for records
parent
9a7736ad
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
5 deletions
+8
-5
circle/firewall/models.py
+6
-3
circle/network/tables.py
+2
-2
No files found.
circle/firewall/models.py
View file @
38144860
...
@@ -278,9 +278,6 @@ class Vlan(models.Model):
...
@@ -278,9 +278,6 @@ class Vlan(models.Model):
def
prefix6
(
self
):
def
prefix6
(
self
):
return
self
.
network6
.
prefixlen
return
self
.
network6
.
prefixlen
def
__unicode__
(
self
):
return
self
.
name
class
VlanGroup
(
models
.
Model
):
class
VlanGroup
(
models
.
Model
):
"""
"""
...
@@ -741,6 +738,12 @@ class Record(models.Model):
...
@@ -741,6 +738,12 @@ class Record(models.Model):
def
get_absolute_url
(
self
):
def
get_absolute_url
(
self
):
return
(
'network.record'
,
None
,
{
'pk'
:
self
.
pk
})
return
(
'network.record'
,
None
,
{
'pk'
:
self
.
pk
})
class
Meta
:
ordering
=
(
'domain'
,
'name'
,
)
class
Blacklist
(
models
.
Model
):
class
Blacklist
(
models
.
Model
):
CHOICES_type
=
((
'permban'
,
'permanent ban'
),
(
'tempban'
,
'temporary ban'
),
CHOICES_type
=
((
'permban'
,
'permanent ban'
),
(
'tempban'
,
'temporary ban'
),
...
...
circle/network/tables.py
View file @
38144860
...
@@ -97,7 +97,7 @@ class RecordTable(Table):
...
@@ -97,7 +97,7 @@ class RecordTable(Table):
fields
=
(
'type'
,
'fqdn'
,
'host'
,
'address'
,
'ttl'
,
'host'
,
fields
=
(
'type'
,
'fqdn'
,
'host'
,
'address'
,
'ttl'
,
'host'
,
'owner'
,
)
'owner'
,
)
sequence
=
(
'type'
,
'fqdn'
,
)
sequence
=
(
'type'
,
'fqdn'
,
)
order_by
=
'name'
#
order_by = 'name'
class
SmallRecordTable
(
Table
):
class
SmallRecordTable
(
Table
):
...
@@ -108,7 +108,7 @@ class SmallRecordTable(Table):
...
@@ -108,7 +108,7 @@ class SmallRecordTable(Table):
attrs
=
{
'class'
:
'table table-striped table-bordered'
}
attrs
=
{
'class'
:
'table table-striped table-bordered'
}
fields
=
(
'type'
,
'fqdn'
,
'host'
,
'address'
,
)
fields
=
(
'type'
,
'fqdn'
,
'host'
,
'address'
,
)
sequence
=
(
'type'
,
'fqdn'
,
)
sequence
=
(
'type'
,
'fqdn'
,
)
order_by
=
'-type'
#
order_by = '-type'
orderable
=
False
orderable
=
False
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment