# Generated by Django 2.1.3 on 2018-12-13 08:34

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


class Migration(migrations.Migration):

    initial = True

    dependencies = [
    ]

    operations = [
        migrations.CreateModel(
            name='Order',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('created', models.DateTimeField(auto_now_add=True)),
                ('updated', models.DateTimeField(auto_now=True)),
                ('paid', models.BooleanField(default=False)),
                ('rated', models.BooleanField(default=False)),
                ('payment_type', models.CharField(choices=[('1', 'COD'), ('2', 'ONLINE'), ('3', 'SUBSCRIPTION')], default='1', max_length=1)),
                ('order_status', models.CharField(choices=[('0', 'FAILED'), ('X', 'CANCELLED'), ('W', 'CANCEL REQUESTED'), ('1', 'PLACED'), ('2', 'CONFIRMED'), ('3', 'OUT FOR DELIVERY'), ('4', 'DELIVERED'), ('P', 'PROCESSING')], default='1', max_length=1)),
                ('preferred_time', models.CharField(blank=True, max_length=20)),
            ],
            options={
                'ordering': ('-created',),
            },
        ),
        migrations.CreateModel(
            name='OrderItem',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('price', models.DecimalField(decimal_places=2, max_digits=10)),
                ('quantity', models.PositiveIntegerField(default=1)),
            ],
        ),
        migrations.CreateModel(
            name='PartyOrders',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('number_of_cans', models.IntegerField(validators=[django.core.validators.MinValueValidator(30), django.core.validators.MaxValueValidator(300)])),
                ('comments', models.TextField(blank=True)),
                ('created', models.DateTimeField(auto_now_add=True)),
            ],
        ),
        migrations.CreateModel(
            name='Subscription',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('subscription', models.CharField(max_length=30)),
                ('number_of_cans', models.IntegerField(blank=True)),
                ('subscribed', models.DateTimeField(auto_now_add=True)),
            ],
        ),
        migrations.CreateModel(
            name='Subscriptions',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=30, unique=True)),
                ('description', models.TextField()),
                ('price', models.DecimalField(decimal_places=2, max_digits=10)),
                ('number_of_cans', models.IntegerField()),
            ],
        ),
        migrations.CreateModel(
            name='Tracking',
            fields=[
                ('order', models.OneToOneField(on_delete=django.db.models.deletion.CASCADE, primary_key=True, serialize=False, to='orders.Order')),
                ('enabled', models.BooleanField(default=False)),
                ('longitude', models.CharField(blank=True, max_length=20)),
                ('latitude', models.CharField(blank=True, max_length=20)),
            ],
        ),
    ]
