structured address from WMS
This commit is contained in:
parent
9c3f6cac3e
commit
d81489d59f
@ -20,20 +20,18 @@
|
|||||||
|
|
||||||
"Address":
|
"Address":
|
||||||
{
|
{
|
||||||
"StreetAddressOne" : "${carrier.address.address_1}",
|
"Name": "${carrier.carrier_structured_address.name_or_company}",
|
||||||
"StreetAddressTwo" : "${carrier.address.address_2}",
|
"StreetAddressOne" : "${carrier.carrier_structured_address.street_and_PO}",
|
||||||
|
"StreetAddressTwo" : "${carrier.carrier_structured_address.additionnal_data}",
|
||||||
<#if carrier.address.address_3?length < 10>
|
"PostalCode" : "${carrier.carrier_structured_address.postal_code}",
|
||||||
"PostalCode" : "${carrier.address.address_3?trim}",
|
"City" : "${carrier.carrier_structured_address.post_code_area_name}",
|
||||||
<#else>
|
"CountryCode" : "${carrier.carrier_structured_address.country_code}",
|
||||||
"PostalCode" : "${carrier.address.address_3?substring(0,9)?trim}",
|
"ProvinceCode": "${carrier.carrier_structured_address.territorial_div_code}",
|
||||||
</#if>
|
"State": "${carrier.carrier_structured_address.country_designation}"
|
||||||
<#if carrier.address.address_4?length < 14>
|
|
||||||
"CountryCode" : ""
|
|
||||||
<#else>
|
|
||||||
"CountryCode" : "${carrier.address.address_4?substring(10,13)?trim}"
|
|
||||||
</#if>
|
|
||||||
},
|
},
|
||||||
|
"Phones": ["${carrier.address.telephone}",
|
||||||
|
"${carrier.address.other_number}"
|
||||||
|
],
|
||||||
"Typology": "TYPOLOGY_CARRIER"
|
"Typology": "TYPOLOGY_CARRIER"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -18,25 +18,20 @@
|
|||||||
<#include "RFXtoRP_HsaCons_ActorCreated_Metadata.ftl">,
|
<#include "RFXtoRP_HsaCons_ActorCreated_Metadata.ftl">,
|
||||||
-->
|
-->
|
||||||
|
|
||||||
|
|
||||||
"Address":
|
"Address":
|
||||||
{
|
{
|
||||||
<#if actor.address.address_3?length > 10>
|
"Name": "${actor.consignee_structured_address.name_or_company}",
|
||||||
"City" : "${actor.address.address_3?substring(10)?trim}",
|
"StreetAddressOne" : "${actor.consignee_structured_address.street_and_PO}",
|
||||||
</#if>
|
"StreetAddressTwo" : "${actor.consignee_structured_address.additionnal_data}",
|
||||||
"StreetAddressOne" : "${actor.address.address_1}",
|
"PostalCode" : "${actor.consignee_structured_address.postal_code}",
|
||||||
"StreetAddressTwo" : "${actor.address.address_2}",
|
"City" : "${actor.consignee_structured_address.post_code_area_name}",
|
||||||
<#if actor.address.address_3?length < 10>
|
"CountryCode" : "${actor.consignee_structured_address.country_code}",
|
||||||
"PostalCode" : "${actor.address.address_3?trim}",
|
"ProvinceCode": "${actor.consignee_structured_address.territorial_div_code}",
|
||||||
<#else>
|
"State": "${actor.consignee_structured_address.country_designation}"
|
||||||
"PostalCode" : "${actor.address.address_3?substring(0,9)?trim}",
|
|
||||||
</#if>
|
|
||||||
<#if actor.address.address_4?length < 14>
|
|
||||||
"CountryCode" : ""
|
|
||||||
<#else>
|
|
||||||
"CountryCode" : "${actor.address.address_4?substring(10,13)?trim}"
|
|
||||||
</#if>
|
|
||||||
},
|
},
|
||||||
|
"Phones": ["${actor.address.telephone}",
|
||||||
|
"${actor.address.other_number}"
|
||||||
|
],
|
||||||
"Typology": "TYPOLOGY_UNKNOWN"
|
"Typology": "TYPOLOGY_UNKNOWN"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -20,23 +20,18 @@
|
|||||||
|
|
||||||
"Address":
|
"Address":
|
||||||
{
|
{
|
||||||
<#if actor.optional_attributes.address_3?length > 10>
|
"Name": "${actor.supplier_structured_address.name_or_company}",
|
||||||
"City" : "${actor.optional_attributes.address_3?substring(10)?trim}",
|
"StreetAddressOne" : "${actor.supplier_structured_address.street_and_PO}",
|
||||||
</#if>
|
"StreetAddressTwo" : "${actor.supplier_structured_address.additionnal_data}",
|
||||||
"StreetAddressOne" : "${actor.optional_attributes.address_1}",
|
"PostalCode" : "${actor.supplier_structured_address.postal_code}",
|
||||||
"StreetAddressTwo" : "${actor.optional_attributes.address_2}",
|
"City" : "${actor.supplier_structured_address.post_code_area_name}",
|
||||||
|
"CountryCode" : "${actor.supplier_structured_address.country_code}",
|
||||||
<#if actor.optional_attributes.address_3?length < 10>
|
"ProvinceCode": "${actor.supplier_structured_address.territorial_div_code}",
|
||||||
"PostalCode" : "${actor.optional_attributes.address_3?trim}",
|
"State": "${actor.supplier_structured_address.country_designation}"
|
||||||
<#else>
|
|
||||||
"PostalCode" : "${actor.optional_attributes.address_3?substring(0,9)?trim}",
|
|
||||||
</#if>
|
|
||||||
<#if actor.optional_attributes.address_4?length < 14>
|
|
||||||
"CountryCode" : ""
|
|
||||||
<#else>
|
|
||||||
"CountryCode" : "${actor.optional_attributes.address_4?substring(10,13)?trim}"
|
|
||||||
</#if>
|
|
||||||
},
|
},
|
||||||
|
"Phones": ["${actor.optional_attributes.telephone}",
|
||||||
|
"${actor.optional_attributes.other_number}"
|
||||||
|
],
|
||||||
"Typology": "TYPOLOGY_UNKNOWN"
|
"Typology": "TYPOLOGY_UNKNOWN"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user