Created
December 16, 2011 20:56
-
-
Save abevoelker/1487933 to your computer and use it in GitHub Desktop.
DataMapper equivalent to ActiveRecord attribute_names
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| module DataMapper::Model | |
| def property_names | |
| properties.map { |m| m.name.to_s } | |
| end | |
| end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment