Use LEFT and RIGHT arrow keys to navigate between flashcards;
Use UP and DOWN arrow keys to flip the card;
H to show hint;
A reads text to speech;
2 Cards in this Set
- Front
- Back
Describe polymorphic associations
|
Allow you to have a single model that can be associated to an arbitrary number of other models.
Person, Company, Address |
|
What are nested resources?
|
They are the touted as the correct way to do REST with parent child model associations.
1. Set up named route map.resources :events, :has_many => :tickets 2. Route helpers new_event_ticket 3. before_filter :get_event def get_event @event = Event.find(params[:event_id]) end |