Re: [Rails-core] custom validations only if all attributes are valid

2012-06-25 Thread Pavel Gabriel
Steve, It's easy to reply to your post, because you have a code example :) In you case, you will have to duplicate all checks in your custom validations, that is not DRY approach. You will duplicate .to_i in all methods that will depends on age as integer. On Thursday, June 21, 2012 3:51:42 PM

Re: [Rails-core] custom validations only if all attributes are valid

2012-06-25 Thread Pavel Gabriel
Carlos, I agree with you. Technically I can check that errors are empty, but I have to do it in all my custom validations. it will not look nice :( What I offer is a two stage validation. When on the second stage you will be sure that all data in correct state and you can use it with

Re: [Rails-core] How to access an engine's method from main application?

2012-06-25 Thread A L
Thanks Ryan! :-) -- You received this message because you are subscribed to the Google Groups Ruby on Rails: Core group. To view this discussion on the web visit https://groups.google.com/d/msg/rubyonrails-core/-/docf8k_s1yEJ. To post to this group, send email to

[Rails-core] ActionView::Template::Error (undefined method `strftime' for nil:NilClass):

2012-06-25 Thread yatta20
Hello, I'm a newbie. I need help resolving this issue. I recently added a pdf to the newsletter admin section of the website and now I can no longer view page 2 of the list of pdf's. Nor can I login to see the newsletters as a student. I'm using Ruby 1.9.3, Rails 3.2.1. Here's the information

Re: [Rails-core] ActionView::Template::Error (undefined method `strftime' for nil:NilClass):

2012-06-25 Thread Ryan Bigg
Please post this to rubyonrails-talk. This list is reserved for discussion about core development of Ruby on Rails. For general issues, post them to rubyonrails-talk. Thanks. On Tuesday, 26 June 2012 at 6:00 AM, yatta20 wrote: Hello, I'm a newbie. I need help resolving this issue. I