[#3356] Prepare for multiples tags per type de champ

This commit is contained in:
Frederic Merizen 2019-02-05 11:42:29 +01:00 committed by simon lehericey
parent 6c3cb2716e
commit d67af741d5

View file

@ -167,12 +167,14 @@ module TagsSubstitutionConcern
end end
def types_de_champ_tags(types_de_champ, available_for_states) def types_de_champ_tags(types_de_champ, available_for_states)
types_de_champ.map do |tdc| types_de_champ.flat_map do |tdc|
[
{ {
libelle: tdc.libelle, libelle: tdc.libelle,
description: tdc.description, description: tdc.description,
available_for_states: available_for_states available_for_states: available_for_states
} }
]
end end
end end