is "collection" a reserved word in rails 3.2, simple_form or in mongoid/mongodb? -
i having problems model "collection".
i'm using mongoid mongodb , rails 3.2.
i have problem when try create nested resource collection select simple_form sth like:
<%= f.input :collection_id, :collection => collection.where(:user_id => current_user.id).order([:created_at, :desc]), :input_html => { :id => "m_collection_id" } %> however other words model working fine.
my question if it's possible create model "collection" word ruby on rails 3.2, mongoid , mongodb.
thank much!
while i'm not sure if "collection" protected word in rails, mongodb, or simple_form, it'd best not use it. there several methods have "collection" in name, such collection_select example. checked around on couple reserved word lists, didn't find there.(here's best 1 found: http://cheat.errtheblog.com/s/rails_reserved_words/)
when i'm not sure word though, go thesaurus online , synonym. ones saw collection compilation, aggregation, assortment, medley(ok, maybe not that, idea).
Comments
Post a Comment