# -*- coding: utf-8 -*-
# Generated by Django 1.9.12 on 2017-07-07 17:33
from __future__ import unicode_literals

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


class Migration(migrations.Migration):

    initial = True

    dependencies = [
        ('payment', '0016_auto_20170707_1333'),
    ]

    operations = [
        migrations.CreateModel(
            name='WebPayTransaction',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('token', models.CharField(max_length=255, verbose_name='Token')),
                ('buy_order', models.CharField(max_length=26, verbose_name='Buy order number')),
                ('commerce_code', models.CharField(max_length=12, verbose_name='Commerce code')),
                ('installments_amount', models.FloatField(verbose_name='Installments amount')),
                ('currency', models.CharField(max_length=3, verbose_name='Currency')),
                ('auth_code', models.CharField(max_length=6, null=True, verbose_name='Authorization code')),
                ('card_number', models.CharField(max_length=4, null=True, verbose_name='Card number')),
                ('error_auth_code', models.IntegerField(choices=[(b'TSY', 'Successful transaction'), (b'TSN', 'Failed transaction'), (b'TO', 'Time limit exceeded'), (b'ABO', 'Transaction aborted by card holder'), (b'U3', 'Authentication internal error')], null=True, verbose_name='Error code')),
                ('transaction_type', models.CharField(choices=[(b'VD', 'Debit sale'), (b'VN', 'Normal sale'), (b'VC', 'Quota sale'), (b'SI', '3 non-interest installments'), (b'S2', '2 non-interest installments'), (b'NC', 'N non-interes installments')], max_length=255, null=True, verbose_name='Transaction type')),
                ('base_transaction', models.OneToOneField(on_delete=django.db.models.deletion.CASCADE, related_name='webpay_transaction_data', to='payment.Transaction')),
            ],
        ),
    ]
