I am new to ruby and trying to work on the an appli开发者_高级运维cation that uses caching. I have a code that actually wait for an database update and keep polling until it finds specific value.
I have two DropDownLists in form, both displaying list of regions. First is required, second not, stored as null in db.
I am working on a simple dictionary where I have words and synonyms to those words. I am not sure which model is a better solution, working with a serialized attribute or association.
I have the following method to check if a user has admin access. def has_admin_access?(user) user.present? && gym_users.where(:role_id => [3, 4]).where([\'user_id = ? AND date_ended IS NUL
Is it possible to create one model that stands for two different objects? for example: I have a blog, on which, I will publish articles on pure text and screencasts with only video.
Closed. This question is seeking recommendations for books, tools, software libraries, and more. It does not meet Stack Overflow guidelines. It is not currently accepting answers.
I have one model call Permissions of about 60 columns where half of the column represents a boolean and half of them a text (:string) field.
I don\'t know if I am explaining this correctly, or if the solution is rather simple, so here goes: I am using MvcMailer, but before that I set up a wizard input form which I call Quote.cshtml. Behin
Does anyone know if its possible to create a model instance and apply the ID and any other attributes without having to load it from the database? I tried doing this, but the associations are not fetc
i\'m using globalize3 in a rails3 app. I have a model called Book with some attributes to be translated, all working great. I\'m trying to write a before_save function to validate changes in the trans