datatracker/ietf/meeting/migrations/0053_attended.py
Robert Sparks 07bfa68a75
feat: explicitly model session attendance (#4025)
* feat: add model to track session attendance

* feat: add model to track session attendance

* feat: add api to set session attendees

* fix: use user pk instead off person pk in the attended api.

* feat: calculate three of five from attended

* feat: management utility to populate Attended model history

* docs: document why nomcom calculations don't use Attended yet.

* fix: add migration to add new personalapikey endpoint to choices

* test: verify very old last login prevents api key use,

* chore: address review nits

* chore: comment on some idiosyncracies of the expected input to populate_attended

* fix: add unique_together constraint for the Attended model

* fix: correctly handle empty querysets passed to three_of_five_eligible functions.
2022-06-20 10:46:36 -05:00

29 lines
961 B
Python

# Copyright The IETF Trust 2022, All Rights Reserved
# Generated by Django 2.2.28 on 2022-06-17 08:40
from django.db import migrations, models
import django.db.models.deletion
import ietf.utils.models
class Migration(migrations.Migration):
dependencies = [
('person', '0023_auto_20220615_1006'),
('meeting', '0052_auto_20220503_1815'),
]
operations = [
migrations.CreateModel(
name='Attended',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('person', ietf.utils.models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='person.Person')),
('session', ietf.utils.models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='meeting.Session')),
],
options={
'unique_together': {('person', 'session')},
},
),
]