fix some errors in participant
This commit is contained in:
parent
d1ab2f2e85
commit
75443808af
@ -412,7 +412,7 @@ class AssignmentPDF(PDFView):
|
|||||||
|
|
||||||
|
|
||||||
# Add result rows
|
# Add result rows
|
||||||
elected_candidates = assignment.elected.all()
|
elected_candidates = list(assignment.elected)
|
||||||
for candidate, poll_list in vote_results.iteritems():
|
for candidate, poll_list in vote_results.iteritems():
|
||||||
row = []
|
row = []
|
||||||
|
|
||||||
|
@ -77,11 +77,11 @@
|
|||||||
<tr class="{% cycle '' 'odd' %}">
|
<tr class="{% cycle '' 'odd' %}">
|
||||||
<td>{{ user.first_name }}</td>
|
<td>{{ user.first_name }}</td>
|
||||||
<td>{{ user.last_name }}</td>
|
<td>{{ user.last_name }}</td>
|
||||||
<td>{{ user.profile.group }}</td>
|
<td>{{ user.openslidesuser.name_surfix }}</td>
|
||||||
<td>{{ user.profile.get_type_display }}</td>
|
<td>{{ user.openslidesuser.get_type_display }}</td>
|
||||||
<td>{{ user.profile.committee }}</td>
|
<td>{{ user.openslidesuser.committee }}</td>
|
||||||
{% if perms.participant.can_manage_participant %}
|
{% if perms.participant.can_manage_participant %}
|
||||||
<td>{{ user.profile.comment|first_line }}</td>
|
<td>{{ user.openslidesuser.comment|first_line }}</td>
|
||||||
<td>{% if user.last_login > user.date_joined %}
|
<td>{% if user.last_login > user.date_joined %}
|
||||||
{{ user.last_login }}
|
{{ user.last_login }}
|
||||||
{% endif %}</td>
|
{% endif %}</td>
|
||||||
|
@ -83,7 +83,7 @@ def get_overview(request):
|
|||||||
openslidesuser__gender__iexact=sortfilter['gender'][0])
|
openslidesuser__gender__iexact=sortfilter['gender'][0])
|
||||||
if 'group' in sortfilter:
|
if 'group' in sortfilter:
|
||||||
query = query.filter(
|
query = query.filter(
|
||||||
openslidesuser__group__iexact=sortfilter['name_surfix'][0])
|
openslidesuser__name_surfix__iexact=sortfilter['group'][0])
|
||||||
if 'type' in sortfilter:
|
if 'type' in sortfilter:
|
||||||
query = query.filter(
|
query = query.filter(
|
||||||
openslidesuser__type__iexact=sortfilter['type'][0])
|
openslidesuser__type__iexact=sortfilter['type'][0])
|
||||||
@ -315,11 +315,11 @@ def group_edit(request, group_id=None):
|
|||||||
|
|
||||||
group = form.save()
|
group = form.save()
|
||||||
try:
|
try:
|
||||||
django_group = DjangoGroup.objects.get(group=group)
|
openslides_group = OpenSlidesGroup.objects.get(group=group)
|
||||||
except DjangoGroup.DoesNotExist:
|
except OpenSlidesGroup.DoesNotExist:
|
||||||
django_group = None
|
django_group = None
|
||||||
if form.cleaned_data['as_user'] and django_group is None:
|
if form.cleaned_data['as_user'] and django_group is None:
|
||||||
DjangoGroup(group=group).save()
|
OpenSlidesGroup(group=group).save()
|
||||||
elif not form.cleaned_data['as_user'] and django_group:
|
elif not form.cleaned_data['as_user'] and django_group:
|
||||||
django_group.delete()
|
django_group.delete()
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user