Merge branch 'dev'
This commit is contained in:
commit
17b23c7332
2 changed files with 4 additions and 2 deletions
|
@ -27,7 +27,9 @@ class AttestationTemplate < ApplicationRecord
|
||||||
used_tags.map do |used_tag|
|
used_tags.map do |used_tag|
|
||||||
corresponding_champ = all_champs_with_libelle_index[used_tag]
|
corresponding_champ = all_champs_with_libelle_index[used_tag]
|
||||||
|
|
||||||
corresponding_champ.value.blank? ? corresponding_champ : nil
|
if corresponding_champ && corresponding_champ.value.blank?
|
||||||
|
corresponding_champ
|
||||||
|
end
|
||||||
end.compact
|
end.compact
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
|
@ -661,7 +661,7 @@ describe Dossier do
|
||||||
# - with tag in body and tag in title
|
# - with tag in body and tag in title
|
||||||
# - with tag correponsing to a champ and an annotation privée
|
# - with tag correponsing to a champ and an annotation privée
|
||||||
# - with a dash in the champ libelle / tag
|
# - with a dash in the champ libelle / tag
|
||||||
let(:title) { "voici --specified champ-in-title-- un --unspecified champ-in-title-- beau --specified annotation privée-in-title-- titre --unspecified annotation privée-in-title-- non" }
|
let(:title) { "voici --specified champ-in-title-- un --unspecified champ-in-title-- beau --specified annotation privée-in-title-- titre --unspecified annotation privée-in-title-- non --numéro du dossier--" }
|
||||||
let(:body) { "voici --specified champ-in-body-- un --unspecified champ-in-body-- beau --specified annotation privée-in-body-- body --unspecified annotation privée-in-body-- non ?" }
|
let(:body) { "voici --specified champ-in-body-- un --unspecified champ-in-body-- beau --specified annotation privée-in-body-- body --unspecified annotation privée-in-body-- non ?" }
|
||||||
let(:attestation_template) { create(:attestation_template, title: title, body: body, activated: activated) }
|
let(:attestation_template) { create(:attestation_template, title: title, body: body, activated: activated) }
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue