Sha256: 9da767f5d4c6f6fb27b82d86c411ee227cba670b59a4409e8ab29d9905d70c6c

Contents?: true

Size: 1.33 KB

Versions: 3

Compression:

Stored size: 1.33 KB

Contents

<% if flash.now[:error].present? %>
  $("<%= form_selector %> <%= attribute_selector %>").addClass("is-invalid-input")
  $("<%= escape_javascript(render partial: %q(decidim/admin/shared/js-callout), locals: { css: %q(alert), text: flash.now[:error] }) %>").appendTo(".callout-wrapper");
<% end %>

<% if flash.now[:alert].present? %>
  $("<%= form_selector %> <%= attribute_selector %>").removeClass("is-invalid-input")
  $("<%= escape_javascript(render partial: %q(decidim/admin/shared/js-callout), locals: { css: %q(warning), text: flash.now[:alert] }) %>").appendTo(".callout-wrapper");
<% end %>

<% if flash.now[:notice].present? %>
  $("<%= escape_javascript(render partial: %q(decidim/admin/shared/js-callout), locals: { css: %q(success), text: flash.now[:notice] }) %>").appendTo(".callout-wrapper");

  <% proposal_ids.each do |id| %>
    $(".table-list [data-id='<%= id %>']")
      .replaceWith("<%= escape_javascript(render partial: %q(proposal-tr), locals: { proposal: proposal_find(id) }) %>");
  <% end %>

  $("<%= form_selector %> <%= attribute_selector %>").removeClass("is-invalid-input")
  $(".js-check-all").prop('checked', false);
  $(".js-check-all-resources").prop('checked', false);
  window.hideBulkActionsButton();
  window.hideBulkActionForms();
  window.showOtherActionsButtons();
  window.selectedResourcesCountUpdate();
<% end %>

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
decidim-proposals-0.28.0 app/views/decidim/proposals/admin/proposals/update_attribute.js.erb
decidim-proposals-0.28.0.rc5 app/views/decidim/proposals/admin/proposals/update_attribute.js.erb
decidim-proposals-0.28.0.rc4 app/views/decidim/proposals/admin/proposals/update_attribute.js.erb