Class: Pinnable::MarkerSerializer
- Inherits:
-
Object
- Object
- Pinnable::MarkerSerializer
- Defined in:
- app/serializers/pinnable/marker_serializer.rb
Overview
The wire shape the in-page overlay reads: enough to re-anchor (anchor blob) and to show the note, never the host’s User object — only its captured label.
Instance Method Summary collapse
- #call ⇒ Object
-
#initialize(pin) ⇒ MarkerSerializer
constructor
A new instance of MarkerSerializer.
Constructor Details
#initialize(pin) ⇒ MarkerSerializer
Returns a new instance of MarkerSerializer.
5 |
# File 'app/serializers/pinnable/marker_serializer.rb', line 5 def initialize(pin) = @pin = pin |
Instance Method Details
#call ⇒ Object
7 8 9 10 11 12 13 14 15 16 17 |
# File 'app/serializers/pinnable/marker_serializer.rb', line 7 def call { public_id: pin.public_id, url: pin.url, body: pin.body, status: pin.status, author_label: pin., anchor: pin.anchor, comments: comments } end |