# Generated by Django 4.0 on 2022-09-21 11:30

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


class Migration(migrations.Migration):

    initial = True

    dependencies = [
        ('auth', '0012_alter_user_first_name_max_length'),
        ('employee', '0003_employee_is_new'),
    ]

    operations = [
        migrations.CreateModel(
            name='Leave',
            fields=[
                ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('date', models.DateField(blank=True, null=True)),
                ('start_date', models.DateField(blank=True, null=True)),
                ('end_date', models.DateField(blank=True, null=True)),
                ('days', models.IntegerField(blank=True, null=True, verbose_name='Loron')),
                ('is_active', models.BooleanField(default=True)),
                ('is_lock', models.BooleanField(default=False, null=True)),
                ('is_send', models.BooleanField(default=False, null=True)),
                ('dep_confirm', models.BooleanField(default=False, null=True)),
                ('dep_send', models.BooleanField(default=False, null=True)),
                ('unit_confirm', models.BooleanField(default=False, null=True)),
                ('unit_send', models.BooleanField(default=False, null=True)),
                ('de_confirm', models.BooleanField(default=False, null=True)),
                ('datetime', models.DateTimeField(null=True)),
                ('hashed', models.CharField(max_length=32, null=True)),
                ('employee', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='leave', to='employee.employee')),
            ],
        ),
        migrations.CreateModel(
            name='LeaveType',
            fields=[
                ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(blank=True, max_length=20, null=True, verbose_name='Naran')),
            ],
        ),
        migrations.CreateModel(
            name='TaskDelegate',
            fields=[
                ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('date', models.DateField(blank=True, null=True)),
                ('obs', models.CharField(blank=True, choices=[('Sim', 'Sim'), ('Lae', 'Lae')], max_length=3, null=True, verbose_name='Observasaun')),
                ('reason', models.TextField(blank=True, null=True, verbose_name='Rajaun')),
                ('is_send', models.BooleanField(default=False, null=True)),
                ('is_approve', models.BooleanField(default=False, null=True)),
                ('datetime', models.DateTimeField(null=True)),
                ('hashed', models.CharField(max_length=32, null=True)),
                ('employee', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='leavedelegate', to='employee.employee', verbose_name='Delega ba')),
                ('leave', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='leavedelegate', to='leave.leave')),
                ('user', models.ForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, to='auth.user')),
            ],
        ),
        migrations.CreateModel(
            name='LeaveCount',
            fields=[
                ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('total', models.IntegerField(blank=True, null=True)),
                ('balance', models.IntegerField(blank=True, null=True, verbose_name='Balansu')),
                ('datetime', models.DateTimeField(null=True)),
                ('hashed', models.CharField(max_length=32, null=True)),
                ('employee', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='leavecount', to='employee.employee')),
                ('leave_type', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='leavecount', to='leave.leavetype', verbose_name='Tipu Licenca')),
                ('user', models.ForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, to='auth.user')),
            ],
        ),
        migrations.AddField(
            model_name='leave',
            name='leave_type',
            field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='leave', to='leave.leavetype', verbose_name='Tipu Licensa'),
        ),
        migrations.AddField(
            model_name='leave',
            name='user',
            field=models.ForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, to='auth.user'),
        ),
    ]
