From d21204a94901d64f5d344271ba26356e4f04882a Mon Sep 17 00:00:00 2001 From: frea Date: Tue, 6 Aug 2024 15:41:22 +0200 Subject: [PATCH 1/2] SCPN1-6998 --- RFXtoRP_HsaCarrier_ActorCreated.ftl | 7 ++++++- RFXtoRP_HsaCons_ActorCreated.ftl | 7 ++++++- RFXtoRP_HsaSup_ActorCreated.ftl | 7 ++++++- RFXtoRP_HsrDepot_ActorCreated.ftl | 7 ++++++- 4 files changed, 24 insertions(+), 4 deletions(-) diff --git a/RFXtoRP_HsaCarrier_ActorCreated.ftl b/RFXtoRP_HsaCarrier_ActorCreated.ftl index 8c35239..f5afbd2 100644 --- a/RFXtoRP_HsaCarrier_ActorCreated.ftl +++ b/RFXtoRP_HsaCarrier_ActorCreated.ftl @@ -29,7 +29,12 @@ "StreetAddressTwo" : "${carrier.carrier_structured_address.additionnal_data?json_string}", "PostalCode" : "${carrier.carrier_structured_address.postal_code?json_string}", "City" : "${carrier.carrier_structured_address.post_code_area_name?json_string}", - "CountryCode" : "${carrier.carrier_structured_address.country_code?json_string}", + <#assign isCountryCode = JsonUtil.isCountryCode(carrier.carrier_structured_address.country_code?upper_case) /> + <#if isCountryCode> + "CountryCode" : "${carrier.carrier_structured_address.country_code?upper_case?json_string}", + <#else> + "CountryCode" : "", + "ProvinceCode": "${carrier.carrier_structured_address.territorial_div_code?json_string}", "State": "${carrier.carrier_structured_address.country_designation?json_string}" diff --git a/RFXtoRP_HsaCons_ActorCreated.ftl b/RFXtoRP_HsaCons_ActorCreated.ftl index 97b21f8..3448388 100644 --- a/RFXtoRP_HsaCons_ActorCreated.ftl +++ b/RFXtoRP_HsaCons_ActorCreated.ftl @@ -29,7 +29,12 @@ "StreetAddressTwo" : "${actor.consignee_structured_address.additionnal_data?json_string}", "PostalCode" : "${actor.consignee_structured_address.postal_code?json_string}", "City" : "${actor.consignee_structured_address.post_code_area_name?json_string}", - "CountryCode" : "${actor.consignee_structured_address.country_code?json_string}", + <#assign isCountryCode = JsonUtil.isCountryCode(actor.consignee_structured_address.country_code?upper_case) /> + <#if isCountryCode> + "CountryCode" : "${actor.consignee_structured_address.country_code?upper_case?json_string}", + <#else> + "CountryCode" : "", + "ProvinceCode": "${actor.consignee_structured_address.territorial_div_code?json_string}", "State": "${actor.consignee_structured_address.country_designation?json_string}" diff --git a/RFXtoRP_HsaSup_ActorCreated.ftl b/RFXtoRP_HsaSup_ActorCreated.ftl index fb804ac..042a51b 100644 --- a/RFXtoRP_HsaSup_ActorCreated.ftl +++ b/RFXtoRP_HsaSup_ActorCreated.ftl @@ -28,7 +28,12 @@ "StreetAddressTwo" : "${actor.supplier_structured_address.additionnal_data?json_string}", "PostalCode" : "${actor.supplier_structured_address.postal_code?json_string}", "City" : "${actor.supplier_structured_address.post_code_area_name?json_string}", - "CountryCode" : "${actor.supplier_structured_address.country_code?json_string}", + <#assign isCountryCode = JsonUtil.isCountryCode(actor.supplier_structured_address.country_code?upper_case) /> + <#if isCountryCode> + "CountryCode" : "${actor.supplier_structured_address.country_code?upper_case?json_string}", + <#else> + "CountryCode" : "", + "ProvinceCode": "${actor.supplier_structured_address.territorial_div_code?json_string}", "State": "${actor.supplier_structured_address.country_designation?json_string}" diff --git a/RFXtoRP_HsrDepot_ActorCreated.ftl b/RFXtoRP_HsrDepot_ActorCreated.ftl index 31774f9..b3042e2 100644 --- a/RFXtoRP_HsrDepot_ActorCreated.ftl +++ b/RFXtoRP_HsrDepot_ActorCreated.ftl @@ -28,7 +28,12 @@ "StreetAddressTwo" : "${depot.physical_depot_structured_address.additionnal_data?json_string}", "PostalCode" : "${depot.physical_depot_structured_address.postal_code?json_string}", "City" : "${depot.physical_depot_structured_address.post_code_area_name?json_string}", - "CountryCode" : "${depot.physical_depot_structured_address.country_code?json_string}", + <#assign isCountryCode = JsonUtil.isCountryCode(depot.physical_depot_structured_address.country_code?upper_case) /> + <#if isCountryCode > + "CountryCode" : "${depot.physical_depot_structured_address.country_code?upper_case?json_string}", + <#else> + "CountryCode" : "", + "ProvinceCode": "${depot.physical_depot_structured_address.territorial_div_code?json_string}", "State": "${depot.physical_depot_structured_address.country_designation?json_string}" From 0468700574c357bfa302929285d34161c0b9f920 Mon Sep 17 00:00:00 2001 From: freat Date: Tue, 6 Aug 2024 16:08:37 +0200 Subject: [PATCH 2/2] Release 1.2.23+1 --- VERSION | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/VERSION b/VERSION index fa909d2..7babec0 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -1.2.22+1 +1.2.23+1