You've already forked reflex-wms-connector
ajout des FTL liés à la création de commande (SCPN1-5019) à valider par Laure
This commit is contained in:
37
RPtoRFX_ExecutionflowEvent.ftl
Normal file
37
RPtoRFX_ExecutionflowEvent.ftl
Normal file
@@ -0,0 +1,37 @@
|
||||
<#-- **** input parameters ***** -->
|
||||
<#-- input : message RFX -->
|
||||
<#-- project : projectId in ReflexPlatform -->
|
||||
<#-- organisation : organisationtId in ReflexPlatform -->
|
||||
|
||||
<#assign eventRP = JsonUtil.jsonToMap(input)>
|
||||
<#assign projectRP = project>
|
||||
<#assign organisationRP = organisation>
|
||||
|
||||
<#switch eventRP.event>
|
||||
<#case "Created">
|
||||
<#-- *********************************************** Action = CREATE or UPDATE ******************** -->
|
||||
<#assign executionflow = eventRP.data />
|
||||
[
|
||||
<#if eventRP.partnerAppRole == "ShipFrom" && executionflow.ShipFrom.ActorID != "" && executionflow.ShipFrom.Actor.IsShipFromConnected?? && executionflow.ShipFrom.Actor.IsShipFromConnected>
|
||||
{
|
||||
<#assign apiRestReflexID = ApiRestReflexID.preparation_orders_post>
|
||||
"apiRestReflexID" : "${apiRestReflexID}",
|
||||
"datas" :
|
||||
<#include "RPtoRFX_Preparation_orders_post.ftl">
|
||||
}
|
||||
</#if>
|
||||
<#if eventRP.partnerAppRole == "ShipTo" && executionflow.ShipTo.ActorID != "" && executionflow.ShipTo.Actor.IsShipToConnected?? && executionflow.ShipTo.Actor.IsShipToConnected>
|
||||
{
|
||||
<#assign apiRestReflexID = ApiRestReflexID.receipts_post>
|
||||
"apiRestReflexID" : "${apiRestReflexID}",
|
||||
"datas" :
|
||||
<#include "RPtoRFX_Receipts_post.ftl">
|
||||
}
|
||||
</#if>
|
||||
|
||||
]
|
||||
<#break>
|
||||
<#default>
|
||||
<#stop "Event not process">
|
||||
</#switch>
|
||||
|
||||
Reference in New Issue
Block a user