Sha256: a650933266dc9d700672e4c8b9a233a0eba411ed911943b0541b4a92256cb605

Contents?: true

Size: 712 Bytes

Versions: 14

Compression:

Stored size: 712 Bytes

Contents

<h1><%= @title || "Listing posts" %></h1>

<%= magic_grid(@posts,
               [ :title,
                 {:col => :body, :to_s => Proc.new {|r| r.body.truncate(30)} },
                 :published,
                 :user,
                 { :label => 'Actions',
                   :to_s => Proc.new { |post| %>
                     <%= link_to 'Show', post %>
                     <%= link_to 'Edit', edit_post_path(post) %>
                     <%= link_to 'Destroy', post, confirm: 'Are you sure?', method: :delete %>
                   <% }
                 }
               ],
               :searchable => [:body, 'users.name'],
               :per_page => 5,
               :id => 2, :remote => true) %>

Version data entries

14 entries across 14 versions & 1 rubygems

Version Path
magic_grid-0.12.3 test/dummy/app/views/posts/by_user.html.erb
magic_grid-0.12.2 test/dummy/app/views/posts/by_user.html.erb
magic_grid-0.12.1 test/dummy/app/views/posts/by_user.html.erb
magic_grid-0.12.0 test/dummy/app/views/posts/by_user.html.erb
magic_grid-0.11.1 test/dummy/app/views/posts/by_user.html.erb
magic_grid-0.11.0 test/dummy/app/views/posts/by_user.html.erb
magic_grid-0.10.4 test/dummy/app/views/posts/by_user.html.erb
magic_grid-0.10.3 test/dummy/app/views/posts/by_user.html.erb
magic_grid-0.10.2 test/dummy/app/views/posts/by_user.html.erb
magic_grid-0.10.1 test/dummy/app/views/posts/by_user.html.erb
magic_grid-0.10.0 test/dummy/app/views/posts/by_user.html.erb
magic_grid-0.9.3.1 test/dummy/app/views/posts/by_user.html.erb
magic_grid-0.9.3 test/dummy/app/views/posts/by_user.html.erb
magic_grid-0.9.2 test/dummy/app/views/posts/by_user.html.erb