I currently have a fixture controller that was working fine,
However now it doesnt seem to work any more.
I have the following in the fixtures_controller
def list
@fixture = Fixture.all
Please see my github for the files https://github.com/jpknegtel/st_francis
If anyone could shed some light onto this it would be a great help
Update: Looking at your code, you do not at all have routes. You need routes for telling rails how to map the url from the request to the controllers and the actions within. Routes go in the
config/routes.rbfile.Your problem is that you do not have a route for
/fixtures/list. Rails thinks you want to show the fixture with the ID list. And does not find any record and throws an error.You need to add some routes. I highly recommend to read the rails guide on routing. And I also recommend the use of ressourceful routing.
If you adopt the method names in your controllers this is really easy, otherwise you have to do a lot of work on your own. Read exspecially section 2. It took quite a while for me to understand RESTful routes, so do not give up – you will love them one day. If you have more questions, feel free to ask.