Skip to content

Commit

Permalink
Fixed migrations
Browse files Browse the repository at this point in the history
  • Loading branch information
paulmwatson committed Dec 11, 2024
1 parent 6cc99dd commit 2ba1973
Show file tree
Hide file tree
Showing 2 changed files with 28 additions and 1 deletion.
27 changes: 27 additions & 0 deletions pombola/core/migrations/0017_auto_20241211_1411.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
# -*- coding: utf-8 -*-
# Generated by Django 1.11.29 on 2024-12-11 14:11
from __future__ import unicode_literals

from django.db import migrations, models
import django.db.models.deletion
import sorl.thumbnail.fields


class Migration(migrations.Migration):

dependencies = [
('contenttypes', '0002_remove_content_type_name'),
('core', '0016_auto_20201119_0713'),
]

operations = [
migrations.AlterModelOptions(
name='organisationhistory',
options={'ordering': ['date_changed'], 'verbose_name_plural': 'organisation histories'},
),
migrations.AlterField(
model_name='organisationhistory',
name='new_organisation',
field=models.ForeignKey(default=0, on_delete=django.db.models.deletion.CASCADE, related_name='org_history_new', to='core.Organisation'),
)
]
2 changes: 1 addition & 1 deletion pombola/core/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -1972,7 +1972,7 @@ def raw_query_with_prefetch(query_model, query, params, fields_prefetches):

class OrganisationHistory(ModelBase):
old_organisation = models.ForeignKey('Organisation', null=False, related_name='org_history_old')
new_organisation = models.ForeignKey('Organisation', null=False, related_name='org_history_new')
new_organisation = models.ForeignKey('Organisation', null=False, related_name='org_history_new', default=0)
date_changed = DateField(null=False)

class Meta:
Expand Down

0 comments on commit 2ba1973

Please sign in to comment.