clayallsopp/formotion — pull request #28 by clayallsopp (2012-08-03 17:59:30+00:00)
Title: ::Formable Models

This allows you to map and edit a plain modal with a ::Form, like so (taken from the example attached):

```ruby
class User
include Formotion::Formable

attr_accessor :name, :score, :team

form_property :name, :string
form_property :score, :number, transform: lambda { |value| value.to_i }

form_property :team, :picker, items: ["Red", "Blue", "Green"]

form_title "Edit User"
end
```

```ruby
user = User.new("Harry", 100, "Green")
controller = Formotion::FormableController.alloc.initWithModel(user)
self.navigationController.pushViewController(controller, animated:true)
```

![image](http://i.imgur.com/SKQ3R.png)

The fields are all KVO-bound to the model, so it updates the object as soon as you start editing. I think it's pretty cool :) Will merge later if looks good