|
| 1 | +# Generated by Django 4.2.29 on 2026-04-10 11:39 |
| 2 | + |
| 3 | +from django.db import migrations, models |
| 4 | +import django.db.models.deletion |
| 5 | + |
| 6 | + |
| 7 | +class Migration(migrations.Migration): |
| 8 | + |
| 9 | + dependencies = [ |
| 10 | + ('deployments', '0093_sector_title_ar_sector_title_en_sector_title_es_and_more'), |
| 11 | + ] |
| 12 | + |
| 13 | + operations = [ |
| 14 | + migrations.CreateModel( |
| 15 | + name='MolnixAppraisal', |
| 16 | + fields=[ |
| 17 | + ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), |
| 18 | + ('molnix_id', models.BigIntegerField(unique=True)), |
| 19 | + ('target_id', models.BigIntegerField()), |
| 20 | + ('deployment_molnix_id', models.BigIntegerField(blank=True, null=True)), |
| 21 | + ('stage', models.CharField(blank=True, max_length=64, null=True)), |
| 22 | + ('appraisers_count', models.IntegerField(blank=True, null=True)), |
| 23 | + ('score', models.DecimalField(blank=True, decimal_places=3, max_digits=7, null=True)), |
| 24 | + ('deployment_country_id', models.IntegerField(blank=True, null=True)), |
| 25 | + ('deployment_start', models.DateTimeField(blank=True, null=True)), |
| 26 | + ('deployment_end', models.DateTimeField(blank=True, null=True)), |
| 27 | + ('deployment_title', models.CharField(blank=True, max_length=255, null=True)), |
| 28 | + ('sending_organization_id', models.BigIntegerField(blank=True, null=True)), |
| 29 | + ('receiving_organization_id', models.BigIntegerField(blank=True, null=True)), |
| 30 | + ('deployment_tags_json', models.JSONField(blank=True, null=True)), |
| 31 | + ('competencies_json', models.JSONField(blank=True, null=True)), |
| 32 | + ('created_at', models.DateTimeField(blank=True, null=True)), |
| 33 | + ('updated_at', models.DateTimeField(blank=True, null=True)), |
| 34 | + ], |
| 35 | + options={ |
| 36 | + 'verbose_name': 'Molnix Appraisal', |
| 37 | + 'verbose_name_plural': 'Molnix Appraisals', |
| 38 | + }, |
| 39 | + ), |
| 40 | + migrations.CreateModel( |
| 41 | + name='MolnixAppraiser', |
| 42 | + fields=[ |
| 43 | + ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), |
| 44 | + ('molnix_id', models.BigIntegerField(unique=True)), |
| 45 | + ('appraisal_molnix_id', models.BigIntegerField()), |
| 46 | + ('appraiser_type', models.CharField(blank=True, max_length=32, null=True)), |
| 47 | + ('person_id', models.BigIntegerField(blank=True, null=True)), |
| 48 | + ('required', models.BooleanField(blank=True, null=True)), |
| 49 | + ('notified_at', models.DateTimeField(blank=True, null=True)), |
| 50 | + ('completed_at', models.DateTimeField(blank=True, null=True)), |
| 51 | + ('created_at', models.DateTimeField(blank=True, null=True)), |
| 52 | + ('updated_at', models.DateTimeField(blank=True, null=True)), |
| 53 | + ], |
| 54 | + options={ |
| 55 | + 'verbose_name': 'Molnix Appraiser', |
| 56 | + 'verbose_name_plural': 'Molnix Appraisers', |
| 57 | + }, |
| 58 | + ), |
| 59 | + migrations.CreateModel( |
| 60 | + name='RrmsPersonSnapshot', |
| 61 | + fields=[ |
| 62 | + ('person_id', models.BigIntegerField(primary_key=True, serialize=False)), |
| 63 | + ('person_status', models.CharField(blank=True, max_length=32, null=True)), |
| 64 | + ('sex', models.CharField(blank=True, max_length=32, null=True)), |
| 65 | + ('current_availability', models.CharField(blank=True, max_length=64, null=True)), |
| 66 | + ('outofscope', models.BooleanField(blank=True, null=True)), |
| 67 | + ('organization_id', models.BigIntegerField(blank=True, null=True)), |
| 68 | + ('organization_name', models.CharField(blank=True, max_length=255, null=True)), |
| 69 | + ('roles_json', models.JSONField(blank=True, null=True)), |
| 70 | + ('languages_json', models.JSONField(blank=True, null=True)), |
| 71 | + ('tags_json', models.JSONField(blank=True, null=True)), |
| 72 | + ('source_updated_at', models.DateTimeField(blank=True, null=True)), |
| 73 | + ('personnel', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='rrms_person_snapshots', to='deployments.personnel')), |
| 74 | + ], |
| 75 | + options={ |
| 76 | + 'verbose_name': 'RRMS Person Snapshot', |
| 77 | + 'verbose_name_plural': 'RRMS Person Snapshots', |
| 78 | + 'db_table': 'rrms_person_snapshot', |
| 79 | + }, |
| 80 | + ), |
| 81 | + migrations.CreateModel( |
| 82 | + name='RrmsEventParticipation', |
| 83 | + fields=[ |
| 84 | + ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), |
| 85 | + ('event_id', models.BigIntegerField()), |
| 86 | + ('event_name', models.CharField(blank=True, max_length=255, null=True)), |
| 87 | + ('person_id', models.BigIntegerField()), |
| 88 | + ('event_person_role', models.CharField(blank=True, max_length=128, null=True)), |
| 89 | + ('event_type', models.CharField(blank=True, max_length=128, null=True)), |
| 90 | + ('event_scale_type', models.CharField(blank=True, max_length=128, null=True)), |
| 91 | + ('event_from', models.DateTimeField(blank=True, null=True)), |
| 92 | + ('event_to', models.DateTimeField(blank=True, null=True)), |
| 93 | + ('participant_start', models.DateTimeField(blank=True, null=True)), |
| 94 | + ('participant_end', models.DateTimeField(blank=True, null=True)), |
| 95 | + ('requested', models.BooleanField(blank=True, null=True)), |
| 96 | + ('event_organization_id', models.BigIntegerField(blank=True, null=True)), |
| 97 | + ('event_organization_name', models.CharField(blank=True, max_length=255, null=True)), |
| 98 | + ('venue', models.CharField(blank=True, max_length=255, null=True)), |
| 99 | + ('tags_json', models.JSONField(blank=True, null=True)), |
| 100 | + ], |
| 101 | + options={ |
| 102 | + 'verbose_name': 'RRMS Event Participation', |
| 103 | + 'verbose_name_plural': 'RRMS Event Participation', |
| 104 | + 'db_table': 'rrms_event_participation', |
| 105 | + 'indexes': [models.Index(fields=['event_id'], name='rrms_event_id_idx'), models.Index(fields=['person_id'], name='rrms_event_person_idx')], |
| 106 | + }, |
| 107 | + ), |
| 108 | + migrations.AddConstraint( |
| 109 | + model_name='rrmseventparticipation', |
| 110 | + constraint=models.UniqueConstraint(fields=('event_id', 'person_id', 'event_person_role'), name='rrms_event_person_role_uniq'), |
| 111 | + ), |
| 112 | + migrations.AddField( |
| 113 | + model_name='molnixappraiser', |
| 114 | + name='appraisal', |
| 115 | + field=models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='appraisers', to='deployments.molnixappraisal'), |
| 116 | + ), |
| 117 | + migrations.AddField( |
| 118 | + model_name='molnixappraiser', |
| 119 | + name='personnel', |
| 120 | + field=models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='molnix_appraisers', to='deployments.personnel'), |
| 121 | + ), |
| 122 | + migrations.AddField( |
| 123 | + model_name='molnixappraisal', |
| 124 | + name='personnel', |
| 125 | + field=models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='molnix_appraisals', to='deployments.personnel'), |
| 126 | + ), |
| 127 | + migrations.AddIndex( |
| 128 | + model_name='rrmspersonsnapshot', |
| 129 | + index=models.Index(fields=['organization_id'], name='rrms_person_org_idx'), |
| 130 | + ), |
| 131 | + migrations.AddIndex( |
| 132 | + model_name='rrmspersonsnapshot', |
| 133 | + index=models.Index(fields=['personnel'], name='rrms_personnel_idx'), |
| 134 | + ), |
| 135 | + migrations.AddIndex( |
| 136 | + model_name='molnixappraiser', |
| 137 | + index=models.Index(fields=['appraisal_molnix_id'], name='molnix_appr_mol_idx'), |
| 138 | + ), |
| 139 | + migrations.AddIndex( |
| 140 | + model_name='molnixappraiser', |
| 141 | + index=models.Index(fields=['appraisal'], name='molnix_appr_idx'), |
| 142 | + ), |
| 143 | + migrations.AddIndex( |
| 144 | + model_name='molnixappraiser', |
| 145 | + index=models.Index(fields=['person_id'], name='molnix_appr_person_idx'), |
| 146 | + ), |
| 147 | + migrations.AddIndex( |
| 148 | + model_name='molnixappraiser', |
| 149 | + index=models.Index(fields=['personnel'], name='molnix_appr_personnel_idx'), |
| 150 | + ), |
| 151 | + migrations.AddIndex( |
| 152 | + model_name='molnixappraisal', |
| 153 | + index=models.Index(fields=['target_id'], name='molnix_app_target_idx'), |
| 154 | + ), |
| 155 | + migrations.AddIndex( |
| 156 | + model_name='molnixappraisal', |
| 157 | + index=models.Index(fields=['personnel'], name='molnix_app_personnel_idx'), |
| 158 | + ), |
| 159 | + migrations.AddIndex( |
| 160 | + model_name='molnixappraisal', |
| 161 | + index=models.Index(fields=['updated_at'], name='molnix_app_updated_idx'), |
| 162 | + ), |
| 163 | + ] |
0 commit comments