# -*- coding: utf-8 -*-
# Generated by Django 1.11 on 2018-04-02 01:17
from __future__ import unicode_literals

from django.conf import settings
from django.db import migrations, models
import django.db.models.deletion
import django_extensions.db.fields


class Migration(migrations.Migration):

    initial = True

    dependencies = [
        migrations.swappable_dependency(settings.AUTH_USER_MODEL),
    ]

    operations = [
        migrations.CreateModel(
            name='Payment',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('price', models.PositiveIntegerField()),
                ('token', models.CharField(blank=True, max_length=500, null=True, unique=True)),
                ('slug', django_extensions.db.fields.RandomCharField(blank=True, editable=False, length=8, unique=True)),
                ('trace_number', django_extensions.db.fields.RandomCharField(blank=True, editable=False, include_alpha=False, length=8, unique=True)),
                ('state', models.CharField(choices=[('created', 'Created'), ('opened', 'Opened'), ('bank', 'Sent to bank'), ('successful', 'Successful payment'), ('unsuccessful', 'Unsuccessful payment')], default='created', max_length=30)),
                ('payment_result', models.CharField(blank=True, max_length=256, null=True)),
                ('verification_result', models.CharField(blank=True, max_length=256, null=True)),
                ('created_at', models.DateTimeField(auto_now_add=True)),
                ('updated_at', models.DateTimeField(auto_now=True)),
                ('gateway', models.CharField(max_length=256, null=True)),
                ('description', models.CharField(max_length=1024, null=True)),
                ('login_required', models.BooleanField(default=False)),
                ('ref_number', models.CharField(max_length=200, null=True, unique=True)),
                ('callable_module', models.CharField(max_length=300, null=True)),
                ('callable_name', models.CharField(max_length=100, null=True)),
                ('return_url', models.CharField(max_length=1024, null=True)),
                ('user', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)),
            ],
        ),
    ]
