Skip to content

Commit

Permalink
For now, only show share-reply on dashboard.
Browse files Browse the repository at this point in the history
Later, we will link correctly.
  • Loading branch information
wilkie committed Mar 24, 2011
1 parent 9ec982b commit b93cc3f
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 4 deletions.
3 changes: 3 additions & 0 deletions rstatus.rb
Original file line number Diff line number Diff line change
Expand Up @@ -124,6 +124,8 @@ class Rstatus < Sinatra::Base

@updates = current_user.timeline(params)

@timeline = true

haml :dashboard
else
haml :index, :layout => false
Expand Down Expand Up @@ -535,6 +537,7 @@ class Rstatus < Sinatra::Base
@prev_page = "?#{Rack::Utils.build_query :page => params[:page] - 1}"
end
@updates = Update.hashtag_search(@hashtag, params)
@timeline = true
haml :dashboard
end

Expand Down
10 changes: 6 additions & 4 deletions views/_updates.haml
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,12 @@
.date
%a{:href => update.url}= update.created_at.ago_in_words
.reply
%a{:href => "javascript:share('#{update.author.username}', '#{update.id}')"}="share"
|
%a{:href => "javascript:reply('#{update.author.username}')"}
reply
-# when @timeline is true, this is a list on the user's page
-unless @timeline.nil?
%a{:href => "javascript:share('#{update.author.username}', '#{update.id}')"}="share"
|
%a{:href => "javascript:reply('#{update.author.username}')"}
reply
- if updates.empty?
.empty
There's no updates here yet

0 comments on commit b93cc3f

Please sign in to comment.