Created
September 24, 2014 20:20
-
-
Save jsmestad/ac3ac5ce33349845a56d to your computer and use it in GitHub Desktop.
This file contains 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
class DomainSerializer | |
attributes :id, :name | |
# Override publicly-exposed ID to actually be GUID | |
def id | |
self.guid | |
end | |
end | |
class RecordSerializer | |
attributes :id, :domain_id | |
def id | |
self.guid | |
end | |
def domain_id | |
self.domain.guid | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment