Sha256: 3d654e9a65de530bf9158e0c4c97d2902c1b87ff5c7302d07273843fe8e5e672

Contents?: true

Size: 684 Bytes

Versions: 10

Compression:

Stored size: 684 Bytes

Contents

<% templates = Decidim::Templates::Template.where(
  target: :proposal_answer,
  templatable: current_component
).order(:templatable_id) %>

<% if templates.any? %>
  <div class="row column">
    <%= append_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

10 entries across 10 versions & 1 rubygems

Version Path
decidim-templates-0.30.0.rc3 app/views/decidim/templates/admin/proposal_answer_templates/_template_chooser.html.erb
decidim-templates-0.30.0.rc2 app/views/decidim/templates/admin/proposal_answer_templates/_template_chooser.html.erb
decidim-templates-0.30.0.rc1 app/views/decidim/templates/admin/proposal_answer_templates/_template_chooser.html.erb
decidim-templates-0.29.2 app/views/decidim/templates/admin/proposal_answer_templates/_template_chooser.html.erb
decidim-templates-0.29.1 app/views/decidim/templates/admin/proposal_answer_templates/_template_chooser.html.erb
decidim-templates-0.29.0 app/views/decidim/templates/admin/proposal_answer_templates/_template_chooser.html.erb
decidim-templates-0.29.0.rc4 app/views/decidim/templates/admin/proposal_answer_templates/_template_chooser.html.erb
decidim-templates-0.29.0.rc3 app/views/decidim/templates/admin/proposal_answer_templates/_template_chooser.html.erb
decidim-templates-0.29.0.rc2 app/views/decidim/templates/admin/proposal_answer_templates/_template_chooser.html.erb
decidim-templates-0.29.0.rc1 app/views/decidim/templates/admin/proposal_answer_templates/_template_chooser.html.erb