Sha256: 5b1b8cff61fd11618380b56f09c2fbe1cee96e0859be54352c87fb1cd5b74679

Contents?: true

Size: 1.48 KB

Versions: 18

Compression:

Stored size: 1.48 KB

Contents

<%
controller ||= params[:controller]

pagination_url_params = params.merge(:controller => controller, :action => :browse, :search => params[:search], :update => 1)
prev_url = url_for(pagination_url_params.merge(:page => page.prev.number)) if page.prev?
next_url = url_for(pagination_url_params.merge(:page => page.next.number)) if page.next?
-%>
<%= content_tag :ol, :class => ('scrollable' unless record_select_config.pagination?) do %>
  <li class="found"><%= rs_(:records_found, :count => page.pager.count,
:model => record_select_config.model.model_name.human(:count => page.pager.count).downcase) %></li>
  <% if page.prev? -%>
  <li class="pagination previous">
    <%= link_to image_tag('record_select/previous.gif', :alt => rs_(:previous)) + " " + rs_(:previous_items,
:count => page.pager.per_page),
                      {:url => prev_url},
                      {:href => prev_url, :method => :get, :remote => true} %>
  </li>
  <% end -%>
  <% page.items.each do |record| -%>
  <li class="record <%= cycle 'odd', 'even' %>" id="rs<%= record.id -%>">
    <%= render_record_from_config(record) %>
  </li>
  <% end -%>
  <% if record_select_config.pagination? && page.next? -%>
  <li class="pagination next">
  <%= link_to (rs_(:next_items, :count => page.pager.per_page) + " " + image_tag('record_select/next.gif', :alt => rs_(:next))).html_safe,
                        {:url => next_url},
                        {:href => next_url, :method => :get, :remote => true} %>
  </li>
  <% end -%>
<% end %>

Version data entries

18 entries across 18 versions & 1 rubygems

Version Path
recordselect-3.5.0 app/views/record_select/_list.html.erb
recordselect-3.4.14 app/views/record_select/_list.html.erb
recordselect-3.4.13 app/views/record_select/_list.html.erb
recordselect-3.4.11 app/views/record_select/_list.html.erb
recordselect-3.4.10 app/views/record_select/_list.html.erb
recordselect-3.4.9 app/views/record_select/_list.html.erb
recordselect-3.4.8 app/views/record_select/_list.html.erb
recordselect-3.4.7 app/views/record_select/_list.html.erb
recordselect-3.4.6 app/views/record_select/_list.html.erb
recordselect-3.4.5 app/views/record_select/_list.html.erb
recordselect-3.4.4 app/views/record_select/_list.html.erb
recordselect-3.4.3 app/views/record_select/_list.html.erb
recordselect-3.4.2 app/views/record_select/_list.html.erb
recordselect-3.4.1 app/views/record_select/_list.html.erb
recordselect-3.4.0 app/views/record_select/_list.html.erb
recordselect-3.3.9 app/views/record_select/_list.html.erb
recordselect-3.3.8 app/views/record_select/_list.html.erb
recordselect-3.3.7 app/views/record_select/_list.html.erb