# Generated by Django 2.2.10 on 2020-08-12 16:50

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


class Migration(migrations.Migration):

    initial = True

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

    operations = [    
        migrations.CreateModel(
            name='MomoTransaction',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('amount', models.DecimalField(decimal_places=4, max_digits=10)),
                ('network', models.IntegerField(choices=[(0, 'MTN'), (1, 'VODAFONE'), (2, 'AIRTELTIGO'), (3, 'GLO'), (4, 'EXPRESSO'), (5, 'UNKNOWN')])),
                ('msisdn', models.CharField(max_length=20)),
                ('merchant_id', models.CharField(max_length=20)),
                ('merchant_name', models.CharField(max_length=100)),
                ('status', models.IntegerField(choices=[(1, 'ACTIVE'), (2, 'PENDING'), (3, 'DELETED'), (4, 'COMPLETED'), (5, 'FAILED'), (6, 'PROCESSING'), (7, 'DISAPPROVED'), (8, 'PAYMENTPENDING')], default=enum.StatusTypes(2))),
                ('info_sent', models.TextField()),
                ('initial_callback', models.CharField(max_length=255, null=True)),
                ('final_callback', models.CharField(max_length=255, null=True)),
                ('time_created', models.DateTimeField(auto_now_add=True)),
                ('time_updated', models.DateTimeField(auto_now=True)),
                ('order_id', models.CharField(max_length=50, unique=True)),
                ('ext_id', models.CharField(max_length=50, null=True)),
                ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)),
            ],
        ),
    ]
