# Generated by Django 3.2.13 on 2024-12-28 09:26

from django.conf import settings
from django.db import migrations, models
import django.db.models.deletion
import uuid


class Migration(migrations.Migration):

    dependencies = [
        migrations.swappable_dependency(settings.AUTH_USER_MODEL),
        ('auth', '0012_alter_user_first_name_max_length'),
        ('authentication', '0054_auto_20241228_0926'),
        ('ticket', '0023_auto_20241228_0919'),
    ]

    operations = [
        migrations.CreateModel(
            name='TicketSupport',
            fields=[
                ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('key', models.UUIDField(default=uuid.uuid4, editable=False, unique=True)),
                ('create_date', models.DateTimeField(auto_now_add=True)),
                ('modify_date', models.DateTimeField(auto_now=True)),
                ('trash', models.BooleanField(default=False)),
                ('title', models.CharField(max_length=100, null=True)),
                ('ticket_id', models.IntegerField(null=True, unique=True)),
                ('status', models.CharField(default='open', max_length=100)),
                ('last_message', models.CharField(max_length=100, null=True)),
                ('type_ticket', models.CharField(default='single', max_length=100)),
                ('read_only', models.BooleanField(default=True)),
                ('role', models.CharField(max_length=100, null=True)),
                ('created_by', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='ticketsupport_createdby', to=settings.AUTH_USER_MODEL)),
                ('modified_by', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='ticketsupport_modifiedby', to=settings.AUTH_USER_MODEL)),
                ('parent', models.ForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, to='ticket.ticketsupport')),
                ('to_role', models.ManyToManyField(related_name='to_role_ticket', to='auth.Group')),
                ('to_user', models.ManyToManyField(related_name='to_user_ticket', to='authentication.SystemUserProfile')),
                ('user', models.ForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, related_name='ticket_support', to='authentication.systemuserprofile')),
            ],
            options={
                'abstract': False,
            },
        ),
    ]
