unicité
This commit is contained in:
parent
25011e68e6
commit
65601133f1
129
ActorPrefix.ftl
129
ActorPrefix.ftl
@ -1,7 +1,126 @@
|
||||
<#-- --------------------------------------------------------------------------------------- -->
|
||||
<#-- Prefix 3 cars -->
|
||||
<#-- Actor Prefix 4 cars -->
|
||||
<#-- --------------------------------------------------------------------------------------- -->
|
||||
<#assign prefixdepot = "" >
|
||||
<#assign prefixcarrier = "" >
|
||||
<#assign prefixsupplier = "" >
|
||||
<#assign prefixconsignee = "" >
|
||||
|
||||
<#-- For Depot -->
|
||||
<#function RFXtoRPprefixDepot depot>
|
||||
<#if uniqueness?? && uniqueness!="" >
|
||||
<#local actor = depot>
|
||||
<#else>
|
||||
<#if text_language_rfx ="fr">
|
||||
<#local actor = "DEP_"+depot>
|
||||
<#else>
|
||||
<#if text_language_rfx ="it">
|
||||
<#local actor = "DEP_"+depot>
|
||||
<#else>
|
||||
<#if text_language_rfx ="es">
|
||||
<#local actor = "DEP_"+depot>
|
||||
<#else>
|
||||
<#if text_language_rfx ="pl">
|
||||
<#local actor = "MAG_"+depot>
|
||||
<#else>
|
||||
<#if text_language_rfx ="nl">
|
||||
<#local actor = "DEP_"+depot>
|
||||
<#else>
|
||||
<#local actor = "DEP_"+depot>
|
||||
</#if>
|
||||
</#if>
|
||||
</#if>
|
||||
</#if>
|
||||
</#if>
|
||||
</#if>
|
||||
<#return (actor)>
|
||||
</#function>
|
||||
|
||||
<#-- For Supplier -->
|
||||
<#function RFXtoRPprefixSupplier supplier>
|
||||
<#if uniqueness?? && uniqueness!="" >
|
||||
<#local actor = supplier>
|
||||
<#else>
|
||||
<#if text_language_rfx ="fr">
|
||||
<#local actor = "FOU_"+supplier>
|
||||
<#else>
|
||||
<#if text_language_rfx ="it">
|
||||
<#local actor = "FOR_"+supplier>
|
||||
<#else>
|
||||
<#if text_language_rfx ="es">
|
||||
<#local actor = "PRO_"+supplier>
|
||||
<#else>
|
||||
<#if text_language_rfx ="pl">
|
||||
<#local actor = "DOS_"+supplier>
|
||||
<#else>
|
||||
<#if text_language_rfx ="nl">
|
||||
<#local actor = "LEV_"+supplier>
|
||||
<#else>
|
||||
<#local actor = "SUP_"+supplier>
|
||||
</#if>
|
||||
</#if>
|
||||
</#if>
|
||||
</#if>
|
||||
</#if>
|
||||
</#if>
|
||||
<#return (actor)>
|
||||
</#function>
|
||||
|
||||
|
||||
<#-- For Carrier -->
|
||||
<#function RFXtoRPprefixCarrier carrier>
|
||||
<#if uniqueness?? && uniqueness!="" >
|
||||
<#local actor = carrier>
|
||||
<#else>
|
||||
<#if text_language_rfx ="fr">
|
||||
<#local actor = "TRA_"+carrier>
|
||||
<#else>
|
||||
<#if text_language_rfx ="it">
|
||||
<#local actor = "VET_"+carrier>
|
||||
<#else>
|
||||
<#if text_language_rfx ="es">
|
||||
<#local actor = "TRA_"+carrier>
|
||||
<#else>
|
||||
<#if text_language_rfx ="pl">
|
||||
<#local actor = "PRZ_"+carrier>
|
||||
<#else>
|
||||
<#if text_language_rfx ="nl">
|
||||
<#local actor = "VER_"+carrier>
|
||||
<#else>
|
||||
<#local actor = "CAR_"+carrier>
|
||||
</#if>
|
||||
</#if>
|
||||
</#if>
|
||||
</#if>
|
||||
</#if>
|
||||
</#if>
|
||||
<#return (actor)>
|
||||
</#function>
|
||||
|
||||
|
||||
<#-- For Consignee -->
|
||||
<#function RFXtoRPprefixConsignee consignee>
|
||||
<#if uniqueness?? && uniqueness!="" >
|
||||
<#local actor = consignee>
|
||||
<#else>
|
||||
<#if text_language_rfx ="fr">
|
||||
<#local actor = "DES_"+consignee>
|
||||
<#else>
|
||||
<#if text_language_rfx ="it">
|
||||
<#local actor = "DES_"+consignee>
|
||||
<#else>
|
||||
<#if text_language_rfx ="es">
|
||||
<#local actor = "DES_"+consignee>
|
||||
<#else>
|
||||
<#if text_language_rfx ="pl">
|
||||
<#local actor = "ODB_"+consignee>
|
||||
<#else>
|
||||
<#if text_language_rfx ="nl">
|
||||
<#local actor = "ONT_"+consignee>
|
||||
<#else>
|
||||
<#local actor = "CON_"+consignee>
|
||||
</#if>
|
||||
</#if>
|
||||
</#if>
|
||||
</#if>
|
||||
</#if>
|
||||
</#if>
|
||||
<#return (actor)>
|
||||
</#function>
|
||||
|
||||
|
||||
@ -8,11 +8,7 @@
|
||||
"ProjectID": "${projectRP}"
|
||||
},
|
||||
"ID": {
|
||||
<#if uniqueness?? && uniqueness!="" >
|
||||
"ActorID": "${stock.physical_depot_code}"
|
||||
<#else>
|
||||
"ActorID": "${prefixdepot}${stock.physical_depot_code}"
|
||||
</#if>
|
||||
"ActorID": "${RFXtoRPprefixDepot(stock.physical_depot_code)}"
|
||||
},
|
||||
"Payload": {
|
||||
<#assign generation_date = RfxDateTimetoUTC(stock.generation_date,time_zone_offset_rfx) />
|
||||
|
||||
@ -8,12 +8,7 @@
|
||||
"ProjectID": "${projectRP}"
|
||||
},
|
||||
"Payload": {
|
||||
<#if uniqueness?? && uniqueness!="" >
|
||||
"ActorID": "${stock.physical_depot_code}",
|
||||
<#else>
|
||||
"ActorID": "${prefixdepot}${stock.physical_depot_code}",
|
||||
</#if>
|
||||
|
||||
"ActorID": "${RFXtoRPprefixDepot(stock.physical_depot_code)}",
|
||||
<#assign generation_date = RfxDateTimetoUTC(stock.generation_date,time_zone_offset_rfx) />
|
||||
"Snapshot": {
|
||||
"DateTime": {
|
||||
|
||||
@ -7,11 +7,7 @@
|
||||
"ProjectID": "${projectRP}"
|
||||
},
|
||||
"ID": {
|
||||
<#if uniqueness?? && uniqueness!="" >
|
||||
"RefID": "${carrier.carrier_code?trim?json_string}"
|
||||
<#else>
|
||||
"RefID": "${prefixcarrier}${carrier.carrier_code?trim?json_string}"
|
||||
</#if>
|
||||
"RefID": "${RFXtoRPprefixCarrier(carrier.carrier_code?trim?json_string)}"
|
||||
},
|
||||
"Payload": {
|
||||
"Name": "${carrier.carrier_designation?json_string}",
|
||||
|
||||
@ -7,13 +7,8 @@
|
||||
"ProjectID": "${projectRP}"
|
||||
},
|
||||
"ID": {
|
||||
<#if uniqueness?? && uniqueness!="" >
|
||||
"RefID": "${carrier.carrier_code?trim?json_string}"
|
||||
<#else>
|
||||
"RefID": "${prefixcarrier}${carrier.carrier_code?trim?json_string}"
|
||||
</#if>
|
||||
"RefID": "${RFXtoRPprefixCarrier(carrier.carrier_code?trim?json_string)}"
|
||||
},
|
||||
|
||||
"Payload": {}
|
||||
}
|
||||
]
|
||||
|
||||
@ -7,13 +7,8 @@
|
||||
"ProjectID": "${projectRP}"
|
||||
},
|
||||
"ID": {
|
||||
<#if uniqueness?? && uniqueness!="" >
|
||||
"RefID": "${actor.code?trim?json_string}"
|
||||
<#else>
|
||||
"RefID": "${prefixconsignee}${actor.code?trim?json_string}"
|
||||
</#if>
|
||||
"RefID": "${RFXtoRPprefixConsignee(actor.code?trim?json_string)}"
|
||||
},
|
||||
|
||||
"Payload": {
|
||||
"Name": "${actor.designation?json_string}",
|
||||
"ManagedStock": false,
|
||||
|
||||
@ -7,11 +7,7 @@
|
||||
"ProjectID": "${projectRP}"
|
||||
},
|
||||
"ID": {
|
||||
<#if uniqueness?? && uniqueness!="" >
|
||||
"RefID": "${actor.code?trim?json_string}"
|
||||
<#else>
|
||||
"RefID": "${prefixconsignee}${actor.code?trim?json_string}"
|
||||
</#if>
|
||||
"RefID": "${RFXtoRPprefixConsignee(actor.code?trim?json_string)}"
|
||||
},
|
||||
"Payload": {}
|
||||
}
|
||||
|
||||
@ -37,11 +37,7 @@
|
||||
"ExecutionflowID": "${reflexMvtStockInterface.physical_depot_code}${reflexMvtStockInterface.activity_code}${reflexMvtStockInterface.ipg_move_year_number}${reflexMvtStockInterface.extended_ipg_move_number}",
|
||||
</#if>
|
||||
"LineID": "${reflexMvtStockInterface.receipt_line_number}",
|
||||
<#if uniqueness?? && uniqueness!="" >
|
||||
"ActorID": "${reflexMvtStockInterface.physical_depot_code?trim?json_string}",
|
||||
<#else>
|
||||
"ActorID": "${prefixdepot}${reflexMvtStockInterface.physical_depot_code?trim?json_string}",
|
||||
</#if>
|
||||
"ActorID": "${RFXtoRPprefixDepot(reflexMvtStockInterface.physical_depot_code?trim?json_string)}",
|
||||
"Quantity": {
|
||||
"LVID": "${quantity_in_base_lv_RP_Cst}",
|
||||
"Value": ${reflexMvtStockInterface.ipg_move_quantity_in_base_lvs}
|
||||
|
||||
@ -42,11 +42,7 @@
|
||||
|
||||
"LVBranchID": "${reflexMvtStockInterface.lv_code?json_string}"
|
||||
},
|
||||
<#if uniqueness?? && uniqueness!="" >
|
||||
"ActorID": "${reflexMvtStockInterface.physical_depot_code?trim?json_string}",
|
||||
<#else>
|
||||
"ActorID": "${prefixdepot}${reflexMvtStockInterface.physical_depot_code?trim?json_string}",
|
||||
</#if>
|
||||
"ActorID": "${RFXtoRPprefixDepot(reflexMvtStockInterface.physical_depot_code?trim?json_string)}",
|
||||
"Movement": {
|
||||
|
||||
"DateTime": {
|
||||
|
||||
@ -7,11 +7,7 @@
|
||||
"ProjectID": "${projectRP}"
|
||||
},
|
||||
"ID": {
|
||||
<#if uniqueness?? && uniqueness!="" >
|
||||
"RefID": "${actor.code?trim?json_string}"
|
||||
<#else>
|
||||
"RefID": "${prefixsupplier}${actor.code?trim?json_string}"
|
||||
</#if>
|
||||
"RefID": "${RFXtoRPprefixSupplier(actor.code?trim?json_string)}"
|
||||
},
|
||||
"Payload": {
|
||||
"Name": "${actor.designation?json_string}",
|
||||
|
||||
@ -7,11 +7,7 @@
|
||||
"ProjectID": "${projectRP}"
|
||||
},
|
||||
"ID": {
|
||||
<#if uniqueness?? && uniqueness!="" >
|
||||
"RefID": "${actor.code?trim?json_string}"
|
||||
<#else>
|
||||
"RefID": "${prefixsupplier}${actor.code?trim?json_string}"
|
||||
</#if>
|
||||
"RefID": "${RFXtoRPprefixSupplier(actor.code?trim?json_string)}"
|
||||
},
|
||||
"Payload": {}
|
||||
}
|
||||
|
||||
@ -7,11 +7,7 @@
|
||||
"ProjectID": "${projectRP}"
|
||||
},
|
||||
"ID": {
|
||||
<#if uniqueness?? && uniqueness!="" >
|
||||
"RefID": "${depot.physical_depot_code?trim?json_string}"
|
||||
<#else>
|
||||
"RefID": "${prefixdepot}${depot.physical_depot_code?trim?json_string}"
|
||||
</#if>
|
||||
"RefID": "${RFXtoRPprefixDepot(depot.physical_depot_code?trim?json_string)}"
|
||||
},
|
||||
"Payload": {
|
||||
"Name": "${depot.physical_depot_designation?json_string}",
|
||||
|
||||
@ -7,11 +7,7 @@
|
||||
"ProjectID": "${projectRP}"
|
||||
},
|
||||
"ID": {
|
||||
<#if uniqueness?? && uniqueness!="" >
|
||||
"RefID": "${depot.physical_depot_code?trim?json_string}"
|
||||
<#else>
|
||||
"RefID": "${prefixdepot}${depot.physical_depot_code?trim?json_string}"
|
||||
</#if>
|
||||
"RefID": "${RFXtoRPprefixDepot(depot.physical_depot_code?trim?json_string)}"
|
||||
},
|
||||
"Payload": {}
|
||||
}
|
||||
|
||||
@ -19,11 +19,7 @@
|
||||
},
|
||||
"Payload":{
|
||||
"Carrier": {
|
||||
<#if uniqueness?? && uniqueness!="" >
|
||||
"ActorID":"${preparationOrder.load_data.carrier_code?trim?json_string}"
|
||||
<#else>
|
||||
"ActorID":"${prefixcarrier}${preparationOrder.load_data.carrier_code?trim?json_string}"
|
||||
</#if>
|
||||
"ActorID": "${RFXtoRPprefixCarrier(preparationOrder.load_data.carrier_code?trim?json_string)}"
|
||||
}
|
||||
<#-- Add transport grade code
|
||||
<#if preparationOrder.transport_grade_code!="">
|
||||
|
||||
@ -118,20 +118,15 @@
|
||||
<#else>
|
||||
"LineID": "${preparation_line.pro_line_number!0}",
|
||||
</#if>
|
||||
<#if uniqueness?? && uniqueness!="" >
|
||||
"ActorID": "${preparationOrder.physical_depot_code?trim?json_string}",
|
||||
<#else>
|
||||
"ActorID": "${prefixdepot}${preparationOrder.physical_depot_code?trim?json_string}",
|
||||
</#if>
|
||||
"Quantity": {
|
||||
"LVID": "${quantity_in_base_lv_RP_Cst}",
|
||||
"Value": ${despatched_ipg.quantity_lvs}
|
||||
"ActorID": "${RFXtoRPprefixDepot(preparationOrder.physical_depot_code?trim?json_string)}",
|
||||
"Quantity": {
|
||||
"LVID": "${quantity_in_base_lv_RP_Cst}",
|
||||
"Value": ${despatched_ipg.quantity_lvs}
|
||||
}
|
||||
|
||||
}
|
||||
]
|
||||
}
|
||||
|
||||
}<#sep>,</#sep>
|
||||
</#list>
|
||||
<#sep>,</#sep>
|
||||
|
||||
@ -19,11 +19,7 @@
|
||||
},
|
||||
"Payload":{
|
||||
"Carrier": {
|
||||
<#if uniqueness?? && uniqueness!="" >
|
||||
"ActorID":"${preparationOrder.load_data.carrier_code?trim?json_string}"
|
||||
<#else>
|
||||
"ActorID":"${prefixcarrier}${preparationOrder.load_data.carrier_code?trim?json_string}"
|
||||
</#if>
|
||||
"ActorID": "${RFXtoRPprefixCarrier(preparationOrder.load_data.carrier_code?trim?json_string)}"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -32,13 +32,8 @@
|
||||
<#if preparationOrder.load_data?? && preparationOrder.load_data.carrier_code?? && preparationOrder.load_data.carrier_code!="" >
|
||||
,
|
||||
"HUCarrier":{
|
||||
<#if uniqueness?? && uniqueness!="" >
|
||||
"ActorID":"${preparationOrder.load_data.carrier_code?trim?json_string}"
|
||||
<#else>
|
||||
"ActorID":"${prefixcarrier}${preparationOrder.load_data.carrier_code?trim?json_string}"
|
||||
</#if>
|
||||
}
|
||||
|
||||
"ActorID": "${RFXtoRPprefixCarrier(preparationOrder.load_data.carrier_code?trim?json_string)}"
|
||||
}
|
||||
</#if>
|
||||
}
|
||||
}
|
||||
|
||||
@ -15,20 +15,13 @@
|
||||
}
|
||||
},
|
||||
"Payload": {
|
||||
|
||||
"HandlingunitID": "${despatched_ipg.hd_number}"
|
||||
|
||||
<#if preparationOrder.load_data?? && preparationOrder.load_data.carrier_code?? && preparationOrder.load_data.carrier_code!="" >
|
||||
,
|
||||
"HUCarrier":{
|
||||
<#if uniqueness?? && uniqueness!="" >
|
||||
"ActorID":"${preparationOrder.load_data.carrier_code?trim?json_string}"
|
||||
<#else>
|
||||
"ActorID":"${prefixcarrier}${preparationOrder.load_data.carrier_code?trim?json_string}"
|
||||
</#if>
|
||||
}
|
||||
|
||||
</#if>
|
||||
<#if preparationOrder.load_data?? && preparationOrder.load_data.carrier_code?? && preparationOrder.load_data.carrier_code!="" >
|
||||
,
|
||||
"HUCarrier":{
|
||||
"ActorID": "${RFXtoRPprefixCarrier(preparationOrder.load_data.carrier_code?trim?json_string)}"
|
||||
}
|
||||
</#if>
|
||||
}
|
||||
}
|
||||
]
|
||||
@ -27,11 +27,7 @@
|
||||
"CarrierService":"${preparation_order.transport_grade_code?trim?json_string}",
|
||||
</#if> -->
|
||||
"ShipFrom": {
|
||||
<#if uniqueness?? && uniqueness!="" >
|
||||
"ActorID": "${preparation_order.physical_depot_code?trim?json_string}"
|
||||
<#else>
|
||||
"ActorID": "${prefixdepot}${preparation_order.physical_depot_code?trim?json_string}"
|
||||
</#if>
|
||||
"ActorID": "${RFXtoRPprefixDepot(preparation_order.physical_depot_code?trim?json_string)}"
|
||||
},
|
||||
"ShipFromAcked": true,
|
||||
"ShipTo": {
|
||||
@ -53,11 +49,7 @@
|
||||
preparation_order.address.territorial_division_code == "" &&
|
||||
preparation_order.address.postal_code == "" &&
|
||||
preparation_order.address.iso_country_code == "">
|
||||
<#if uniqueness?? && uniqueness!="" >
|
||||
"ActorID": "${preparation_order.end_consignee_code}"
|
||||
<#else>
|
||||
"ActorID": "${prefixconsignee}${preparation_order.end_consignee_code}"
|
||||
</#if>
|
||||
"ActorID": "${RFXtoRPprefixConsignee(preparation_order.end_consignee_code)}"
|
||||
<#else>
|
||||
"Actor":
|
||||
{
|
||||
@ -93,7 +85,6 @@
|
||||
</#if>
|
||||
<#-- Line Metadata inclusion -->
|
||||
<#include "RFXtoRP_HsrPro_ExecutionflowDetected_LineMetadata.ftl">,
|
||||
|
||||
"RequestedContent":
|
||||
{
|
||||
"Goods":
|
||||
@ -104,10 +95,8 @@
|
||||
<#assign forced_priority_date = preparation_order_line.optional_attributes.forced_priority_date?datetime(rfx_date_format_default)?iso_utc />
|
||||
"PriorityDate": "${forced_priority_date}",
|
||||
</#if>
|
||||
|
||||
<#-- Segmentation Keys inclusion -->
|
||||
<#include "RFXtoRP_HsrPro_ExecutionflowDetected_SegmentationKeys.ftl">
|
||||
|
||||
},
|
||||
"Quantity" :
|
||||
{
|
||||
@ -119,7 +108,6 @@
|
||||
</#list>
|
||||
],
|
||||
</#if>
|
||||
|
||||
"RequestedMilestones" :
|
||||
{
|
||||
"RequestedDeliveryDateTime" :
|
||||
|
||||
@ -26,29 +26,16 @@
|
||||
|
||||
"ShipFrom":
|
||||
{
|
||||
<#if uniqueness?? && uniqueness!="" >
|
||||
"ActorID": "${receipt.original_code?trim?json_string}"
|
||||
<#else>
|
||||
"ActorID": "${prefixsupplier}${receipt.original_code?trim?json_string}"
|
||||
</#if>
|
||||
|
||||
"ActorID": "${RFXtoRPprefixSupplier(receipt.original_code?trim?json_string)}"
|
||||
},
|
||||
"ShipTo" :
|
||||
{
|
||||
<#if uniqueness?? && uniqueness!="" >
|
||||
"ActorID": "${receipt.physical_depot_code?trim?json_string}"
|
||||
<#else>
|
||||
"ActorID": "${prefixdepot}${receipt.physical_depot_code?trim?json_string}"
|
||||
</#if>
|
||||
"ActorID": "${RFXtoRPprefixDepot(receipt.physical_depot_code?trim?json_string)}"
|
||||
},
|
||||
"ShipToAcked": true,
|
||||
|
||||
<#if receipt.carrier_informations.carrier_code != "">
|
||||
<#if uniqueness?? && uniqueness!="" >
|
||||
"Carrier" : {"ActorID": "${receipt.carrier_informations.carrier_code?trim?json_string}"},
|
||||
<#else>
|
||||
"Carrier" : {"ActorID": "${prefixcarrier}${receipt.carrier_informations.carrier_code?trim?json_string}"},
|
||||
</#if>
|
||||
"Carrier": "${RFXtoRPprefixCarrier(receipt.carrier_informations.carrier_code?trim?json_string)}",
|
||||
</#if>
|
||||
|
||||
<#if receipt.line_list??>
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user