From 90bfd41f41dd9f8169c2d20673416ffad33b9e75 Mon Sep 17 00:00:00 2001 From: frea Date: Tue, 15 Oct 2024 16:19:31 +0200 Subject: [PATCH] Ajout du flux LoadInfo --- RFXtoRP_HsrLoadInfo.ftl | 40 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) create mode 100644 RFXtoRP_HsrLoadInfo.ftl diff --git a/RFXtoRP_HsrLoadInfo.ftl b/RFXtoRP_HsrLoadInfo.ftl new file mode 100644 index 0000000..8b00fd7 --- /dev/null +++ b/RFXtoRP_HsrLoadInfo.ftl @@ -0,0 +1,40 @@ +<#-- **** input parameters ***** --> +<#-- input : message RFX --> +<#-- project : projectId in ReflexPlatform --> +<#-- organisation : organisationtId in ReflexPlatform --> + +<#assign cloudEventMsg = JsonUtil.jsonToMap(input)> +<#assign projectRP = project> +<#assign organisationRP = organisation> + +<#assign aDateTime = .now> + +<#stop> + +<#switch cloudEventMsg.action> + <#case "C"> + <#case "U"> + <#-- *********************************************** Action = CREATE or UPDATE ******************** --> + <#assign dataRfx = JsonUtil.decodeBase64(cloudEventMsg.data) /> + <#assign depot = JsonUtil.jsonToMap(dataRfx)> + [ + { + + } + ] + <#break> + + <#case "D"> + <#-- *********************************************** Action = DELETE *************************** --> + <#assign dataRfx = JsonUtil.decodeBase64(cloudEventMsg.data) /> + <#assign depot = JsonUtil.jsonToMap(dataRfx)> + [ + { + + } + ] + <#break> + + <#default> + <#stop "event not supported"> + \ No newline at end of file