forked from ubccr/coldfront
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
root
committed
Dec 12, 2023
1 parent
ca797e8
commit fa83246
Showing
2 changed files
with
182 additions
and
96 deletions.
There are no files selected for viewing
96 changes: 0 additions & 96 deletions
96
coldfront/core/allocation/migrations/0014_auto_20231004_1242.py
This file was deleted.
Oops, something went wrong.
182 changes: 182 additions & 0 deletions
182
coldfront/core/allocation/migrations/0014_auto_20231211_1932.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,182 @@ | ||
# Generated by Django 3.2.17 on 2023-12-12 00:32 | ||
|
||
from django.conf import settings | ||
from django.db import migrations, models | ||
import django.db.models.deletion | ||
import django.utils.timezone | ||
import model_utils.fields | ||
import simple_history.models | ||
|
||
|
||
class Migration(migrations.Migration): | ||
|
||
dependencies = [ | ||
migrations.swappable_dependency(settings.AUTH_USER_MODEL), | ||
('allocation', '0013_allocationaccount'), | ||
] | ||
|
||
operations = [ | ||
migrations.CreateModel( | ||
name='AllocationUserAttributeType', | ||
fields=[ | ||
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), | ||
('created', model_utils.fields.AutoCreatedField(default=django.utils.timezone.now, editable=False, verbose_name='created')), | ||
('modified', model_utils.fields.AutoLastModifiedField(default=django.utils.timezone.now, editable=False, verbose_name='modified')), | ||
('name', models.CharField(max_length=50)), | ||
('is_required', models.BooleanField(default=False)), | ||
('is_unique', models.BooleanField(default=False)), | ||
('is_private', models.BooleanField(default=True)), | ||
('is_changeable', models.BooleanField(default=False)), | ||
('attribute_type', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='allocation.attributetype')), | ||
], | ||
options={ | ||
'ordering': ['name'], | ||
}, | ||
), | ||
migrations.AlterModelOptions( | ||
name='allocation', | ||
options={'ordering': ['project'], 'permissions': (('can_view_all_allocations', 'Can view all allocations'), ('can_review_allocation_requests', 'Can review allocation requests'), ('can_manage_invoice', 'Can manage invoice'))}, | ||
), | ||
migrations.AlterModelOptions( | ||
name='historicalallocation', | ||
options={'get_latest_by': ('history_date', 'history_id'), 'ordering': ('-history_date', '-history_id'), 'verbose_name': 'historical allocation', 'verbose_name_plural': 'historical allocations'}, | ||
), | ||
migrations.AlterModelOptions( | ||
name='historicalallocationattribute', | ||
options={'get_latest_by': ('history_date', 'history_id'), 'ordering': ('-history_date', '-history_id'), 'verbose_name': 'historical allocation attribute', 'verbose_name_plural': 'historical allocation attributes'}, | ||
), | ||
migrations.AlterModelOptions( | ||
name='historicalallocationattributechangerequest', | ||
options={'get_latest_by': ('history_date', 'history_id'), 'ordering': ('-history_date', '-history_id'), 'verbose_name': 'historical allocation attribute change request', 'verbose_name_plural': 'historical allocation attribute change requests'}, | ||
), | ||
migrations.AlterModelOptions( | ||
name='historicalallocationattributetype', | ||
options={'get_latest_by': ('history_date', 'history_id'), 'ordering': ('-history_date', '-history_id'), 'verbose_name': 'historical allocation attribute type', 'verbose_name_plural': 'historical allocation attribute types'}, | ||
), | ||
migrations.AlterModelOptions( | ||
name='historicalallocationattributeusage', | ||
options={'get_latest_by': ('history_date', 'history_id'), 'ordering': ('-history_date', '-history_id'), 'verbose_name': 'historical allocation attribute usage', 'verbose_name_plural': 'historical allocation attribute usages'}, | ||
), | ||
migrations.AlterModelOptions( | ||
name='historicalallocationchangerequest', | ||
options={'get_latest_by': ('history_date', 'history_id'), 'ordering': ('-history_date', '-history_id'), 'verbose_name': 'historical allocation change request', 'verbose_name_plural': 'historical allocation change requests'}, | ||
), | ||
migrations.AlterModelOptions( | ||
name='historicalallocationuser', | ||
options={'get_latest_by': ('history_date', 'history_id'), 'ordering': ('-history_date', '-history_id'), 'verbose_name': 'historical allocation user', 'verbose_name_plural': 'historical Allocation User Status'}, | ||
), | ||
migrations.RemoveField( | ||
model_name='allocationuser', | ||
name='allocation_group_quota', | ||
), | ||
migrations.RemoveField( | ||
model_name='allocationuser', | ||
name='allocation_group_usage_bytes', | ||
), | ||
migrations.RemoveField( | ||
model_name='historicalallocationuser', | ||
name='allocation_group_quota', | ||
), | ||
migrations.RemoveField( | ||
model_name='historicalallocationuser', | ||
name='allocation_group_usage_bytes', | ||
), | ||
migrations.AlterField( | ||
model_name='historicalallocation', | ||
name='history_date', | ||
field=models.DateTimeField(db_index=True), | ||
), | ||
migrations.AlterField( | ||
model_name='historicalallocationattribute', | ||
name='history_date', | ||
field=models.DateTimeField(db_index=True), | ||
), | ||
migrations.AlterField( | ||
model_name='historicalallocationattributechangerequest', | ||
name='history_date', | ||
field=models.DateTimeField(db_index=True), | ||
), | ||
migrations.AlterField( | ||
model_name='historicalallocationattributetype', | ||
name='history_date', | ||
field=models.DateTimeField(db_index=True), | ||
), | ||
migrations.AlterField( | ||
model_name='historicalallocationattributeusage', | ||
name='history_date', | ||
field=models.DateTimeField(db_index=True), | ||
), | ||
migrations.AlterField( | ||
model_name='historicalallocationchangerequest', | ||
name='history_date', | ||
field=models.DateTimeField(db_index=True), | ||
), | ||
migrations.AlterField( | ||
model_name='historicalallocationuser', | ||
name='history_date', | ||
field=models.DateTimeField(db_index=True), | ||
), | ||
migrations.CreateModel( | ||
name='HistoricalAllocationUserAttributeType', | ||
fields=[ | ||
('id', models.IntegerField(auto_created=True, blank=True, db_index=True, verbose_name='ID')), | ||
('created', model_utils.fields.AutoCreatedField(default=django.utils.timezone.now, editable=False, verbose_name='created')), | ||
('modified', model_utils.fields.AutoLastModifiedField(default=django.utils.timezone.now, editable=False, verbose_name='modified')), | ||
('name', models.CharField(max_length=50)), | ||
('is_required', models.BooleanField(default=False)), | ||
('is_unique', models.BooleanField(default=False)), | ||
('is_private', models.BooleanField(default=True)), | ||
('is_changeable', models.BooleanField(default=False)), | ||
('history_id', models.AutoField(primary_key=True, serialize=False)), | ||
('history_date', models.DateTimeField(db_index=True)), | ||
('history_change_reason', models.CharField(max_length=100, null=True)), | ||
('history_type', models.CharField(choices=[('+', 'Created'), ('~', 'Changed'), ('-', 'Deleted')], max_length=1)), | ||
('attribute_type', models.ForeignKey(blank=True, db_constraint=False, null=True, on_delete=django.db.models.deletion.DO_NOTHING, related_name='+', to='allocation.attributetype')), | ||
('history_user', models.ForeignKey(null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='+', to=settings.AUTH_USER_MODEL)), | ||
], | ||
options={ | ||
'verbose_name': 'historical allocation user attribute type', | ||
'verbose_name_plural': 'historical allocation user attribute types', | ||
'ordering': ('-history_date', '-history_id'), | ||
'get_latest_by': ('history_date', 'history_id'), | ||
}, | ||
bases=(simple_history.models.HistoricalChanges, models.Model), | ||
), | ||
migrations.CreateModel( | ||
name='HistoricalAllocationUserAttribute', | ||
fields=[ | ||
('id', models.IntegerField(auto_created=True, blank=True, db_index=True, verbose_name='ID')), | ||
('created', model_utils.fields.AutoCreatedField(default=django.utils.timezone.now, editable=False, verbose_name='created')), | ||
('modified', model_utils.fields.AutoLastModifiedField(default=django.utils.timezone.now, editable=False, verbose_name='modified')), | ||
('value', models.CharField(max_length=128)), | ||
('history_id', models.AutoField(primary_key=True, serialize=False)), | ||
('history_date', models.DateTimeField(db_index=True)), | ||
('history_change_reason', models.CharField(max_length=100, null=True)), | ||
('history_type', models.CharField(choices=[('+', 'Created'), ('~', 'Changed'), ('-', 'Deleted')], max_length=1)), | ||
('allocationuser', models.ForeignKey(blank=True, db_constraint=False, null=True, on_delete=django.db.models.deletion.DO_NOTHING, related_name='+', to='allocation.allocationuser')), | ||
('allocationuser_attribute_type', models.ForeignKey(blank=True, db_constraint=False, null=True, on_delete=django.db.models.deletion.DO_NOTHING, related_name='+', to='allocation.allocationuserattributetype')), | ||
('history_user', models.ForeignKey(null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='+', to=settings.AUTH_USER_MODEL)), | ||
], | ||
options={ | ||
'verbose_name': 'historical allocation user attribute', | ||
'verbose_name_plural': 'historical allocation user attributes', | ||
'ordering': ('-history_date', '-history_id'), | ||
'get_latest_by': ('history_date', 'history_id'), | ||
}, | ||
bases=(simple_history.models.HistoricalChanges, models.Model), | ||
), | ||
migrations.CreateModel( | ||
name='AllocationUserAttribute', | ||
fields=[ | ||
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), | ||
('created', model_utils.fields.AutoCreatedField(default=django.utils.timezone.now, editable=False, verbose_name='created')), | ||
('modified', model_utils.fields.AutoLastModifiedField(default=django.utils.timezone.now, editable=False, verbose_name='modified')), | ||
('value', models.CharField(max_length=128)), | ||
('allocationuser', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='allocation.allocationuser')), | ||
('allocationuser_attribute_type', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='allocation.allocationuserattributetype')), | ||
], | ||
options={ | ||
'abstract': False, | ||
}, | ||
), | ||
] |