]> git.openstreetmap.org Git - rails.git/blob - app/views/api/relations/_relation.json.jbuilder
Merge remote-tracking branch 'upstream/pull/5366'
[rails.git] / app / views / api / relations / _relation.json.jbuilder
1 json.type "relation"
2 json.id relation.id
3 json.timestamp relation.timestamp.xmlschema
4 json.version relation.version
5 json.changeset relation.changeset_id
6 json.user relation.changeset.user.display_name
7 json.uid relation.changeset.user_id
8
9 json.visible relation.visible unless relation.visible
10
11 unless relation.relation_members.empty?
12   json.members(relation.relation_members) do |m|
13     json.type m.member_type.downcase
14     json.ref m.member_id
15     json.role m.member_role
16   end
17 end
18
19 json.tags relation.tags unless relation.tags.empty?