View Example - GET response.json
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
{ | |
"data": { | |
"id": "2235", | |
"type": "places", | |
"attributes": { | |
"name": "Test name", | |
"coordinates": { | |
"lon": 5.11135, | |
"lat": 45.41 | |
}, |
View models.js.erb
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
export const song_attributes = <%= SerializableSong.devour_attributes.to_json %> | |
export const song_document_attributes = <%= SerializableSongDocument.devour_attributes.to_json %> |
View Lock.rb
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 Lock | |
include Mongoid::Document | |
include Mongoid::Timestamps | |
include Mongoid::EmbeddedFindable | |
include GlobalID::Identification | |
DEFAULT_INTERFACE = :default | |
embedded_in :lockable, polymorphic: true |