<%e_pages = ActionController::Pagination::Paginator.new( self, elt.elts_count, PAGE_ELT_LENGTH, @params['page']) elts = Elt.find(:all, :conditions => "parent_id = '#{elt.id}'", :order => 'position, elts.created_on DESC', :include => :person, :limit => e_pages.items_per_page, :offset => e_pages.current.offset) %> <% if e_pages.length > 1 %>
  • <%= link_to_remote('|<', { :update => 'eltSubs_'+elt.id.to_s, :url => { :action => 'list', :id => elt, :page => e_pages.first }, :before => visual_effect(:BlindUp, 'eltSubs_'+elt.id.to_s, { :queue => 'end' }), :loaded => visual_effect(:BlindDown, 'eltSubs_'+elt.id.to_s, { :queue => 'end' }) }, { :href => url_for(:controller => 'elt', :action => 'show', :id => @elt, :page => e_pages.first)}) if e_pages.first != e_pages.current %> <%= link_to_remote('<', { :update => 'eltSubs_'+elt.id.to_s, :url => { :action => 'list', :id => elt, :page => e_pages.current.previous }, :before => visual_effect(:BlindUp, 'eltSubs_'+elt.id.to_s, { :queue => 'end' }), :loaded => visual_effect(:BlindDown, 'eltSubs_'+elt.id.to_s, { :queue => 'end' }) }, { :href => url_for(:controller => 'elt', :action => 'show', :id => @elt, :page => e_pages.current.previous )}) if e_pages.current.previous and e_pages.current.previous != e_pages.first %> <%= e_pages.current.to_i %> / <%= e_pages.length %> <%= link_to_remote('>', { :update => 'eltSubs_'+elt.id.to_s, :url => { :action => 'list', :id => elt, :page => e_pages.current.next }, :before => visual_effect(:BlindUp, 'eltSubs_'+elt.id.to_s, { :queue => 'end' }), :loaded => visual_effect(:BlindDown, 'eltSubs_'+elt.id.to_s, { :queue => 'end' }) }, { :href => url_for(:controller => 'elt', :action => 'show', :id => @elt, :page => e_pages.current.next )}) if e_pages.current.next and e_pages.current.next != e_pages.last %> <%= link_to_remote('>|', { :update => 'eltSubs_'+elt.id.to_s, :url => { :action => 'list', :id => elt, :page => e_pages.last }, :before => visual_effect(:BlindUp, 'eltSubs_'+elt.id.to_s, { :queue => 'end' }), :loaded => visual_effect(:BlindDown, 'eltSubs_'+elt.id.to_s, { :queue => 'end' }) }, { :href => url_for(:controller => 'elt', :action => 'show', :id => @elt, :page => e_pages.last)}) if e_pages.last != e_pages.current %>
  • <% end %> <%= render :partial => '/elt/elt', :collection => elts, :locals => { :eltTop => false } %> <% if e_pages.length > 1 %>
  • <%= link_to_remote('|<', { :update => 'eltSubs_'+elt.id.to_s, :url => { :action => 'list', :id => elt, :page => e_pages.first }, :before => visual_effect(:BlindUp, 'eltSubs_'+elt.id.to_s, { :queue => 'end' }), :loaded => visual_effect(:BlindDown, 'eltSubs_'+elt.id.to_s, { :queue => 'end' }) }, { :href => url_for(:controller => 'elt', :action => 'show', :id => @elt, :page => e_pages.first)}) if e_pages.first != e_pages.current %> <%= link_to_remote('<', { :update => 'eltSubs_'+elt.id.to_s, :url => { :action => 'list', :id => elt, :page => e_pages.current.previous }, :before => visual_effect(:BlindUp, 'eltSubs_'+elt.id.to_s, { :queue => 'end' }), :loaded => visual_effect(:BlindDown, 'eltSubs_'+elt.id.to_s, { :queue => 'end' }) }, { :href => url_for(:controller => 'elt', :action => 'show', :id => @elt, :page => e_pages.current.previous )}) if e_pages.current.previous and e_pages.current.previous != e_pages.first %> <%= e_pages.current.to_i %> / <%= e_pages.length %> <%= link_to_remote('>', { :update => 'eltSubs_'+elt.id.to_s, :url => { :action => 'list', :id => elt, :page => e_pages.current.next }, :before => visual_effect(:BlindUp, 'eltSubs_'+elt.id.to_s, { :queue => 'end' }), :loaded => visual_effect(:BlindDown, 'eltSubs_'+elt.id.to_s, { :queue => 'end' }) }, { :href => url_for(:controller => 'elt', :action => 'show', :id => @elt, :page => e_pages.current.next )}) if e_pages.current.next and e_pages.current.next != e_pages.last %> <%= link_to_remote('>|', { :update => 'eltSubs_'+elt.id.to_s, :url => { :action => 'list', :id => elt, :page => e_pages.last }, :before => visual_effect(:BlindUp, 'eltSubs_'+elt.id.to_s, { :queue => 'end' }), :loaded => visual_effect(:BlindDown, 'eltSubs_'+elt.id.to_s, { :queue => 'end' }) }, { :href => url_for(:controller => 'elt', :action => 'show', :id => @elt, :page => e_pages.last)}) if e_pages.last != e_pages.current %>
  • <% end %>