mirror of
https://github.com/Growstuff/growstuff.git
synced 2026-02-05 23:21:07 -05:00
* Pull in openfarm icons, photos, info * Truncating member location * tidying up harvest display, and reducing duplication in css styles * Tiny crop chip * only show crop charts if there is data to show * Make the styles more Growstuff * Fixed links to openfarm * Updating specs to cope with new photo sources fix broken garden timeline on some pages * Update homepage blurb * Import crop companions * More fluid page * use thumbnail unless the source is flickr * Messing with homepage * Added crop growing_degree_days * expect full size url on photos helper spec * formatted dates from seeds#show * tidy up places#show * Move progress bar * Quicker buttons for approve/reject crops * Remove kaminari gem * use crop cards on hierarchy page * more crops on crops#index * Wrap photo creation in transaction * Wrap crop companions in a transaction
58 lines
1.7 KiB
Plaintext
58 lines
1.7 KiB
Plaintext
- content_for :title, @author ? t('.title.author_posts', author: @author) : t('.title.default')
|
|
|
|
- content_for :breadcrumbs do
|
|
%li.breadcrumb-item= link_to 'Posts', posts_path
|
|
- if @author.present?
|
|
%li.breadcrumb-item= link_to @author, @author
|
|
%li.breadcrumb-item.active= link_to 'posts', posts_path(author: @author.slug)
|
|
|
|
%h1= @author ? t('.title.author_posts', author: @author) : t('.title.default')
|
|
|
|
= render 'layouts/nav', model: Post
|
|
|
|
= will_paginate @posts
|
|
|
|
- @posts.each do |post|
|
|
.card.post
|
|
.card-body
|
|
%h5.card-title
|
|
= link_to strip_tags(post.subject), post
|
|
- if post.comments.size.positive?
|
|
%span.badge.badge-pill.badge-info.float-right
|
|
= icon 'fas', 'comment'
|
|
|
|
= post.comments.size
|
|
%p.text-muted
|
|
Posted by
|
|
- if post.author
|
|
= link_to post.author.login_name, member_path(post.author)
|
|
- else
|
|
Member Deleted
|
|
|
|
- if post.forum
|
|
in #{link_to post.forum, post.forum}
|
|
on #{post.created_at}"
|
|
- if post.updated_at > post.created_at
|
|
and edited at #{post.updated_at}
|
|
= render 'members/tiny', member: post.author
|
|
.card-body
|
|
.post-body= display_post_truncated(post)
|
|
- post.crops.each do |crop|
|
|
= render 'crops/tiny', crop: crop
|
|
|
|
|
|
= will_paginate @posts
|
|
|
|
%p
|
|
- if @author
|
|
Subscribe to
|
|
= succeed "." do
|
|
= link_to "#{@author}'s posts RSS feed", member_posts_path(@author, format: 'rss')
|
|
|
|
- else
|
|
Subscribe to the #{ENV['GROWSTUFF_SITE_NAME']}
|
|
= link_to "posts RSS feed", posts_path(format: 'rss')
|
|
or
|
|
= succeed "." do
|
|
= link_to "comments RSS feed", comments_path(format: 'rss')
|