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
8ccc0cde
authored
Feb 11, 2013
by
Őry Máté
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
one: do not recontext if not needed
parent
6c99d3eb
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
3 deletions
+5
-3
one/views.py
+5
-3
No files found.
one/views.py
View file @
8ccc0cde
...
...
@@ -193,7 +193,8 @@ def vm_saveas(request, vmid):
@require_POST
@login_required
def
vm_new
(
request
,
template
=
None
,
share
=
None
):
base
=
None
base
=
None
extra
=
None
if
template
:
base
=
get_object_or_404
(
Template
,
pk
=
template
)
else
:
...
...
@@ -209,10 +210,11 @@ def vm_new(request, template=None, share=None):
t
.
system
=
base
.
system
t
.
save
()
base
=
t
extra
=
"<RECONTEXT>YES</RECONTEXT>"
try
:
#Gány quota
if
share
==
None
or
(
share
!=
None
and
share
.
get_running
()
<
share
.
instance_limit
):
i
=
Instance
.
submit
(
base
,
request
.
user
,
extra
=
"<RECONTEXT>YES</RECONTEXT>"
,
share
=
share
)
if
share
==
None
or
(
share
!=
None
and
share
.
get_running
()
<
share
.
instance_limit
)
or
extra
:
i
=
Instance
.
submit
(
base
,
request
.
user
,
extra
=
extra
,
share
=
share
)
return
redirect
(
i
)
except
Exception
as
e
:
logger
.
error
(
'Failed to create virtual machine.'
+
unicode
(
e
))
...
...
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