From cebcf5783d88eaae0e7ad98065e0b2c446f80578 Mon Sep 17 00:00:00 2001 From: decabeza Date: Tue, 19 Mar 2019 18:07:40 +0100 Subject: [PATCH] Refactor proposed action --- app/views/dashboard/_proposed_action.html.erb | 36 ++++++++----------- 1 file changed, 15 insertions(+), 21 deletions(-) diff --git a/app/views/dashboard/_proposed_action.html.erb b/app/views/dashboard/_proposed_action.html.erb index 5c653efef..11cb29138 100644 --- a/app/views/dashboard/_proposed_action.html.erb +++ b/app/views/dashboard/_proposed_action.html.erb @@ -16,28 +16,22 @@

<%= l(proposed_action.executed_actions.find_by(proposal: proposal).executed_at.to_date) %>

- <% if proposed_action.description.present? %> - - <%= t("dashboard.recommended_actions.show_description") %> - -
- <%= proposed_action.description.html_safe %> -
- <% end %> - <% else %> - <% if proposed_action.description.present? %> - - <%= t("dashboard.recommended_actions.show_description") %> - -
- <%= proposed_action.description.html_safe %> -
- <% end %> - <% proposed_action.links.each do |link| %> -

<%= link_to link.label, link.url, target: "_blank" %>

- <% end %> - <%= render partial: 'document', collection: proposed_action.documents %> <% end %> + + <% if proposed_action.description.present? %> + + <%= t("dashboard.recommended_actions.show_description") %> + +
+ <%= proposed_action.description.html_safe %> +
+ <% end %> + + <% proposed_action.links.each do |link| %> +

<%= link_to link.label, link.url, target: "_blank" %>

+ <% end %> + + <%= render partial: 'document', collection: proposed_action.documents %>