# Generated by Django 2.2.13 on 2021-08-27 09:41

from django.conf import settings
from django.db import migrations, models
import django.db.models.deletion
import django.utils.timezone
import ra.base.models


class Migration(migrations.Migration):

    dependencies = [
        ('crm', '0003_remove_customer_user'),
        ('hr', '0001_initial'),
        migrations.swappable_dependency(settings.AUTH_USER_MODEL),
        ('forex', '0002_auto_20210805_0750'),
    ]

    operations = [
        migrations.CreateModel(
            name='ExpenseTransaction',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('slug', models.SlugField(blank=True, verbose_name='refer code')),
                ('doc_date', models.DateTimeField(db_index=True, verbose_name='date')),
                ('doc_type', models.CharField(db_index=True, max_length=30)),
                ('notes', models.TextField(blank=True, null=True, verbose_name='notes')),
                ('value', models.DecimalField(decimal_places=2, default=0, max_digits=19, verbose_name='value')),
                ('creation_date', models.DateTimeField(default=django.utils.timezone.now, verbose_name='creation date and time')),
                ('lastmod', models.DateTimeField(db_index=True, verbose_name='last modification')),
                ('status', models.CharField(blank=True, choices=[('unpaid', 'unpaid'), ('partial', 'partial'), ('completed', 'completed')], max_length=32)),
                ('percent_per_month', models.DecimalField(decimal_places=2, max_digits=5)),
                ('amount_left', models.IntegerField(default=0)),
                ('account_type', models.CharField(max_length=32)),
                ('account_number', models.CharField(max_length=32)),
                ('user_id', models.CharField(max_length=32)),
                ('customer', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='Forex_transaction_employee', to='crm.Customer')),
                ('employee', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='Forex_transaction_employee', to='hr.Employee')),
                ('lastmod_user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='forex_expensetransaction_lastmod_related', to=settings.AUTH_USER_MODEL, verbose_name='last modification by')),
                ('owner', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='forex_expensetransaction_related', to=settings.AUTH_USER_MODEL, verbose_name='owner')),
                ('sponsor', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='Forex_transaction_sponsor', to='crm.Customer')),
            ],
            options={
                'verbose_name': 'Forex Transaction',
                'verbose_name_plural': 'Forex Transactions',
            },
            bases=(ra.base.models.DiffingMixin, models.Model),
        ),
        migrations.RemoveField(
            model_name='saleproducts',
            name='lastmod_user',
        ),
        migrations.RemoveField(
            model_name='saleproducts',
            name='owner',
        ),
        migrations.RemoveField(
            model_name='saleproducts',
            name='sale',
        ),
        migrations.DeleteModel(
            name='Sale',
        ),
        migrations.DeleteModel(
            name='SaleProducts',
        ),
    ]
