# Generated by Django 5.2.6 on 2025-10-01 21:41 import django.db.models.deletion from django.db import migrations, models class Migration(migrations.Migration): initial = True dependencies = [ ('jobs', '0001_initial'), ] operations = [ migrations.CreateModel( name='ApplicantForm', fields=[ ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(help_text="Form version name (e.g., 'Version A', 'Version B' etc)", max_length=200)), ('description', models.TextField(blank=True, help_text='Optional description of this form version')), ('is_active', models.BooleanField(default=False, help_text='Only one form can be active per job')), ('created_at', models.DateTimeField(auto_now_add=True)), ('updated_at', models.DateTimeField(auto_now=True)), ('job_posting', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='applicant_forms', to='jobs.jobposting')), ], options={ 'verbose_name': 'Application Form', 'verbose_name_plural': 'Application Forms', 'ordering': ['-created_at'], 'unique_together': {('job_posting', 'name')}, }, ), migrations.CreateModel( name='ApplicantSubmission', fields=[ ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('submitted_at', models.DateTimeField(auto_now_add=True)), ('data', models.JSONField()), ('ip_address', models.GenericIPAddressField(blank=True, null=True)), ('score', models.FloatField(default=0, help_text='Ranking score for the applicant submission')), ('form', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='applicant.applicantform')), ('job_posting', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='jobs.jobposting')), ], options={ 'verbose_name': 'Applicant Submission', 'verbose_name_plural': 'Applicant Submissions', 'ordering': ['-submitted_at'], }, ), migrations.CreateModel( name='FormField', fields=[ ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('label', models.CharField(max_length=255)), ('field_type', models.CharField(choices=[('text', 'Text'), ('email', 'Email'), ('phone', 'Phone'), ('number', 'Number'), ('date', 'Date'), ('select', 'Dropdown'), ('radio', 'Radio Buttons'), ('checkbox', 'Checkbox'), ('textarea', 'Paragraph Text'), ('file', 'File Upload'), ('image', 'Image Upload')], max_length=20)), ('required', models.BooleanField(default=True)), ('help_text', models.TextField(blank=True)), ('choices', models.TextField(blank=True, help_text='Comma-separated options for select/radio fields')), ('order', models.IntegerField(default=0)), ('field_name', models.CharField(blank=True, max_length=100)), ('form', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='fields', to='applicant.applicantform')), ], options={ 'verbose_name': 'Form Field', 'verbose_name_plural': 'Form Fields', 'ordering': ['order'], }, ), ]