[#2180] Keep information that this type de champ was cloned from a PJ

This commit is contained in:
Frederic Merizen 2019-01-10 13:36:38 +01:00
parent 651fd6149b
commit 8cb509d192
3 changed files with 6 additions and 2 deletions

View file

@ -55,7 +55,10 @@ class PiecesJustificativesService
type_champ: TypeDeChamp.type_champs.fetch(:piece_justificative),
description: description,
order_place: order_place,
mandatory: tpj.mandatory
mandatory: tpj.mandatory,
old_pj: {
stable_id: tpj.id
}
)
end
if types_de_champ.count > 1