You've already forked reflex-wms-connector
Compare commits
195 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 9cadf3329e | |||
| 4502df6fb0 | |||
| 3ca4b61e3b | |||
| 4a26fd9249 | |||
| 4624bab7ad | |||
| c754edaafb | |||
| adff1396c1 | |||
| 0b70c90257 | |||
| 2828c01cc4 | |||
| 4553507e3b | |||
| 830db1493b | |||
| 79ad7f53e8 | |||
| c280b2c83a | |||
| 3a0bbdc479 | |||
| 1e9ce7cdc4 | |||
| eefc7070ac | |||
| f9c62d5ee4 | |||
| bcf77601b9 | |||
| 1670a22218 | |||
| cdc78d71b1 | |||
| 6b840c0ce7 | |||
| 8ee7527ba4 | |||
| 1be67f65b2 | |||
| dec9a4b17f | |||
| eb6182c337 | |||
| 9f63f0ee62 | |||
| 5b3de10184 | |||
| 8cfd636c72 | |||
| 18808b6033 | |||
| a849b1c92e | |||
| 810e0eaa89 | |||
| 1dc77965ce | |||
| 9aee7a9448 | |||
| d4765890e5 | |||
| 58bcf838bd | |||
| 24f17f434e | |||
| c16c48b270 | |||
| 29e16f12cc | |||
| c74470b780 | |||
| fab2238278 | |||
| 432cca8ec9 | |||
| 08e4b04f7f | |||
| bf0ae15a50 | |||
| 3f7cd7a245 | |||
| 173deec755 | |||
| 85bfe55af7 | |||
| 730750b898 | |||
| d85abf8235 | |||
| 46a9a82e12 | |||
| ae0b82b6e4 | |||
| 5fc26e6015 | |||
| 236c2d754c | |||
| 5499e3059f | |||
| cae9bf80bb | |||
| ed0141584b | |||
| e6a27c2ba2 | |||
| 0a26159dc9 | |||
| a4f3bf8151 | |||
| 867fdc5743 | |||
| b69bfa50ba | |||
| 834abe1b78 | |||
| e190a16ddc | |||
| e63b14d0ff | |||
| 04bc005cda | |||
| 6e46d30221 | |||
| 1f2d3ab212 | |||
| 771915ad19 | |||
| 4a1fe56381 | |||
| a9a357d4ed | |||
| 0e3e60b45a | |||
| f0e27a6f88 | |||
| f72bcc2537 | |||
| 9700548214 | |||
| 96aec6555c | |||
| 54511c55f1 | |||
| de828ed606 | |||
| eaa7ef1b9b | |||
| 4c84e4195b | |||
| 113c94f100 | |||
| 7963b351aa | |||
| 8425747b42 | |||
| 03e20e7aed | |||
| 04b7974c77 | |||
| 087346139d | |||
| 0a4263d551 | |||
| b00302c8e3 | |||
| 55b7b54b44 | |||
| 26003c24f2 | |||
| 0468700574 | |||
| fe35481144 | |||
| d21204a949 | |||
| 46421972a8 | |||
| ccca6d1592 | |||
| 68622896f0 | |||
| fea5691ddd | |||
| 2fb5dcd103 | |||
| 04253d939f | |||
| b80623e631 | |||
| 23a87c1995 | |||
| a3a2fa3b23 | |||
| 22b26ac7d3 | |||
| 0b3f07add9 | |||
| 28659b1157 | |||
| 3de6a2f6a9 | |||
| 4afc7fa50c | |||
| 6910fb80a8 | |||
| 1052849c12 | |||
| 24a94caf29 | |||
| 513a5c2c3e | |||
| 011540fc51 | |||
| 5e9804db40 | |||
| e344cca043 | |||
| b0b4714df9 | |||
| 15bd095feb | |||
| c0dd029d1f | |||
| 2e0d61310b | |||
| f62ccadba5 | |||
| 2c29166ccb | |||
| 4534155f2e | |||
| 5948467818 | |||
| c63e4ff5c8 | |||
| 457cfc85c2 | |||
| 6809b32410 | |||
| 37a5e64e83 | |||
| 2f31833bc3 | |||
| cff0f18d8a | |||
| 22b78b4ffe | |||
| 25bf3110e9 | |||
| 0a32ead29a | |||
| 46a9dc8996 | |||
| 1eb262c91c | |||
| 2588fda3a8 | |||
| d060d3eb10 | |||
| 28e99e9a2b | |||
| 78b0b467a3 | |||
| 6f287e878a | |||
| c3a23254b1 | |||
| c47672b8cc | |||
| 9cdcd2784d | |||
| cfe6bddf8d | |||
| 0cb3cc7dd0 | |||
| 6b633663e9 | |||
| c801c574ab | |||
| 6282266c6d | |||
| cb9d61bfe9 | |||
| 60c6f812d1 | |||
| c2f6537e0c | |||
| f5970127b0 | |||
| 33c7ab08a7 | |||
| fb8f9ca651 | |||
| 16c7d6b686 | |||
| fc919c2199 | |||
| 3365a94098 | |||
| e055eab522 | |||
| c95bdc7f00 | |||
| 319cb6cc51 | |||
| 1f289e229c | |||
| fba36b5d77 | |||
| 892812e85e | |||
| a512e4c23a | |||
| 884ad540fe | |||
| 3a9620e3ee | |||
| d5573b6dba | |||
| 162b73e75f | |||
| bb4315bba1 | |||
| c4910785e0 | |||
| 5688244be2 | |||
| de5e94be3c | |||
| 646256d879 | |||
| 60355d1ba5 | |||
| 737763dc7f | |||
| 098b2d4e1d | |||
| 7b55a4bcd0 | |||
| b369dd8adf | |||
| fd1cfcc2c5 | |||
| fc8290648f | |||
| 378c1ba75f | |||
| d94a74d399 | |||
| a882ac4b86 | |||
| d2d9443fc7 | |||
| 30ae93b9e7 | |||
| 64e03640d1 | |||
| 270f90a9b3 | |||
| b5c85220b5 | |||
| 2409cf3a01 | |||
| 957df51487 | |||
| d09fa33577 | |||
| 3bcdec1d5d | |||
| b4ea1e7798 | |||
| 80aecb3aa7 | |||
| e02218f7b1 | |||
| 6270992346 | |||
| a544f6700d | |||
| 04ec57377a | |||
| b209e8b5e1 |
@@ -2,9 +2,6 @@
|
|||||||
<#-- input : message RFX -->
|
<#-- input : message RFX -->
|
||||||
<#-- project : projectId in ReflexPlatform -->
|
<#-- project : projectId in ReflexPlatform -->
|
||||||
<#-- organisation : organisationtId in ReflexPlatform -->
|
<#-- organisation : organisationtId in ReflexPlatform -->
|
||||||
<#include "ReflexUtils.ftl">
|
|
||||||
<#include "HfRpConfig.ftl">
|
|
||||||
<#include "ActorPrefix.ftl">
|
|
||||||
|
|
||||||
<#assign cloudEventMsg = JsonUtil.jsonToMap(input)>
|
<#assign cloudEventMsg = JsonUtil.jsonToMap(input)>
|
||||||
<#assign projectRP = project>
|
<#assign projectRP = project>
|
||||||
@@ -18,22 +15,6 @@
|
|||||||
<#-- *********************************************** Action = CREATE or UPDATE ******************** -->
|
<#-- *********************************************** Action = CREATE or UPDATE ******************** -->
|
||||||
<#assign dataRfx = JsonUtil.decodeBase64(cloudEventMsg.data) />
|
<#assign dataRfx = JsonUtil.decodeBase64(cloudEventMsg.data) />
|
||||||
<#assign carrier = JsonUtil.jsonToMap(dataRfx)>
|
<#assign carrier = JsonUtil.jsonToMap(dataRfx)>
|
||||||
<#assign refID = RFXtoRPprefixCarrier(carrier.carrier_code?trim?json_string)>
|
|
||||||
|
|
||||||
<#assign payLoad = '{"Header": {"ProjectID": "${projectRP!""}"},"IDs": [{"RefID": "${refID}"}]}' />
|
|
||||||
<#assign queryApiReflexPlatformID = QueryApiReflexPlatformID.ActorGetByIds>
|
|
||||||
<#assign response = QueryApiReflexPlatformCall.call(queryApiReflexPlatformID,payLoad) />
|
|
||||||
<#assign actorRP = JsonUtil.jsonToMap(response)>
|
|
||||||
<#if actorRP?? && actorRP.Objects?? && actorRP.Objects[0]?? && actorRP.Objects[0].ID.RefID?? >
|
|
||||||
[
|
|
||||||
{
|
|
||||||
<#assign apiReflexPlatformID = ApiReflexPlatformID.ActorCreated>
|
|
||||||
"apiReflexPlatformID" : "${apiReflexPlatformID}",
|
|
||||||
"datas" :
|
|
||||||
<#include "RFXtoRP_HsaCarrier_ActorUpdated.ftl">
|
|
||||||
}
|
|
||||||
]
|
|
||||||
<#else>
|
|
||||||
[
|
[
|
||||||
{
|
{
|
||||||
<#assign apiReflexPlatformID = ApiReflexPlatformID.ActorCreated>
|
<#assign apiReflexPlatformID = ApiReflexPlatformID.ActorCreated>
|
||||||
@@ -42,7 +23,6 @@
|
|||||||
<#include "RFXtoRP_HsaCarrier_ActorCreated.ftl">
|
<#include "RFXtoRP_HsaCarrier_ActorCreated.ftl">
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
</#if>
|
|
||||||
<#break>
|
<#break>
|
||||||
|
|
||||||
<#case "D">
|
<#case "D">
|
||||||
|
|||||||
@@ -1,3 +1,6 @@
|
|||||||
|
<#include "ReflexUtils.ftl">
|
||||||
|
<#include "HfRpConfig.ftl">
|
||||||
|
<#include "ActorPrefix.ftl">
|
||||||
[
|
[
|
||||||
{
|
{
|
||||||
"Header": {
|
"Header": {
|
||||||
|
|||||||
@@ -1,3 +1,6 @@
|
|||||||
|
<#include "ReflexUtils.ftl">
|
||||||
|
<#include "HfRpConfig.ftl">
|
||||||
|
<#include "ActorPrefix.ftl">
|
||||||
[
|
[
|
||||||
{
|
{
|
||||||
"Header": {
|
"Header": {
|
||||||
|
|||||||
@@ -1,75 +0,0 @@
|
|||||||
[
|
|
||||||
{
|
|
||||||
"Header": {
|
|
||||||
"ProjectID": "${projectRP}"
|
|
||||||
},
|
|
||||||
"ID": {
|
|
||||||
"RefID": "${RFXtoRPprefixCarrier(carrier.carrier_code?trim?json_string)}"
|
|
||||||
},
|
|
||||||
"Payload": {
|
|
||||||
"Name": "${carrier.carrier_designation?json_string}",
|
|
||||||
"PartnerID" : "${actorRP.Objects[0].Payload.PartnerID!""?json_string}",
|
|
||||||
"IsCarrier" : ${(actorRP.Objects[0].Payload.IsCarrier!false)?c},
|
|
||||||
"ManagedStock": ${(actorRP.Objects[0].Payload.ManagedStock!false)?c},
|
|
||||||
"IsShipFromConnected": ${(actorRP.Objects[0].Payload.IsShipFromConnected!false)?c},
|
|
||||||
<#if actorRP.Objects[0].Payload.IsShipFromConnected?? && actorRP.Objects[0].Payload.IsShipFromConnected>
|
|
||||||
"ShipFromPartnerAppID" : "${actorRP.Objects[0].Payload.ShipFromPartnerAppID!""?json_string}",
|
|
||||||
</#if>
|
|
||||||
"IsShipToConnected": ${(actorRP.Objects[0].Payload.IsShipToConnected!false)?c},
|
|
||||||
<#if actorRP.Objects[0].Payload.IsShipToConnected?? && actorRP.Objects[0].Payload.IsShipToConnected>
|
|
||||||
"ShipToPartnerAppID" : "${actorRP.Objects[0].Payload.ShipToPartnerAppID!""?json_string}",
|
|
||||||
</#if>
|
|
||||||
"PhotoURI": "${actorRP.Objects[0].Payload.PhotoURI!""}",
|
|
||||||
<#if actorRP.Objects[0].Payload.CarrierServices??>
|
|
||||||
"CarrierServices" : [
|
|
||||||
<#list actorRP.Objects[0].Payload.CarrierServices as carrierService>
|
|
||||||
{
|
|
||||||
"ID" : "${carrierService.ID!""}",
|
|
||||||
"Label" : "${carrierService.Label!""}"
|
|
||||||
}<#sep>,</#sep>
|
|
||||||
</#list>
|
|
||||||
],
|
|
||||||
</#if>
|
|
||||||
<#include "RFXtoRP_HsaCons_ActorCreated_Metadata.ftl">,
|
|
||||||
|
|
||||||
"Address":
|
|
||||||
{
|
|
||||||
|
|
||||||
<#-- if Reflex WMS is structured -->
|
|
||||||
<#if carrier.carrier_structured_address??>
|
|
||||||
|
|
||||||
"Name": "${carrier.carrier_structured_address.name_or_company?json_string}",
|
|
||||||
"StreetAddressOne" : "${carrier.carrier_structured_address.street_and_PO?json_string}",
|
|
||||||
"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}",
|
|
||||||
<#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" : "",
|
|
||||||
</#if>
|
|
||||||
"ProvinceCode": "${carrier.carrier_structured_address.territorial_div_code?json_string}",
|
|
||||||
"State": "${carrier.carrier_structured_address.country_designation?json_string}"
|
|
||||||
|
|
||||||
<#-- if Reflex WMS is not structured -->
|
|
||||||
<#else>
|
|
||||||
<#if carrier.address?? >
|
|
||||||
|
|
||||||
"Name": "${carrier.address.company_name?json_string}",
|
|
||||||
"StreetAddressOne" : "${carrier.address.address_1?json_string}",
|
|
||||||
"StreetAddressTwo" : "${carrier.address.address_2?json_string}",
|
|
||||||
"StreetAddressThree" : "${carrier.address.address_3?json_string}",
|
|
||||||
"CountryCode" : ""
|
|
||||||
</#if>
|
|
||||||
</#if>
|
|
||||||
},
|
|
||||||
<#if carrier.address?? >
|
|
||||||
"Phones": ["${carrier.address.telephone?json_string}",
|
|
||||||
"${carrier.address.other_number?json_string}"
|
|
||||||
],
|
|
||||||
</#if>
|
|
||||||
"Typology": "TYPOLOGY_UNKNOWN"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
]
|
|
||||||
@@ -2,10 +2,6 @@
|
|||||||
<#-- input : message RFX -->
|
<#-- input : message RFX -->
|
||||||
<#-- project : projectId in ReflexPlatform -->
|
<#-- project : projectId in ReflexPlatform -->
|
||||||
<#-- organisation : organisationtId in ReflexPlatform -->
|
<#-- organisation : organisationtId in ReflexPlatform -->
|
||||||
<#include "ReflexUtils.ftl">
|
|
||||||
<#include "HfRpConfig.ftl">
|
|
||||||
<#include "ActorPrefix.ftl">
|
|
||||||
|
|
||||||
|
|
||||||
<#assign cloudEventMsg = JsonUtil.jsonToMap(input)>
|
<#assign cloudEventMsg = JsonUtil.jsonToMap(input)>
|
||||||
<#assign projectRP = project>
|
<#assign projectRP = project>
|
||||||
@@ -19,22 +15,6 @@
|
|||||||
<#-- *********************************************** Action = CREATE or UPDATE ******************** -->
|
<#-- *********************************************** Action = CREATE or UPDATE ******************** -->
|
||||||
<#assign dataRfx = JsonUtil.decodeBase64(cloudEventMsg.data) />
|
<#assign dataRfx = JsonUtil.decodeBase64(cloudEventMsg.data) />
|
||||||
<#assign actor = JsonUtil.jsonToMap(dataRfx)>
|
<#assign actor = JsonUtil.jsonToMap(dataRfx)>
|
||||||
<#assign refID = RFXtoRPprefixConsignee(actor.code?trim?json_string)>
|
|
||||||
|
|
||||||
<#assign payLoad = '{"Header": {"ProjectID": "${projectRP!""}"},"IDs": [{"RefID": "${refID}"}]}' />
|
|
||||||
<#assign queryApiReflexPlatformID = QueryApiReflexPlatformID.ActorGetByIds>
|
|
||||||
<#assign response = QueryApiReflexPlatformCall.call(queryApiReflexPlatformID,payLoad) />
|
|
||||||
<#assign actorRP = JsonUtil.jsonToMap(response)>
|
|
||||||
<#if actorRP?? && actorRP.Objects?? && actorRP.Objects[0]?? && actorRP.Objects[0].ID.RefID?? >
|
|
||||||
[
|
|
||||||
{
|
|
||||||
<#assign apiReflexPlatformID = ApiReflexPlatformID.ActorCreated>
|
|
||||||
"apiReflexPlatformID" : "${apiReflexPlatformID}",
|
|
||||||
"datas" :
|
|
||||||
<#include "RFXtoRP_HsaCons_ActorUpdated.ftl">
|
|
||||||
}
|
|
||||||
]
|
|
||||||
<#else>
|
|
||||||
[
|
[
|
||||||
{
|
{
|
||||||
<#assign apiReflexPlatformID = ApiReflexPlatformID.ActorCreated>
|
<#assign apiReflexPlatformID = ApiReflexPlatformID.ActorCreated>
|
||||||
@@ -43,7 +23,6 @@
|
|||||||
<#include "RFXtoRP_HsaCons_ActorCreated.ftl">
|
<#include "RFXtoRP_HsaCons_ActorCreated.ftl">
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
</#if>
|
|
||||||
<#break>
|
<#break>
|
||||||
|
|
||||||
<#case "D">
|
<#case "D">
|
||||||
|
|||||||
@@ -1,3 +1,6 @@
|
|||||||
|
<#include "ReflexUtils.ftl">
|
||||||
|
<#include "HfRpConfig.ftl">
|
||||||
|
<#include "ActorPrefix.ftl">
|
||||||
[
|
[
|
||||||
{
|
{
|
||||||
"Header": {
|
"Header": {
|
||||||
|
|||||||
@@ -1,3 +1,6 @@
|
|||||||
|
<#include "ReflexUtils.ftl">
|
||||||
|
<#include "HfRpConfig.ftl">
|
||||||
|
<#include "ActorPrefix.ftl">
|
||||||
[
|
[
|
||||||
{
|
{
|
||||||
"Header": {
|
"Header": {
|
||||||
|
|||||||
@@ -1,75 +0,0 @@
|
|||||||
[
|
|
||||||
{
|
|
||||||
"Header": {
|
|
||||||
"ProjectID": "${projectRP}"
|
|
||||||
},
|
|
||||||
"ID": {
|
|
||||||
"RefID": "${RFXtoRPprefixConsignee(actor.code?trim?json_string)}"
|
|
||||||
},
|
|
||||||
"Payload": {
|
|
||||||
"Name": "${actor.designation?json_string}",
|
|
||||||
"PartnerID" : "${actorRP.Objects[0].Payload.PartnerID!""?json_string}",
|
|
||||||
"IsCarrier" : ${(actorRP.Objects[0].Payload.IsCarrier!false)?c},
|
|
||||||
"ManagedStock": ${(actorRP.Objects[0].Payload.ManagedStock!false)?c},
|
|
||||||
"IsShipFromConnected": ${(actorRP.Objects[0].Payload.IsShipFromConnected!false)?c},
|
|
||||||
<#if actorRP.Objects[0].Payload.IsShipFromConnected?? && actorRP.Objects[0].Payload.IsShipFromConnected>
|
|
||||||
"ShipFromPartnerAppID" : "${actorRP.Objects[0].Payload.ShipFromPartnerAppID!""?json_string}",
|
|
||||||
</#if>
|
|
||||||
"IsShipToConnected": ${(actorRP.Objects[0].Payload.IsShipToConnected!false)?c},
|
|
||||||
<#if actorRP.Objects[0].Payload.IsShipToConnected?? && actorRP.Objects[0].Payload.IsShipToConnected>
|
|
||||||
"ShipToPartnerAppID" : "${actorRP.Objects[0].Payload.ShipToPartnerAppID!""?json_string}",
|
|
||||||
</#if>
|
|
||||||
"PhotoURI": "${actorRP.Objects[0].Payload.PhotoURI!""}",
|
|
||||||
<#if actorRP.Objects[0].Payload.CarrierServices??>
|
|
||||||
"CarrierServices" : [
|
|
||||||
<#list actorRP.Objects[0].Payload.CarrierServices as carrierService>
|
|
||||||
{
|
|
||||||
"ID" : "${carrierService.ID!""}",
|
|
||||||
"Label" : "${carrierService.Label!""}"
|
|
||||||
}<#sep>,</#sep>
|
|
||||||
</#list>
|
|
||||||
],
|
|
||||||
</#if>
|
|
||||||
<#include "RFXtoRP_HsaCons_ActorCreated_Metadata.ftl">,
|
|
||||||
|
|
||||||
"Address":
|
|
||||||
{
|
|
||||||
|
|
||||||
<#-- if Reflex WMS is structured -->
|
|
||||||
<#if actor.consignee_structured_address??>
|
|
||||||
|
|
||||||
"Name": "${actor.consignee_structured_address.name_or_company?json_string}",
|
|
||||||
"StreetAddressOne" : "${actor.consignee_structured_address.street_and_PO?json_string}",
|
|
||||||
"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}",
|
|
||||||
<#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" : "",
|
|
||||||
</#if>
|
|
||||||
"ProvinceCode": "${actor.consignee_structured_address.territorial_div_code?json_string}",
|
|
||||||
"State": "${actor.consignee_structured_address.country_designation?json_string}"
|
|
||||||
|
|
||||||
<#-- if Reflex WMS is not structured -->
|
|
||||||
<#else>
|
|
||||||
<#if actor.address?? >
|
|
||||||
|
|
||||||
"Name": "${actor.address.company_name?json_string}",
|
|
||||||
"StreetAddressOne" : "${actor.address.address_1?json_string}",
|
|
||||||
"StreetAddressTwo" : "${actor.address.address_2?json_string}",
|
|
||||||
"StreetAddressThree" : "${actor.address.address_3?json_string}",
|
|
||||||
"CountryCode" : ""
|
|
||||||
</#if>
|
|
||||||
</#if>
|
|
||||||
},
|
|
||||||
<#if actor.address?? >
|
|
||||||
"Phones": ["${actor.address.telephone?json_string}",
|
|
||||||
"${actor.address.other_number?json_string}"
|
|
||||||
],
|
|
||||||
</#if>
|
|
||||||
"Typology": "TYPOLOGY_UNKNOWN"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
]
|
|
||||||
@@ -39,30 +39,29 @@
|
|||||||
</#if>
|
</#if>
|
||||||
"Value": "${dispute.dispute_amount}"
|
"Value": "${dispute.dispute_amount}"
|
||||||
},
|
},
|
||||||
<#-- To configure -->
|
|
||||||
<#include "RFXtoRP_HsaDispute_TableReasonCodeToClaimTypeID.ftl">
|
|
||||||
<#if dispute.dispute_type_code=="050" >
|
<#if dispute.dispute_type_code=="050" >
|
||||||
<#if dispute.dispute_preparation.preparation_order_list?? && dispute.dispute_preparation.preparation_order_list?size != 0>
|
<#if dispute.dispute_preparation.preparation_order_list?? && dispute.dispute_preparation.preparation_order_list?size != 0>
|
||||||
"EntityID":"${dispute.dispute_preparation.preparation_order_list[0].preparation_order_contractor_reference?trim?json_string}",
|
"EntityID":"${dispute.dispute_preparation.preparation_order_list[0].preparation_order_contractor_reference?trim?json_string}",
|
||||||
<#if TableReasonCode[dispute.dispute_reason_code]??>
|
|
||||||
"ClaimTypeID":"CLAIMTYPE_${projectRP}_ORDER_${TableReasonCode[dispute.dispute_reason_code]}"
|
|
||||||
<#else>
|
<#else>
|
||||||
<#stop "preparation order list is empty" >
|
<#stop "preparation order list is empty" >
|
||||||
</#if>
|
</#if>
|
||||||
</#if>
|
|
||||||
<#else>
|
<#else>
|
||||||
<#if dispute.dispute_type_code=="070" || dispute.dispute_type_code=="030" >
|
<#if dispute.dispute_type_code=="070" || dispute.dispute_type_code=="030" >
|
||||||
"EntityID":"${dispute.dispute_reception.reception_reference?trim?json_string}",
|
"EntityID":"${dispute.dispute_reception.reception_reference?trim?json_string}",
|
||||||
<#if TableReasonCode[dispute.dispute_reason_code]??>
|
|
||||||
"ClaimTypeID":"CLAIMTYPE_${projectRP}_ORDER_${TableReasonCode[dispute.dispute_reason_code]}"
|
|
||||||
<#else>
|
<#else>
|
||||||
<#stop "Type not supported" >
|
<#stop "Type not supported" >
|
||||||
</#if>
|
</#if>
|
||||||
</#if>
|
</#if>
|
||||||
|
<#-- To configure -->
|
||||||
|
<#include "RFXtoRP_HsaDispute_TableReasonCodeToClaimTypeID.ftl">
|
||||||
|
|
||||||
|
<#if TableReasonCode[dispute.dispute_reason_code]??>
|
||||||
|
"ClaimTypeID":"${TableReasonCode[dispute.dispute_reason_code]}"
|
||||||
|
<#else>
|
||||||
|
<#stop "Claim reason code not supported" >
|
||||||
</#if>
|
</#if>
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -54,7 +54,7 @@
|
|||||||
"ExternalMoveRef" : "${reflexMvtStockInterface.ipg_move_year_number} - ${reflexMvtStockInterface.ipg_move_number}",
|
"ExternalMoveRef" : "${reflexMvtStockInterface.ipg_move_year_number} - ${reflexMvtStockInterface.ipg_move_number}",
|
||||||
"Type": "${MoveType_KV[reflexMvtStockInterface.ipg_move_type]!reflexMvtStockInterface.ipg_move_type}",
|
"Type": "${MoveType_KV[reflexMvtStockInterface.ipg_move_type]!reflexMvtStockInterface.ipg_move_type}",
|
||||||
<#if reflexMvtStockInterface.ipg_move_type == "520" >
|
<#if reflexMvtStockInterface.ipg_move_type == "520" >
|
||||||
"Reason": " Direct Transfert ${RFXtoRPprefixDepot(reflexMvtStockInterface.physical_depot_code?trim?json_string)} to ${RFXtoRPprefixDepot(reflexMvtStockInterface.transfer_consignee_physical_depot_code?trim?json_string)}",
|
"Reason": " Transfert ${RFXtoRPprefixDepot(reflexMvtStockInterface.physical_depot_code?trim?json_string)} to ${RFXtoRPprefixDepot(reflexMvtStockInterface.transfer_consignee_physical_depot_code?trim?json_string)}",
|
||||||
<#else>
|
<#else>
|
||||||
"Reason": "${reflexMvtStockInterface.miscellaneous_receipts_despatches_code?json_string}",
|
"Reason": "${reflexMvtStockInterface.miscellaneous_receipts_despatches_code?json_string}",
|
||||||
</#if>
|
</#if>
|
||||||
|
|||||||
@@ -2,9 +2,6 @@
|
|||||||
<#-- input : message RFX -->
|
<#-- input : message RFX -->
|
||||||
<#-- project : projectId in ReflexPlatform -->
|
<#-- project : projectId in ReflexPlatform -->
|
||||||
<#-- organisation : organisationtId in ReflexPlatform -->
|
<#-- organisation : organisationtId in ReflexPlatform -->
|
||||||
<#include "ReflexUtils.ftl">
|
|
||||||
<#include "HfRpConfig.ftl">
|
|
||||||
<#include "ActorPrefix.ftl">
|
|
||||||
|
|
||||||
<#assign cloudEventMsg = JsonUtil.jsonToMap(input)>
|
<#assign cloudEventMsg = JsonUtil.jsonToMap(input)>
|
||||||
<#assign projectRP = project>
|
<#assign projectRP = project>
|
||||||
@@ -18,22 +15,6 @@
|
|||||||
<#-- *********************************************** Action = CREATE or UPDATE ******************** -->
|
<#-- *********************************************** Action = CREATE or UPDATE ******************** -->
|
||||||
<#assign dataRfx = JsonUtil.decodeBase64(cloudEventMsg.data) />
|
<#assign dataRfx = JsonUtil.decodeBase64(cloudEventMsg.data) />
|
||||||
<#assign actor = JsonUtil.jsonToMap(dataRfx)>
|
<#assign actor = JsonUtil.jsonToMap(dataRfx)>
|
||||||
<#assign refID = RFXtoRPprefixSupplier(actor.code?trim?json_string)>
|
|
||||||
|
|
||||||
<#assign payLoad = '{"Header": {"ProjectID": "${projectRP!""}"},"IDs": [{"RefID": "${refID}"}]}' />
|
|
||||||
<#assign queryApiReflexPlatformID = QueryApiReflexPlatformID.ActorGetByIds>
|
|
||||||
<#assign response = QueryApiReflexPlatformCall.call(queryApiReflexPlatformID,payLoad) />
|
|
||||||
<#assign actorRP = JsonUtil.jsonToMap(response)>
|
|
||||||
<#if actorRP?? && actorRP.Objects?? && actorRP.Objects[0]?? && actorRP.Objects[0].ID.RefID?? >
|
|
||||||
[
|
|
||||||
{
|
|
||||||
<#assign apiReflexPlatformID = ApiReflexPlatformID.ActorCreated>
|
|
||||||
"apiReflexPlatformID" : "${apiReflexPlatformID}",
|
|
||||||
"datas" :
|
|
||||||
<#include "RFXtoRP_HsaSup_ActorUpdated.ftl">
|
|
||||||
}
|
|
||||||
]
|
|
||||||
<#else>
|
|
||||||
[
|
[
|
||||||
{
|
{
|
||||||
<#assign apiReflexPlatformID = ApiReflexPlatformID.ActorCreated>
|
<#assign apiReflexPlatformID = ApiReflexPlatformID.ActorCreated>
|
||||||
@@ -42,7 +23,6 @@
|
|||||||
<#include "RFXtoRP_HsaSup_ActorCreated.ftl">
|
<#include "RFXtoRP_HsaSup_ActorCreated.ftl">
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
</#if>
|
|
||||||
<#break>
|
<#break>
|
||||||
|
|
||||||
<#case "D">
|
<#case "D">
|
||||||
|
|||||||
@@ -1,3 +1,6 @@
|
|||||||
|
<#include "ReflexUtils.ftl">
|
||||||
|
<#include "HfRpConfig.ftl">
|
||||||
|
<#include "ActorPrefix.ftl">
|
||||||
[
|
[
|
||||||
{
|
{
|
||||||
"Header": {
|
"Header": {
|
||||||
|
|||||||
@@ -1,3 +1,6 @@
|
|||||||
|
<#include "ReflexUtils.ftl">
|
||||||
|
<#include "HfRpConfig.ftl">
|
||||||
|
<#include "ActorPrefix.ftl">
|
||||||
[
|
[
|
||||||
{
|
{
|
||||||
"Header": {
|
"Header": {
|
||||||
|
|||||||
@@ -1,75 +0,0 @@
|
|||||||
[
|
|
||||||
{
|
|
||||||
"Header": {
|
|
||||||
"ProjectID": "${projectRP}"
|
|
||||||
},
|
|
||||||
"ID": {
|
|
||||||
"RefID": "${RFXtoRPprefixSupplier(actor.code?trim?json_string)}"
|
|
||||||
},
|
|
||||||
"Payload": {
|
|
||||||
"Name": "${actor.designation?json_string}",
|
|
||||||
"PartnerID" : "${actorRP.Objects[0].Payload.PartnerID!""?json_string}",
|
|
||||||
"IsCarrier" : ${(actorRP.Objects[0].Payload.IsCarrier!false)?c},
|
|
||||||
"ManagedStock": ${(actorRP.Objects[0].Payload.ManagedStock!false)?c},
|
|
||||||
"IsShipFromConnected": ${(actorRP.Objects[0].Payload.IsShipFromConnected!false)?c},
|
|
||||||
<#if actorRP.Objects[0].Payload.IsShipFromConnected?? && actorRP.Objects[0].Payload.IsShipFromConnected>
|
|
||||||
"ShipFromPartnerAppID" : "${actorRP.Objects[0].Payload.ShipFromPartnerAppID!""?json_string}",
|
|
||||||
</#if>
|
|
||||||
"IsShipToConnected": ${(actorRP.Objects[0].Payload.IsShipToConnected!false)?c},
|
|
||||||
<#if actorRP.Objects[0].Payload.IsShipToConnected?? && actorRP.Objects[0].Payload.IsShipToConnected>
|
|
||||||
"ShipToPartnerAppID" : "${actorRP.Objects[0].Payload.ShipToPartnerAppID!""?json_string}",
|
|
||||||
</#if>
|
|
||||||
"PhotoURI": "${actorRP.Objects[0].Payload.PhotoURI!""}",
|
|
||||||
<#if actorRP.Objects[0].Payload.CarrierServices??>
|
|
||||||
"CarrierServices" : [
|
|
||||||
<#list actorRP.Objects[0].Payload.CarrierServices as carrierService>
|
|
||||||
{
|
|
||||||
"ID" : "${carrierService.ID!""}",
|
|
||||||
"Label" : "${carrierService.Label!""}"
|
|
||||||
}<#sep>,</#sep>
|
|
||||||
</#list>
|
|
||||||
],
|
|
||||||
</#if>
|
|
||||||
<#include "RFXtoRP_HsaCons_ActorCreated_Metadata.ftl">,
|
|
||||||
|
|
||||||
"Address":
|
|
||||||
{
|
|
||||||
|
|
||||||
<#-- if Reflex WMS is structured -->
|
|
||||||
<#if actor.supplier_structured_address??>
|
|
||||||
|
|
||||||
"Name": "${actor.supplier_structured_address.name_or_company?json_string}",
|
|
||||||
"StreetAddressOne" : "${actor.supplier_structured_address.street_and_PO?json_string}",
|
|
||||||
"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}",
|
|
||||||
<#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" : "",
|
|
||||||
</#if>
|
|
||||||
"ProvinceCode": "${actor.supplier_structured_address.territorial_div_code?json_string}",
|
|
||||||
"State": "${actor.supplier_structured_address.country_designation?json_string}"
|
|
||||||
|
|
||||||
<#-- if Reflex WMS is not structured -->
|
|
||||||
<#else>
|
|
||||||
<#if actor.optional_attributes?? >
|
|
||||||
|
|
||||||
"Name": "${actor.optional_attributes.company_name?json_string}",
|
|
||||||
"StreetAddressOne" : "${actor.optional_attributes.address_1?json_string}",
|
|
||||||
"StreetAddressTwo" : "${actor.optional_attributes.address_2?json_string}",
|
|
||||||
"StreetAddressThree" : "${actor.optional_attributes.address_3?json_string}",
|
|
||||||
"CountryCode" : ""
|
|
||||||
</#if>
|
|
||||||
</#if>
|
|
||||||
},
|
|
||||||
<#if actor.optional_attributes?? >
|
|
||||||
"Phones": ["${actor.optional_attributes.telephone?json_string}",
|
|
||||||
"${actor.optional_attributes.other_number?json_string}"
|
|
||||||
],
|
|
||||||
</#if>
|
|
||||||
"Typology": "TYPOLOGY_UNKNOWN"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
]
|
|
||||||
@@ -6,7 +6,6 @@
|
|||||||
<#assign cloudEventMsg = JsonUtil.jsonToMap(input)>
|
<#assign cloudEventMsg = JsonUtil.jsonToMap(input)>
|
||||||
<#assign projectRP = project>
|
<#assign projectRP = project>
|
||||||
<#assign organisationRP = organisation>
|
<#assign organisationRP = organisation>
|
||||||
<#include "RFX_PartnerAPP_Settings.ftl">
|
|
||||||
|
|
||||||
<#assign aDateTime = .now>
|
<#assign aDateTime = .now>
|
||||||
|
|
||||||
@@ -55,7 +54,7 @@
|
|||||||
<#list preparationOrder.preparation_line_lst?filter(l ->l.despatched_ipg_list?? && l.preparation_order_originator_reference!="") as preparation_line>
|
<#list preparationOrder.preparation_line_lst?filter(l ->l.despatched_ipg_list?? && l.preparation_order_originator_reference!="") as preparation_line>
|
||||||
<#list preparation_line.despatched_ipg_list as despatched_ipg>
|
<#list preparation_line.despatched_ipg_list as despatched_ipg>
|
||||||
<#assign HUadded_packing_datetime = RfxDateTimetoUTCWithTimezone(preparation_line.confirmation_datetime,time_zone_rfx) />
|
<#assign HUadded_packing_datetime = RfxDateTimetoUTCWithTimezone(preparation_line.confirmation_datetime,time_zone_rfx) />
|
||||||
<#if !hd_numberHmap[despatched_ipg.hd_number]?? && (trackingNumberSource==2 || trackingNumberSource==3 || (despatched_ipg.consignment_unit_id!="" && trackingNumberSource==1))>
|
<#if !hd_numberHmap[despatched_ipg.hd_number]?? >
|
||||||
<#assign hd_numberHmap += {despatched_ipg.hd_number,despatched_ipg.hd_number}>
|
<#assign hd_numberHmap += {despatched_ipg.hd_number,despatched_ipg.hd_number}>
|
||||||
,
|
,
|
||||||
{
|
{
|
||||||
@@ -79,7 +78,7 @@
|
|||||||
"datas" :
|
"datas" :
|
||||||
<#include "RFXtoRP_HsrPrepa_HUsAdded_HandlingUnitDispatched.ftl">
|
<#include "RFXtoRP_HsrPrepa_HUsAdded_HandlingUnitDispatched.ftl">
|
||||||
}
|
}
|
||||||
<#if !hd_numberHmapHUadded[despatched_ipg.hd_number]?? && (trackingNumberSource==2 || trackingNumberSource==3 )>
|
<#if !hd_numberHmapHUadded[despatched_ipg.hd_number]??>
|
||||||
<#assign hd_numberHmapHUadded += {despatched_ipg.hd_number,despatched_ipg.hd_number}>
|
<#assign hd_numberHmapHUadded += {despatched_ipg.hd_number,despatched_ipg.hd_number}>
|
||||||
,
|
,
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,7 +1,6 @@
|
|||||||
<#include "HfRpConfig.ftl">
|
<#include "HfRpConfig.ftl">
|
||||||
<#include "ReflexUtils.ftl">
|
<#include "ReflexUtils.ftl">
|
||||||
<#include "ActorPrefix.ftl">
|
<#include "ActorPrefix.ftl">
|
||||||
<#include "RFX_PartnerAPP_Settings.ftl">
|
|
||||||
[
|
[
|
||||||
<#assign dispatched_datetime4 = RfxDateTimetoUTCWithTimezone(preparationOrder.stock_despatch_at_preparation_datetime,time_zone_rfx) />
|
<#assign dispatched_datetime4 = RfxDateTimetoUTCWithTimezone(preparationOrder.stock_despatch_at_preparation_datetime,time_zone_rfx) />
|
||||||
{
|
{
|
||||||
@@ -9,20 +8,6 @@
|
|||||||
"ProjectID": "${projectRP}"
|
"ProjectID": "${projectRP}"
|
||||||
},
|
},
|
||||||
"ID": {
|
"ID": {
|
||||||
<#switch trackingNumberSource>
|
|
||||||
<#case 1>
|
|
||||||
<#if despatched_ipg.consignment_unit_id!="">
|
|
||||||
"RefID": "${despatched_ipg.consignment_unit_id?trim?json_string}",
|
|
||||||
</#if>
|
|
||||||
<#break>
|
|
||||||
<#case 2>
|
|
||||||
<#if despatched_ipg.carton_number != "000000000000000000">
|
|
||||||
"RefID":"${despatched_ipg.carton_number}",
|
|
||||||
<#else>
|
|
||||||
"RefID":"${despatched_ipg.hd_number}",
|
|
||||||
</#if>
|
|
||||||
<#break>
|
|
||||||
<#case 3>
|
|
||||||
<#if despatched_ipg.consignment_unit_id!="">
|
<#if despatched_ipg.consignment_unit_id!="">
|
||||||
"RefID": "${despatched_ipg.consignment_unit_id?trim?json_string}",
|
"RefID": "${despatched_ipg.consignment_unit_id?trim?json_string}",
|
||||||
<#else>
|
<#else>
|
||||||
@@ -32,18 +17,6 @@
|
|||||||
"RefID":"${despatched_ipg.hd_number}",
|
"RefID":"${despatched_ipg.hd_number}",
|
||||||
</#if>
|
</#if>
|
||||||
</#if>
|
</#if>
|
||||||
<#break>
|
|
||||||
<#default>
|
|
||||||
<#if despatched_ipg.consignment_unit_id!="">
|
|
||||||
"RefID": "${despatched_ipg.consignment_unit_id?trim?json_string}",
|
|
||||||
<#else>
|
|
||||||
<#if despatched_ipg.carton_number != "000000000000000000">
|
|
||||||
"RefID":"${despatched_ipg.carton_number}",
|
|
||||||
<#else>
|
|
||||||
"RefID":"${despatched_ipg.hd_number}",
|
|
||||||
</#if>
|
|
||||||
</#if>
|
|
||||||
</#switch>
|
|
||||||
|
|
||||||
"RefDate": {
|
"RefDate": {
|
||||||
"DateTime": "${dispatched_datetime4}",
|
"DateTime": "${dispatched_datetime4}",
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
[
|
[
|
||||||
{
|
{
|
||||||
<#assign planned_final_delivery_start_datetime = RfxDateTimetoUTCWithTimezone(preparation_order.planned_final_delivery_start_datetime,time_zone_rfx) />
|
<#assign planned_final_delivery_start_datetime = RfxDateTimetoUTCWithTimezone(preparation_order.planned_final_delivery_start_datetime,time_zone_rfx) />
|
||||||
<#assign pro_creation_datetime = RfxDateTimetoUTCWithTimezoneWithTimezone(preparation_order.creation_datetime,time_zone_rfx) />
|
<#assign pro_creation_datetime = RfxDateTimetoUTCWithTimezone(preparation_order.creation_datetime,time_zone_rfx) />
|
||||||
"Header": {
|
"Header": {
|
||||||
"ProjectID": "${projectRP}"
|
"ProjectID": "${projectRP}"
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
[
|
[
|
||||||
{
|
{
|
||||||
<#assign receipt_datetime = RfxDateTimetoUTCWithTimezone(receipt.receipt_datetime,time_zone_rfx) />
|
<#assign receipt_datetime = RfxDateTimetoUTCWithTimezone(receipt.receipt_datetime,time_zone_rfx) />
|
||||||
<#assign receipt_creation_datetime = RfxDateTimetoUTCWithTimezoneWithTimezone(receipt.creation_datetime,time_zone_rfx) />
|
<#assign receipt_creation_datetime = RfxDateTimetoUTCWithTimezone(receipt.creation_datetime,time_zone_rfx) />
|
||||||
"Header": {
|
"Header": {
|
||||||
"ProjectID": "${projectRP}"
|
"ProjectID": "${projectRP}"
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
<#include "HfRpConfig.ftl">
|
<#include "HfRpConfig.ftl">
|
||||||
<#include "ReflexUtils.ftl">
|
<#include "ReflexUtils.ftl">
|
||||||
<#assign receipt_status_datetime = RfxDateTimetoUTCWithTimezoneWithTimezone(receipt.confirmation_datetime,time_zone_rfx) />
|
<#assign receipt_status_datetime = RfxDateTimetoUTCWithTimezone(receipt.confirmation_datetime,time_zone_rfx) />
|
||||||
[
|
[
|
||||||
{
|
{
|
||||||
"Header": {
|
"Header": {
|
||||||
|
|||||||
@@ -25,8 +25,8 @@
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
<#noparse><#assign time_zone_rfx = </#noparse>"${file.author_time_zone!"UTC"}<#noparse>"></#noparse>
|
<#noparse><#assign time_zone_rfx = </#noparse>"${file.author_time_zone!"Europe/Paris"}<#noparse>"></#noparse>
|
||||||
<#noparse><#assign time_zone_offset_rfx = </#noparse>"${file.time_zone_offset!"+00:00"}<#noparse>"></#noparse>
|
<#noparse><#assign time_zone_offset_rfx = </#noparse>"${file.time_zone_offset!"+01:00"}<#noparse>"></#noparse>
|
||||||
|
|
||||||
|
|
||||||
<#list file.reflex_platform_project_list?filter(l -> l.name == projectRP) as reflex_platform_project>
|
<#list file.reflex_platform_project_list?filter(l -> l.name == projectRP) as reflex_platform_project>
|
||||||
|
|||||||
@@ -9,11 +9,6 @@
|
|||||||
<#return dateutc?datetime.iso?iso_nz(locale)>
|
<#return dateutc?datetime.iso?iso_nz(locale)>
|
||||||
</#function>
|
</#function>
|
||||||
|
|
||||||
<#function RfxDateTimetoUTCWithTimezone rfxdatetime timezone>
|
|
||||||
<#setting time_zone=timezone>
|
|
||||||
<#return (rfxdatetime?datetime.iso?iso_utc)>
|
|
||||||
</#function>
|
|
||||||
|
|
||||||
<#-- --------------------------------------------------------------------------------------- -->
|
<#-- --------------------------------------------------------------------------------------- -->
|
||||||
<#-- Split email reflex into json array string -->
|
<#-- Split email reflex into json array string -->
|
||||||
<#-- Example : splitemail "john.doe@hardis-group.com,; name@hardis-group.com" -->
|
<#-- Example : splitemail "john.doe@hardis-group.com,; name@hardis-group.com" -->
|
||||||
|
|||||||
Reference in New Issue
Block a user