Skip to content

Commit

Permalink
🚚 [#4788] Rename several fields on Objects API config model
Browse files Browse the repository at this point in the history
  • Loading branch information
stevenbal committed Dec 2, 2024
1 parent 6de6199 commit 5cb5618
Show file tree
Hide file tree
Showing 6 changed files with 11 additions and 9 deletions.
4 changes: 2 additions & 2 deletions docker/setup_configuration/data.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ objects_api:
identifier: config-1
objects_service_identifier: objecten-test
objecttypes_service_identifier: objecttypen-test
drc_service_identifier: documenten-test
documenten_service_identifier: documenten-test
catalogi_service_identifier: catalogi-test
catalogue_domain: TEST
catalogue_rsin: "000000000"
Expand All @@ -49,7 +49,7 @@ objects_api:
identifier: config-2
objects_service_identifier: objecten-test
objecttypes_service_identifier: objecttypen-test
drc_service_identifier: documenten-test
documenten_service_identifier: documenten-test
catalogi_service_identifier: catalogi-test
catalogue_domain: OTHER
catalogue_rsin: "000000000"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ class SingleObjectsAPIGroupConfigModel(ConfigurationModel):
objecttypes_service_identifier: str = DjangoModelRef(
ObjectsAPIGroupConfig, "objecttypes_service"
)
drc_service_identifier: str = DjangoModelRef(
documenten_service_identifier: str = DjangoModelRef(
ObjectsAPIGroupConfig, "drc_service", default=""
)
catalogi_service_identifier: str = DjangoModelRef(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,10 @@ def execute(self, model: ObjectsAPIGroupConfigModel):
"iot_submission_csv": config.iot_submission_csv,
"iot_attachment": config.iot_attachment,
}
if config.drc_service_identifier:
defaults["drc_service"] = get_service(config.drc_service_identifier)
if config.documenten_service_identifier:
defaults["drc_service"] = get_service(
config.documenten_service_identifier
)
if config.catalogi_service_identifier:
defaults["catalogi_service"] = get_service(
config.catalogi_service_identifier
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ objects_api:
identifier: config-1
objects_service_identifier: objecten-test
objecttypes_service_identifier: objecttypen-test
drc_service_identifier: documenten-test
documenten_service_identifier: documenten-test
catalogi_service_identifier: catalogi-test
catalogue_domain: TEST
catalogue_rsin: "000000000"
Expand All @@ -17,7 +17,7 @@ objects_api:
identifier: config-2
objects_service_identifier: objecten-test
objecttypes_service_identifier: objecttypen-test
drc_service_identifier: documenten-test
documenten_service_identifier: documenten-test
catalogi_service_identifier: catalogi-test
catalogue_domain: OTHER
catalogue_rsin: "000000000"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ objects_api:
identifier: config-1
objects_service_identifier: objecten-test
objecttypes_service_identifier: objecttypen-test
drc_service_identifier: documenten-test
documenten_service_identifier: documenten-test
catalogi_service_identifier: catalogi-test
catalogue_domain: TEST
catalogue_rsin: "000000000"
Expand Down
2 changes: 1 addition & 1 deletion src/openforms/contrib/objects_api/tests/test_migrations.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
from openforms.utils.tests.test_migrations import TestMigrations


class MigrateFeatureFlagsTests(TestMigrations):
class AddObjectsAPIGroupIdentifierTests(TestMigrations):
app = "objects_api"
migrate_from = "0001_initial"
migrate_to = "0002_objectsapigroupconfig_identifier"
Expand Down

0 comments on commit 5cb5618

Please sign in to comment.