sschlosser/photofeed — pull request #3 by sschlosser (2012-10-09 06:41:24+00:00)
Title: Adding models and scaffolding

Dunx,

We will still need one custom controller that can provide the correct combinations of data in the right areas but this is a basic outline of the model.

Basically if you want to check this out before merging it :

- pull the branch down to your local box using git fetch and create a local tracking branch
- setup your database like the config/database.yml or run rake db:create
- run rake db:migrate.

This change allows you to run
localhost:3000/pods
localhost:3000/twitter_lists
localhost:3000/twitter_members
localhost:3000/tweets

Each one gives you basic CRUD operations for testing so you can put your data in can get it out through the interface so we should have enough code to where we can put together a controller for the designers fairly quickly.

The join tables exist only in the model - I did not generate any controllers or views for them.

Pod
:id
:name

TwitterList
:id
:name
:owner_screen_name
:list_slug

TwitterMember
:id
:twitter_id=>44215023,
:name=>"Jane Lynch",
:screen_name=>"janemarielynch",
:location=>"Los Angeles",
:description=>"Actress, Bon Vivant",
:url=>nil,

Tweet
:id
:twitter_created_at=>"Sat Oct 06 00:47:45 +0000 2012",
:twitter_id=>254382402191912960,
:text=>"In full clown face after photo shoot... http://t.co/naKuR5Fx",
:source=>"Camera on iOS",
:media_url=>"http://pbs.twimg.com/media/A4e_cnACcAEXuOS.jpg",
:media_url_https=>"https://pbs.twimg.com/media/A4e_cnACcAEXuOS.jpg",
:url=>"http://t.co/naKuR5Fx",
:display_url=>"pic.twitter.com/naKuR5Fx",
:expanded_url=>"http://twitter.com/janemarielynch/status/254382402191912960/photo/1",

Join Tables :

PodTwitterList
:id
:pod_id
:twitter_list_id

TwitterListMember
:id
:twitter_list_id
:twitter_member_id

TwitterMemberTweet
:id
:twitter_member_id
:tweet_id