Merge pull request #5044 from mmd-osm/patch/rn1

JSON partial rendering in loop
This commit is contained in:
Andy Allan 2024-08-07 16:12:53 +01:00 committed by GitHub
commit 2a649d16df
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
5 changed files with 10 additions and 10 deletions

View file

@ -1,5 +1,5 @@
json.partial! "api/root_attributes"
json.changesets(@changesets) do |changeset|
json.partial! changeset
json.changesets do
json.array! @changesets, :partial => "changeset", :as => :changeset
end

View file

@ -1,5 +1,5 @@
json.partial! "api/root_attributes"
json.messages(@messages) do |message|
json.partial! message
json.messages do
json.array! @messages, :partial => "message", :as => :message
end

View file

@ -1,5 +1,5 @@
json.partial! "api/root_attributes"
json.messages(@messages) do |message|
json.partial! message
json.messages do
json.array! @messages, :partial => "message", :as => :message
end

View file

@ -1,5 +1,5 @@
json.type "FeatureCollection"
json.features(@notes) do |note|
json.partial! note
json.features do
json.array! @notes, :partial => "note", :as => :note
end

View file

@ -1,5 +1,5 @@
json.partial! "api/root_attributes"
json.users(@users) do |user|
json.partial! user
json.users do
json.array! @users, :partial => "user", :as => :user
end