Sha256: 6130e2d18fb65964b06901b43e11781c2e5477b8cc2ac365d8779dfdbede6a07

Contents?: true

Size: 1.15 KB

Versions: 5

Compression:

Stored size: 1.15 KB

Contents

<% if admin_allowed_to?(:hide_proposal, :proposals, extra_context = { proposal: proposal }, chain = [::Decidim::ReportingProposals::Admin::Permissions]) %>
  <% if proposal.reported? %>
    <%= icon_link_to "trash", decidim_admin_reporting_proposals.hide_proposal_path(id: proposal),
                     t("actions.hide", scope: "decidim.moderations"), method: :put, class: "action-icon" %>
  <% else %>
    <%= cell("decidim/flag_modal", proposal, modal_id: "flagModal#{proposal.id}") %>
    <button type="button" class="link-alt"
            data-open="<%= current_user.present? ? "flagModal#{proposal.id}" : "loginModal" %>"
            title="<%= t("report", scope: "decidim.proposals.proposals.show") %>"
            aria-controls="<%= current_user.present? ? "flagModal#{proposal.id}" : "loginModal" %>"
            aria-haspopup="true"
            tabindex="0"
            style="color:#97a2b2; cursor: pointer">
      <%= icon "flag", aria_hidden: true, class: "action-icon--preview", role: "img", "aria-hidden": true %>
      <span class="show-for-sr">
    <%= t("report", scope: "decidim.proposals.proposals.show") %>
  </span>
    </button>
  <% end %>
<% end %>

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
decidim-reporting_proposals-0.5.2 app/views/decidim/reporting_proposals/admin/proposals/_proposal_td_hide.html.erb
decidim-reporting_proposals-0.5.1 app/views/decidim/reporting_proposals/admin/proposals/_proposal_td_hide.html.erb
decidim-reporting_proposals-0.5.0 app/views/decidim/reporting_proposals/admin/proposals/_proposal_td_hide.html.erb
decidim-reporting_proposals-0.4.2 app/views/decidim/reporting_proposals/admin/proposals/_proposal_td_hide.html.erb
decidim-reporting_proposals-0.2.0 app/views/decidim/reporting_proposals/admin/proposals/_proposal_td_hide.html.erb