Created
November 29, 2011 16:03
-
-
Save marklocklear/1405319 to your computer and use it in GitHub Desktop.
Copy object attributes
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
| ruby-1.9.2-head :001 > t = Template.first | |
| => #<Template id: 1, name: "Computer Tech Template", created_at: "2011-11-22 18:38:45", updated_at: "2011-11-22 18:38:45"> | |
| r = Rubric.new(t.attributes.merge(:name => t.name, :created_at => t.created_at)) | |
| => #<Rubric id: nil, name: "Computer Tech Template", section_id: nil, created_at: "2011-11-22 18:38:45", updated_at: "2011-11-22 18:38:45", competency: nil> | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment