# Generated by Django 2.1.7 on 2020-01-07 15:35

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


class Migration(migrations.Migration):

    initial = True

    dependencies = [
        ('inventory', '0026_auto_20200107_0922'),
        ('company', '0019_user_pwd_changed'),
        migrations.swappable_dependency(settings.AUTH_USER_MODEL),
    ]

    operations = [
        migrations.CreateModel(
            name='BugChanel',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('label_code', models.CharField(max_length=20, verbose_name='标签号码')),
                ('tm_delivery', models.DateTimeField(verbose_name='发货时间')),
                ('dt', models.DateField(auto_now_add=True, db_index=True, verbose_name='日期')),
                ('tm', models.DateTimeField(auto_now_add=True, verbose_name='生成时间')),
                ('remark', models.CharField(blank=True, max_length=100, null=True, verbose_name='备注说明')),
                ('ancestor', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='bugchanel_ancestor', to='company.Company', verbose_name='族系')),
                ('batch', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='bugchanel_company_to', to='inventory.Batch', verbose_name='Batch')),
                ('company', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='bugchanel_company', to='company.Company', verbose_name='公司名称')),
                ('company_fr', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='bugchanel_company_fr', to='company.Company', verbose_name='发货公司')),
                ('company_to', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='bugchanel_company_to', to='company.Company', verbose_name='目的公司')),
                ('hierarchy', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='bugchanel_hierarchy', to='company.Company', verbose_name='体系')),
                ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL, verbose_name='操作员')),
            ],
            options={
                'verbose_name': '渠道窜货记录',
                'verbose_name_plural': '渠道窜货记录',
            },
        ),
    ]
