Tagged Questions
Ruby on Rails is an open source full-stack web application framework written in Ruby. It follows the popular MVC framework model and is known for its "convention over configuration" approach to application development.
0
votes
0answers
4 views
configuration does not specify adapter (ActiveRecord::AdapterNotSpecified)
I have a demo Rails app up and running on a VPS thanks to Ryan Bates' deploying to a VPS episode on Railscasts. On my server I created a directory structure like this /home/username/apps and the ...
0
votes
1answer
10 views
Adding unique two-column index with already not unique data
I have a rails app and need to add a unique constraint, so that a :record never has the same (:user, :hour) combination.
I imagine the best way to do this is by adding a unique index:
add_index ...
0
votes
1answer
6 views
Rails 4 Devise/Omniauth Email exists in database error
I am "banging" my head against a wall trying to figure this out. I decided to allow users to log in through twitter, Google,my site or Facebook. The problem is that twitter does not provide emails, so ...
1
vote
1answer
22 views
Rails + ActiveRecord + optimization: Is there a better way to update on 300,000 records?
So I have a rake task that does this:
wine_club_memberships = WineClubMembership.pluck(:billing_info_id)
total_updated = BillingInfo.joins(:order).where(["orders.ordered_date < (CURRENT_DATE - ...
0
votes
1answer
31 views
A blog using Bootstrap and Ruby on rails
I've been stuck for a time now with my commenting system on my blog. I now need you help to solv the problem and push me in the right direction. I'm using Ruby on rails and the twitter open source ...
0
votes
1answer
5 views
sort_link routing error for ransack
I've been using sort_link to sort the links on my page
= sort_link(@search, :project_token, "Project ID")
it works fine......but when the user filters something it takes me to the url ...
0
votes
0answers
6 views
Rails: associations for models, using :dependent and :foreign keys
I'm making my first Rails app (actually it's my first programming experience) and I have a few questions about models and associations.
My first app is blog.
Blog have users. Users have posts.
One ...
-1
votes
1answer
15 views
Using CSS inside Rails 3.2.13
Checked out some links, but it seems that people who answer assume a little bit more than I know.
I'm using Rails 3.2.13 and I need to add some styling to my Views.
I have the ...
0
votes
1answer
12 views
Call a method and initiate debugging from the rails console without editing the source code?
Sometimes when I'm working in the rails console, I find I want to step through a particular method (from my rails app) in the debugger. In the past I have done this by temporarily adding a debugger ...
0
votes
1answer
23 views
Rails: Change content with jquery?
I want to update the content in a span tag when a user click on a button. The span tag has a class called fa_button_id_counter and a id with the post id. It should be simple, but I can't make it work. ...
1
vote
2answers
38 views
Select only next div in jQuery
I have a Rails app with a list, and each list item has details about that item in a div like this:
<ul>
<% @procedures.each do |procedure| %>
<li class="proc-names">
<%= ...
0
votes
2answers
20 views
“Password can't be blank” displayed twice
I'm trying to validate a user's password on create and update (custom authentication, no gems). A password should ALWAYS be required on create, but only required on update if they type something in.
...
0
votes
1answer
21 views
Ruby on rails finding unique entries
I want to populate a select menu with options from my database. There are many copies of the same entree, and because of that I get a drop down menu that have the same name again and again. I want ...
-1
votes
1answer
18 views
How to link to local file with Ruby on Rails
I'm new to Ruby. I worked through Michael Hartl's ruby on rails tutorial and now I'm creating my own site, locally on my mac localhost:3000 , based on what I've learned. I want to link to a .docx file ...
0
votes
1answer
16 views
Conditional assignment not working for possibly undefined variable
I have this at the beginning of a rails view partial:
<% enabled = true unless defined?(enabled) %>
This is to handle cases when the calling view doesn't pass in the enabled local, by setting ...