diff --git a/RPtoRFX_AppointmentEvent.ftl b/RPtoRFX_AppointmentEvent.ftl index 21be0c7..65a2015 100644 --- a/RPtoRFX_AppointmentEvent.ftl +++ b/RPtoRFX_AppointmentEvent.ftl @@ -28,19 +28,21 @@ <#assign appointment = eventRP.data /> [ <#if eventRP.appointmentCustomFields?has_content> - { - <#assign apiRestReflexID = ApiRestReflexID.appointment_post_physical_receipt_associations_by_number> - "apiRestReflexID" : "${apiRestReflexID}", - "datas" : - <#include "RPtoRFX_CarrierAppointmentPhysicalReceiptAssociationByNumber.ftl"> - } - <#else> - { - <#assign apiRestReflexID = ApiRestReflexID.appointment_post_physical_receipt_associations_by_ref> - "apiRestReflexID" : "${apiRestReflexID}", - "datas" : - <#include "RPtoRFX_CarrierAppointmentPhysicalReceiptAssociationByRef.ftl"> - } + <#list eventRP.executionflowCustomFields as commission> + { + <#assign apiRestReflexID = ApiRestReflexID.appointment_post_physical_receipt_associations_by_number> + "apiRestReflexID" : "${apiRestReflexID}", + "datas" : + <#include "RPtoRFX_CarrierAppointmentPhysicalReceiptAssociationByNumber.ftl"> + } + <#else> + { + <#assign apiRestReflexID = ApiRestReflexID.appointment_post_physical_receipt_associations_by_ref> + "apiRestReflexID" : "${apiRestReflexID}", + "datas" : + <#include "RPtoRFX_CarrierAppointmentPhysicalReceiptAssociationByRef.ftl"> + } + ] <#break> diff --git a/RPtoRFX_CarrierAppointmentPhysicalReceiptAssociationByNumber.ftl b/RPtoRFX_CarrierAppointmentPhysicalReceiptAssociationByNumber.ftl index 3a6ba80..9d8f372 100644 --- a/RPtoRFX_CarrierAppointmentPhysicalReceiptAssociationByNumber.ftl +++ b/RPtoRFX_CarrierAppointmentPhysicalReceiptAssociationByNumber.ftl @@ -12,7 +12,7 @@ <#if appointment.Commissions??> <#if appointment.AppointmentType == "APPOINTMENT_TYPE_UNLOADING"> "physical_receipt_list": [ - <#list eventRP.executionflowCustomFields.entrySet()?filter(l ->l.value?? && l.value?has_content) as custom> + <#list commission.entrySet()?filter(l ->l.value?? && l.value?has_content) as custom> { "receipt_activity": "${custom.value.activity_code?json_string}", "originator_code": "${custom.value.originator_code?json_string}",