Sha256: a0ad7ccae4f52d164cac3caea6689998360da0639708b0592c46dd48de0a7da5

Contents?: true

Size: 1.48 KB

Versions: 22

Compression:

Stored size: 1.48 KB

Contents

<%= decidim_form_for @form,
                     method: :patch,
                     url: voting_path(@current_voting),
                     html: { class: "form edit_voting" } do |f| %>
  <%= render partial: "form", object: f %>
  <div class="button--double form-general-submit">
    <%= f.submit t("votings.edit.update", scope: "decidim.votings.admin"), class: "button", disabled: !allowed_to?(:update, :voting, voting: current_voting) %>

    <% if allowed_to? :publish, :voting, voting: @current_voting %>
      <% if @current_voting.published? %>
        <%= link_to t("votings.actions.unpublish", scope: "decidim.votings.admin"),
                    url_for(action: :unpublish, id: @current_voting, controller: "votings"),
                    method: :put,
                    class: "button muted" %>
      <% else %>
        <%= link_to t("votings.actions.publish", scope: "decidim.votings.admin"),
                    url_for(action: :publish, id: @current_voting, controller: "votings"),
                    method: :put,
                    class: "button hollow" %>
      <% end %>
    <% end %>

    <% if allowed_to? :destroy, :voting, voting: @current_voting %>
      <%= link_to t("votings.actions.destroy", scope: "decidim.votings.admin"),
                  @current_voting,
                  method: :delete,
                  class: "alert button",
                  data: { confirm: t("votings.actions.confirm_destroy", scope: "decidim.votings.admin") } %>
    <% end %>
  </div>
<% end %>

Version data entries

22 entries across 22 versions & 1 rubygems

Version Path
decidim-elections-0.27.3 app/views/decidim/votings/admin/votings/edit.html.erb
decidim-elections-0.26.7 app/views/decidim/votings/admin/votings/edit.html.erb
decidim-elections-0.26.5 app/views/decidim/votings/admin/votings/edit.html.erb
decidim-elections-0.27.2 app/views/decidim/votings/admin/votings/edit.html.erb
decidim-elections-0.27.1 app/views/decidim/votings/admin/votings/edit.html.erb
decidim-elections-0.26.4 app/views/decidim/votings/admin/votings/edit.html.erb
decidim-elections-0.27.0 app/views/decidim/votings/admin/votings/edit.html.erb
decidim-elections-0.26.3 app/views/decidim/votings/admin/votings/edit.html.erb
decidim-elections-0.27.0.rc2 app/views/decidim/votings/admin/votings/edit.html.erb
decidim-elections-0.27.0.rc1 app/views/decidim/votings/admin/votings/edit.html.erb
decidim-elections-0.26.2 app/views/decidim/votings/admin/votings/edit.html.erb
decidim-elections-0.26.1 app/views/decidim/votings/admin/votings/edit.html.erb
decidim-elections-0.26.0 app/views/decidim/votings/admin/votings/edit.html.erb
decidim-elections-0.26.0.rc2 app/views/decidim/votings/admin/votings/edit.html.erb
decidim-elections-0.26.0.rc1 app/views/decidim/votings/admin/votings/edit.html.erb
decidim-elections-0.25.2 app/views/decidim/votings/admin/votings/edit.html.erb
decidim-elections-0.25.1 app/views/decidim/votings/admin/votings/edit.html.erb
decidim-elections-0.25.0 app/views/decidim/votings/admin/votings/edit.html.erb
decidim-elections-0.25.0.rc4 app/views/decidim/votings/admin/votings/edit.html.erb
decidim-elections-0.25.0.rc3 app/views/decidim/votings/admin/votings/edit.html.erb