# -*- coding: utf-8 -*-
# Generated by Django 1.9.6 on 2016-07-12 12:39
from __future__ import unicode_literals

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


class Migration(migrations.Migration):

    initial = True

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

    operations = [
        migrations.CreateModel(
            name='CustomItem',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('barcode', models.CharField(max_length=20, unique=True, verbose_name='\u56fd\u9645\u6761\u7801')),
                ('name', models.CharField(db_index=True, max_length=255, verbose_name='\u5546\u54c1\u540d')),
                ('model', models.CharField(blank=True, max_length=100, null=True, verbose_name='\u89c4\u683c')),
                ('flavor', models.CharField(blank=True, max_length=100, null=True, verbose_name='\u53e3\u5473')),
                ('series', models.CharField(blank=True, max_length=100, null=True, verbose_name='\u7cfb\u5217')),
                ('category', models.CharField(blank=True, max_length=100, null=True, verbose_name='\u5206\u7c7b')),
                ('last_updated', models.DateTimeField(auto_now=True, verbose_name='\u6700\u540e\u66f4\u65b0\u65f6\u95f4')),
                ('created_at', models.DateTimeField(auto_now_add=True, verbose_name='\u751f\u6210\u65e5\u671f')),
            ],
            options={
                'verbose_name': '\u54c1\u724c\u81ea\u5b9a\u8bae\u5546\u54c1',
                'verbose_name_plural': '\u54c1\u724c\u81ea\u5b9a\u8bae\u5546\u54c1',
            },
        ),
        migrations.CreateModel(
            name='MonitorBarcodes',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('start_date', models.DateTimeField(blank=True, null=True, verbose_name='\u5f00\u59cb\u65e5\u671f')),
                ('end_date', models.DateTimeField(blank=True, null=True, verbose_name='\u7d50\u675f\u65e5\u671f')),
                ('last_updated', models.DateTimeField(auto_now=True, verbose_name='\u6700\u540e\u66f4\u65b0\u65f6\u95f4')),
                ('created_at', models.DateTimeField(auto_now_add=True, verbose_name='\u751f\u6210\u65e5\u671f')),
                ('barcodes', models.ManyToManyField(related_name='monitors', to='monitor.CustomItem', verbose_name='\u5b9a\u8bae\u5546\u54c1')),
                ('user', models.ForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, related_name='monitor_barcodes', to=settings.AUTH_USER_MODEL, verbose_name='\u7528\u6236')),
            ],
            options={
                'verbose_name': '\u54c1\u724c\u76d1\u6d4b\u7ba1\u7406',
                'verbose_name_plural': '\u54c1\u724c\u76d1\u6d4b\u7ba1\u7406',
            },
        ),
    ]
