show landingpage even if there are no groups, yet
This commit is contained in:
parent
1ed3f3f4b9
commit
d24e853fcd
1 changed files with 4 additions and 1 deletions
|
|
@ -31,7 +31,10 @@ def landingpage(request):
|
||||||
if 'ldap_admins' in [g.name for g in request.user.groups.all()]:
|
if 'ldap_admins' in [g.name for g in request.user.groups.all()]:
|
||||||
is_admin = True
|
is_admin = True
|
||||||
groups = Group.objects.all()
|
groups = Group.objects.all()
|
||||||
|
try:
|
||||||
admins = Group.objects.get(name="ldap_admins").user_set.all()
|
admins = Group.objects.get(name="ldap_admins").user_set.all()
|
||||||
|
except:
|
||||||
|
admins = []
|
||||||
|
|
||||||
# values = get_user_values(request.user.username, request.session['ldap_password'])
|
# values = get_user_values(request.user.username, request.session['ldap_password'])
|
||||||
#return render_to_response("dashboard.html", locals())
|
#return render_to_response("dashboard.html", locals())
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue