Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
CIRCLE
/
cloud
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
94
Merge Requests
10
Pipelines
Wiki
Snippets
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
3702c874
authored
Jun 30, 2014
by
Kálmán Viktor
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
dashboard: don't display change resource button if no perm
parent
ba3fcdc2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
0 deletions
+6
-0
circle/dashboard/templates/dashboard/vm-detail/resources.html
+2
-0
circle/dashboard/views.py
+4
-0
No files found.
circle/dashboard/templates/dashboard/vm-detail/resources.html
View file @
3702c874
...
...
@@ -33,6 +33,7 @@
</div>
</p>
{% if can_change_resources %}
<p
class=
"row"
>
<div
class=
"col-sm-12"
>
<button
type=
"submit"
class=
"btn btn-success btn-sm enabled-when-stopped"
id=
"vm-details-resources-save"
...
...
@@ -42,6 +43,7 @@
</button>
</div>
</p>
{% endif %}
</form>
<hr
/>
...
...
circle/dashboard/views.py
View file @
3702c874
...
...
@@ -287,6 +287,10 @@ class VmDetailView(CheckedDetailView):
# ipv6 infos
context
[
'ipv6_host'
]
=
instance
.
get_connect_host
(
use_ipv6
=
True
)
context
[
'ipv6_port'
]
=
instance
.
get_connect_port
(
use_ipv6
=
True
)
# resources change perm
context
[
'can_change_resources'
]
=
self
.
request
.
user
.
has_perm
(
"vm.change_resources"
)
return
context
def
post
(
self
,
request
,
*
args
,
**
kwargs
):
...
...
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