# -*- coding: utf-8 -*-
# Generated by Django 1.9.9 on 2016-09-21 02:37
from __future__ import unicode_literals

import django.contrib.postgres.fields.jsonb
from django.db import migrations, models
import django.db.models.deletion
from django.contrib.postgres.operations import HStoreExtension

class Migration(migrations.Migration):

    initial = True

    dependencies = [
        ('questions', '0003_question_values'),
    ]

    operations = [
	HStoreExtension(),
        migrations.CreateModel(
            name='Demography',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('code', models.CharField(max_length=128, unique=True)),
                ('text', models.CharField(default='', max_length=512)),
                ('vs', django.contrib.postgres.fields.jsonb.JSONField(default={})),
            ],
        ),
        migrations.CreateModel(
            name='Response',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('year', models.IntegerField(default=0)),
                ('value', models.IntegerField(default=-1)),
                ('demographics', models.ManyToManyField(to='responses.Demography')),
                ('question', models.ForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, to='questions.Question')),
            ],
        ),
    ]
