mongoid
How do you add indexes to your Mongoid database in Padrino?
I need to be able to add indexes to my Mongoid database in a Padrino project.I saw that they added rake tasks for this here:[详细]
2023-04-09 15:28 分类:问答Rails 3.1 Mongoid has_secure_password
I\'m attempting to get has_secure_password to play nice with mongoid. I\'m following Railscasts #270, however when I to signin with a username/password, I get the error:[详细]
2023-04-09 07:17 分类:问答How can one mongoid model query another?
If I have a model called Product class Product include Mongoid::Document field :product_id field :brand field :name[详细]
2023-04-09 04:52 分类:问答How does Mongoid "criteria" work?
I\'m trying to do something straight forward such as: User.all(:criteria => {:project_id 开发者_如何学C=> 2})[详细]
2023-04-08 05:18 分类:问答Mongoid namespaced models and inheritance
I\'m trying the use namespaced models with Mongoid and can\'t seem to get it to work. I have the following models: Achievement, Flag, FlagCaptured[详细]
2023-04-07 11:54 分类:问答How do I get mongoid's eager loading to work?
I get the following error: NoMethodError (undefined method `eager_load\' for nil:NilC开发者_开发问答lass)[详细]
2023-04-07 11:38 分类:问答Mongoid: before_destroy and Paranoia
Is there some callbacks for soft deleting in Mongoid? Because before_destory won\'t be triggered. Now I thought I can use before_update but it looks开发者_开发问答 not so clear solution as I want and[详细]
2023-04-07 10:22 分类:问答Ruby Gem for comments with mongoid
I am in need to integrate comments to my existing mongoid documents. is the开发者_如何学Pythonre any rubygem available to achieve it?usually you\'d useacts_as_commentable[详细]
2023-04-07 07:50 分类:问答Updating timestamps in mongoid
How do I update/change the TimestampSequence on a Mongoid document in rails/ruby? If you dont know in Mongoid but know in MongoDB that开发者_如何学编程 will work as well.[详细]
2023-04-06 22:10 分类:问答Factory Girl + Mongoid embedded documents in fixtures
Let’s say you have the following mongoid documents: class User include Mongoid::Document embeds_one :name[详细]
2023-04-06 22:01 分类:问答