Merge branch 'master' of github.com:diaspora/diaspora
This commit is contained in:
commit
92a2df5c77
5 changed files with 7 additions and 22 deletions
|
|
@ -62,8 +62,11 @@ def warzombie
|
||||||
|
|
||||||
backer_number = YAML.load_file(Rails.root.join('config','backer_number.yml'))[:seed_number].to_i
|
backer_number = YAML.load_file(Rails.root.join('config','backer_number.yml'))[:seed_number].to_i
|
||||||
username = backer_info[backer_number]['username'].gsub(/ /,'').downcase
|
username = backer_info[backer_number]['username'].gsub(/ /,'').downcase
|
||||||
|
|
||||||
|
@fixture_name = File.dirname(__FILE__) + "../../../public/images/users/#{username}.jpg"
|
||||||
|
|
||||||
photo = current_user.post(:photo, :album_id => album.id,
|
photo = current_user.post(:photo, :album_id => album.id,
|
||||||
:user_file => "public/images/users/#{username}.jpg")
|
:user_file => "")
|
||||||
|
|
||||||
current_user.update_profile(:image_url => photo.url)
|
current_user.update_profile(:image_url => photo.url)
|
||||||
end
|
end
|
||||||
|
|
|
||||||
|
|
@ -6,17 +6,12 @@ class StatusMessagesController < ApplicationController
|
||||||
@status_message = current_user.post(:status_message, params[:status_message])
|
@status_message = current_user.post(:status_message, params[:status_message])
|
||||||
|
|
||||||
if @status_message.created_at
|
if @status_message.created_at
|
||||||
flash[:notice] = "Successfully created status message."
|
|
||||||
render :nothing => true
|
render :nothing => true
|
||||||
else
|
else
|
||||||
render :action => 'new'
|
redirect_to root_url
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
def new
|
|
||||||
@status_message = StatusMessage.new
|
|
||||||
end
|
|
||||||
|
|
||||||
def destroy
|
def destroy
|
||||||
@status_message = StatusMessage.where(:id => params[:id]).first
|
@status_message = StatusMessage.where(:id => params[:id]).first
|
||||||
@status_message.destroy
|
@status_message.destroy
|
||||||
|
|
|
||||||
|
|
@ -1,13 +0,0 @@
|
||||||
- title "New Status Message"
|
|
||||||
|
|
||||||
= form_for @status_message, :remote => true do |f|
|
|
||||||
= f.error_messages
|
|
||||||
%p
|
|
||||||
= f.label :message
|
|
||||||
%br
|
|
||||||
= f.text_field :message
|
|
||||||
%p
|
|
||||||
= f.submit
|
|
||||||
|
|
||||||
|
|
||||||
%p= link_to "Back to List", status_messages_path
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
development:
|
development:
|
||||||
debug: false
|
debug: false
|
||||||
socket_debug : true
|
socket_debug : false
|
||||||
socket_port: 8080
|
socket_port: 8080
|
||||||
pubsub_server: 'https://pubsubhubbub.appspot.com/'
|
pubsub_server: 'https://pubsubhubbub.appspot.com/'
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,7 @@
|
||||||
Diaspora::Application.routes.draw do
|
Diaspora::Application.routes.draw do
|
||||||
resources :people, :only => [:index, :show, :destroy]
|
resources :people, :only => [:index, :show, :destroy]
|
||||||
resources :users, :except => [:create, :new]
|
resources :users, :except => [:create, :new]
|
||||||
resources :status_messages, :except => [:index]
|
resources :status_messages, :only => [:create, :destroy, :show]
|
||||||
resources :comments, :except => [:index]
|
resources :comments, :except => [:index]
|
||||||
resources :requests, :except => [:edit, :update]
|
resources :requests, :except => [:edit, :update]
|
||||||
resources :photos, :except => [:index]
|
resources :photos, :except => [:index]
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue