# -*- coding: utf-8 -*-
# Generated by Django 1.11 on 2017-05-21 15:38
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='Backup',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('title', models.CharField(blank=True, help_text='Just a title', max_length=128, verbose_name='Title')),
                ('file_name', models.CharField(help_text='Date and time will be added to the file name automagically. Example: backup.zip', max_length=64, verbose_name='File name')),
                ('output_directory', models.CharField(help_text='Where to store files localy? Example: /home/user/backups/', max_length=256, verbose_name='Output directory')),
                ('upload', models.BooleanField(default=False, verbose_name='Upload to Yandex.Disk')),
                ('delete_after_upload', models.BooleanField(default=False, verbose_name='Delete after upload')),
                ('mysqldump', models.BooleanField(default=False, help_text="Create a backup of the projects's database", verbose_name='MySQL dump')),
                ('pub_date', models.DateTimeField(auto_now_add=True, verbose_name='Published')),
                ('description', models.TextField(blank=True, verbose_name='Description')),
            ],
            options={
                'verbose_name_plural': 'Backups',
                'verbose_name': 'Backup',
            },
        ),
        migrations.CreateModel(
            name='Path',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('path', models.CharField(help_text='Absolute path to file or folder', max_length=256, verbose_name='Path')),
                ('backup', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='paths', to='YaBackup.Backup')),
            ],
            options={
                'verbose_name_plural': 'Files and folders',
                'verbose_name': 'file or folder',
            },
        ),
    ]
