<reponame>gargrave/snippets-server<gh_stars>10-100
# -*- coding: utf-8 -*-
# Generated by Django 1.9.2 on 2017-01-31 18:31
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):

    dependencies = [
        migrations.swappable_dependency(settings.AUTH_USER_MODEL),
        ('api_snippets_v1', '0007_auto_20170126_2200'),
    ]

    operations = [
        migrations.CreateModel(
            name='Tag',
            fields=[
                ('basemodel_ptr', models.OneToOneField(auto_created=True, on_delete=django.db.models.deletion.CASCADE, parent_link=True, primary_key=True, serialize=False, to='api_snippets_v1.BaseModel')),
                ('title', models.CharField(max_length=100)),
                ('owner', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)),
            ],
            bases=('api_snippets_v1.basemodel',),
        ),
        migrations.CreateModel(
            name='TagSnippetRelation',
            fields=[
                ('basemodel_ptr', models.OneToOneField(auto_created=True, on_delete=django.db.models.deletion.CASCADE, parent_link=True, primary_key=True, serialize=False, to='api_snippets_v1.BaseModel')),
                ('_snippet', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='tags', to='api_snippets_v1.Snippet')),
                ('_tag', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='api_snippets_v1.Tag')),
                ('owner', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)),
            ],
            bases=('api_snippets_v1.basemodel',),
        ),
        migrations.AlterUniqueTogether(
            name='tag',
            unique_together=set([('owner', 'title')]),
        ),
    ]

# -*- coding: utf-8 -*-
# Generated by Django 1.9.2 on 2017-01-31 18:31
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):

    dependencies = [
        migrations.swappable_dependency(settings.AUTH_USER_MODEL),
        ('api_snippets_v1', '0007_auto_20170126_2200'),
    ]

    operations = [
        migrations.CreateModel(
            name='Tag',
            fields=[
                ('basemodel_ptr', models.OneToOneField(auto_created=True, on_delete=django.db.models.deletion.CASCADE, parent_link=True, primary_key=True, serialize=False, to='api_snippets_v1.BaseModel')),
                ('title', models.CharField(max_length=100)),
                ('owner', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)),
            ],
            bases=('api_snippets_v1.basemodel',),
        ),
        migrations.CreateModel(
            name='TagSnippetRelation',
            fields=[
                ('basemodel_ptr', models.OneToOneField(auto_created=True, on_delete=django.db.models.deletion.CASCADE, parent_link=True, primary_key=True, serialize=False, to='api_snippets_v1.BaseModel')),
                ('_snippet', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='tags', to='api_snippets_v1.Snippet')),
                ('_tag', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='api_snippets_v1.Tag')),
                ('owner', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)),
            ],
            bases=('api_snippets_v1.basemodel',),
        ),
        migrations.AlterUniqueTogether(
            name='tag',
            unique_together=set([('owner', 'title')]),
        ),
    ]
# -*- coding: utf-8 -*- # Generated by Django 1.9.2 on 2017-01-31 18:31