<reponame>terrameijar/bluebottle<gh_stars>1-10
# -*- coding: utf-8 -*-
# Generated by Django 1.10.8 on 2017-10-17 18:15
from __future__ import unicode_literals

import adminsortable.fields
from django.db import migrations, models
import django.db.models.deletion


class Migration(migrations.Migration):

    dependencies = [
        ('utils', '0002_maillog'),
        ('cms', '0020_add_group_permissions'),
    ]

    operations = [
        migrations.CreateModel(
            name='Link',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('highlight', models.BooleanField(default=False)),
                ('title', models.CharField(max_length=100, verbose_name='Title')),
                ('component', models.CharField(blank=True, choices=[(b'page', 'Page'), (b'project', 'Project'), (b'task', 'Task'), (b'fundraiser', 'Fundraiser'), (b'results', 'Results'), (b'news', 'News')], max_length=50, verbose_name='Component')),
                ('component_id', models.CharField(blank=True, max_length=100, verbose_name='Component ID')),
                ('external_link', models.CharField(blank=True, max_length=2000, verbose_name='External Link')),
                ('link_order', models.PositiveIntegerField(db_index=True, default=0, editable=False)),
            ],
            options={
                'ordering': ['link_order'],
            },
        ),
        migrations.CreateModel(
            name='LinkGroup',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(choices=[(b'main', 'Main'), (b'about', 'About'), (b'info', 'Info'), (b'discover', 'Discover'), (b'social', 'Social')], default=b'main', max_length=25, unique=True)),
                ('title', models.CharField(blank=True, max_length=50, verbose_name='Title')),
            ],
        ),
        migrations.CreateModel(
            name='LinkPermission',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('permission', models.CharField(help_text='A dot separated app name and permission codename.', max_length=255)),
                ('present', models.BooleanField(default=True, help_text='Should the permission be present or not to access the link?')),
            ],
        ),
        migrations.CreateModel(
            name='SiteLinks',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('has_copyright', models.BooleanField(default=True)),
                ('language', models.OneToOneField(on_delete=django.db.models.deletion.CASCADE, to='utils.Language')),
            ],
            options={
                'verbose_name_plural': 'Site links',
            },
        ),
        migrations.AddField(
            model_name='linkgroup',
            name='site_links',
            field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='link_groups', to='cms.SiteLinks'),
        ),
        migrations.AddField(
            model_name='link',
            name='link_group',
            field=adminsortable.fields.SortableForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='links', to='cms.LinkGroup'),
        ),
        migrations.AddField(
            model_name='link',
            name='link_permissions',
            field=models.ManyToManyField(blank=True, to='cms.LinkPermission'),
        ),
    ]

# -*- coding: utf-8 -*-
# Generated by Django 1.10.8 on 2017-10-17 18:15
from __future__ import unicode_literals

import adminsortable.fields
from django.db import migrations, models
import django.db.models.deletion


class Migration(migrations.Migration):

    dependencies = [
        ('utils', '0002_maillog'),
        ('cms', '0020_add_group_permissions'),
    ]

    operations = [
        migrations.CreateModel(
            name='Link',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('highlight', models.BooleanField(default=False)),
                ('title', models.CharField(max_length=100, verbose_name='Title')),
                ('component', models.CharField(blank=True, choices=[(b'page', 'Page'), (b'project', 'Project'), (b'task', 'Task'), (b'fundraiser', 'Fundraiser'), (b'results', 'Results'), (b'news', 'News')], max_length=50, verbose_name='Component')),
                ('component_id', models.CharField(blank=True, max_length=100, verbose_name='Component ID')),
                ('external_link', models.CharField(blank=True, max_length=2000, verbose_name='External Link')),
                ('link_order', models.PositiveIntegerField(db_index=True, default=0, editable=False)),
            ],
            options={
                'ordering': ['link_order'],
            },
        ),
        migrations.CreateModel(
            name='LinkGroup',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(choices=[(b'main', 'Main'), (b'about', 'About'), (b'info', 'Info'), (b'discover', 'Discover'), (b'social', 'Social')], default=b'main', max_length=25, unique=True)),
                ('title', models.CharField(blank=True, max_length=50, verbose_name='Title')),
            ],
        ),
        migrations.CreateModel(
            name='LinkPermission',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('permission', models.CharField(help_text='A dot separated app name and permission codename.', max_length=255)),
                ('present', models.BooleanField(default=True, help_text='Should the permission be present or not to access the link?')),
            ],
        ),
        migrations.CreateModel(
            name='SiteLinks',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('has_copyright', models.BooleanField(default=True)),
                ('language', models.OneToOneField(on_delete=django.db.models.deletion.CASCADE, to='utils.Language')),
            ],
            options={
                'verbose_name_plural': 'Site links',
            },
        ),
        migrations.AddField(
            model_name='linkgroup',
            name='site_links',
            field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='link_groups', to='cms.SiteLinks'),
        ),
        migrations.AddField(
            model_name='link',
            name='link_group',
            field=adminsortable.fields.SortableForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='links', to='cms.LinkGroup'),
        ),
        migrations.AddField(
            model_name='link',
            name='link_permissions',
            field=models.ManyToManyField(blank=True, to='cms.LinkPermission'),
        ),
    ]
# -*- coding: utf-8 -*- # Generated by Django 1.10.8 on 2017-10-17 18:15