I'm struggling with my Ruby on Rails App that has a legacy database. It works in general but now I'm trying to show the associations created in the database.
The two relevant scaffolds are called repo
and build
.
One repo has many builds
- so I have a foreign key repo_id
in my builds table.
The problem is the following:
- calling
repo/7
in browser is working - calling
repo/7/builds/8
is also working - but if I call
repo/7/builds
my system is crashing down ;)
Furthermore I can do that in the rails console without any problems, like that:
r = Repo.find(7)
r.builds
--> returns all builds belonging to repo with id 7
Does anyone know what's going wrong here? Thanks in advance!