Showing off some styles discussed at Las Vegas Ruby Meetup
Pull request Compare This branch is even with jcasimir:master.
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
app
autotest
config
db
doc
lib/tasks
public
script
spec
vendor/plugins
.gitignore
.rspec
Gemfile
Gemfile.lock
README
Rakefile
config.ru

README

== Real Estate Example

At the 12/15/10 meeting of the Las Vegas Ruby Group there were two items of "how do I" discussion centered around scopes.  I put together a little example app that illustrates both topics and one additional:

# Writing class methods instead of actual rails scopes (http://www.railway.at/2010/03/09/named-scopes-are-dead/)
# Composing complex queries by chaining scopes.  Here exhibited by things like Listings.by_state("NV").for_rent
# Creating a SEARCH method on the model that accepts flexible parameters from the controller, allowing the controller to have almost no intelligence.

There are also RSpec tests to exercise the model's features.

If you have any additions, feel free to fork!

Enjoy,
Jeff