8
0
Fork 0
mirror of https://gitlab2.federez.net/re2o/re2o synced 2024-11-22 03:13:12 +00:00

Shell -> ListShell

This commit is contained in:
Gabriel Detraz 2018-03-28 20:46:17 +02:00 committed by chirac
parent 746eef0f74
commit 12cf400e2a
3 changed files with 8 additions and 8 deletions

View file

@ -65,7 +65,7 @@ HISTORY_BIND = {
'school' : users.models.School,
'listright' : users.models.ListRight,
'serviceuser' : users.models.ServiceUser,
'shell' : users.models.ListShell,
'listshell' : users.models.ListShell,
},
'preferences' : {
'service' : preferences.models.Service,
@ -81,8 +81,8 @@ HISTORY_BIND = {
'port' : topologie.models.Port,
'room' : topologie.models.Room,
'stack' : topologie.models.Stack,
'model_switch' : topologie.models.ModelSwitch,
'constructor_switch' : topologie.models.ConstructorSwitch,
'modelswitch' : topologie.models.ModelSwitch,
'constructorswitch' : topologie.models.ConstructorSwitch,
'accesspoint' : topologie.models.AccessPoint,
},
'machines' : {

View file

@ -82,12 +82,12 @@ urlpatterns = [
url(r'^del_listright/$', views.del_listright, name='del-listright'),
url(r'^add_shell/$', views.add_shell, name='add-shell'),
url(
r'^edit_shell/(?P<shellid>[0-9]+)$',
r'^edit_shell/(?P<listshellid>[0-9]+)$',
views.edit_shell,
name='edit-shell'
),
url(
r'^del_shell/(?P<shellid>[0-9]+)$',
r'^del_shell/(?P<listshellid>[0-9]+)$',
views.del_shell,
name='del-shell'
),

View file

@ -515,8 +515,8 @@ def add_shell(request):
@login_required
@can_edit(ListShell)
def edit_shell(request, shell_instance, shellid):
""" Editer un shell à partir du shellid"""
def edit_shell(request, shell_instance, listshellid):
""" Editer un shell à partir du listshellid"""
shell = ShellForm(request.POST or None, instance=shell_instance)
if shell.is_valid():
with transaction.atomic(), reversion.create_revision():
@ -532,7 +532,7 @@ def edit_shell(request, shell_instance, shellid):
@login_required
@can_delete(ListShell)
def del_shell(request, shell, shellid):
def del_shell(request, shell, listshellid):
"""Destruction d'un shell"""
if request.method == "POST":
with transaction.atomic(), reversion.create_revision():