From 33f9869a4d1501f2dda10fd6b18b483b7c4549aa Mon Sep 17 00:00:00 2001 From: Paul Girard Date: Thu, 9 Mar 2017 16:45:26 +0100 Subject: [PATCH] adding dates to contracts export in annex4 fixes #375 --- server/export/annex4.js | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/server/export/annex4.js b/server/export/annex4.js index 9ef9a81c..97c26184 100644 --- a/server/export/annex4.js +++ b/server/export/annex4.js @@ -104,6 +104,7 @@ const TEMPLATES = { {{~#if instrument}}, {{instrument}}{{/if~}} {{~#if manager}}, {{manager.firstName}} {{manager.name}}{{/if~}} {{~#if role}}, {{role}}{{/if~}} + {{~#if startDate}}, {{formatRange .}}{{/if~}} {{/each}} @@ -513,7 +514,9 @@ const TABS = [ name:'', organization:'', program:'', - instrument:'' + instrument:'', + startDate:'', + endDate:'' }; if (activity.acronym) @@ -537,6 +540,12 @@ const TABS = [ info.instrument = index[grant.grantInstrument] || grant.grantInstrument; } + if (activity.startDate) + info.startDate = activity.startDate; + + if (activity.endDate) + info.endDate = activity.endDate; + const manager = activity.people.find(person => { return ( person.role === 'responsableScientifique' ||