0b5f75339e
* Fixed agenda permissions * Renamed assignment to assignments, fixed assignments permission names * Renamed mediafile to mediafiles * Renamed motion to motions. Fixed motions permission names
18 lines
600 B
Python
18 lines
600 B
Python
from django.utils.translation import ugettext_lazy
|
|
|
|
from openslides.utils.personal_info import PersonalInfo
|
|
|
|
from .models import Assignment, AssignmentRelatedUser
|
|
|
|
|
|
class AssignmentPersonalInfo(PersonalInfo):
|
|
"""
|
|
Class for personal info block for the assignment app.
|
|
"""
|
|
headline = ugettext_lazy('I am candidate for the following elections')
|
|
default_weight = 40
|
|
|
|
def get_queryset(self):
|
|
return (Assignment.objects.filter(assignment_related_users__user=self.request.user)
|
|
.exclude(assignment_related_users__status=AssignmentRelatedUser.STATUS_BLOCKED))
|