1 # frozen_string_literal: true
5 json.created_at changeset.created_at.xmlschema
6 json.open changeset.open?
7 json.comments_count changeset.comments.length
8 json.changes_count changeset.num_changes
10 json.closed_at changeset.closed_at.xmlschema unless changeset.open?
11 if changeset.bbox.complete?
12 json.min_lat GeoRecord::Coord.new(changeset.bbox.to_unscaled.min_lat)
13 json.min_lon GeoRecord::Coord.new(changeset.bbox.to_unscaled.min_lon)
14 json.max_lat GeoRecord::Coord.new(changeset.bbox.to_unscaled.max_lat)
15 json.max_lon GeoRecord::Coord.new(changeset.bbox.to_unscaled.max_lon)
19 if changeset.user.data_public?
20 json.uid changeset.user_id
21 json.user changeset.user.display_name
24 json.tags changeset.tags unless changeset.tags.empty?
27 json.comments(@comments) do |comment|