# -*- coding: utf-8 -*-
# Generated by Django 1.9.6 on 2016-05-23 08:32
from __future__ import unicode_literals

import colorfield.fields
from django.db import migrations, models
import django.db.models.deletion
import django.db.models.manager
import mptt.fields


class Migration(migrations.Migration):

    dependencies = [
        ('article', '0013_auto_20160523_0308'),
    ]

    operations = [
        migrations.CreateModel(
            name='Tag',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(blank=True, max_length=50, null=True)),
                ('color', colorfield.fields.ColorField(default='#FF0000', help_text='Please choose a color from <a href="https://flatuicolors.com/" target="_blank">FLAT UI Color</a>', max_length=10)),
                ('lft', models.PositiveIntegerField(db_index=True, editable=False)),
                ('rght', models.PositiveIntegerField(db_index=True, editable=False)),
                ('tree_id', models.PositiveIntegerField(db_index=True, editable=False)),
                ('level', models.PositiveIntegerField(db_index=True, editable=False)),
                ('parent', mptt.fields.TreeForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='children', to='article.Tag')),
            ],
            options={
                'verbose_name': 'Tag',
                'verbose_name_plural': 'Tags',
            },
            managers=[
                ('_default_manager', django.db.models.manager.Manager()),
            ],
        ),
        migrations.RemoveField(
            model_name='shortcut',
            name='articles',
        ),
        migrations.RemoveField(
            model_name='shortcut',
            name='parent',
        ),
        migrations.RemoveField(
            model_name='article',
            name='categories',
        ),
        migrations.RemoveField(
            model_name='category',
            name='color',
        ),
        migrations.AddField(
            model_name='category',
            name='activated',
            field=models.BooleanField(default=True),
        ),
        migrations.AddField(
            model_name='category',
            name='articles',
            field=models.ManyToManyField(blank=True, help_text='Tags that describe this article.', to='article.Article'),
        ),
        migrations.AddField(
            model_name='category',
            name='click_counter',
            field=models.IntegerField(default=0),
        ),
        migrations.AddField(
            model_name='category',
            name='icon',
            field=models.CharField(blank=True, default='', help_text='Add an icon to your category ! <a href="https://design.google.com/icons/">Click Here !</a>', max_length=500, null=True),
        ),
        migrations.AlterField(
            model_name='category',
            name='name',
            field=models.CharField(max_length=300, null=True, unique=True),
        ),
        migrations.DeleteModel(
            name='Shortcut',
        ),
        migrations.AddField(
            model_name='article',
            name='tags',
            field=models.ManyToManyField(blank=True, help_text='Tags that describe this article.', to='article.Tag'),
        ),
    ]
