Re: [Rails] Re: after_save in plugin

2012-01-31 Thread Tsirkin Evgeny
Thanks Tom , I have actually figured out the problem. Seems like since the lib of the plugin is not reloaded on every request but the main app is .The plugin override works for first request but the original methods are restored the next one. The solution that worked for me was wrapping our

Re: [Rails] Re: captcha issue

2012-01-31 Thread sachin kewale
On Tue, Jan 31, 2012 at 11:15 AM, sachin kewale sachinkew...@gmail.comwrote: On Tue, Jan 31, 2012 at 11:00 AM, subbarao subbarao@gmail.com wrote: ** On Tuesday 31 January 2012 10:43 AM, sachin kewale wrote: On Mon, Jan 30, 2012 at 6:44 PM, subbarao subbarao@gmail.com wrote:

Re: [Rails] Fwd: [chennaiocc] Looking for Ruby on Rails developers - Remote working is also accepted.

2012-01-31 Thread vishal singh
Hello, My name is vishal Singh.I have 1 year exp in Ruby On Rails.I will work for you remotely.check my github account https://github.com/vishalsingh/multiple_upload_photo. Regards, Vishal Singh -- You received this message because you are subscribed to the Google Groups Ruby on

Re: [Rails] Re: Database level authentication

2012-01-31 Thread Colin Law
On 31 January 2012 07:53, Marcin S msporys...@gmail.com wrote: That would be second option. Since you have top posted everyone will have to scroll down to see which that is. I will repeat it here to make it easier for those reading it: prevent the user from logging in unless he uses a valid

Re: [Rails] Re: Database level authentication

2012-01-31 Thread Peter De Berdt
On 31 Jan 2012, at 10:43, Colin Law wrote: That would be second option. Since you have top posted everyone will have to scroll down to see which that is. I will repeat it here to make it easier for those reading it: prevent the user from logging in unless he uses a valid name/ password

[Rails] Instantiating a new object with a template, through an association

2012-01-31 Thread Vladiim
class Project ActiveRecord::Base has_one :template end class Template ActiveRecord::Base belongs_to :project, foreign_key: project_id end When you create a new project I'd like you to select the template from a collection of existing templates (created by an admin). The new

[Rails] Re: Gem Load Error

2012-01-31 Thread LED
On Jan 28, 12:52 am, Eduardo Rabelo oieduardorab...@gmail.com wrote: Hi group, I'm new here, and, after search and search on Bing (trollface), I decided to ask the group, I'm having this problem `to_specs': Could not find railties (= 0) amongst [bundler-1.0.21, bundler-1.0.21,

[Rails] scope in relationship

2012-01-31 Thread grentis
Hi all, is it possible to use scope in model relationships? example class Post ActiveRecord::Base scope :published, where(:published, true) end class User ActiveRecord::Base has_many :posts has_many :published_posts, class_name: 'Post' . here I would like to use the

[Rails] Problems with stylesheet_tag_link and print.js and print.css inside HTML SLIM

2012-01-31 Thread Leonardo Kreisman
Hey folks I'm getting an issue and I'm needing huge help, I got a project recently and this project was made by another guy, the guy is really good, one of the best rails programmer here in Brazil, but the problem I`m facing is that I have an html slim, and a stylesheet_tag_link referencing to

[Rails] Re: Fwd: [chennaiocc] Looking for Ruby on Rails developers - Remote working is also accepted.

2012-01-31 Thread Anushank Lal
Hello Karthik, I am B.Tech Computer Science final year student.Presently, i am taking training in a software company where i already developed a project on Ruby on Rails on Automated Report Generation for the same company.I have developed this project in Six month with 2 members in

[Rails] Emails delivery

2012-01-31 Thread Evgeniy Serykh
Hi all. Does anyone know it there are open sources rails app with api like e.g unisender? I will deploy same app and use it in my apps. -- You received this message because you are subscribed to the Google Groups Ruby on Rails: Talk group. To post to this group, send email to

[Rails] Re: Why can't I access attributes in rails model?

2012-01-31 Thread Frederick Cheung
On Jan 31, 2:29 am, Rodrigo Ruiz rodrigo.ru...@gmail.com wrote: I thought they where attr_accessor method. Thank you for clearing things up for me. To add a little more info, the attribute values are stored in the @attributes / @attributes_cache hashes Fred On Monday, January 30, 2012,

[Rails] Connect with MySql and Ruby

2012-01-31 Thread Srimanta Chakraborty
Hi everybody, I am very new in Ruby on Rails. I install ruby(1.9.2p180) and Rails(3.1.3). Also I install RubyMine3.1.1 as IDE. I successfully have done some simple simple practices. Now I want to play with database(mysql).Though I have checked so some of the URLs but unable to make out.

[Rails] Re: Separation of concerns and more...

2012-01-31 Thread Mohamad El-Husseini
Just a bump! -- You received this message because you are subscribed to the Google Groups Ruby on Rails: Talk group. To view this discussion on the web visit https://groups.google.com/d/msg/rubyonrails-talk/-/QLo8XdPmGJgJ. To post to this group, send email to rubyonrails-talk@googlegroups.com.

Re: [Rails] Connect with MySql and Ruby

2012-01-31 Thread Colin Law
On 31 January 2012 11:47, Srimanta Chakraborty li...@ruby-forum.com wrote: Hi everybody,   I am very new in Ruby on Rails. I install ruby(1.9.2p180) and Rails(3.1.3). Also I install RubyMine3.1.1 as IDE.    I successfully have done some simple simple practices. Now I want to play with

[Rails] Re: Connect with MySql and Ruby

2012-01-31 Thread Srimanta Chakraborty
Colin Law wrote in post #1043229: On 31 January 2012 11:47, Srimanta Chakraborty li...@ruby-forum.com wrote: Hi everybody, I am very new in Ruby on Rails. I install ruby(1.9.2p180) and Rails(3.1.3). Also I install RubyMine3.1.1 as IDE. I successfully have done some simple simple

[Rails] Will_paginate

2012-01-31 Thread Pedro
I'm using will_paginate on my app and it's working fine. The problem came when I had to put search field. After the search, the first page comes according to the parameter passed, but when I go to the second page, it don't brings me the second page, but a new search with no search parameter

Re: [Rails] Re: Connect with MySql and Ruby

2012-01-31 Thread Colin Law
On 31 January 2012 12:01, Srimanta Chakraborty li...@ruby-forum.com wrote: Colin Law wrote in post #1043229: On 31 January 2012 11:47, Srimanta Chakraborty li...@ruby-forum.com wrote: Hi everybody,  I am very new in Ruby on Rails. I install ruby(1.9.2p180) and Rails(3.1.3). Also I install

Re: [Rails] Will_paginate

2012-01-31 Thread Colin Law
On 31 January 2012 12:16, Pedro pogerm...@gmail.com wrote: I'm using will_paginate on my app and it's working fine. The problem came when I had to put search field. After the search, the first page comes according to the parameter passed, but when I go to the second page, it don't brings me

Re: [Rails] Re: Gem Load Error

2012-01-31 Thread Peter Vandenabeele
On Mon, Jan 30, 2012 at 3:04 PM, LED leedap...@gmail.com wrote: On Jan 28, 12:52 am, Eduardo Rabelo oieduardorab...@gmail.com wrote: Hi group, I'm new here, and, after search and search on Bing (trollface), I decided to ask the group, I'm having this problem `to_specs': Could not

[Rails] Re: Database level authentication

2012-01-31 Thread soldier.coder
http://railscasts.com/episodes/209-introducing-devise or even more fun: http://railscasts.com/episodes/235-omniauth-part-1 and http://railscasts.com/episodes/236-omniauth-part-2 On Jan 30, 11:36 am, Marcin S msporys...@gmail.com wrote: Hello, Im trying to write a simple app  for company

[Rails] Re: Database level authentication

2012-01-31 Thread soldier.coder
Sounds like you want DB to tell you the roles people play and what permissions go with those roles. On Jan 30, 2:06 pm, Marcin S msporys...@gmail.com wrote: No, I think... Its like every db on server have its own set of permissions for different users ,right? And i want to authenticate user

[Rails] Re: Re: Connect with MySql and Ruby

2012-01-31 Thread Srimanta Chakraborty
Colin Law wrote in post #1043237: On 31 January 2012 12:01, Srimanta Chakraborty li...@ruby-forum.com wrote: Please help me how to do that, what files or folders should I place gplus.to/clanlaw I am using Windows OS. In my pc, already xampp is installed. Now by making use of that mysql

[Rails] (de)serialization problem with rails 3.2

2012-01-31 Thread Florian S.
I have a custom serializer object that I use for an attribute of ActiveRecord as presented in this article: http://www.edgerails.info/articles/what-s-new-in-edge-rails/2011/03/09/custom-activerecord-attribute-serialization/index.html If I assign a value to that attribute with a form (in my case a

[Rails] Re: Rails 3: include a field from has_many through association

2012-01-31 Thread Rolando Garro
you have to do an extra loop to get recommendation_id I think your @rec_id should be an array I have had problems with has_many through in the past personally I try to avoid it. On Jan 30, 2:54 pm, Raminder G. li...@ruby-forum.com wrote: My model association is as follows: #book model class

[Rails] Re: Will_paginate

2012-01-31 Thread Pedro
Hi Colin, I found the problem, :params wasn't present on partial, so I did it: %= will_paginate @cursos , :previous_label = h(), :next_label = h(), :params = { controller=embaixada,action=cursos, search= params[:search]} % Thanks! Pedro On Jan 31, 10:33 am, Colin Law clan...@googlemail.com

Re: [Rails] Re: Database level authentication

2012-01-31 Thread Marcin S
2012/1/31 Peter De Berdt peter.de.be...@pandora.be: On 31 Jan 2012, at 10:43, Colin Law wrote: That would be second option. Since you have top posted everyone will have to scroll down to see which that is.  I will repeat it here to make it easier for those reading it: prevent the user

Re: [Rails] Database level authentication

2012-01-31 Thread Kevin Bedell
I appreciate what you're trying to do. I've been a dba in the past and have built apps using database credentials in the past. But this is a mistake. They key to being successful with rails is to leave behind the ways you did things before and embrace 'the rails way'. ActiveRecord using a single

[Rails] Re: Re: Gem install bundler works, gem bundle doesn't?

2012-01-31 Thread Martin O.
I also have this problem but I have root access. Are there any options? -- Posted via http://www.ruby-forum.com/. -- You received this message because you are subscribed to the Google Groups Ruby on Rails: Talk group. To post to this group, send email to rubyonrails-talk@googlegroups.com. To

[Rails] Why Heroku so slow?

2012-01-31 Thread Rodrigo Ruiz
Hi, I just deployed a simple crud (Rails 3.1) to heroku, and it takes more than 5 seconds to load the index page. Does anyone know how to solve this? Ps.: locally it takes less than 500 ms, and have more data at the database. Thanks in advance. -- You received this message because you are

Re: [Rails] Why Heroku so slow?

2012-01-31 Thread Javier Quarite
On Tue, Jan 31, 2012 at 11:56 AM, Rodrigo Ruiz rodrigo.ru...@gmail.comwrote: Hi, I just deployed a simple crud (Rails 3.1) to heroku, and it takes more than 5 seconds to load the index page. Does anyone know how to solve this? Ps.: locally it takes less than 500 ms, and have more data at

Re: [Rails] Why Heroku so slow?

2012-01-31 Thread Rodrigo Ruiz
That is weird, in the logs it looks like everything is working smoothly, but when I try to access it, takes me about 5 seconds. On Tue, Jan 31, 2012 at 2:59 PM, Javier Quarite jquari...@gmail.com wrote: On Tue, Jan 31, 2012 at 11:56 AM, Rodrigo Ruiz rodrigo.ru...@gmail.comwrote: Hi, I just

Re: [Rails] Why Heroku so slow?

2012-01-31 Thread Dieter Lunn
It could be the internet itself. Connections are not instantaneous. Dieter Lunn http://ubiety.ca On Tue, Jan 31, 2012 at 11:04 AM, Rodrigo Ruiz rodrigo.ru...@gmail.com wrote: That is weird, in the logs it looks like everything is working smoothly, but when I try to access it, takes me about

Re: [Rails] Why Heroku so slow?

2012-01-31 Thread Greg Akins
On Tue, Jan 31, 2012 at 12:19 PM, Dieter Lunn coder2...@gmail.com wrote: On Tue, Jan 31, 2012 at 11:04 AM, Rodrigo Ruiz rodrigo.ru...@gmail.com wrote: That is weird, in the logs it looks like everything is working smoothly, but when I try to access it, takes me about 5 seconds. I can't be

Re: [Rails] Why Heroku so slow?

2012-01-31 Thread Javier Quarite
On Tue, Jan 31, 2012 at 12:04 PM, Rodrigo Ruiz rodrigo.ru...@gmail.comwrote: That is weird, in the logs it looks like everything is working smoothly, but when I try to access it, takes me about 5 seconds. It seems that (for example) if I access the app yesterday and then I access now, the

Re: [Rails] Why Heroku so slow?

2012-01-31 Thread Peter De Berdt
On 31 Jan 2012, at 18:27, Javier Quarite wrote: That is weird, in the logs it looks like everything is working smoothly, but when I try to access it, takes me about 5 seconds. It seems that (for example) if I access the app yesterday and then I access now, the server starts again (that's

Re: [Rails] Re: has_many association and parent_id

2012-01-31 Thread Dave Aronson
On Tue, Jan 31, 2012 at 02:28, Soichi Ishida li...@ruby-forum.com wrote:  It was simpler than I thought! Rails often is. For example, a while back I was trying to do a simple timesheet system. Couldn't figure out how to force the newly entered entries into the right places. Came up with a

[Rails] Rails cache not cleared when running tests

2012-01-31 Thread morgoth
Hi. I noticed that Rails cache is not cleared between tests. I'm wondering if this shouldn't be the default behaviour. What are your thoughts on this? -- You received this message because you are subscribed to the Google Groups Ruby on Rails: Talk group. To view this discussion on the web

Re: [Rails] Database level authentication

2012-01-31 Thread Peter Vandenabeele
On Tue, Jan 31, 2012 at 5:26 PM, Kevin Bedell kbed...@gmail.com wrote: In this case, use 'device' -- Small detail, it's 'devise' (with an 's'). https://github.com/plataformatec/devise Peter -- You received this message because you are subscribed to the Google Groups Ruby on Rails: Talk

Re: [Rails] Why Heroku so slow?

2012-01-31 Thread Scott Eisenberg
I believe this to be the root issue. That's why things like reserved instances at AWS are sometimes better because they stay up all the time. I understand the Google App engine is the same way. Makes it unusable for Grails apps because spinning up the JVM is so slow the app startup even times

Re: [Rails] Why Heroku so slow?

2012-01-31 Thread Paulo Gabriel Poiati
Heroku put you app into a sleep mode when it's no accessed in a certain amount of time. Sometimes when no one visited you application in the last several minutes and whoever access it, the app will bootstrap, this process can take several minutes. But this only occurs in the first request,

[Rails] Ruby developer wanted in Hungary

2012-01-31 Thread tompatun
We are looking for web developer in our professional ruby on rails team in Hungary, who: - thinks ruby is not a jewel (Ruby experience) - stores even his/her own to-dos in database (familiarity with mysql, postgresql, oracle) - waited eagerly for HTML 5.0 as a child (html, css, javascript

[Rails] Flushing a log file

2012-01-31 Thread Paul
Hi all, Since moving to Rails 3.2.1, I haven't been able to figure out how to flush the log file in production. I found this release note (https://gist.github.com/1472145), which I don't understand: - ActiveSupport::BufferedLogger#auto_flushing is deprecated. Either set

Re: [Rails] Why Heroku so slow?

2012-01-31 Thread Peter Vandenabeele
On Tue, Jan 31, 2012 at 6:12 PM, Paulo Gabriel Poiati paulogpoi...@gmail.com wrote: Heroku put you app into a sleep mode when it's no accessed in a certain amount of time. Sometimes when no one visited you application in the last several minutes and whoever access it, the app will bootstrap,

[Rails] Why does Time#to_s(:db) force UTC?

2012-01-31 Thread Woody Peterson
I see in the original commit for Time#to_s in TimeWithZone (https:// github.com/rails/rails/commit/ 022d9f7ce6d1237c4103a2aed561220e1c0f4dcc) to_s(:db) intentionally forces UTC; conceptually, is there a reason for this? I would expect it to respect ActiveRecord::Base.default_timezone. I would

Re: [Rails] Why Heroku so slow?

2012-01-31 Thread Dave Aronson
On Tue, Jan 31, 2012 at 18:02, Peter Vandenabeele pe...@vandenabeele.com wrote: And of course, there are people pinging their own low traffic app as a work-around ... Not sure what I have to think about that practice. Is it costly/wasteful for the operator? Off the top of my pointy little

[Rails] User and Game Association help.

2012-01-31 Thread Christopher Jones
Hi all, I am currently doing work on my rails project and have hit a wall. I am quite new to Rails so at the moment only know a little bit about it. I have a users table and a games table. At the moment I am able to enter in user information as well as add new games to the games table. What I

[Rails] Re: rubygems Problem on ubuntu 10.04

2012-01-31 Thread Bob B.
Awesome that DNS fix in etc/hosts worked for me Finally .. $ sudo gem install rails Fetching: i18n-0.6.0.gem (100%) Fetching: multi_json-1.0.4.gem (100%) .. Many thanks Damian!! Bob Damian M. wrote in post #1031895: MaT 2. wrote in post #1031374: i really need help.. i hope someone can help

[Rails] Does Devise make use of a status method? Weird bug.

2012-01-31 Thread Duane Morin
So I've inherited a legacy application and I'm trying to work around the edges as I put an admin tool interface on top of the existing code base. I install Devise for user authentication, since I've used it in the past. I change none of the default code. And yet, on successful sign in, I get an

[Rails] Re: Does Devise make use of a status method? Weird bug.

2012-01-31 Thread Mike Kim
Duane, Try running rake routes in order to see which controller is being used for the create method. Hopefully that'll help narrow things down. Best, Mike On Jan 31, 7:45 pm, Duane Morin li...@ruby-forum.com wrote: So I've inherited a legacy application and I'm trying to work around the

[Rails] How do I install this gem?

2012-01-31 Thread Paet Worlds II
I'm trying to figure out how I can setup my own forums using Ruby, but I can't get passed installing nifty-generators... I haven't a clue how to install the gems... Please tell me what I'm doing wrong? I open the command prompt, I type in : gem install nifty-generators And this is what I get:

[Rails] Unable to run rake db:create:all

2012-01-31 Thread Ajit Teli
I am able to create databases (development, test, and production databases) as follows . ajit@ajit:~$ su - postgres Password: postgres@ajit:~$ psql postgres=# create DATABASE book_shelf_development; CREATE DATABASE postgres=# create

[Rails] Re: User and Game Association help.

2012-01-31 Thread CavalryJim
On Jan 31, 7:16 pm, Christopher Jones li...@ruby-forum.com wrote: Hi all, I am currently doing work on my rails project and have hit a wall. I am quite new to Rails so at the moment only know a little bit about it. I have a users table and a games table. At the moment I am able to enter in

[Rails] Devise with Rails 3

2012-01-31 Thread angel david
Hi All, Im using devise with rails 3. My requirement in this is, There are two scenarios. 1. User send reset password for their email id. 2. Admin send reset password for the user mail id, where the user is not active. When this scenario is generated, the reset instruction mail should be

[Rails] Re: How do I install this gem?

2012-01-31 Thread Robert Walker
Paet Worlds II wrote in post #1043392: gem install nifty-generators And this is what I get: Successfully installed nifty-generators-0.4.6 1 gem installed Installing ri documentation for nifty-generators-0.4.6... ERROR: While generating documentation for nifty-generators-0.4.6 ...

[Rails] insert problem with rails3

2012-01-31 Thread amvis
tran =Transaction.select(transactions.id,transactions.user_id,transactions.branch_id,transactions.customer_id,transactions.membership_type_id,transactions.bill_amount,transactions.bill_date) treport = TransactionReport.new puts from report tran.each do |u| bs = *TransactionReport*.new(