blob: bf5073fe639e84a2c2af5ddbbfea97bcd858679d (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
|
%table#streams-index
%tr#streams-index-header-row
%th Stream Topic
%th Updates
%th Last Post
- @streams.each do |stream|
%tr
%td
= link_to stream.title, stream, class: "stream-link"
%br
%time= stream.created_at.strftime("%B #{stream.created_at.day.ordinalize}, %Y at %-I:%M:%S%P")
%td= stream.updates.size
%td
- unless stream.updates.empty?
- latest_post = stream.updates.order(created_at: :desc).first
= link_to (stripped_markdown(latest_post.body)[0, 30] + "..."), stream
%br
%time= latest_post.created_at.strftime("%B #{latest_post.created_at.day.ordinalize}, %Y at %-I:%M:%S%P")
= will_paginate @streams
|