diff --git a/src/openforms/registrations/contrib/objects_api/submission_registration.py b/src/openforms/registrations/contrib/objects_api/submission_registration.py index 144461bd17..ddff734795 100644 --- a/src/openforms/registrations/contrib/objects_api/submission_registration.py +++ b/src/openforms/registrations/contrib/objects_api/submission_registration.py @@ -63,7 +63,8 @@ def _point_coordinate(value: Any) -> dict[str, Any] | object: if not isinstance(value, list) or len(value) != 2: return SKIP - return {"type": "Point", "coordinates": [value[0], value[1]]} + # Providing the coordinates as [lng, lat] #4955 + return {"type": "Point", "coordinates": [value[1], value[0]]} def _resolve_documenttype( diff --git a/src/openforms/registrations/contrib/objects_api/tests/files/vcr_cassettes/ObjectsAPIBackendV1Tests/ObjectsAPIBackendV1Tests.test_submission_with_objects_api_backend_override_defaults.yaml b/src/openforms/registrations/contrib/objects_api/tests/files/vcr_cassettes/ObjectsAPIBackendV1Tests/ObjectsAPIBackendV1Tests.test_submission_with_objects_api_backend_override_defaults.yaml index 1c8c84e6fc..5259a493c2 100644 --- a/src/openforms/registrations/contrib/objects_api/tests/files/vcr_cassettes/ObjectsAPIBackendV1Tests/ObjectsAPIBackendV1Tests.test_submission_with_objects_api_backend_override_defaults.yaml +++ b/src/openforms/registrations/contrib/objects_api/tests/files/vcr_cassettes/ObjectsAPIBackendV1Tests/ObjectsAPIBackendV1Tests.test_submission_with_objects_api_backend_override_defaults.yaml @@ -1,7 +1,7 @@ interactions: - request: body: '{"informatieobjecttype": "http://localhost:8003/catalogi/api/v1/informatieobjecttypen/f2908f6f-aa07-42ef-8760-74c5234f2d25", - "bronorganisatie": "123456782", "creatiedatum": "2024-09-16", "titel": "Form + "bronorganisatie": "123456782", "creatiedatum": "2024-12-19", "titel": "Form 018", "auteur": "Aanvrager", "taal": "eng", "formaat": "application/pdf", "inhoud": "", "status": "definitief", "bestandsnaam": "open-forms-Form 018.pdf", "ontvangstdatum": null, "beschrijving": "Ingezonden formulier", "indicatieGebruiksrecht": false, @@ -12,7 +12,7 @@ interactions: Accept-Encoding: - gzip, deflate, br Authorization: - - Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJ0ZXN0X2NsaWVudF9pZCIsImlhdCI6MTcyNjQ5NjM2MSwiY2xpZW50X2lkIjoidGVzdF9jbGllbnRfaWQiLCJ1c2VyX2lkIjoiIiwidXNlcl9yZXByZXNlbnRhdGlvbiI6IiJ9.0gG7t1lHg95HuBzN2WTSWrXolOHfVg9PGwtNUGW-uBw + - Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJ0ZXN0X2NsaWVudF9pZCIsImlhdCI6MTczNDYxMDUyNSwiY2xpZW50X2lkIjoidGVzdF9jbGllbnRfaWQiLCJ1c2VyX2lkIjoiIiwidXNlcl9yZXByZXNlbnRhdGlvbiI6IiJ9.LY-_15pdojkK5SuQH1J1Jax_Tg_eH5hMQ6WMzqlGWQM Connection: - keep-alive Content-Length: @@ -25,9 +25,9 @@ interactions: uri: http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten response: body: - string: '{"url":"http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/e9059611-9abf-4c21-ad11-86b6a9dcbe1e","identificatie":"DOCUMENT-2024-0000000067","bronorganisatie":"123456782","creatiedatum":"2024-09-16","titel":"Form - 018","vertrouwelijkheidaanduiding":"openbaar","auteur":"Aanvrager","status":"definitief","formaat":"application/pdf","taal":"eng","versie":1,"beginRegistratie":"2024-09-16T14:19:21.842296Z","bestandsnaam":"open-forms-Form - 018.pdf","inhoud":"http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/e9059611-9abf-4c21-ad11-86b6a9dcbe1e/download?versie=1","bestandsomvang":0,"link":"","beschrijving":"Ingezonden + string: '{"url":"http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/f98002c7-c166-4114-9b01-897b9ab15e12","identificatie":"DOCUMENT-2024-0000000087","bronorganisatie":"123456782","creatiedatum":"2024-12-19","titel":"Form + 018","vertrouwelijkheidaanduiding":"openbaar","auteur":"Aanvrager","status":"definitief","formaat":"application/pdf","taal":"eng","versie":1,"beginRegistratie":"2024-12-19T12:15:25.876397Z","bestandsnaam":"open-forms-Form + 018.pdf","inhoud":"http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/f98002c7-c166-4114-9b01-897b9ab15e12/download?versie=1","bestandsomvang":0,"link":"","beschrijving":"Ingezonden formulier","ontvangstdatum":null,"verzenddatum":null,"indicatieGebruiksrecht":false,"verschijningsvorm":"","ondertekening":{"soort":"","datum":null},"integriteit":{"algoritme":"","waarde":"","datum":null},"informatieobjecttype":"http://localhost:8003/catalogi/api/v1/informatieobjecttypen/f2908f6f-aa07-42ef-8760-74c5234f2d25","locked":false,"bestandsdelen":[],"trefwoorden":[],"lock":""}' headers: API-version: @@ -41,7 +41,7 @@ interactions: Cross-Origin-Opener-Policy: - same-origin Location: - - http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/e9059611-9abf-4c21-ad11-86b6a9dcbe1e + - http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/f98002c7-c166-4114-9b01-897b9ab15e12 Referrer-Policy: - same-origin Vary: @@ -55,7 +55,7 @@ interactions: message: Created - request: body: '{"informatieobjecttype": "http://localhost:8003/catalogi/api/v1/informatieobjecttypen/d1cfb1d8-8593-4814-919d-72e38e80388f", - "bronorganisatie": "123456782", "creatiedatum": "2024-09-16", "titel": "Form + "bronorganisatie": "123456782", "creatiedatum": "2024-12-19", "titel": "Form 018 (csv)", "auteur": "Aanvrager", "taal": "eng", "formaat": "text/csv", "inhoud": "Rm9ybXVsaWVybmFhbSxJbnplbmRpbmdkYXR1bSxUYWFsY29kZSx2b29ybmFhbSxhY2h0ZXJuYWFtLHR1c3NlbnZvZWdzZWwsZ2Vib29ydGVkYXR1bSxjb29yZGluYWF0DQpGb3JtIDAxOCwsZW4sRm9vLEJhcixkZSwyMDAwLTEyLTMxLCJbNTIuMzY2NzMzNzg5NjcxMjIsIDQuODkzMTY0Mjc0NDcwMjk5XSINCg==", "status": "definitief", "bestandsnaam": "open-forms-Form 018 (csv).csv", "ontvangstdatum": @@ -67,7 +67,7 @@ interactions: Accept-Encoding: - gzip, deflate, br Authorization: - - Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJ0ZXN0X2NsaWVudF9pZCIsImlhdCI6MTcyNjQ5NjM2MSwiY2xpZW50X2lkIjoidGVzdF9jbGllbnRfaWQiLCJ1c2VyX2lkIjoiIiwidXNlcl9yZXByZXNlbnRhdGlvbiI6IiJ9.0gG7t1lHg95HuBzN2WTSWrXolOHfVg9PGwtNUGW-uBw + - Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJ0ZXN0X2NsaWVudF9pZCIsImlhdCI6MTczNDYxMDUyNSwiY2xpZW50X2lkIjoidGVzdF9jbGllbnRfaWQiLCJ1c2VyX2lkIjoiIiwidXNlcl9yZXByZXNlbnRhdGlvbiI6IiJ9.LY-_15pdojkK5SuQH1J1Jax_Tg_eH5hMQ6WMzqlGWQM Connection: - keep-alive Content-Length: @@ -80,9 +80,9 @@ interactions: uri: http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten response: body: - string: '{"url":"http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/2f72e9d2-a208-4921-b6e2-fd694c84e889","identificatie":"DOCUMENT-2024-0000000068","bronorganisatie":"123456782","creatiedatum":"2024-09-16","titel":"Form - 018 (csv)","vertrouwelijkheidaanduiding":"openbaar","auteur":"Aanvrager","status":"definitief","formaat":"text/csv","taal":"eng","versie":1,"beginRegistratie":"2024-09-16T14:19:21.976830Z","bestandsnaam":"open-forms-Form - 018 (csv).csv","inhoud":"http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/2f72e9d2-a208-4921-b6e2-fd694c84e889/download?versie=1","bestandsomvang":175,"link":"","beschrijving":"Ingezonden + string: '{"url":"http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/3b63cf06-20fc-4e94-912e-961a85a465e9","identificatie":"DOCUMENT-2024-0000000088","bronorganisatie":"123456782","creatiedatum":"2024-12-19","titel":"Form + 018 (csv)","vertrouwelijkheidaanduiding":"openbaar","auteur":"Aanvrager","status":"definitief","formaat":"text/csv","taal":"eng","versie":1,"beginRegistratie":"2024-12-19T12:15:25.986595Z","bestandsnaam":"open-forms-Form + 018 (csv).csv","inhoud":"http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/3b63cf06-20fc-4e94-912e-961a85a465e9/download?versie=1","bestandsomvang":175,"link":"","beschrijving":"Ingezonden formulierdata","ontvangstdatum":null,"verzenddatum":null,"indicatieGebruiksrecht":false,"verschijningsvorm":"","ondertekening":{"soort":"","datum":null},"integriteit":{"algoritme":"","waarde":"","datum":null},"informatieobjecttype":"http://localhost:8003/catalogi/api/v1/informatieobjecttypen/d1cfb1d8-8593-4814-919d-72e38e80388f","locked":false,"bestandsdelen":[],"trefwoorden":[],"lock":""}' headers: API-version: @@ -96,7 +96,7 @@ interactions: Cross-Origin-Opener-Policy: - same-origin Location: - - http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/2f72e9d2-a208-4921-b6e2-fd694c84e889 + - http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/3b63cf06-20fc-4e94-912e-961a85a465e9 Referrer-Policy: - same-origin Vary: @@ -139,11 +139,11 @@ interactions: Cross-Origin-Opener-Policy: - same-origin Date: - - Mon, 16 Sep 2024 14:19:22 GMT + - Thu, 19 Dec 2024 12:15:26 GMT Referrer-Policy: - same-origin Server: - - nginx/1.27.0 + - nginx/1.27.3 Vary: - origin X-Content-Type-Options: @@ -160,11 +160,11 @@ interactions: {"test-slug": {"voornaam": "Foo", "achternaam": "Bar", "tussenvoegsel": "de", "geboortedatum": "2000-12-31", "coordinaat": [52.36673378967122, 4.893164274470299]}}, "taal": "en", "betrokkenen": [{"inpBsn": "", "rolOmschrijvingGeneriek": "initiator"}], - "pdf": "http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/e9059611-9abf-4c21-ad11-86b6a9dcbe1e", - "csv": "http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/2f72e9d2-a208-4921-b6e2-fd694c84e889", + "pdf": "http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/f98002c7-c166-4114-9b01-897b9ab15e12", + "csv": "http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/3b63cf06-20fc-4e94-912e-961a85a465e9", "bijlagen": [], "payment": {"completed": false, "amount": 0, "public_order_ids": - [], "payment_ids": []}}, "startAt": "2024-09-16", "geometry": {"type": "Point", - "coordinates": [52.36673378967122, 4.893164274470299]}}}' + [], "payment_ids": []}}, "startAt": "2024-12-19", "geometry": {"type": "Point", + "coordinates": [4.893164274470299, 52.36673378967122]}}}' headers: Accept: - '*/*' @@ -186,8 +186,8 @@ interactions: uri: http://localhost:8002/api/v2/objects response: body: - string: '{"url":"http://objects-web:8000/api/v2/objects/1271a648-0231-4c20-8f76-3c6e63f4da9f","uuid":"1271a648-0231-4c20-8f76-3c6e63f4da9f","type":"http://objecttypes-web:8000/api/v2/objecttypes/8faed0fa-7864-4409-aa6d-533a37616a9e","record":{"index":1,"typeVersion":1,"data":{"bron":{"naam":"Open - Formulieren","kenmerk":"aaaaaaaa-aaaa-aaaa-aaaa-aaaaaaaaaaaa"},"type":"testproduct","aanvraaggegevens":{"test-slug":{"voornaam":"Foo","achternaam":"Bar","tussenvoegsel":"de","geboortedatum":"2000-12-31","coordinaat":[52.36673378967122,4.893164274470299]}},"taal":"en","betrokkenen":[{"inpBsn":"","rolOmschrijvingGeneriek":"initiator"}],"pdf":"http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/e9059611-9abf-4c21-ad11-86b6a9dcbe1e","csv":"http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/2f72e9d2-a208-4921-b6e2-fd694c84e889","bijlagen":[],"payment":{"completed":false,"amount":0,"public_order_ids":[],"payment_ids":[]}},"geometry":{"type":"Point","coordinates":[52.36673378967122,4.893164274470299]},"startAt":"2024-09-16","endAt":null,"registrationAt":"2024-09-16","correctionFor":null,"correctedBy":null}}' + string: '{"url":"http://objects-web:8000/api/v2/objects/8c36c481-bd08-4597-9b3a-753d6b1dfaeb","uuid":"8c36c481-bd08-4597-9b3a-753d6b1dfaeb","type":"http://objecttypes-web:8000/api/v2/objecttypes/8faed0fa-7864-4409-aa6d-533a37616a9e","record":{"index":1,"typeVersion":1,"data":{"bron":{"naam":"Open + Formulieren","kenmerk":"aaaaaaaa-aaaa-aaaa-aaaa-aaaaaaaaaaaa"},"type":"testproduct","aanvraaggegevens":{"test-slug":{"voornaam":"Foo","achternaam":"Bar","tussenvoegsel":"de","geboortedatum":"2000-12-31","coordinaat":[52.36673378967122,4.893164274470299]}},"taal":"en","betrokkenen":[{"inpBsn":"","rolOmschrijvingGeneriek":"initiator"}],"pdf":"http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/f98002c7-c166-4114-9b01-897b9ab15e12","csv":"http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/3b63cf06-20fc-4e94-912e-961a85a465e9","bijlagen":[],"payment":{"completed":false,"amount":0,"public_order_ids":[],"payment_ids":[]}},"geometry":{"type":"Point","coordinates":[4.893164274470299,52.36673378967122]},"startAt":"2024-12-19","endAt":null,"registrationAt":"2024-12-19","correctionFor":null,"correctedBy":null}}' headers: Allow: - GET, POST, HEAD, OPTIONS @@ -202,13 +202,13 @@ interactions: Cross-Origin-Opener-Policy: - same-origin Date: - - Mon, 16 Sep 2024 14:19:22 GMT + - Thu, 19 Dec 2024 12:15:27 GMT Location: - - http://localhost:8002/api/v2/objects/1271a648-0231-4c20-8f76-3c6e63f4da9f + - http://localhost:8002/api/v2/objects/8c36c481-bd08-4597-9b3a-753d6b1dfaeb Referrer-Policy: - same-origin Server: - - nginx/1.27.0 + - nginx/1.27.3 Vary: - origin X-Content-Type-Options: @@ -226,18 +226,18 @@ interactions: Accept-Encoding: - gzip, deflate, br Authorization: - - Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJ0ZXN0X2NsaWVudF9pZCIsImlhdCI6MTcyNjQ5NjM2MiwiY2xpZW50X2lkIjoidGVzdF9jbGllbnRfaWQiLCJ1c2VyX2lkIjoiIiwidXNlcl9yZXByZXNlbnRhdGlvbiI6IiJ9.i4dqstVtjRbZvXWbWvePMpZXKaJMHa46vzpIJjR3C_s + - Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJ0ZXN0X2NsaWVudF9pZCIsImlhdCI6MTczNDYxMDUyNywiY2xpZW50X2lkIjoidGVzdF9jbGllbnRfaWQiLCJ1c2VyX2lkIjoiIiwidXNlcl9yZXByZXNlbnRhdGlvbiI6IiJ9.j6VBzP1jDfEDAuoUS20eT0c7QRGrZcls8n0g0uYb-2k Connection: - keep-alive User-Agent: - python-requests/2.32.2 method: GET - uri: http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/2f72e9d2-a208-4921-b6e2-fd694c84e889 + uri: http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/3b63cf06-20fc-4e94-912e-961a85a465e9 response: body: - string: '{"url":"http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/2f72e9d2-a208-4921-b6e2-fd694c84e889","identificatie":"DOCUMENT-2024-0000000068","bronorganisatie":"123456782","creatiedatum":"2024-09-16","titel":"Form - 018 (csv)","vertrouwelijkheidaanduiding":"openbaar","auteur":"Aanvrager","status":"definitief","formaat":"text/csv","taal":"eng","versie":1,"beginRegistratie":"2024-09-16T14:19:21.976830Z","bestandsnaam":"open-forms-Form - 018 (csv).csv","inhoud":"http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/2f72e9d2-a208-4921-b6e2-fd694c84e889/download?versie=1","bestandsomvang":175,"link":"","beschrijving":"Ingezonden + string: '{"url":"http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/3b63cf06-20fc-4e94-912e-961a85a465e9","identificatie":"DOCUMENT-2024-0000000088","bronorganisatie":"123456782","creatiedatum":"2024-12-19","titel":"Form + 018 (csv)","vertrouwelijkheidaanduiding":"openbaar","auteur":"Aanvrager","status":"definitief","formaat":"text/csv","taal":"eng","versie":1,"beginRegistratie":"2024-12-19T12:15:25.986595Z","bestandsnaam":"open-forms-Form + 018 (csv).csv","inhoud":"http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/3b63cf06-20fc-4e94-912e-961a85a465e9/download?versie=1","bestandsomvang":175,"link":"","beschrijving":"Ingezonden formulierdata","ontvangstdatum":null,"verzenddatum":null,"indicatieGebruiksrecht":false,"verschijningsvorm":"","ondertekening":{"soort":"","datum":null},"integriteit":{"algoritme":"","waarde":"","datum":null},"informatieobjecttype":"http://localhost:8003/catalogi/api/v1/informatieobjecttypen/d1cfb1d8-8593-4814-919d-72e38e80388f","locked":false,"bestandsdelen":[],"trefwoorden":[]}' headers: API-version: @@ -251,7 +251,7 @@ interactions: Cross-Origin-Opener-Policy: - same-origin ETag: - - '"5a77c55bfa52d6509314385573170fbd"' + - '"d5d3a004e302094178153496fbd097dc"' Referrer-Policy: - same-origin Vary: @@ -271,18 +271,18 @@ interactions: Accept-Encoding: - gzip, deflate, br Authorization: - - Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJ0ZXN0X2NsaWVudF9pZCIsImlhdCI6MTcyNjQ5NjM2MiwiY2xpZW50X2lkIjoidGVzdF9jbGllbnRfaWQiLCJ1c2VyX2lkIjoiIiwidXNlcl9yZXByZXNlbnRhdGlvbiI6IiJ9.i4dqstVtjRbZvXWbWvePMpZXKaJMHa46vzpIJjR3C_s + - Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJ0ZXN0X2NsaWVudF9pZCIsImlhdCI6MTczNDYxMDUyNywiY2xpZW50X2lkIjoidGVzdF9jbGllbnRfaWQiLCJ1c2VyX2lkIjoiIiwidXNlcl9yZXByZXNlbnRhdGlvbiI6IiJ9.j6VBzP1jDfEDAuoUS20eT0c7QRGrZcls8n0g0uYb-2k Connection: - keep-alive User-Agent: - python-requests/2.32.2 method: GET - uri: http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/e9059611-9abf-4c21-ad11-86b6a9dcbe1e + uri: http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/f98002c7-c166-4114-9b01-897b9ab15e12 response: body: - string: '{"url":"http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/e9059611-9abf-4c21-ad11-86b6a9dcbe1e","identificatie":"DOCUMENT-2024-0000000067","bronorganisatie":"123456782","creatiedatum":"2024-09-16","titel":"Form - 018","vertrouwelijkheidaanduiding":"openbaar","auteur":"Aanvrager","status":"definitief","formaat":"application/pdf","taal":"eng","versie":1,"beginRegistratie":"2024-09-16T14:19:21.842296Z","bestandsnaam":"open-forms-Form - 018.pdf","inhoud":"http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/e9059611-9abf-4c21-ad11-86b6a9dcbe1e/download?versie=1","bestandsomvang":0,"link":"","beschrijving":"Ingezonden + string: '{"url":"http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/f98002c7-c166-4114-9b01-897b9ab15e12","identificatie":"DOCUMENT-2024-0000000087","bronorganisatie":"123456782","creatiedatum":"2024-12-19","titel":"Form + 018","vertrouwelijkheidaanduiding":"openbaar","auteur":"Aanvrager","status":"definitief","formaat":"application/pdf","taal":"eng","versie":1,"beginRegistratie":"2024-12-19T12:15:25.876397Z","bestandsnaam":"open-forms-Form + 018.pdf","inhoud":"http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/f98002c7-c166-4114-9b01-897b9ab15e12/download?versie=1","bestandsomvang":0,"link":"","beschrijving":"Ingezonden formulier","ontvangstdatum":null,"verzenddatum":null,"indicatieGebruiksrecht":false,"verschijningsvorm":"","ondertekening":{"soort":"","datum":null},"integriteit":{"algoritme":"","waarde":"","datum":null},"informatieobjecttype":"http://localhost:8003/catalogi/api/v1/informatieobjecttypen/f2908f6f-aa07-42ef-8760-74c5234f2d25","locked":false,"bestandsdelen":[],"trefwoorden":[]}' headers: API-version: @@ -296,7 +296,7 @@ interactions: Cross-Origin-Opener-Policy: - same-origin ETag: - - '"90d255d07c6e708d98977b9367c8fd31"' + - '"3098fe854bbeb9ee2bf7874dfe9ea8c9"' Referrer-Policy: - same-origin Vary: diff --git a/src/openforms/registrations/contrib/objects_api/tests/files/vcr_cassettes/ObjectsAPIBackendV2Tests/ObjectsAPIBackendV2Tests.test_submission_with_objects_api_v2.yaml b/src/openforms/registrations/contrib/objects_api/tests/files/vcr_cassettes/ObjectsAPIBackendV2Tests/ObjectsAPIBackendV2Tests.test_submission_with_objects_api_v2.yaml index 10a9e036f6..27a0d709ce 100644 --- a/src/openforms/registrations/contrib/objects_api/tests/files/vcr_cassettes/ObjectsAPIBackendV2Tests/ObjectsAPIBackendV2Tests.test_submission_with_objects_api_v2.yaml +++ b/src/openforms/registrations/contrib/objects_api/tests/files/vcr_cassettes/ObjectsAPIBackendV2Tests/ObjectsAPIBackendV2Tests.test_submission_with_objects_api_v2.yaml @@ -2,8 +2,8 @@ interactions: - request: body: '{"informatieobjecttype": "http://localhost:8003/catalogi/api/v1/informatieobjecttypen/7a474713-0833-402a-8441-e467c08ac55b", "bronorganisatie": "000000000", "creatiedatum": "2024-03-19", "titel": "Form - 030", "auteur": "Aanvrager", "taal": "nld", "formaat": "application/pdf", "inhoud": - "", "status": "definitief", "bestandsnaam": "open-forms-Form 030.pdf", "ontvangstdatum": + 031", "auteur": "Aanvrager", "taal": "nld", "formaat": "application/pdf", "inhoud": + "", "status": "definitief", "bestandsnaam": "open-forms-Form 031.pdf", "ontvangstdatum": null, "beschrijving": "Ingezonden formulier", "indicatieGebruiksrecht": false, "bestandsomvang": 0}' headers: @@ -25,9 +25,9 @@ interactions: uri: http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten response: body: - string: '{"url":"http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/bb2c5270-0cb2-4917-bed4-42faea54ba4b","identificatie":"DOCUMENT-2024-0000000077","bronorganisatie":"000000000","creatiedatum":"2024-03-19","titel":"Form - 030","vertrouwelijkheidaanduiding":"openbaar","auteur":"Aanvrager","status":"definitief","formaat":"application/pdf","taal":"nld","versie":1,"beginRegistratie":"2024-09-16T14:19:25.170967Z","bestandsnaam":"open-forms-Form - 030.pdf","inhoud":"http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/bb2c5270-0cb2-4917-bed4-42faea54ba4b/download?versie=1","bestandsomvang":0,"link":"","beschrijving":"Ingezonden + string: '{"url":"http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/aee82c2a-ad9a-47fe-ae47-f6e3801c250e","identificatie":"DOCUMENT-2024-0000000089","bronorganisatie":"000000000","creatiedatum":"2024-03-19","titel":"Form + 031","vertrouwelijkheidaanduiding":"openbaar","auteur":"Aanvrager","status":"definitief","formaat":"application/pdf","taal":"nld","versie":1,"beginRegistratie":"2024-12-19T12:15:28.450225Z","bestandsnaam":"open-forms-Form + 031.pdf","inhoud":"http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/aee82c2a-ad9a-47fe-ae47-f6e3801c250e/download?versie=1","bestandsomvang":0,"link":"","beschrijving":"Ingezonden formulier","ontvangstdatum":null,"verzenddatum":null,"indicatieGebruiksrecht":false,"verschijningsvorm":"","ondertekening":{"soort":"","datum":null},"integriteit":{"algoritme":"","waarde":"","datum":null},"informatieobjecttype":"http://localhost:8003/catalogi/api/v1/informatieobjecttypen/7a474713-0833-402a-8441-e467c08ac55b","locked":false,"bestandsdelen":[],"trefwoorden":[],"lock":""}' headers: API-version: @@ -41,7 +41,7 @@ interactions: Cross-Origin-Opener-Policy: - same-origin Location: - - http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/bb2c5270-0cb2-4917-bed4-42faea54ba4b + - http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/aee82c2a-ad9a-47fe-ae47-f6e3801c250e Referrer-Policy: - same-origin Vary: @@ -56,9 +56,9 @@ interactions: - request: body: '{"informatieobjecttype": "http://localhost:8003/catalogi/api/v1/informatieobjecttypen/b2d83b94-9b9b-4e80-a82f-73ff993c62f3", "bronorganisatie": "000000000", "creatiedatum": "2024-03-19", "titel": "Form - 030 (csv)", "auteur": "Aanvrager", "taal": "nld", "formaat": "text/csv", "inhoud": - "Rm9ybXVsaWVybmFhbSxJbnplbmRpbmdkYXR1bSxhZ2UsbGFzdG5hbWUsbG9jYXRpb24NCkZvcm0gMDMwLDIwMjQtMDMtMDIgMDI6MzY6NTcuNzE5NzMxLDIwLE15IGxhc3QgbmFtZSwiWzUyLjM2NjczMzc4OTY3MTIyLCA0Ljg5MzE2NDI3NDQ3MDI5OV0iDQo=", - "status": "definitief", "bestandsnaam": "open-forms-Form 030 (csv).csv", "ontvangstdatum": + 031 (csv)", "auteur": "Aanvrager", "taal": "nld", "formaat": "text/csv", "inhoud": + "Rm9ybXVsaWVybmFhbSxJbnplbmRpbmdkYXR1bSxhZ2UsbGFzdG5hbWUsbG9jYXRpb24NCkZvcm0gMDMxLDIwMjQtMDMtMDcgMDY6NDc6MDQuMDU3Njk5LDIwLE15IGxhc3QgbmFtZSwiWzUyLjM2NjczMzc4OTY3MTIyLCA0Ljg5MzE2NDI3NDQ3MDI5OV0iDQo=", + "status": "definitief", "bestandsnaam": "open-forms-Form 031 (csv).csv", "ontvangstdatum": null, "beschrijving": "Ingezonden formulierdata", "indicatieGebruiksrecht": false, "bestandsomvang": 146}' headers: @@ -80,9 +80,9 @@ interactions: uri: http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten response: body: - string: '{"url":"http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/6d6fb09a-c205-43a2-95e6-6ba2d2fabfcb","identificatie":"DOCUMENT-2024-0000000078","bronorganisatie":"000000000","creatiedatum":"2024-03-19","titel":"Form - 030 (csv)","vertrouwelijkheidaanduiding":"openbaar","auteur":"Aanvrager","status":"definitief","formaat":"text/csv","taal":"nld","versie":1,"beginRegistratie":"2024-09-16T14:19:25.237270Z","bestandsnaam":"open-forms-Form - 030 (csv).csv","inhoud":"http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/6d6fb09a-c205-43a2-95e6-6ba2d2fabfcb/download?versie=1","bestandsomvang":146,"link":"","beschrijving":"Ingezonden + string: '{"url":"http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/86897795-b8c3-494f-9be1-70f445ab7882","identificatie":"DOCUMENT-2024-0000000090","bronorganisatie":"000000000","creatiedatum":"2024-03-19","titel":"Form + 031 (csv)","vertrouwelijkheidaanduiding":"openbaar","auteur":"Aanvrager","status":"definitief","formaat":"text/csv","taal":"nld","versie":1,"beginRegistratie":"2024-12-19T12:15:28.572012Z","bestandsnaam":"open-forms-Form + 031 (csv).csv","inhoud":"http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/86897795-b8c3-494f-9be1-70f445ab7882/download?versie=1","bestandsomvang":146,"link":"","beschrijving":"Ingezonden formulierdata","ontvangstdatum":null,"verzenddatum":null,"indicatieGebruiksrecht":false,"verschijningsvorm":"","ondertekening":{"soort":"","datum":null},"integriteit":{"algoritme":"","waarde":"","datum":null},"informatieobjecttype":"http://localhost:8003/catalogi/api/v1/informatieobjecttypen/b2d83b94-9b9b-4e80-a82f-73ff993c62f3","locked":false,"bestandsdelen":[],"trefwoorden":[],"lock":""}' headers: API-version: @@ -96,7 +96,7 @@ interactions: Cross-Origin-Opener-Policy: - same-origin Location: - - http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/6d6fb09a-c205-43a2-95e6-6ba2d2fabfcb + - http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/86897795-b8c3-494f-9be1-70f445ab7882 Referrer-Policy: - same-origin Vary: @@ -125,24 +125,24 @@ interactions: uri: http://localhost:8001/api/v2/objecttypes/8e46e0a5-b1b4-449b-b9e9-fa3cea655f48 response: body: - string: '{"url":"http://objecttypes-web:8000/api/v2/objecttypes/8e46e0a5-b1b4-449b-b9e9-fa3cea655f48","uuid":"8e46e0a5-b1b4-449b-b9e9-fa3cea655f48","name":"Person","namePlural":"Persons","description":"","dataClassification":"open","maintainerOrganization":"","maintainerDepartment":"","contactPerson":"","contactEmail":"","source":"","updateFrequency":"unknown","providerOrganization":"","documentationUrl":"","labels":{},"createdAt":"2023-10-24","modifiedAt":"2024-02-08","allowGeometry":true,"versions":["http://objecttypes-web:8000/api/v2/objecttypes/8e46e0a5-b1b4-449b-b9e9-fa3cea655f48/versions/1","http://objecttypes-web:8000/api/v2/objecttypes/8e46e0a5-b1b4-449b-b9e9-fa3cea655f48/versions/2","http://objecttypes-web:8000/api/v2/objecttypes/8e46e0a5-b1b4-449b-b9e9-fa3cea655f48/versions/3"]}' + string: '{"url":"http://objecttypes-web:8000/api/v2/objecttypes/8e46e0a5-b1b4-449b-b9e9-fa3cea655f48","uuid":"8e46e0a5-b1b4-449b-b9e9-fa3cea655f48","name":"Person","namePlural":"Persons","description":"","dataClassification":"open","maintainerOrganization":"","maintainerDepartment":"","contactPerson":"","contactEmail":"","source":"","updateFrequency":"unknown","providerOrganization":"","documentationUrl":"","labels":{},"createdAt":"2023-10-24","modifiedAt":"2024-02-08","allowGeometry":true,"versions":["http://objecttypes-web:8000/api/v2/objecttypes/8e46e0a5-b1b4-449b-b9e9-fa3cea655f48/versions/2","http://objecttypes-web:8000/api/v2/objecttypes/8e46e0a5-b1b4-449b-b9e9-fa3cea655f48/versions/3","http://objecttypes-web:8000/api/v2/objecttypes/8e46e0a5-b1b4-449b-b9e9-fa3cea655f48/versions/1","http://objecttypes-web:8000/api/v2/objecttypes/8e46e0a5-b1b4-449b-b9e9-fa3cea655f48/versions/4"]}' headers: Allow: - GET, PUT, PATCH, DELETE, HEAD, OPTIONS Connection: - keep-alive Content-Length: - - '790' + - '887' Content-Type: - application/json Cross-Origin-Opener-Policy: - same-origin Date: - - Mon, 16 Sep 2024 14:19:25 GMT + - Thu, 19 Dec 2024 12:15:28 GMT Referrer-Policy: - same-origin Server: - - nginx/1.27.0 + - nginx/1.27.3 Vary: - origin X-Content-Type-Options: @@ -156,11 +156,11 @@ interactions: body: '{"type": "http://objecttypes-web:8000/api/v2/objecttypes/8e46e0a5-b1b4-449b-b9e9-fa3cea655f48", "record": {"typeVersion": 3, "data": {"age": 20, "name": {"last.name": "My last name"}, "submission_date": "2024-03-19T13:40:00+00:00", "submission_pdf_url": - "http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/bb2c5270-0cb2-4917-bed4-42faea54ba4b", - "submission_csv_url": "http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/6d6fb09a-c205-43a2-95e6-6ba2d2fabfcb", + "http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/aee82c2a-ad9a-47fe-ae47-f6e3801c250e", + "submission_csv_url": "http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/86897795-b8c3-494f-9be1-70f445ab7882", "submission_payment_completed": false, "submission_payment_amount": null, "submission_payment_public_ids": [], "cosign_date": null}, "startAt": "2024-03-19", "geometry": {"type": "Point", - "coordinates": [52.36673378967122, 4.893164274470299]}}}' + "coordinates": [4.893164274470299, 52.36673378967122]}}}' headers: Accept: - '*/*' @@ -182,8 +182,8 @@ interactions: uri: http://localhost:8002/api/v2/objects response: body: - string: '{"url":"http://objects-web:8000/api/v2/objects/3400aa0c-809c-4ce2-ac31-ad6c95f216b0","uuid":"3400aa0c-809c-4ce2-ac31-ad6c95f216b0","type":"http://objecttypes-web:8000/api/v2/objecttypes/8e46e0a5-b1b4-449b-b9e9-fa3cea655f48","record":{"index":1,"typeVersion":3,"data":{"age":20,"name":{"last.name":"My - last name"},"submission_date":"2024-03-19T13:40:00+00:00","submission_pdf_url":"http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/bb2c5270-0cb2-4917-bed4-42faea54ba4b","submission_csv_url":"http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/6d6fb09a-c205-43a2-95e6-6ba2d2fabfcb","submission_payment_completed":false,"submission_payment_amount":null,"submission_payment_public_ids":[],"cosign_date":null},"geometry":{"type":"Point","coordinates":[52.36673378967122,4.893164274470299]},"startAt":"2024-03-19","endAt":null,"registrationAt":"2024-09-16","correctionFor":null,"correctedBy":null}}' + string: '{"url":"http://objects-web:8000/api/v2/objects/c48ef42d-cfdf-4535-8da1-a7faa20b9692","uuid":"c48ef42d-cfdf-4535-8da1-a7faa20b9692","type":"http://objecttypes-web:8000/api/v2/objecttypes/8e46e0a5-b1b4-449b-b9e9-fa3cea655f48","record":{"index":1,"typeVersion":3,"data":{"age":20,"name":{"last.name":"My + last name"},"submission_date":"2024-03-19T13:40:00+00:00","submission_pdf_url":"http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/aee82c2a-ad9a-47fe-ae47-f6e3801c250e","submission_csv_url":"http://localhost:8003/documenten/api/v1/enkelvoudiginformatieobjecten/86897795-b8c3-494f-9be1-70f445ab7882","submission_payment_completed":false,"submission_payment_amount":null,"submission_payment_public_ids":[],"cosign_date":null},"geometry":{"type":"Point","coordinates":[4.893164274470299,52.36673378967122]},"startAt":"2024-03-19","endAt":null,"registrationAt":"2024-12-19","correctionFor":null,"correctedBy":null}}' headers: Allow: - GET, POST, HEAD, OPTIONS @@ -198,13 +198,13 @@ interactions: Cross-Origin-Opener-Policy: - same-origin Date: - - Mon, 16 Sep 2024 14:19:25 GMT + - Thu, 19 Dec 2024 12:15:28 GMT Location: - - http://localhost:8002/api/v2/objects/3400aa0c-809c-4ce2-ac31-ad6c95f216b0 + - http://localhost:8002/api/v2/objects/c48ef42d-cfdf-4535-8da1-a7faa20b9692 Referrer-Policy: - same-origin Server: - - nginx/1.27.0 + - nginx/1.27.3 Vary: - origin X-Content-Type-Options: diff --git a/src/openforms/registrations/contrib/objects_api/tests/test_backend_v2.py b/src/openforms/registrations/contrib/objects_api/tests/test_backend_v2.py index c0c139f633..fe30456b66 100644 --- a/src/openforms/registrations/contrib/objects_api/tests/test_backend_v2.py +++ b/src/openforms/registrations/contrib/objects_api/tests/test_backend_v2.py @@ -173,7 +173,7 @@ def test_submission_with_objects_api_v2(self): result["record"]["geometry"], { "type": "Point", - "coordinates": [52.36673378967122, 4.893164274470299], + "coordinates": [4.893164274470299, 52.36673378967122], }, ) @@ -498,7 +498,7 @@ def test_submission_with_map_component_inside_data(self): data["pointCoordinates"], { "type": "Point", - "coordinates": [52.36673378967122, 4.893164274470299], + "coordinates": [4.893164274470299, 52.36673378967122], }, ) diff --git a/src/openforms/registrations/contrib/zgw_apis/plugin.py b/src/openforms/registrations/contrib/zgw_apis/plugin.py index 9913f4e870..f23d053a03 100644 --- a/src/openforms/registrations/contrib/zgw_apis/plugin.py +++ b/src/openforms/registrations/contrib/zgw_apis/plugin.py @@ -76,7 +76,8 @@ def get_property_mappings_from_submission( def _point_coordinate(value): if not value or not isinstance(value, list) or len(value) != 2: return SKIP - return {"type": "Point", "coordinates": [value[0], value[1]]} + # Providing the coordinates as [lng, lat] #4955 + return {"type": "Point", "coordinates": [value[1], value[0]]} def _gender_choices(value):