Skip to content

Commit

Permalink
Adds note's description to note's XML / JSON
Browse files Browse the repository at this point in the history
Adds description field to generated note's XML and JSON files with note's description.
  • Loading branch information
nenad-vujicic committed Jan 24, 2025
1 parent 256c773 commit 691e914
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions app/views/api/notes/_note.json.jbuilder
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ end

json.properties do
json.id note.id
json.description note_description(note)
json.url api_note_url(note, :format => params[:format])

if note.closed?
Expand Down
2 changes: 1 addition & 1 deletion app/views/api/notes/_note.xml.builder
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
xml.note("lon" => note.lon, "lat" => note.lat) do
xml.note("lon" => note.lon, "lat" => note.lat, "description" => note_description(note)) do
xml.id note.id
xml.url api_note_url(note, :format => params[:format])

Expand Down

0 comments on commit 691e914

Please sign in to comment.