remove '+' and use variable in I18n
This commit is contained in:
parent
384b7f9fac
commit
d52ee477b0
3 changed files with 7 additions and 1 deletions
|
@ -98,7 +98,7 @@ class DossierProjectionService
|
|||
.where(dossier_id: dossiers_ids)
|
||||
.pluck('dossier_id', 'question_answer')
|
||||
.group_by { |dossier_id, _| dossier_id }
|
||||
.to_h { |dossier_id, question_answer| [dossier_id, question_answer.map { |_, answer| answer }&.compact&.tally&.map { |k, v| I18n.t("helpers.label.question_answer.#{k}") + ": #{v}" }&.join(' / ')] }
|
||||
.to_h { |dossier_id, question_answer| [dossier_id, question_answer.map { |_, answer| answer }&.compact&.tally&.map { |k, v| I18n.t("helpers.label.question_answer_with_count.#{k}", count: v) }&.join(' / ')] }
|
||||
# rubocop:enable Style/HashTransformValues
|
||||
end
|
||||
end
|
||||
|
|
|
@ -21,6 +21,9 @@ en:
|
|||
question_answer:
|
||||
true: 'yes'
|
||||
false: 'no'
|
||||
question_answer_with_count:
|
||||
true: "yes : %{count}"
|
||||
false: "no : %{count}"
|
||||
confirmation:
|
||||
revoke: "Would you like to revoke the opinion request to %{email} ?"
|
||||
remind: "Would you like to remind %{email} ?"
|
||||
|
|
|
@ -21,6 +21,9 @@ fr:
|
|||
question_answer:
|
||||
true: oui
|
||||
false: non
|
||||
question_answer_with_count:
|
||||
true: "oui : %{count}"
|
||||
false: "non : %{count}"
|
||||
confirmation:
|
||||
revoke: "Souhaitez-vous révoquer la demande d’avis à %{email} ?"
|
||||
remind: "Souhaitez-vous relancer %{email} ?"
|
||||
|
|
Loading…
Reference in a new issue