OpenSlides/server/openslides/users/migrations/0015_user_vote_delegated_to.py
Joshua Sangmeister 3ac8569712
Add vote delegation on server side
Add user_has_voted_for_delegations. Add tests

Prevent self delegation

Make delegated_user visible
2020-09-30 14:05:22 +02:00

28 lines
695 B
Python

# Generated by Django 2.2.16 on 2020-09-03 11:13
from django.conf import settings
from django.db import migrations, models
import openslides.utils.models
class Migration(migrations.Migration):
dependencies = [
("users", "0014_user_rename_permission"),
]
operations = [
migrations.AddField(
model_name="user",
name="vote_delegated_to",
field=models.ForeignKey(
blank=True,
null=True,
on_delete=openslides.utils.models.SET_NULL_AND_AUTOUPDATE,
related_name="vote_delegated_from_users",
to=settings.AUTH_USER_MODEL,
),
),
]