<gh_stars>0
# -*- coding: utf-8 -*-
# Generated by Django 1.11.7 on 2017-12-23 16:19
from __future__ import unicode_literals

from django.conf import settings
from django.contrib.auth import get_user_model
from django.db import migrations, models
import django.db.models.deletion

def migration_code(apps, schema_editor):
    User = get_user_model()
    user = User.objects.create_user(id=1, username="test", email="<EMAIL>", password="")
    user.is_active = False

class Migration(migrations.Migration):

    dependencies = [
        migrations.swappable_dependency(settings.AUTH_USER_MODEL),
        ('mediane', '0014_auto_20171223_1619'),
    ]

    operations = [
        migrations.CreateModel(
            name='Job',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('creation', models.DateTimeField(help_text='Creation time')),
                ('bench', models.BooleanField(default=False, verbose_name='bench')),
                ('dist', models.ForeignKey(help_text='The distance used for this job', on_delete=django.db.models.deletion.CASCADE, to='mediane.Distance')),
                ('norm', models.ForeignKey(help_text='The distance used for this job', on_delete=django.db.models.deletion.CASCADE, to='mediane.Normalization')),
                ('owner', models.ForeignKey(help_text='User who created this job', on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)),
            ],
        ),
        migrations.CreateModel(
            name='Result',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('distance_value', models.FloatField(blank=True, null=True)),
                ('results', models.TextField(blank=True, help_text="the consensus(es) computed for the givent dataset and job's distance", null=True)),
                ('algo', models.ForeignKey(help_text='The distance used for this job', on_delete=django.db.models.deletion.CASCADE, to='mediane.Algorithm')),
                ('dataset', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='mediane.DataSet')),
                ('job', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='mediane.Job')),
            ],
        ),
        migrations.RunPython(migration_code, reverse_code=migrations.RunPython.noop),
    ]

# -*- coding: utf-8 -*-
# Generated by Django 1.11.7 on 2017-12-23 16:19
from __future__ import unicode_literals

from django.conf import settings
from django.contrib.auth import get_user_model
from django.db import migrations, models
import django.db.models.deletion

def migration_code(apps, schema_editor):
    User = get_user_model()
    user = User.objects.create_user(id=1, username="test", email="<EMAIL>", password="")
    user.is_active = False

class Migration(migrations.Migration):

    dependencies = [
        migrations.swappable_dependency(settings.AUTH_USER_MODEL),
        ('mediane', '0014_auto_20171223_1619'),
    ]

    operations = [
        migrations.CreateModel(
            name='Job',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('creation', models.DateTimeField(help_text='Creation time')),
                ('bench', models.BooleanField(default=False, verbose_name='bench')),
                ('dist', models.ForeignKey(help_text='The distance used for this job', on_delete=django.db.models.deletion.CASCADE, to='mediane.Distance')),
                ('norm', models.ForeignKey(help_text='The distance used for this job', on_delete=django.db.models.deletion.CASCADE, to='mediane.Normalization')),
                ('owner', models.ForeignKey(help_text='User who created this job', on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)),
            ],
        ),
        migrations.CreateModel(
            name='Result',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('distance_value', models.FloatField(blank=True, null=True)),
                ('results', models.TextField(blank=True, help_text="the consensus(es) computed for the givent dataset and job's distance", null=True)),
                ('algo', models.ForeignKey(help_text='The distance used for this job', on_delete=django.db.models.deletion.CASCADE, to='mediane.Algorithm')),
                ('dataset', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='mediane.DataSet')),
                ('job', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='mediane.Job')),
            ],
        ),
        migrations.RunPython(migration_code, reverse_code=migrations.RunPython.noop),
    ]
# -*- coding: utf-8 -*- # Generated by Django 1.11.7 on 2017-12-23 16:19