Link country to organization
This commit is contained in:
parent
d8eeb21b04
commit
f4b2cbfe79
2 changed files with 20 additions and 1 deletions
19
app/migrations/0022_alter_organization_country.py
Normal file
19
app/migrations/0022_alter_organization_country.py
Normal file
|
@ -0,0 +1,19 @@
|
||||||
|
# Generated by Django 3.2.5 on 2021-11-26 06:47
|
||||||
|
|
||||||
|
from django.db import migrations, models
|
||||||
|
import django.db.models.deletion
|
||||||
|
|
||||||
|
|
||||||
|
class Migration(migrations.Migration):
|
||||||
|
|
||||||
|
dependencies = [
|
||||||
|
('app', '0021_alter_range_checked'),
|
||||||
|
]
|
||||||
|
|
||||||
|
operations = [
|
||||||
|
migrations.AlterField(
|
||||||
|
model_name='organization',
|
||||||
|
name='country',
|
||||||
|
field=models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.DO_NOTHING, to='app.country'),
|
||||||
|
),
|
||||||
|
]
|
|
@ -329,7 +329,7 @@ class Organization(models.Model):
|
||||||
url = models.TextField(blank=True, null=True)
|
url = models.TextField(blank=True, null=True)
|
||||||
tel = models.TextField(blank=True, null=True)
|
tel = models.TextField(blank=True, null=True)
|
||||||
email = models.TextField(blank=True, null=True)
|
email = models.TextField(blank=True, null=True)
|
||||||
country = models.TextField(blank=True, null=True)
|
country = models.ForeignKey(Country, models.DO_NOTHING, blank=True, null=True, to_field='id')
|
||||||
tags = models.TextField(blank=True, null=True)
|
tags = models.TextField(blank=True, null=True)
|
||||||
description = models.TextField(blank=True, null=True)
|
description = models.TextField(blank=True, null=True)
|
||||||
northing = models.TextField(blank=True, null=True)
|
northing = models.TextField(blank=True, null=True)
|
||||||
|
|
Loading…
Reference in a new issue