Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
Fukász Rómeó Ervin
/
cloud
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
A prog2-höz tartozó friss repo anyagok itt elérhetőek:
https://git.iit.bme.hu/
Commit
03ae1309
authored
Jul 04, 2014
by
Őry Máté
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
dashboard: reorder operation buttons by hand
parent
f49834d1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
24 additions
and
14 deletions
+24
-14
circle/dashboard/views.py
+24
-14
No files found.
circle/dashboard/views.py
View file @
03ae1309
...
...
@@ -17,6 +17,7 @@
from
__future__
import
unicode_literals
,
absolute_import
from
collections
import
OrderedDict
from
itertools
import
chain
from
os
import
getenv
import
json
...
...
@@ -691,22 +692,31 @@ class VmSaveView(FormOperationMixin, VmOperationView):
op
=
'save_as_template'
icon
=
'save'
effect
=
'info'
form_class
=
VmSaveForm
vm_ops
=
{
'reset'
:
VmOperationView
.
factory
(
op
=
'reset'
,
icon
=
'bolt'
),
'deploy'
:
VmOperationView
.
factory
(
op
=
'deploy'
,
icon
=
'play'
),
'migrate'
:
VmMigrateView
,
'reboot'
:
VmOperationView
.
factory
(
op
=
'reboot'
,
icon
=
'refresh'
),
'shut_off'
:
VmOperationView
.
factory
(
op
=
'shut_off'
,
icon
=
'ban-circle'
),
'shutdown'
:
VmOperationView
.
factory
(
op
=
'shutdown'
,
icon
=
'off'
),
'save_as_template'
:
VmSaveView
,
'destroy'
:
VmOperationView
.
factory
(
op
=
'destroy'
,
icon
=
'remove'
),
'sleep'
:
VmOperationView
.
factory
(
op
=
'sleep'
,
icon
=
'moon'
),
'wake_up'
:
VmOperationView
.
factory
(
op
=
'wake_up'
,
icon
=
'sun'
),
'create_disk'
:
VmCreateDiskView
,
'download_disk'
:
VmDownloadDiskView
,
}
vm_ops
=
OrderedDict
([
(
'deploy'
,
VmOperationView
.
factory
(
op
=
'deploy'
,
icon
=
'play'
)),
(
'wake_up'
,
VmOperationView
.
factory
(
op
=
'wake_up'
,
icon
=
'sun'
)),
(
'sleep'
,
VmOperationView
.
factory
(
op
=
'sleep'
,
icon
=
'moon'
)),
(
'migrate'
,
VmMigrateView
),
(
'save_as_template'
,
VmSaveView
),
(
'reboot'
,
VmOperationView
.
factory
(
op
=
'reboot'
,
icon
=
'refresh'
)),
(
'reset'
,
VmOperationView
.
factory
(
op
=
'reset'
,
icon
=
'bolt'
)),
(
'shutdown'
,
VmOperationView
.
factory
(
op
=
'shutdown'
,
icon
=
'off'
)),
(
'shut_off'
,
VmOperationView
.
factory
(
op
=
'shut_off'
,
icon
=
'ban-circle'
)),
(
'destroy'
,
VmOperationView
.
factory
(
op
=
'destroy'
,
icon
=
'remove'
)),
(
'create_disk'
,
VmCreateDiskView
),
(
'download_disk'
,
VmDownloadDiskView
),
])
def
get_operations
(
instance
,
user
):
...
...
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