[Rails] Re: Working with dynamic fields

2013-08-15 Thread Diego N.
Thanks Matt Jones! I will create my validations! Thanks, Diego -- 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 unsubscribe from this group and stop receiving emails from it, send an email t

[Rails] Working with dynamic fields

2013-08-14 Thread Diego N.
Hi, I'm developing a app with dynamic field using hstore ( postgres ). The app works great, but now, i'm trying to implement validations. my code is: #model .. def initialize_custom_fields class_eval do validates field.f, :presence => true end end .. #user controller def create user = U