Sha256: afefdc2041104de1b1803f7f4f628e142f2db4ba3e8561c55dc03fd8f236c65f

Contents?: true

Size: 689 Bytes

Versions: 2

Compression:

Stored size: 689 Bytes

Contents

<%= will_paginate @posts, :params => { :pagination => nil } %>
<%= ajax_pagination_loadzone do %>
  <% @posts.each do |post| %>
    <div style="border-bottom: 1px solid black; padding-bottom: 10px;">
      <p><h3><%= post.title %></h3><i>Published on <%= post.published_at.strftime('%d %B %Y') if post.published_at? %></i></p>
      <%= simple_format(post.content) %>
      <%= link_to 'Show', post %>
      <% if session[:admin] %>
        | <%= link_to 'Edit', edit_post_path(post) %> |
        <%= link_to 'Destroy', post, :confirm => 'Are you sure?', :method => :delete %>
      <% end %>
    </div>
  <% end %>
<% end %>
<%= will_paginate @posts, :params => { :pagination => nil } %>

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
ajax_pagination-0.2.0 spec/rails_app/app/views/posts/_page.html.erb
ajax_pagination-0.1.0 spec/rails_app/app/views/posts/_page.html.erb