about summary refs log tree commit diff stats
path: root/app/views/records
diff options
context:
space:
mode:
authorKelly Rauchenberger <fefferburbia@gmail.com>2018-07-07 16:23:04 -0400
committerKelly Rauchenberger <fefferburbia@gmail.com>2018-07-07 16:23:04 -0400
commit42d9db526d3aef2e08848d6bc587feaf3700db42 (patch)
tree29bfcb6653bb6419fa087f87de72b00b00e68fd6 /app/views/records
parentdd231a335758873dcd9024db7618837094fcc0a5 (diff)
downloadthoughts-42d9db526d3aef2e08848d6bc587feaf3700db42.tar.gz
thoughts-42d9db526d3aef2e08848d6bc587feaf3700db42.tar.bz2
thoughts-42d9db526d3aef2e08848d6bc587feaf3700db42.zip
Added tags
Blogs and streams can now be tagged. Records now show the appropriate tags for an entry. Updates work oddly, because their records show the stream's tags, since updates do not have tags themselves.

refs #2
Diffstat (limited to 'app/views/records')
-rw-r--r--app/views/records/_record.html.haml7
-rw-r--r--app/views/records/index.html.haml8
2 files changed, 8 insertions, 7 deletions
diff --git a/app/views/records/_record.html.haml b/app/views/records/_record.html.haml new file mode 100644 index 0000000..80a365c --- /dev/null +++ b/app/views/records/_record.html.haml
@@ -0,0 +1,7 @@
1%li
2 %span.description= link_to record.description, record.recordable.path
3 %ul.tags
4 %li.record-date= record.created_at.strftime("%m.%d.%y")
5 %li.entry-type{ class: "entry-type-#{record.recordable_type.downcase}" }= record.recordable_type
6 - record.recordable.taggable.tag_list.each do |tag|
7 %li.entry-tag= tag
diff --git a/app/views/records/index.html.haml b/app/views/records/index.html.haml index 200321e..4ceed2c 100644 --- a/app/views/records/index.html.haml +++ b/app/views/records/index.html.haml
@@ -1,7 +1 @@
1%ul#records %ul#records= render @records
2 - @records.each do |record|
3 %li
4 %span.description= link_to record.description, record.recordable.path
5 %ul.tags
6 %li.record-date= record.created_at.strftime("%m.%d.%y")
7 %li.entry-type{ class: "entry-type-#{record.recordable_type.downcase}" }= record.recordable_type