Sha256: 4f5e12204fec5b40e8614edc61f27cb08db77af8755e7c1bab7b005fbc1aacd0
Contents?: true
Size: 863 Bytes
Versions: 4
Compression:
Stored size: 863 Bytes
Contents
<% if policy(Proclaim::Post).new? %> <%= link_to 'New Post', new_post_path %> <% end %> <% if @posts.empty? %> <p>No posts have been made, yet.</p> <% else %> <% @posts.each do |post| %> <h1><%= link_to post.title, post %></h1> <div id = "post_<%= post.id %>"> <% excerpt = post.excerpt %> <span class = "excerpt"><%= excerpt %></span> <% if excerpt.length < post.body.length %> . . . <%= link_to "(more)", post %> <% end %> </div> <div class = "post_excerpt_information"> <div style = "float: right;"> <% if policy(post).edit? %> <%= link_to 'Edit', edit_post_path(post) %> <% end %> <% if policy(post).destroy? %> <%= link_to 'Delete', post, method: :delete, data: { confirm: 'Are you sure?' } %> <% end %> </div> <%= post.author.send(Proclaim.author_name_method) %> </div> <% end %> <% end %>
Version data entries
4 entries across 4 versions & 1 rubygems