No association found for name `products'. Has it been defined yet?
Working on a project, I had to make some changes to the associations – where Product_Lines had many Products to Product_Lines has one Product. (The reason behind this is a whole other story.)
This is the error I got:
No association found for name `products’. Has it been defined yet?
I had changed the Product_Lines model to has_one Product. But, I had over looked the accepts_nested_attributes_for line. I changed :products to :product and it fixed it.



Wow this is a great resource.. I’m enjoying it.. good article
It’s interesting to find how challenging the content side is for some