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
77cb1b9c
authored
Apr 14, 2014
by
Kálmán Viktor
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
dashboard: default ordering of interfaces by managed attr
parent
ef4fa009
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
1 deletions
+2
-1
circle/dashboard/views.py
+1
-1
circle/vm/models/network.py
+1
-0
No files found.
circle/dashboard/views.py
View file @
77cb1b9c
...
...
@@ -215,7 +215,7 @@ class VmDetailView(CheckedDetailView):
context
[
'vlans'
]
=
Vlan
.
get_objects_with_level
(
'user'
,
self
.
request
.
user
)
.
exclude
(
)
.
exclude
(
# exclude already added interfaces
pk__in
=
Interface
.
objects
.
filter
(
instance
=
self
.
get_object
())
.
values_list
(
"vlan"
,
flat
=
True
)
)
.
all
()
...
...
circle/vm/models/network.py
View file @
77cb1b9c
...
...
@@ -53,6 +53,7 @@ class Interface(Model):
class
Meta
:
app_label
=
'vm'
db_table
=
'vm_interface'
ordering
=
(
"-vlan__managed"
,
)
def
__unicode__
(
self
):
return
'cloud-'
+
str
(
self
.
instance
.
id
)
+
'-'
+
str
(
self
.
vlan
.
vid
)
...
...
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