Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Merge branch 'master' of git@github.com:newscloud/n2

  • Loading branch information...
commit 71cbbb2b484a6c3d5a72978f538e436febc2e4ac 2 parents 7346533 + bfabebb
Russell authored
View
2  app/controllers/users_controller.rb
@@ -57,6 +57,8 @@ def show
@actions = @user.comments.newest
elsif @curr_action == 'likes'
@actions = @user.votes.newest
+ elsif @curr_action == 'all_actions'
+ @actions = @user.newest_actions
else
@actions = false
end
View
25 app/views/shared/feed_items/_article.fbml.haml
@@ -1,13 +1,16 @@
-# expects 'article => @article'
-.storyBlockWrap
- .feed_poster
- .avatar
- = local_linked_profile_pic article.user, :size => 'square', :width => '30'
- %h3
- %span.bold= t('.blurb', :fb_name => local_linked_profile_name(article.user))
- = t('.blurb_date', :date => time_ago_in_words(article.created_at))
- %p.storyHead
- = link_to article.title, article_path(article)
- %p.storyCaption
- = linked_story_caption article
+%li
+ .thumb
+ - if article.images.present?
+ = image_tag article.images.first.url(:thumb)
+ - else
+ = image_tag ('default/default_thumb_b.gif', :width => "100%")
+ .storyBlockWrap.storyBlockSpacer
+ %h2.storyHead= link_to article.title, article_path(article)
+ %p.storyCaption= linked_story_caption article
+ .profilePic= local_linked_profile_pic article.user
+ .storyBlockMeta.float_left
+ %h3= t('.stories_posted_by', :fb_name => local_linked_profile_name(article.user), :date => time_ago_in_words(article.created_at))
+ %span.btnComment.float_left== #{like_link article} #{article.votes_tally}
+ %span.btnComment.float_left== #{link_to t('comments'), story_path(article, :anchor => "commentListTop")} #{article.comments_count}
View
25 app/views/shared/feed_items/_article.html.haml
@@ -1,13 +1,16 @@
-# expects 'article => @article'
-.storyBlockWrap
- .feed_poster
- .avatar
- = local_linked_profile_pic article.user, :size => 'square', :width => '30'
- %h3
- %span.bold= t('.blurb', :fb_name => local_linked_profile_name(article.user))
- = t('.blurb_date', :date => time_ago_in_words(article.created_at))
- %p.storyHead
- = link_to article.title, article_path(article)
- %p.storyCaption
- = linked_story_caption article
+%li
+ .thumb
+ - if article.images.present?
+ = image_tag article.images.first.url(:thumb)
+ - else
+ = image_tag ('default/default_thumb_b.gif', :width => "100%")
+ .storyBlockWrap.storyBlockSpacer
+ %h2.storyHead= link_to article.title, article_path(article)
+ %p.storyCaption= linked_story_caption article
+ .profilePic= local_linked_profile_pic article.user
+ .storyBlockMeta.float_left
+ %h3= t('.stories_posted_by', :fb_name => local_linked_profile_name(article.user), :date => time_ago_in_words(article.created_at))
+ %span.btnComment.float_left== #{like_link article} #{article.votes_tally}
+ %span.btnComment.float_left== #{link_to t('comments'), story_path(article, :anchor => "commentListTop")} #{article.comments_count}
View
26 app/views/shared/feed_items/_comment.fbml.haml
@@ -1,12 +1,20 @@
-# expects 'comment => @comment'
-.storyBlockWrap
- .feed_poster
- .avatar
- = local_linked_profile_pic comment.user, :size => 'square', :width => '30'
+%li
+ .thumb
+ - if comment.commentable.images.present?
+ = image_tag comment.commentable.images.first.url(:thumb)
+ - else
+ = image_tag ('default/default_thumb_b.gif', :width => "100%")
+ .storyBlockWrap.storyBlockSpacer
+ %blockquote
+ .quotes
+ %p= linked_comment_caption comment
+ .profilePic= local_linked_profile_pic comment.user, :width => '30px', :height => '30px'
%h3
- %span.bold= t('.blurb', :fb_name => local_linked_profile_name(comment.user), :story => link_to(comment.commentable.title, comment.commentable))
- = t('.blurb_date', :date => time_ago_in_words((comment.created_at || comment.date)))
- %blockquote
- .quotes
- %p= linked_comment_caption comment
+ = t('posted_by', :fb_name => local_linked_profile_name(comment.user), :date => time_ago_in_words(comment.created_at || comment.date))
+ %h3
+ Re:
+ = link_to caption(comment.commentable.title,120), comment.commentable
+ %span.btnComment.float_left== #{like_link comment.commentable} #{comment.commentable.votes_tally}
+ %span.btnComment== #{link_to t('comments'), content_path(comment.commentable, :anchor => "commentListTop")} #{comment.commentable.comments_count}
View
26 app/views/shared/feed_items/_comment.html.haml
@@ -1,12 +1,20 @@
-# expects 'comment => @comment'
-.storyBlockWrap
- .feed_poster
- .avatar
- = local_linked_profile_pic comment.user, :size => 'square', :width => '30'
+%li
+ .thumb
+ - if comment.commentable.images.present?
+ = image_tag comment.commentable.images.first.url(:thumb)
+ - else
+ = image_tag ('default/default_thumb_b.gif', :width => "100%")
+ .storyBlockWrap.storyBlockSpacer
+ %blockquote
+ .quotes
+ %p= linked_comment_caption comment
+ .profilePic= local_linked_profile_pic comment.user, :width => '30px', :height => '30px'
%h3
- %span.bold= t('.blurb', :fb_name => local_linked_profile_name(comment.user), :story => link_to(comment.commentable.title, comment.commentable))
- = t('.blurb_date', :date => time_ago_in_words((comment.created_at || comment.date)))
- %blockquote
- .quotes
- %p= linked_comment_caption comment
+ = t('posted_by', :fb_name => local_linked_profile_name(comment.user), :date => time_ago_in_words(comment.created_at || comment.date))
+ %h3
+ Re:
+ = link_to caption(comment.commentable.title,120), comment.commentable
+ %span.btnComment.float_left== #{like_link comment.commentable} #{comment.commentable.votes_tally}
+ %span.btnComment== #{link_to t('comments'), content_path(comment.commentable, :anchor => "commentListTop")} #{comment.commentable.comments_count}
View
25 app/views/shared/feed_items/_story.fbml.haml
@@ -1,13 +1,16 @@
-# expects 'story => @story'
-.storyBlockWrap
- .feed_poster
- .avatar
- = local_linked_profile_pic story.user, :size => 'square', :width => '30'
- %h3
- %span.bold= t('.blurb', :fb_name => local_linked_profile_name(story.user))
- = t('.blurb_date', :date => time_ago_in_words(story.created_at))
- %p.storyHead
- = link_to story.title, story_path(story)
- %p.storyCaption
- = linked_story_caption story
+%li
+ .thumb
+ - if story.images.present?
+ = image_tag story.images.first.url(:thumb)
+ - else
+ = image_tag ('default/default_thumb_b.gif', :width => "100%")
+ .storyBlockWrap.storyBlockSpacer
+ %h2.storyHead= link_to story.title, story_path(story)
+ %p.storyCaption= linked_story_caption story
+ .profilePic= local_linked_profile_pic story.user
+ .storyBlockMeta.float_left
+ %h3= t('posted_by', :fb_name => local_linked_profile_name(story.user), :date => time_ago_in_words(story.created_at))
+ %span.btnComment.float_left== #{like_link story} #{story.votes_tally}
+ %span.btnComment.float_left== #{link_to t('comments'), story_path(story, :anchor => "commentListTop")} #{story.comments_count}
View
25 app/views/shared/feed_items/_story.html.haml
@@ -1,13 +1,16 @@
-# expects 'story => @story'
-.storyBlockWrap
- .feed_poster
- .avatar
- = local_linked_profile_pic story.user, :size => 'square', :width => '30'
- %h3
- %span.bold= t('.blurb', :fb_name => local_linked_profile_name(story.user))
- = t('.blurb_date', :date => time_ago_in_words(story.created_at))
- %p.storyHead
- = link_to story.title, story_path(story)
- %p.storyCaption
- = linked_story_caption story
+%li
+ .thumb
+ - if story.images.present?
+ = image_tag story.images.first.url(:thumb)
+ - else
+ = image_tag ('default/default_thumb_b.gif', :width => "100%")
+ .storyBlockWrap.storyBlockSpacer
+ %h2.storyHead= link_to story.title, story_path(story)
+ %p.storyCaption= linked_story_caption story
+ .profilePic= local_linked_profile_pic story.user
+ .storyBlockMeta.float_left
+ %h3= t('posted_by', :fb_name => local_linked_profile_name(story.user), :date => time_ago_in_words(story.created_at))
+ %span.btnComment.float_left== #{like_link story} #{story.votes_tally}
+ %span.btnComment.float_left== #{link_to t('comments'), story_path(story, :anchor => "commentListTop")} #{story.comments_count}
View
10 app/views/shared/feed_items/_vote.fbml.haml
@@ -1,9 +1,7 @@
-# expects 'vote => @vote'
-.storyBlockWrap
- .feed_poster
- .avatar
- = local_linked_profile_pic vote.voter, :size => 'square', :width => '30'
+%li
+ .storyBlockWrap.storyBlockSpacer
%h3
- %span.bold= t('.blurb', :fb_name => local_linked_profile_name(vote.voter), :voteable_type => voteable_type_name(vote), :voteable_link => voteable_type_link(vote))
- = t('.blurb_date', :date => time_ago_in_words(vote.created_at))
+ =t('.blurb', :fb_name => local_linked_profile_name(vote.voter), :voteable_type => voteable_type_name(vote), :voteable_link => voteable_type_link(vote))
+ =t('.blurb_date', :date => time_ago_in_words(vote.created_at))
View
10 app/views/shared/feed_items/_vote.html.haml
@@ -1,9 +1,7 @@
-# expects 'vote => @vote'
-.storyBlockWrap
- .feed_poster
- .avatar
- = local_linked_profile_pic vote.voter, :size => 'square', :width => '30'
+%li
+ .storyBlockWrap.storyBlockSpacer
%h3
- %span.bold= t('.blurb', :fb_name => local_linked_profile_name(vote.voter), :voteable_type => voteable_type_name(vote), :voteable_link => voteable_type_link(vote))
- = t('.blurb_date', :date => time_ago_in_words(vote.created_at))
+ =t('.blurb', :fb_name => local_linked_profile_name(vote.voter), :voteable_type => voteable_type_name(vote), :voteable_link => voteable_type_link(vote))
+ =t('.blurb_date', :date => time_ago_in_words(vote.created_at))
View
4 app/views/users/show.fbml.haml
@@ -78,4 +78,6 @@
%li.actionFeedItem
= build_feed_item(action, action.class.name)
#col_right
- = render :partial => 'shared/sidebar/top_stories', :locals => { :top_stories => @top_stories }
+ = render :partial => 'shared/sidebar/top_stories', :locals => { :top_stories => @top_stories }
+ = render :partial => 'shared/ads_banner' ,:locals => { :slot_data => @ad_skyscraper }
+
View
4 app/views/users/show.html.haml
@@ -78,4 +78,6 @@
%li.actionFeedItem
= build_feed_item(action, action.class.name)
#col_right
- = render :partial => 'shared/sidebar/top_stories', :locals => { :top_stories => @top_stories }
+ = render :partial => 'shared/sidebar/top_stories', :locals => { :top_stories => @top_stories }
+ = render :partial => 'shared/ads_banner' ,:locals => { :slot_data => @ad_skyscraper }
+
Please sign in to comment.
Something went wrong with that request. Please try again.