search for: logincontroller

Displaying 20 results from an estimated 51 matches for "logincontroller".

2012 May 01
1
uninitialized constant LoginController in Ruby
...plication_controller.rb class ApplicationController < ActionController::Base # protect_from_forgery before_filter :parse_facebook_cookies def parse_facebook_cookies @facebook_cookies = Koala::Facebook::OAuth.new.get_user_info_from_cookie(cookies) end end This is my login_controller.rb class LoginController < ApplicationController def index graph = Koala::Facebook::GraphAPI.new(@facebook_cookies["access_token"]) @likes = graph.get_connections("me", "likes") end I am using Rails 3 and the error I am getting is this: uninitialized constant LoginController in R...
2006 Apr 19
6
undefined method `create_table'' for #<LoginController:0x5e60
I am geeting the foolowing error. undefined method `create_table'' for #<LoginController:0x5e60110> I wrote the crete action in application controller. I am coping ther total worng please help me! class ApplicationController < ActionController::Base model :cart model :line_item before_filter :authorize def create # create_table() yields a TableDefinition instance create_ta...
2007 Oct 23
9
Running rails specs outside of the normal project tree
I want to create a spec/regressions directory with various regressions (for my rails project). I tried the following: describe LoginController, "regression for user creation when steves_sister does not exist", :behavior_type => :controller do controller_name :login before :each do @params = { "commit"=>"Create Account", "account"=> { [snip] end But I got thi...
2008 Jan 16
4
ActionController::InvalidAuthenticityToken in LoginController
Hi, I''m having a problem trying to get a login controller working. When I try and post to my login controller I get the following error: ActionController::InvalidAuthenticityToken in LoginController#login login_controller: class LoginController < ApplicationController def login case request.method when :post if @session[''user''] = User.authenticate(@params[''username''], @params[''password'']) flash[''no...
2005 Nov 19
1
How I provide a session object to Functional Tests?
...lid_user, which tests that it''s possible to login with a valid user/password combo. Then, he talks about extracting the code he just wrote and placing it into a login method inside of test_helper.rb Once the method is there, he can re-use the login method in later functional tests of the LoginController class. So, the discussion is easy to follow and I understand it. My question: Suppose I want to test other controllers besides the LoginController. How do I make use of login in test_helper.rb to place the user object in my session object? Or in other words, How do I make test_helper.login genera...
2007 Jan 09
0
Production Mode with SCGI
...getting stack trace instead of HTTP status 500 (Application Error) and the error is logged production.log. The application works fine without SCGI. Your help is highly appreciated.... Thanx /* production.log */ # Logfile created on Thu Jan 04 16:35:43 +0530 2007 by logger.rb/1.5.2.9 Processing LoginController#login (for 127.0.0.1 at 2007-01-04 16:35:59) [GET] Session ID: c5c36f100311012d253434a7b9685ac9 Parameters: {"action"=>"login", "controller"=>"login"} Errno::EBADF (Bad file descriptor - connect(2)): c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1....
2006 May 17
2
MissingSourceFile in LoginController#login PROBLEM
Hi All, I''m new to this and having a hard time getting a ruby on rails app to work. The problem seems to be realted to sqlite3 but as far as I know sqlite3 is working properly on its own. You can check out my error messages at http://129.173.68.245 Any advice on what might be causing this problem is greatly appreciated. S. --------------------------------- All new Yahoo!
2007 Jan 19
2
route issue after update to 1.2.1
...1] INFO WEBrick 1.3.1 [2007-01-18 21:39:31] INFO ruby 1.8.5 (2006-12-04) [i386-linux] [2007-01-18 21:39:31] INFO WEBrick::HTTPServer#start: pid=6792 port=3000 Failed on first connect...(first line in log/development.log) Expected script/../config/../app/controllers/login_controller.rb to define LoginController First 2 lines in app/controllers/login_controller.rb... # contains the basic information to maintain ''users'', ''rights'' and ''roles'' class LoginController < ApplicationController First route in ''config/routes.rb'' map.conne...
2006 Apr 22
5
ActiveRBAC 0.3.1 Released
...ake extending Models in your own code easier. (#112) * Moving the constants User::DEFAULT_PASSWORD_HASH_TYPES and User::DEFAULT_STATES to private class methods with lowercased names. (CHECK FOR DEPENDENCY IN YOUR CODE) * Renaming the "redirect_to" parameter/session variable nam of LoginController to "return_to" (#103) * Adding "all_static_permissions" method to User. (#109) * Adding Version identifier as described in http://api.rails- engines.org/engines/classes/Engine.html (#104) * Removing 3 lines from user_controller.rb that expected InvalidStateTransition to be th...
2006 Apr 27
6
Functional Test Problem. Nubee, please help
ALl my controllers require the user to be logged in. SO they will be redirected to my "login" controller. How do i login first in a functional test? Im assuming i use the setup method to login the controller. This is the setup method for the Activities controller functional test: def setup @controller = ActivitiesController.new @request =
2008 Jun 02
2
Cannot log in/authenticate within RSpec Story
...everywhere I could think to, and it does not contain a username in the data hash. Additionally, I''m told that session is a nil object within the login controller if I try something like: -------------------------------------------------- Given("I am logged in") do @lc = LoginController.new @lc.authenticate(''domain'', ''username'', ''password'') end -------------------------------------------------- I''ve also tried setting the session variable directly, but after that particular Given .. do clause is finished, any s...
2008 Apr 22
2
error after sending email.(conection refused- connect(2))
...go to a page where they can enter their mail id and the login details''ll be mailed them to that mail id.after mailing them the user''ll be redirected to the login page. but after entering the mail id and clicking the button im getting error like Errno::ECONNREFUSED in LoginController#take_forgotten Connection refused - connect(2) people knows whats the problem please help me. -- Posted via http://www.ruby-forum.com/. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk&qu...
2006 Apr 19
0
My database model''s connection appears messed up.
...redirect_to(:action => :add_customer_admin) end end end I made some changes by doing a global cut and paste after I changed the tablename, but it still does not explain why there are no errors. I appears the is no instruction attemmpting to insert the data into the table Processing LoginController#add_customer_admin (for 127.0.0.1 at 2006-04-19 01:45:49) [POST] Session ID: 34381c7b5af9cb7293c7bed8eddcf935 Parameters: {"action"=>"add_customer_admin", "controller"=>"login", "customer_admin"=>{"firstnames"=>""...
2006 Feb 28
1
Oracle OraNumber problem with Authentication. Please help!
I have added an authenticator using the instructions here: http://wiki.rubyonrails.org/rails/pages/HowtoAuthenticate The LoginController sets session["employee"] to an employee. When i try to access the session["employee"] from another controller i get this error : " TypeError (no marshal_dump is defined for class OraNumber): c:/ruby/lib/ruby/1.8/pstore.rb:159:in `dump'' c:/ruby/lib/ruby/1....
2005 Dec 17
1
lost in an ActiveRecord::StatementInvalid
I have an error I don''t know how to debug. I am adding the login suport in Depot (the example in the RoR book) and LoginController#add_user throws ActiveRecord::StatementInvalid in an innocent /login/add_user GET request. The trace goes down to a call to SQLiteAdapter#table_structure, and the source code suggests what''s happening is that "PRAGMA table_structure(#{table_name})" is returning empty metad...
2005 Dec 29
1
Posting to a separate controller in a functional test
Hi, I need to post to a controller to log in a user in a functional test, but I''m not sure what to do to post to a separate controller. I''ve tried: post { :controller => :account, :action => :do_login }, { bla bla bla } But that doesnt seem to have worked. Help? Mitch -- Posted via http://www.ruby-forum.com/.
2008 Oct 16
2
rails and security
Hi, I am wondering if there is a way to secure rails application logs ? My issue is that I discovered that form parameters are shown in clear in the logs. So when users are authenticating, you see the login and password in clear Processing LoginController#index (for xxxxx at 2008-10-16 11:22:43) [POST] Session ID: 8cb95e2e50332added5715eff9e84938 Parameters: {"authenticity_token"=>"f2ccf4bf93a1a334e5b3ed227eef84e12fafbbf6", "action"=>"index", "controller"=>"login", "passwo...
2008 Oct 10
16
rspec - undefined method `describe'' for main:Object
When i run a spec file i am getting the following error D:\Diwakar\spec_diwa\spec\controllers>spec sandbox_controller_spec.rb c:/ruby/lib/ruby/gems/1.8/gems/rspec-0.5.15/lib/spec/api/sugar.rb:17:in `method_ missing'': undefined method `describe'' for main:Object (NoMethodError) from ./sandbox_controller_spec.rb:7 from
2007 Dec 04
1
ssl_required being ignored?
...s like it did before I added those two lines. What have I missed? I believe ssl is working on my server, as I can actually change any address in my app to https instead of http, and it works fine, but it seems to be ignoring the ssl_required line. Here is a taste of what I''ve got: class LoginController < ApplicationController ssl_required :login before_filter :authorize, :except => [:login, :index] layout ''public'' def login ... end ... end Any help would be greatly appreciated. Hopefully I''ve just missed something simple, but as I said, I'&...
2006 Mar 08
3
Namespace & Organisation Conventions
Hi All I wanted a little advice on the convention for namespace usage and organisation of code. I originally used PHP and often had an "admin" backend that performed the various admin tasks with users, and data Then I had a front-end often situated at the root that had user services. I''m trying to emulate this in Rails but feel I''m missing a significant point here and