Sha256: 52fe8010f6683fb6a0e9cd7e98402d581d03a2cf466727250b374e6a3cf594ee

Contents?: true

Size: 701 Bytes

Versions: 4

Compression:

Stored size: 701 Bytes

Contents

<% templates = Decidim::Templates::Template .where(
  target: :proposal_answer,
  templatable: [current_organization, current_component]
).order(:templatable_id) %>
<% if templates.any? %>
  <div class="row column">
    <%= javascript_pack_tag "decidim_templates_admin" %>

    <select id="proposal_answer_template_chooser" data-locale="en" data-proposal="<%= proposal.id %>" data-url="<%= decidim_admin_templates.fetch_proposal_answer_templates_url %>">
      <option value=""><%= t(".select_template") %></option>
      <% templates.each do |template| %>
        <option value="<%= template.id %>"><%= translated_attribute(template.name) %></option>
      <% end %>
    </select>
  </div>
<% end %>

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
decidim-reporting_proposals-0.5.2 app/views/decidim/templates/admin/proposal_answer_templates/_template_chooser.html.erb
decidim-reporting_proposals-0.5.1 app/views/decidim/templates/admin/proposal_answer_templates/_template_chooser.html.erb
decidim-reporting_proposals-0.5.0 app/views/decidim/templates/admin/proposal_answer_templates/_template_chooser.html.erb
decidim-reporting_proposals-0.4.2 app/views/decidim/templates/admin/proposal_answer_templates/_template_chooser.html.erb