# Generated by Django 3.2.12 on 2022-11-12 11:43

from django.db import migrations, models
import django.db.models.deletion


class Migration(migrations.Migration):

    initial = True

    dependencies = [
        ('users', '0001_initial'),
    ]

    operations = [
        migrations.CreateModel(
            name='Plan',
            fields=[
                ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=250)),
                ('type', models.CharField(max_length=250)),
                ('price', models.DecimalField(decimal_places=2, default=75, max_digits=12, verbose_name='Price')),
            ],
        ),
        migrations.CreateModel(
            name='Subscription',
            fields=[
                ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('status', models.IntegerField()),
                ('duration', models.DateField()),
                ('start_date', models.DateField()),
                ('end_date', models.DateField()),
                ('reference', models.TextField(help_text='Free text field for user references', max_length=100)),
                ('last_updated', models.DateTimeField(auto_now=True, help_text='Keeps track of when a record was last updated')),
                ('reason', models.TextField(help_text='Reason for state change, if applicable.')),
            ],
        ),
        migrations.CreateModel(
            name='UserSubcriptions',
            fields=[
                ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('subscriptions', models.ManyToManyField(to='subscriptions.Subscription')),
                ('user', models.OneToOneField(on_delete=django.db.models.deletion.CASCADE, to='users.customer')),
            ],
        ),
    ]
