Add toggle description to proposed action
This commit is contained in:
@@ -10,21 +10,32 @@
|
||||
<span class="unchecked"></span>
|
||||
<% end %>
|
||||
<% end %>
|
||||
|
||||
<div class="action-content">
|
||||
<h4><%= proposed_action.title %></h4>
|
||||
|
||||
<% if proposed_action.proposals.where(id: proposal.id).any? %>
|
||||
<p><%= l(proposed_action.executed_actions.find_by(proposal: proposal).executed_at.to_date) %></p>
|
||||
<p class="inline">
|
||||
<%= l(proposed_action.executed_actions.find_by(proposal: proposal).executed_at.to_date) %>
|
||||
</p>
|
||||
<% if proposed_action.description.present? %>
|
||||
<a data-toggle="proposed_action_description_<%= dom_id(proposed_action) %>">
|
||||
<small><%= t("dashboard.recommended_actions.show_description") %></small>
|
||||
</a>
|
||||
<div id="proposed_action_description_<%= dom_id(proposed_action) %>" class="hide" data-toggler=".hide">
|
||||
<%= proposed_action.description.html_safe %>
|
||||
</div>
|
||||
<% end %>
|
||||
<% else %>
|
||||
<% if proposed_action.description.present? %>
|
||||
<p><%= proposed_action.description.html_safe %></p>
|
||||
<a data-toggle="proposed_action_description_<%= dom_id(proposed_action) %>">
|
||||
<small><%= t("dashboard.recommended_actions.show_description") %></small>
|
||||
</a>
|
||||
<div id="proposed_action_description_<%= dom_id(proposed_action) %>" class="hide" data-toggler=".hide">
|
||||
<%= proposed_action.description.html_safe %>
|
||||
</div>
|
||||
<% end %>
|
||||
|
||||
<% proposed_action.links.each do |link| %>
|
||||
<p><%= link_to link.label, link.url, target: "_blank" %></p>
|
||||
<% end %>
|
||||
|
||||
<%= render partial: 'document', collection: proposed_action.documents %>
|
||||
<% end %>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user