I have to be specific for this to make sense. In my application I have a model called theme which contains widget color theme information. We provide a few themes, but mainly rely on the user to create their own themes. So the question is: where do I store my themes? If I store them in the theme database, then anytime I switch databases or flush it during testing, I must re-enter the themes in. This is not a huge deal, it just seems sloppy.
Right now I have the themes stored in a Hash in the controller. The problem with that is since each widget has a theme, each widget has a theme_id, and there is no theme_id for our provided themes because they are not stored in the database.
I know that a solution to this issue is pretty simple, but I want to make sure my solution employs the best coding practices. Does anyone have any suggestions for this? Maybe there is a way to add entries into the database during a migration or other rake task...
Thank you!
Tony