add code postal, city code and department infos in view
This commit is contained in:
parent
a70e7ca903
commit
ce1cd4240c
3 changed files with 19 additions and 7 deletions
|
@ -8,17 +8,23 @@
|
|||
= champ.rnf_id
|
||||
= render Dsfr::CopyButtonComponent.new(text: champ.rnf_id, title: t("activemodel.attributes.rnf_champ.paste"), success: t("activemodel.attributes.rnf_champ.paste_success"))
|
||||
|
||||
- ['title', 'email', 'phone', 'address', 'status'].each do |scope|
|
||||
- ['title', 'email', 'phone','status'].each do |scope|
|
||||
- if champ.data[scope].present?
|
||||
= render Dossiers::RowShowComponent.new(label: t("activemodel.attributes.rnf_champ.data.#{scope}")) do |c|
|
||||
- if scope == 'address'
|
||||
- c.with_value do
|
||||
%p= champ.data[scope]['label']
|
||||
- else
|
||||
- c.with_value do
|
||||
%p= champ.data[scope]
|
||||
- c.with_value do
|
||||
%p= champ.data[scope]
|
||||
|
||||
- ['createdAt', 'updatedAt', 'dissolvedAt'].each do |scope|
|
||||
- if champ.data[scope].present?
|
||||
= render Dossiers::RowShowComponent.new(label: t("activemodel.attributes.rnf_champ.data.#{scope}")) do |c|
|
||||
- c.with_value do
|
||||
%p= l(champ.data[scope].to_date)
|
||||
|
||||
- if champ.data['address'].present?
|
||||
- ['label', 'cityCode', 'postalCode'].each do |scope|
|
||||
= render Dossiers::RowShowComponent.new(label: t("activemodel.attributes.rnf_champ.data.#{scope}")) do |c|
|
||||
- c.with_value do
|
||||
%p= champ.data['address'][scope]
|
||||
= render Dossiers::RowShowComponent.new(label: t("activemodel.attributes.rnf_champ.data.department")) do |c|
|
||||
- c.with_value do
|
||||
%p= "#{champ.data['address']['departmentCode']} – #{champ.data['address']['departmentName']}"
|
||||
|
|
|
@ -12,6 +12,9 @@ en:
|
|||
dissolvedAt: Dissolved at
|
||||
address: Address
|
||||
status: Status
|
||||
cityCode: City code
|
||||
postalCode: Postal code
|
||||
department: Department
|
||||
paste: Copy the RNF to the clipboard
|
||||
paste_success: The RNF has been copied to the clipboard
|
||||
activerecord:
|
||||
|
|
|
@ -12,6 +12,9 @@ fr:
|
|||
dissolvedAt: Dissoute le
|
||||
address: Adresse
|
||||
status: Statut
|
||||
cityCode: Code INSEE
|
||||
postalCode: Code postal
|
||||
department: Département
|
||||
paste: Copier le RNF dans le presse-papier
|
||||
paste_success: Le RNF a été copié dans le presse-papier
|
||||
activerecord:
|
||||
|
|
Loading…
Reference in a new issue