Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
Gutyán Gábor
/
circlestack
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):
def
prefix6
(
self
):
return
self
.
network6
.
prefixlen
def
__unicode__
(
self
):
return
self
.
name
class
VlanGroup
(
models
.
Model
):
"""
...
...
@@ -741,6 +738,12 @@ class Record(models.Model):
def
get_absolute_url
(
self
):
return
(
'network.record'
,
None
,
{
'pk'
:
self
.
pk
})
class
Meta
:
ordering
=
(
'domain'
,
'name'
,
)
class
Blacklist
(
models
.
Model
):
CHOICES_type
=
((
'permban'
,
'permanent ban'
),
(
'tempban'
,
'temporary ban'
),
...
...
circle/network/tables.py
View file @
38144860
...
...
@@ -97,7 +97,7 @@ class RecordTable(Table):
fields
=
(
'type'
,
'fqdn'
,
'host'
,
'address'
,
'ttl'
,
'host'
,
'owner'
,
)
sequence
=
(
'type'
,
'fqdn'
,
)
order_by
=
'name'
#
order_by = 'name'
class
SmallRecordTable
(
Table
):
...
...
@@ -108,7 +108,7 @@ class SmallRecordTable(Table):
attrs
=
{
'class'
:
'table table-striped table-bordered'
}
fields
=
(
'type'
,
'fqdn'
,
'host'
,
'address'
,
)
sequence
=
(
'type'
,
'fqdn'
,
)
order_by
=
'-type'
#
order_by = '-type'
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