Skip to main content
How can I grow this search object?
That's much better! I'd clean this up too slightly since you're repeating the exclude every time. ```ruby def search @images = Image.excluding(@excluded_image_ids) if @params[:commi...
Chris Oliver replied

How to compare and write conditions on active record field "time"
[Edited] So all the Time instances in Rails include a date with the Time. It will default to January 1st, 2000 as you can see but you can safely ignore that portion of the output. You should...
Chris Oliver replied

Page Specific Javascript
I had to do something like this in a specific circumstance. The solution I used was to create a unique body class for each page with interpolation. In HAML: `%body{:class => "#{controller_nam...
Greg Cosgrove replied

Multitenancy with Apartment Gem
@Vitor the Apartment docs should have a good explanation for that. 👍
Chris Oliver replied

Clarification needed for simple_calendar sort_by method
I didnt know how i missed this part. Thanks
sid d replied

Multitenancy with the Apartment gem
I think im goin to try sidekiq. :)
Francisco Quinones replied Solved

jQuery and Turbolinks not playing nicely
Ok, so I'll try to make this brief. I have a new Rails 4.2.1 app using Ruby 2.2.2 and I'm trying to do a live search on a basic crud model. I have ransack installed and it's working great. But...
shakycode posted

Admin for the specific case
Thanks for answer! Now I'm going to pundit screencast :)
Jan Lachowicz replied

Ransack undefined method path in Rails 4.2.1
Ok, I figured this out. Similar to issues I was seeing with breaking Rails naming conventions in my other forms, I had to pass the url and method in the `search_form_for` helper method. It's work...
shakycode replied

Ransack undefined method _path in Rails 4.2.1
I'm working on a simple CRUD Asset Management app and I want to use Ransack. I think I have this setup properly in my view and controller but each time the index view is hit I get the exception: ...
shakycode posted

Video Idea: Accepting Credit Card Payments
Sweet. Looking forward to this!
Michael Stitt replied

CSV Model method and Summing Hours cleanly.
With some help this morning from Chris and me reading APIDocs on filtering arrays we came to this method which works right. :) ```` def self.to_csv(records = [], options = {}) CSV.genera...
shakycode replied

Coffeescript Instantiation
Haha! Always the simplest things producing the hardest problems.
Chris Oliver replied

Devise with multiple User Models with single login form
Got here trough searching on google. devise_group does sound super useful!! Thanks a lot for finding this.
TL replied

Release GoRails platform subscribers or OSS?
It will be the challenges for us to contribution and help to improve over times and also get if we could have a chance to send pull requests to improve and get feedbacks from yours as well. What do...
Samnang Chhun replied

Help needed on how to create spatial indexing
Screencast would be great. Active record postgis adapter documentation fine too.
sid d replied

Problems with Routes and Forms (Am I a Newb? What am I missing here?)
When the brainfog clears and the caffeine kicks in, it's go time :)
shakycode replied

Using scopes to rank users based on votes they get from their posts
Ok got it Chris. Time to look into writing cron jobs then! Thanks.
Ariff Munshi replied

How to use Sweet Alert to replace standard confirm dialog
Hey came across this thread as I was facing the same problem. I tried to stay away from them gems initially and downloaded Sweet Alerts 2 from source. All worked well until I had to the confirmatio...
Ariff Munshi replied

rubber:passenger:add_to_pool takes forever
Weird! In any case, nginx and unicorn are awesome so you'll be in good hands with that setup as well. I've had some weirdness with Passenger 5 myself and have reverted back to using Puma for now.
Chris Oliver replied

Subscribe to the newsletter

Join 30,005+ developers who get early access to new screencasts, articles, guides, updates, and more.

    By clicking this button, you agree to the GoRails Terms of Service and Privacy Policy.

    More of a social being? We're also on Twitter and YouTube.