# Generated by Django 2.2.27 on 2022-04-20 15:27

from django.conf import settings
from django.db import migrations, models


def default_accomm():
    options = list(settings.PRICES['accomm'].items())
    options.sort(key=lambda kv:
            kv[1].get('price', not kv[1].get('bursary', False)))
    if options:
        return options[0][0]
    return ''


class Migration(migrations.Migration):

    dependencies = [
        ('register', '0014_attendee_confirm_covid_tests'),
    ]

    operations = [
        migrations.AddField(
            model_name='accomm',
            name='option',
            field=models.CharField(default=default_accomm(), max_length=32),
        ),
    ]
