Skip to content

Commit

Permalink
Fix virtualserver readonly access (#2715)
Browse files Browse the repository at this point in the history
* Fix virtualserver readonly access
  • Loading branch information
mkurek authored and szok committed Aug 11, 2016
1 parent 5d7d9e0 commit 06245d4
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions src/ralph/virtual/admin.py
Expand Up @@ -52,8 +52,11 @@ class VirtualServerTypeForm(RalphAdmin):
class VirtualServerForm(RalphAdminForm):
def __init__(self, *args, **kwargs):
super().__init__(*args, **kwargs)
self.fields['parent'].label = _('Hypervisor')
self.fields['parent'].required = True
if 'parent' in self.fields:
self.fields['parent'].required = True

class Meta:
labels = {'parent': _('Hypervisor')}


class VirtualServerNetworkView(NetworkView):
Expand Down

0 comments on commit 06245d4

Please sign in to comment.