<%= plan.id %>
|
<%= translated_attribute(plan.title) %>
|
<% if plan.category %>
<%= translated_attribute plan.category.name %>
<% end %>
|
<% if current_participatory_space.scopes_enabled? %>
<% if plan.scope %>
<%= translated_attribute plan.scope.name %>
<% else %>
<%= t("decidim.scopes.global") %>
<% end %>
|
<% end %>
<%= humanize_plan_state plan.state %>
|
<% if current_component.settings.comments_enabled? and !current_settings.comments_blocked? %>
<%= plan.comments.count %>
|
<% end %>
<%= l plan.created_at, format: :decidim_short %>
|
<% if allowed_to? :edit, :plan, plan: plan %>
<%= icon_link_to "pencil", edit_plan_path(plan), t("actions.edit_plan", scope: "decidim.plans"), class: "action-icon--edit-plan" %>
<% end %>
<% if allowed_to? :close, :plan, plan: plan %>
<% if plan.closed? %>
<%= icon_link_to "action-undo", reopen_plan_path(plan), t("actions.reopen_plan", scope: "decidim.plans"), method: :post, class: "action-icon--reopen-plan" %>
<% else %>
<%= icon_link_to "ban", close_plan_path(plan), t("actions.close_plan", scope: "decidim.plans"), method: :post, class: "action-icon--close-plan" %>
<% end %>
<% end %>
<% if allowed_to? :create, :plan_answer %>
<%= icon_link_to "comment-square", edit_plan_plan_answer_path(plan_id: plan.id, id: plan.id), t("actions.answer", scope: "decidim.plans"), class: " icon--small" %>
<% else %>
<%= icon "comment-square", scope: "decidim.plans.admin", class: "action-icon action-icon--disabled" %>
<% end %>
<%= resource_permissions_link(plan) %>
<%= icon_link_to "eye", resource_locator(plan).path, t("actions.preview", scope: "decidim.plans.admin"), class: "action-icon--preview", target: :blank %>
|