Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add two territories to Country dataset. #5787

Merged
merged 1 commit into from
Nov 13, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 24 additions & 0 deletions datahub/metadata/migrations/0088_add_countries.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
# Generated by Django 4.2.10 on 2024-03-19 23:38
from pathlib import PurePath

from django.db import migrations, models

from datahub.core.migration_utils import load_yaml_data_in_migration


def load_countries(apps, _):
load_yaml_data_in_migration(
apps,
PurePath(__file__).parent / '0088_add_countries.yaml'
)


class Migration(migrations.Migration):

dependencies = [
('metadata', '0087_update_services'),
]

operations = [
migrations.RunPython(load_countries, migrations.RunPython.noop),
]
16 changes: 16 additions & 0 deletions datahub/metadata/migrations/0088_add_countries.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
- model: metadata.country
pk: f9a1148c-073a-4832-bfc6-2d96c7212a50
fields:
disabled_on: 2023-02-01T00:00:01Z
name: French Southern Territories
overseas_region: 8d4c4f31-06ce-4320-8e2f-1c13559e125f
is_export_win: True
iso_alpha2_code: TF
- model: metadata.country
pk: 453b18b0-8d9b-4d37-a673-2ee4e2650fd2
fields:
disabled_on: 2018-01-01T00:00:01Z
name: Saint-Martin (French part)
overseas_region: 5616ccf5-ab4a-4c2c-9624-13c69be3c46b
is_export_win: True
iso_alpha2_code: MF