# -*- coding: utf-8 -*-
from __future__ import unicode_literals

from django.db import models, migrations
import django.core.validators


class Migration(migrations.Migration):
    dependencies = [
        ('projects', '__first__'),
        ('referencegases', '__first__'),
        ('bags', '__first__'),
        ('clients', '__first__'),
    ]

    operations = [
        migrations.CreateModel(
            name='Sample',
            fields=[
                ('id', models.AutoField(primary_key=True, serialize=False, auto_created=True, verbose_name='ID')),
                ('is_active', models.BooleanField(default=True, editable=False)),
                ('name', models.CharField(max_length=63, unique=True, verbose_name='name')),
                ('reference', models.CharField(max_length=63, blank=True, verbose_name='reference')),
                ('comments', models.TextField(max_length=1023, blank=True, verbose_name='comments')),
                ('sampled_at', models.DateTimeField(verbose_name='time of sampling')),
                ('factor', models.FloatField(validators=[django.core.validators.MinValueValidator(limit_value=1.0)],
                                             default=1.0)),
                ('contained_in', models.ForeignKey(related_name='sample', to='bags.Bag', unique=True)),
                ('cylinder',
                 models.ForeignKey(related_name='samples', blank=True, null=True, to='referencegases.ReferenceGas')),
                ('project', models.ForeignKey(related_name='samples', blank=True, null=True, to='projects.Project')),
                ('source_sample',
                 models.ForeignKey(to='samples.Sample', blank=True, verbose_name='source sample', null=True)),
                ('supplier',
                 models.ForeignKey(to='clients.ClientOffice', blank=True, verbose_name='supplier', null=True)),
            ],
            options={
                'verbose_name': 'sample',
                'verbose_name_plural': 'samples',
            },
            bases=(models.Model,),
        ),
    ]
