Revert "* postgres-copy added to jam-admin"

This reverts commit 03bfd143db.
This commit is contained in:
Seth Call 2013-06-03 06:55:00 -05:00
parent 03bfd143db
commit a4ef4b20ef
8 changed files with 18 additions and 41 deletions

View File

@ -45,7 +45,6 @@ gem "meta_search", '>= 1.1.0.pre'
gem 'fog', "~> 1.3.1"
gem 'country-select'
gem 'aasm', '3.0.16'
gem 'postgres-copy'
gem 'eventmachine', '1.0.0'
gem 'amqp', '0.9.8'

View File

@ -2,7 +2,7 @@ PATH
remote: ~/workspace/jam-db/target/ruby_package
specs:
jam_db (0.0.1)
pg_migrate (= 0.1.7)
pg_migrate (= 0.1.6)
PATH
remote: ~/workspace/jam-pb/target/ruby/jampb
@ -62,7 +62,7 @@ GEM
amq-client (0.9.12)
amq-protocol (>= 1.2.0)
eventmachine
amq-protocol (1.5.0)
amq-protocol (1.3.0)
amqp (0.9.8)
amq-client (~> 0.9.5)
amq-protocol (>= 0.9.4)
@ -77,7 +77,7 @@ GEM
bootstrap-sass (2.0.4.0)
bootstrap-will_paginate (0.0.6)
will_paginate
bourbon (3.1.6)
bourbon (3.1.4)
sass (>= 3.2.0)
thor
builder (3.0.4)
@ -122,7 +122,7 @@ GEM
factory_girl (~> 4.1.0)
railties (>= 3.0.0)
fastercsv (1.5.5)
ffi (1.8.1)
ffi (1.7.0)
fog (1.3.1)
builder
excon (~> 0.13.0)
@ -175,7 +175,7 @@ GEM
launchy (2.3.0)
addressable (~> 2.3)
libv8 (3.11.8.17)
listen (1.0.3)
listen (1.0.2)
rb-fsevent (>= 0.9.3)
rb-inotify (>= 0.9)
rb-kqueue (>= 0.2)
@ -196,7 +196,7 @@ GEM
polyamorous (~> 0.5.0)
method_source (0.8.1)
mime-types (1.23)
multi_json (1.7.3)
multi_json (1.7.2)
net-scp (1.0.4)
net-ssh (>= 1.99.1)
net-ssh (2.6.7)
@ -204,7 +204,7 @@ GEM
open4 (1.3.0)
orm_adapter (0.4.0)
pg (0.14.0)
pg_migrate (0.1.7)
pg_migrate (0.1.6)
logging (= 1.7.2)
pg (= 0.14.0)
thor (= 0.15.4)
@ -259,7 +259,7 @@ GEM
rspec-expectations (2.13.0)
diff-lcs (>= 1.1.3, < 2.0)
rspec-mocks (2.13.1)
rspec-rails (2.13.1)
rspec-rails (2.13.0)
actionpack (>= 3.0)
activesupport (>= 3.0)
railties (>= 3.0)
@ -296,7 +296,7 @@ GEM
eventmachine (>= 0.12.6)
rack (>= 1.0.0)
thor (0.15.4)
tilt (1.4.0)
tilt (1.3.7)
treetop (1.4.12)
polyglot
polyglot (>= 0.3.1)

View File

@ -1,27 +1,3 @@
class ApplicationController < ActionController::Base
protect_from_forgery
def authenticate_admin_user! #use predefined method name
session["murp"] = false
puts "session id #{session["session_id"]}"
puts "session #{session.inspect}"
puts "current_user #{current_admin_user} user_signed_in? #{user_signed_in?}"
redirect_to '/' and return if user_signed_in? && !current_user.is_admin?
authenticate_user!
end
def current_admin_user #use predefined method name
puts "current user #{current_user}"
return nil if user_signed_in? && !current_user.is_admin?
current_user
end
#def authenticate_spawn_ruby_user!
# p "oh hai: #{current_user}:redirecting3"
#
# redirect_to new_user_session_path unless current_user.try(:is_admin?)
#end
#def current_spawn_ruby_user
# return current_user
#end
end

View File

@ -1,4 +1,3 @@
module ApplicationHelper
end

View File

@ -1,3 +1,2 @@
module UsersHelper
end

View File

@ -14,4 +14,3 @@
</body>
</html>
1

View File

@ -55,7 +55,7 @@ ActiveAdmin.setup do |config|
#
# This setting changes the method which Active Admin calls
# within the controller.
config.authentication_method = :authenticate_admin_user!
#config.authentication_method = :authenticate_admin_user!
# == Current User
@ -65,7 +65,7 @@ ActiveAdmin.setup do |config|
#
# This setting changes the method which Active Admin calls
# to return the currently logged in user.
config.current_user_method = :current_admin_user
#config.current_user_method = :current_admin_user
# == Logging Out

View File

@ -2,14 +2,19 @@ JamAdmin::Application.routes.draw do
# ActiveAdmin::Devise.config,
scope ENV['RAILS_RELATIVE_URL_ROOT'] || '/' do
devise_for :users, :class_name => "JamRuby::User", :path_prefix => '/', :path => '', :path_names => {:sign_in => 'login', :sign_out => 'logout'}
devise_for :users, :class_name => "JamRuby::User", :path_prefix => '/admin', :path => '', :path_names => {:sign_in => 'login', :sign_out => 'logout'}
scope ENV['RAILS_RELATIVE_URL_ROOT'] || '/' do
root :to => "admin/dashboard#index"
ActiveAdmin.routes(self)
# The priority is based upon order of creation:
# first created -> highest priority.