Merge branch 'mysql' of github.com:diaspora/diaspora into mysql
This commit is contained in:
commit
c1e036d4f7
6 changed files with 6 additions and 5 deletions
|
|
@ -71,7 +71,7 @@ class UsersController < ApplicationController
|
||||||
@person = @user.person
|
@person = @user.person
|
||||||
@profile = @user.profile
|
@profile = @user.profile
|
||||||
@services = @user.services
|
@services = @user.services
|
||||||
@requests = Request.to(@person).all
|
@requests = Request.where(:recipient_id => @person.id).all
|
||||||
|
|
||||||
@step = ((params[:step].to_i>0)&&(params[:step].to_i<5)) ? params[:step].to_i : 1
|
@step = ((params[:step].to_i>0)&&(params[:step].to_i<5)) ? params[:step].to_i : 1
|
||||||
@step ||= 1
|
@step ||= 1
|
||||||
|
|
|
||||||
|
|
@ -3,6 +3,7 @@
|
||||||
# the COPYRIGHT file.
|
# the COPYRIGHT file.
|
||||||
#
|
#
|
||||||
class Notification < ActiveRecord::Base
|
class Notification < ActiveRecord::Base
|
||||||
|
require File.join(Rails.root, 'lib/diaspora/web_socket')
|
||||||
include Diaspora::Socketable
|
include Diaspora::Socketable
|
||||||
|
|
||||||
belongs_to :recipient, :class_name => 'User'
|
belongs_to :recipient, :class_name => 'User'
|
||||||
|
|
|
||||||
|
|
@ -36,7 +36,7 @@
|
||||||
- notes.each do |note|
|
- notes.each do |note|
|
||||||
%li.message{:data=>{:guid => note.id}, :class => "#{note.unread ? 'unread' : ''}"}
|
%li.message{:data=>{:guid => note.id}, :class => "#{note.unread ? 'unread' : ''}"}
|
||||||
%span.from
|
%span.from
|
||||||
= link_to "#{note.person.name.titleize}", person_path(note.person)
|
= link_to "#{note.actor.name.titleize}", person_path(note.actor)
|
||||||
= object_link(note)
|
= object_link(note)
|
||||||
|
|
||||||
%span.time= "#{t('ago', :time => time_ago_in_words(note.created_at))}"
|
%span.time= "#{t('ago', :time => time_ago_in_words(note.created_at))}"
|
||||||
|
|
|
||||||
|
|
@ -5,5 +5,5 @@
|
||||||
= link_to t('.new', :type => object.class.to_s, :from => object.person.name), object_path(object.post)
|
= link_to t('.new', :type => object.class.to_s, :from => object.person.name), object_path(object.post)
|
||||||
|
|
||||||
|
|
||||||
= link_to "#{note.person.name.titelize}", person_path(note.person)
|
= link_to "#{note.actor.name.titelize}", person_path(note.actor)
|
||||||
= object_link(note)
|
= object_link(note)
|
||||||
|
|
|
||||||
|
|
@ -37,7 +37,7 @@ When /^I wait for the aspects page to load$/ do
|
||||||
end
|
end
|
||||||
|
|
||||||
When /^I wait for the request's profile page to load$/ do
|
When /^I wait for the request's profile page to load$/ do
|
||||||
wait_until { current_path == person_path(Request.where(:recipient_id => @me.id).first.sender) }
|
wait_until { current_path == person_path(Request.where(:recipient_id => @me.person.id).first.sender) }
|
||||||
end
|
end
|
||||||
|
|
||||||
When /^I wait for the ajax to finish$/ do
|
When /^I wait for the ajax to finish$/ do
|
||||||
|
|
|
||||||
|
|
@ -12,7 +12,7 @@ module NavigationHelpers
|
||||||
when /^my acceptance form page$/
|
when /^my acceptance form page$/
|
||||||
accept_user_invitation_path(:invitation_token => @me.invitation_token)
|
accept_user_invitation_path(:invitation_token => @me.invitation_token)
|
||||||
when /^the requestor's profile page$/
|
when /^the requestor's profile page$/
|
||||||
person_path(Request.to(@me).first.from)
|
person_path(Request.where(:recipient_id => @me.person.id).first.sender)
|
||||||
when /^"([^\"]*)"'s page$/
|
when /^"([^\"]*)"'s page$/
|
||||||
person_path(User.find_by_email($1).person)
|
person_path(User.find_by_email($1).person)
|
||||||
when /^"(\/.*)"/
|
when /^"(\/.*)"/
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue