Merge branch 'mysql' of github.com:diaspora/diaspora into mysql

This commit is contained in:
Sarah Mei 2010-12-28 20:04:34 -08:00
commit c1e036d4f7
6 changed files with 6 additions and 5 deletions

View file

@ -71,7 +71,7 @@ class UsersController < ApplicationController
@person = @user.person
@profile = @user.profile
@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 ||= 1

View file

@ -3,6 +3,7 @@
# the COPYRIGHT file.
#
class Notification < ActiveRecord::Base
require File.join(Rails.root, 'lib/diaspora/web_socket')
include Diaspora::Socketable
belongs_to :recipient, :class_name => 'User'

View file

@ -36,7 +36,7 @@
- notes.each do |note|
%li.message{:data=>{:guid => note.id}, :class => "#{note.unread ? 'unread' : ''}"}
%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)
%span.time= "#{t('ago', :time => time_ago_in_words(note.created_at))}"

View file

@ -5,5 +5,5 @@
= 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)

View file

@ -37,7 +37,7 @@ When /^I wait for the aspects page to load$/ do
end
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
When /^I wait for the ajax to finish$/ do

View file

@ -12,7 +12,7 @@ module NavigationHelpers
when /^my acceptance form page$/
accept_user_invitation_path(:invitation_token => @me.invitation_token)
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$/
person_path(User.find_by_email($1).person)
when /^"(\/.*)"/