One thing to mention is that in the routes file, the default version has to be the last one to be defined.
I had a problem where I added a v2 on top of v1 and made it the default like this:
routes.rb
...
namespace :api, defaults: { format:'json' } do
scope module: :v2, constraints:ApiConstraints.new(version:2, default:true) do
...
end
scope module: :v1, constraints:ApiConstraints.new(version:1) do
...
endend
...
All V1 requests would be redirected to the V2 Controllers
+1
One thing to mention is that in the routes file, the default version has to be the last one to be defined.
I had a problem where I added a v2 on top of v1 and made it the default like this:
All V1 requests would be redirected to the V2 Controllers
yes, after you insert a new field, find the select element and call chosen on it.
In my case it was like this:
this is my association:
I add the class chzn-select which is used to find the element.
I had the same problem. Found the solution here:
http://ubuntuforums.org/showthread.php?t=1396862
Uninstalled postgresql-common and reinstalled postgresql and libpq-dev
apt-get purge postgresql-common postgresql libpq-dev
apt-get install postgresql libpq-dev
Great episode.
I'm new to rails and so happy I subscribed.