diff --git a/RFXtoRP_HfDtlStockLs_ActorSnapshotCompleted.ftl b/RFXtoRP_HfDtlStockLs_ActorSnapshotCompleted.ftl index e248350..f507c4a 100644 --- a/RFXtoRP_HfDtlStockLs_ActorSnapshotCompleted.ftl +++ b/RFXtoRP_HfDtlStockLs_ActorSnapshotCompleted.ftl @@ -11,7 +11,7 @@ "RefID": "${RFXtoRPprefixDepot(stock.physical_depot_code)}" }, "Payload": { - <#assign generation_date = RfxDateTimetoUTC(stock.generation_date,time_zone_offset_rfx) /> + <#assign generation_date = RfxDateTimetoUTCWithTimezone(stock.generation_date,time_zone_rfx) /> "Snapshot": { "EndDateTime": { "DateTime": "${generation_date}", diff --git a/RFXtoRP_HfDtlStockLs_StockSnapshotted.ftl b/RFXtoRP_HfDtlStockLs_StockSnapshotted.ftl index fcf0f0c..4914bac 100644 --- a/RFXtoRP_HfDtlStockLs_StockSnapshotted.ftl +++ b/RFXtoRP_HfDtlStockLs_StockSnapshotted.ftl @@ -9,7 +9,7 @@ }, "Payload": { "ActorID": "${RFXtoRPprefixDepot(stock.physical_depot_code)}", - <#assign generation_date = RfxDateTimetoUTC(stock.generation_date,time_zone_offset_rfx) /> + <#assign generation_date = RfxDateTimetoUTCWithTimezone(stock.generation_date,time_zone_rfx) /> "Snapshot": { "DateTime": { "DateTime": "${generation_date}", diff --git a/RFXtoRP_HfDtlStockLs_StockSnapshotted_SegmentationKeys.ftl b/RFXtoRP_HfDtlStockLs_StockSnapshotted_SegmentationKeys.ftl index a26d58e..9a24817 100644 --- a/RFXtoRP_HfDtlStockLs_StockSnapshotted_SegmentationKeys.ftl +++ b/RFXtoRP_HfDtlStockLs_StockSnapshotted_SegmentationKeys.ftl @@ -17,21 +17,21 @@ "Value": { "String" : "no batch"} <#else> "Value": { "String" : "${stock.batch_1}"} - + }, { "Key": "HeldForSpecificCode", "Value": { "Bool" : "${stock.held_for_specific_code}"} }, - + { - <#assign manufacturing_datetime = RfxDateTimetoUTC(stock.Date_of_manufacture,time_zone_offset_rfx) /> + <#assign manufacturing_datetime = RfxDateTimetoUTCWithTimezone(stock.Date_of_manufacture,time_zone_rfx) /> "Key": "ManufacturingDate", "Value": "Timestamp": { "AuthorTimeZone": "${time_zone_rfx}", "DateTime": "${manufacturing_datetime}" } - } + } ] --> diff --git a/RFXtoRP_HsaIpgMove_GoodsReceived.ftl b/RFXtoRP_HsaIpgMove_GoodsReceived.ftl index 8653828..8ab1721 100644 --- a/RFXtoRP_HsaIpgMove_GoodsReceived.ftl +++ b/RFXtoRP_HsaIpgMove_GoodsReceived.ftl @@ -2,7 +2,7 @@ <#include "ReflexUtils.ftl"> <#include "ActorPrefix.ftl"> [ - <#assign receipt_confirmation_datetime = RfxDateTimetoUTC(reflexMvtStockInterface.ipg_move_creation_datetime,time_zone_offset_rfx) /> + <#assign receipt_confirmation_datetime = RfxDateTimetoUTCWithTimezone(reflexMvtStockInterface.ipg_move_creation_datetime,time_zone_rfx) /> <#assign priority_date = reflexMvtStockInterface.ipg_priority_date?datetime(rfx_date_format_default)?iso_utc /> { "Header": { diff --git a/RFXtoRP_HsaIpgMove_StockMoved.ftl b/RFXtoRP_HsaIpgMove_StockMoved.ftl index d9d0fd7..8077536 100644 --- a/RFXtoRP_HsaIpgMove_StockMoved.ftl +++ b/RFXtoRP_HsaIpgMove_StockMoved.ftl @@ -21,7 +21,7 @@ "465":"STOCK_MOVEMENT_TYPE_FIX", "520":"STOCK_MOVEMENT_TYPE_OUTBOUND" }> -<#assign generation_date = RfxDateTimetoUTC(reflexMvtStockInterface.ipg_move_creation_datetime,time_zone_offset_rfx) /> +<#assign generation_date = RfxDateTimetoUTCWithTimezone(reflexMvtStockInterface.ipg_move_creation_datetime,time_zone_rfx) /> <#assign ipg_priority_datetime = reflexMvtStockInterface.ipg_priority_date?datetime(rfx_date_format_default)?iso_utc /> [ { diff --git a/RFXtoRP_HsaProStatus_ExecutionflowCancelled.ftl b/RFXtoRP_HsaProStatus_ExecutionflowCancelled.ftl index 0a1b945..db1899a 100644 --- a/RFXtoRP_HsaProStatus_ExecutionflowCancelled.ftl +++ b/RFXtoRP_HsaProStatus_ExecutionflowCancelled.ftl @@ -1,6 +1,6 @@ <#include "HfRpConfig.ftl"> <#include "ReflexUtils.ftl"> -<#assign preparation_status_datetime = RfxDateTimetoUTC(preparationStatusInterface.preparation_status_datetime,time_zone_offset_rfx) /> +<#assign preparation_status_datetime = RfxDateTimetoUTCWithTimezone(preparationStatusInterface.preparation_status_datetime,time_zone_rfx) /> [ { diff --git a/RFXtoRP_HsaProStatus_PreparationCompleted.ftl b/RFXtoRP_HsaProStatus_PreparationCompleted.ftl index 7f9c79a..04c48ae 100644 --- a/RFXtoRP_HsaProStatus_PreparationCompleted.ftl +++ b/RFXtoRP_HsaProStatus_PreparationCompleted.ftl @@ -1,6 +1,6 @@ <#include "HfRpConfig.ftl"> <#include "ReflexUtils.ftl"> -<#assign preparation_status_datetime = RfxDateTimetoUTC(preparationStatusInterface.preparation_status_datetime,time_zone_offset_rfx) /> +<#assign preparation_status_datetime = RfxDateTimetoUTCWithTimezone(preparationStatusInterface.preparation_status_datetime,time_zone_rfx) /> [ { "Header": { diff --git a/RFXtoRP_HsaProStatus_PreparationExpected.ftl b/RFXtoRP_HsaProStatus_PreparationExpected.ftl index 7f9c79a..04c48ae 100644 --- a/RFXtoRP_HsaProStatus_PreparationExpected.ftl +++ b/RFXtoRP_HsaProStatus_PreparationExpected.ftl @@ -1,6 +1,6 @@ <#include "HfRpConfig.ftl"> <#include "ReflexUtils.ftl"> -<#assign preparation_status_datetime = RfxDateTimetoUTC(preparationStatusInterface.preparation_status_datetime,time_zone_offset_rfx) /> +<#assign preparation_status_datetime = RfxDateTimetoUTCWithTimezone(preparationStatusInterface.preparation_status_datetime,time_zone_rfx) /> [ { "Header": { diff --git a/RFXtoRP_HsaProStatus_PreparationStarted.ftl b/RFXtoRP_HsaProStatus_PreparationStarted.ftl index 7f9c79a..04c48ae 100644 --- a/RFXtoRP_HsaProStatus_PreparationStarted.ftl +++ b/RFXtoRP_HsaProStatus_PreparationStarted.ftl @@ -1,6 +1,6 @@ <#include "HfRpConfig.ftl"> <#include "ReflexUtils.ftl"> -<#assign preparation_status_datetime = RfxDateTimetoUTC(preparationStatusInterface.preparation_status_datetime,time_zone_offset_rfx) /> +<#assign preparation_status_datetime = RfxDateTimetoUTCWithTimezone(preparationStatusInterface.preparation_status_datetime,time_zone_rfx) /> [ { "Header": { diff --git a/RFXtoRP_HsaProStatus_TransportStarted.ftl b/RFXtoRP_HsaProStatus_TransportStarted.ftl index 7f9c79a..04c48ae 100644 --- a/RFXtoRP_HsaProStatus_TransportStarted.ftl +++ b/RFXtoRP_HsaProStatus_TransportStarted.ftl @@ -1,6 +1,6 @@ <#include "HfRpConfig.ftl"> <#include "ReflexUtils.ftl"> -<#assign preparation_status_datetime = RfxDateTimetoUTC(preparationStatusInterface.preparation_status_datetime,time_zone_offset_rfx) /> +<#assign preparation_status_datetime = RfxDateTimetoUTCWithTimezone(preparationStatusInterface.preparation_status_datetime,time_zone_rfx) /> [ { "Header": { diff --git a/RFXtoRP_HsrPrepa.ftl b/RFXtoRP_HsrPrepa.ftl index d9afb7f..cda3dab 100644 --- a/RFXtoRP_HsrPrepa.ftl +++ b/RFXtoRP_HsrPrepa.ftl @@ -53,7 +53,7 @@ <#assign hd_numberHmapHUadded ={}> <#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> - <#assign HUadded_packing_datetime = RfxDateTimetoUTC(preparation_line.confirmation_datetime,time_zone_offset_rfx) /> + <#assign HUadded_packing_datetime = RfxDateTimetoUTCWithTimezone(preparation_line.confirmation_datetime,time_zone_rfx) /> <#if !hd_numberHmap[despatched_ipg.hd_number]?? > <#assign hd_numberHmap += {despatched_ipg.hd_number,despatched_ipg.hd_number}> , diff --git a/RFXtoRP_HsrPrepa_HUsAdded_HandlingUnitDispatched.ftl b/RFXtoRP_HsrPrepa_HUsAdded_HandlingUnitDispatched.ftl index 1a780d5..4b7da84 100644 --- a/RFXtoRP_HsrPrepa_HUsAdded_HandlingUnitDispatched.ftl +++ b/RFXtoRP_HsrPrepa_HUsAdded_HandlingUnitDispatched.ftl @@ -1,7 +1,7 @@ <#include "HfRpConfig.ftl"> <#include "ReflexUtils.ftl"> [ -<#assign dispatched3_datetime = RfxDateTimetoUTC(preparationOrder.stock_despatch_at_preparation_datetime,time_zone_offset_rfx) /> +<#assign dispatched3_datetime = RfxDateTimetoUTCWithTimezone(preparationOrder.stock_despatch_at_preparation_datetime,time_zone_rfx) /> <#list preparationOrder.preparation_line_lst?filter(l ->l.despatched_ipg_list??) as preparation_line3> <#list preparation_line3.despatched_ipg_list?filter(j ->j.carton_number!="000000000000000000") as despatched_ipg3> diff --git a/RFXtoRP_HsrPrepa_HUsAdded_TrackingHuLabelled.ftl b/RFXtoRP_HsrPrepa_HUsAdded_TrackingHuLabelled.ftl index f6c8deb..1adfad0 100644 --- a/RFXtoRP_HsrPrepa_HUsAdded_TrackingHuLabelled.ftl +++ b/RFXtoRP_HsrPrepa_HUsAdded_TrackingHuLabelled.ftl @@ -2,7 +2,7 @@ <#include "ReflexUtils.ftl"> <#include "ActorPrefix.ftl"> [ -<#assign dispatched_datetime5 = RfxDateTimetoUTC(preparationOrder.stock_despatch_at_preparation_datetime,time_zone_offset_rfx) /> +<#assign dispatched_datetime5 = RfxDateTimetoUTCWithTimezone(preparationOrder.stock_despatch_at_preparation_datetime,time_zone_rfx) /> { "Header": { "ProjectID": "${projectRP}" diff --git a/RFXtoRP_HsrPrepa_HandlingUnitDispatched.ftl b/RFXtoRP_HsrPrepa_HandlingUnitDispatched.ftl index a1b31be..7a6abd1 100644 --- a/RFXtoRP_HsrPrepa_HandlingUnitDispatched.ftl +++ b/RFXtoRP_HsrPrepa_HandlingUnitDispatched.ftl @@ -1,7 +1,7 @@ <#include "HfRpConfig.ftl"> <#include "ReflexUtils.ftl"> [ -<#assign dispatched_datetime = RfxDateTimetoUTC(preparationOrder.stock_despatch_at_preparation_datetime,time_zone_offset_rfx) /> +<#assign dispatched_datetime = RfxDateTimetoUTCWithTimezone(preparationOrder.stock_despatch_at_preparation_datetime,time_zone_rfx) /> <#assign refIDHmap_local ={}> <#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> diff --git a/RFXtoRP_HsrPrepa_HandlingunitGoodsPrepared.ftl b/RFXtoRP_HsrPrepa_HandlingunitGoodsPrepared.ftl index a8ff88b..8aed82c 100644 --- a/RFXtoRP_HsrPrepa_HandlingunitGoodsPrepared.ftl +++ b/RFXtoRP_HsrPrepa_HandlingunitGoodsPrepared.ftl @@ -4,7 +4,7 @@ [ <#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> - <#assign packing_datetime = RfxDateTimetoUTC(preparation_line.confirmation_datetime,time_zone_offset_rfx) /> + <#assign packing_datetime = RfxDateTimetoUTCWithTimezone(preparation_line.confirmation_datetime,time_zone_rfx) /> { "Header": { "ProjectID": "${projectRP}" diff --git a/RFXtoRP_HsrPrepa_TrackingHuLabelled.ftl b/RFXtoRP_HsrPrepa_TrackingHuLabelled.ftl index de29490..e88a3b0 100644 --- a/RFXtoRP_HsrPrepa_TrackingHuLabelled.ftl +++ b/RFXtoRP_HsrPrepa_TrackingHuLabelled.ftl @@ -2,7 +2,7 @@ <#include "ReflexUtils.ftl"> <#include "ActorPrefix.ftl"> [ -<#assign dispatched_datetime4 = RfxDateTimetoUTC(preparationOrder.stock_despatch_at_preparation_datetime,time_zone_offset_rfx) /> +<#assign dispatched_datetime4 = RfxDateTimetoUTCWithTimezone(preparationOrder.stock_despatch_at_preparation_datetime,time_zone_rfx) /> { "Header": { "ProjectID": "${projectRP}" diff --git a/RFXtoRP_HsrPro_ExecutionflowCancelled.ftl b/RFXtoRP_HsrPro_ExecutionflowCancelled.ftl index 9cdd1b6..b518fa7 100644 --- a/RFXtoRP_HsrPro_ExecutionflowCancelled.ftl +++ b/RFXtoRP_HsrPro_ExecutionflowCancelled.ftl @@ -1,6 +1,6 @@ <#include "HfRpConfig.ftl"> <#include "ReflexUtils.ftl"> -<#assign preparation_status_datetime = RfxDateTimetoUTC(preparation_order.modification_datetime,time_zone_offset_rfx) /> +<#assign preparation_status_datetime = RfxDateTimetoUTCWithTimezone(preparation_order.modification_datetime,time_zone_rfx) /> [ { "Header": { diff --git a/RFXtoRP_HsrPro_ExecutionflowDetected.ftl b/RFXtoRP_HsrPro_ExecutionflowDetected.ftl index 53f554a..ee97306 100644 --- a/RFXtoRP_HsrPro_ExecutionflowDetected.ftl +++ b/RFXtoRP_HsrPro_ExecutionflowDetected.ftl @@ -3,8 +3,8 @@ <#include "ActorPrefix.ftl"> [ { - <#assign planned_final_delivery_start_datetime = RfxDateTimetoUTC(preparation_order.planned_final_delivery_start_datetime,time_zone_offset_rfx) /> - <#assign pro_creation_datetime = RfxDateTimetoUTC(preparation_order.creation_datetime,time_zone_offset_rfx) /> + <#assign planned_final_delivery_start_datetime = RfxDateTimetoUTCWithTimezone(preparation_order.planned_final_delivery_start_datetime,time_zone_rfx) /> + <#assign pro_creation_datetime = RfxDateTimetoUTCWithTimezone(preparation_order.creation_datetime,time_zone_rfx) /> "Header": { "ProjectID": "${projectRP}" }, diff --git a/RFXtoRP_HsrReceiptList_ExecutionflowCancelled.ftl b/RFXtoRP_HsrReceiptList_ExecutionflowCancelled.ftl index 46a8692..e262117 100644 --- a/RFXtoRP_HsrReceiptList_ExecutionflowCancelled.ftl +++ b/RFXtoRP_HsrReceiptList_ExecutionflowCancelled.ftl @@ -1,6 +1,6 @@ <#include "HfRpConfig.ftl"> <#include "ReflexUtils.ftl"> -<#assign receipt_status_datetime = RfxDateTimetoUTC(receipt.modification_datetime,time_zone_offset_rfx) /> +<#assign receipt_status_datetime = RfxDateTimetoUTCWithTimezone(receipt.modification_datetime,time_zone_rfx) /> [ { diff --git a/RFXtoRP_HsrReceiptList_ExecutionflowDetected.ftl b/RFXtoRP_HsrReceiptList_ExecutionflowDetected.ftl index b5568df..be2fc6a 100644 --- a/RFXtoRP_HsrReceiptList_ExecutionflowDetected.ftl +++ b/RFXtoRP_HsrReceiptList_ExecutionflowDetected.ftl @@ -3,8 +3,8 @@ <#include "ActorPrefix.ftl"> [ { - <#assign receipt_datetime = RfxDateTimetoUTC(receipt.receipt_datetime,time_zone_offset_rfx) /> - <#assign receipt_creation_datetime = RfxDateTimetoUTC(receipt.creation_datetime,time_zone_offset_rfx) /> + <#assign receipt_datetime = RfxDateTimetoUTCWithTimezone(receipt.receipt_datetime,time_zone_rfx) /> + <#assign receipt_creation_datetime = RfxDateTimetoUTCWithTimezone(receipt.creation_datetime,time_zone_rfx) /> "Header": { "ProjectID": "${projectRP}" }, diff --git a/RFXtoRP_HsrReceiptList_ExecutionflowReceiptCompleted.ftl b/RFXtoRP_HsrReceiptList_ExecutionflowReceiptCompleted.ftl index 485a5c5..91390fb 100644 --- a/RFXtoRP_HsrReceiptList_ExecutionflowReceiptCompleted.ftl +++ b/RFXtoRP_HsrReceiptList_ExecutionflowReceiptCompleted.ftl @@ -1,6 +1,6 @@ <#include "HfRpConfig.ftl"> <#include "ReflexUtils.ftl"> -<#assign receipt_status_datetime = RfxDateTimetoUTC(receipt.confirmation_datetime,time_zone_offset_rfx) /> +<#assign receipt_status_datetime = RfxDateTimetoUTCWithTimezone(receipt.confirmation_datetime,time_zone_rfx) /> [ { "Header": { diff --git a/RFXtoRP_HsrReceiptList_ReceiptExpected.ftl b/RFXtoRP_HsrReceiptList_ReceiptExpected.ftl index 65f257c..23cf130 100644 --- a/RFXtoRP_HsrReceiptList_ReceiptExpected.ftl +++ b/RFXtoRP_HsrReceiptList_ReceiptExpected.ftl @@ -1,6 +1,6 @@ <#include "HfRpConfig.ftl"> <#include "ReflexUtils.ftl"> -<#assign receipt_status_datetime = RfxDateTimetoUTC(receipt.creation_datetime,time_zone_offset_rfx) /> +<#assign receipt_status_datetime = RfxDateTimetoUTCWithTimezone(receipt.creation_datetime,time_zone_rfx) /> [ { diff --git a/RFXtoRP_RfxConfigurationRp.ftl b/RFXtoRP_RfxConfigurationRp.ftl index d89dac8..1b19bf7 100644 --- a/RFXtoRP_RfxConfigurationRp.ftl +++ b/RFXtoRP_RfxConfigurationRp.ftl @@ -25,8 +25,8 @@ -<#noparse><#assign time_zone_rfx = "${file.author_time_zone!"UTC"}<#noparse>"> -<#noparse><#assign time_zone_offset_rfx = "${file.time_zone_offset!"+00:00"}<#noparse>"> +<#noparse><#assign time_zone_rfx = "${file.author_time_zone!"Europe/Paris"}<#noparse>"> +<#noparse><#assign time_zone_offset_rfx = "${file.time_zone_offset!"+01:00"}<#noparse>"> <#list file.reflex_platform_project_list?filter(l -> l.name == projectRP) as reflex_platform_project> diff --git a/ReflexUtils.ftl b/ReflexUtils.ftl index afa299e..7bc33f6 100644 --- a/ReflexUtils.ftl +++ b/ReflexUtils.ftl @@ -9,6 +9,11 @@ <#return dateutc?datetime.iso?iso_nz(locale)> +<#function RfxDateTimetoUTCWithTimezone rfxdatetime timezone> + <#setting time_zone=timezone> + <#return (rfxdatetime?datetime.iso?iso_utc)> + + <#-- --------------------------------------------------------------------------------------- --> <#-- Split email reflex into json array string --> <#-- Example : splitemail "john.doe@hardis-group.com,; name@hardis-group.com" -->