# -*- coding: utf-8 -*-
# Generated by Django 1.10.3 on 2016-11-30 15:55
from __future__ import unicode_literals

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


class Migration(migrations.Migration):

    initial = True

    dependencies = [
    ]

    operations = [
        migrations.CreateModel(
            name='Accion',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('accion', models.TextField(max_length=200)),
            ],
        ),
        migrations.CreateModel(
            name='Area',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('nombre', models.CharField(max_length=30)),
            ],
        ),
        migrations.CreateModel(
            name='Comentario',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('comentario', models.TextField(max_length=200)),
            ],
        ),
        migrations.CreateModel(
            name='Componente',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('nombre', models.CharField(max_length=100)),
            ],
        ),
        migrations.CreateModel(
            name='Equipo',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('nombre', models.CharField(max_length=30)),
                ('informacion', models.TextField(blank=True, max_length=200, null=True)),
                ('imagen', models.ImageField(blank=True, null=True, upload_to='')),
                ('area', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='mantPlanta.Area')),
                ('componente', models.ManyToManyField(blank=True, to='mantPlanta.Componente')),
            ],
        ),
        migrations.CreateModel(
            name='Mantencion',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('causa', models.TextField(max_length=500)),
                ('realizada', models.BooleanField(default=False)),
                ('solicitante', models.CharField(max_length=30)),
                ('correo', models.EmailField(max_length=254)),
                ('equipos', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='mantPlanta.Equipo')),
            ],
        ),
        migrations.CreateModel(
            name='Tipo',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('nombre', models.CharField(max_length=30)),
            ],
        ),
        migrations.AddField(
            model_name='equipo',
            name='tipo',
            field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='mantPlanta.Tipo'),
        ),
        migrations.AddField(
            model_name='comentario',
            name='mantencion',
            field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='mantPlanta.Mantencion'),
        ),
        migrations.AddField(
            model_name='accion',
            name='mantecion',
            field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='mantPlanta.Mantencion'),
        ),
    ]
