# Generated by Django 3.0.4 on 2020-03-19 04:29

from django.conf import settings
from django.db import migrations, models
import django.db.models.deletion
import unimatrix.lib.timezone


class Migration(migrations.Migration):

    dependencies = [
        ('iam', '0019_auto_20200319_0356'),
    ]

    operations = [
        migrations.CreateModel(
            name='AcceptedPlatformAgreement',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('host', models.GenericIPAddressField(db_column='host')),
                ('timestamp', models.BigIntegerField(db_column='timestamp', default=unimatrix.lib.timezone.now)),
                ('checksum', models.CharField(db_column='checksum', editable=False, max_length=128, unique=True)),
                ('agreement', models.ForeignKey(db_column='agreement_checksum', on_delete=django.db.models.deletion.PROTECT, to='iam.PlatformAgreementLanguage', to_field='checksum')),
                ('subject', models.ForeignKey(db_column='subject_id', on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)),
            ],
            options={
                'verbose_name': 'Accepted Platform Agreement',
                'verbose_name_plural': 'Accepted Platform Agreements',
                'db_table': 'acceptedplatformagreements',
                'default_permissions': [],
                'unique_together': {('agreement', 'subject')},
            },
        ),
    ]
