Hi
I have a controller that I want to refactor. This controller basically renders a formatted XML document.
The controller does 4 main things.
- It get records from a DB
- It reads a static xml file from rails_root/config
- It iterates through DB records and gsubs the XML doc using the DB data
- It renders the XML document as :text
My question is:
Where is the correct place for 2/3 to happen within in the Rails framework? It seems to me that they shouldn't be in the controller.
I'm on Rails 2.3
Cheers