Get returning of bugs as GPX files working

This commit is contained in:
Tom Hughes 2011-05-07 14:53:30 +01:00
parent 560e41ebf9
commit cc311ff301
5 changed files with 29 additions and 24 deletions

View file

@ -47,7 +47,7 @@ class MapBugsController < ApplicationController
format.js
format.xml {render :template => 'map_bugs/get_bugs.xml'}
format.json { render :json => @bugs.to_json(:methods => [:lat, :lon], :only => [:id, :status, :date_created], :include => { :map_bug_comment => { :only => [:commenter_name, :date_created, :comment]}}) }
# format.gpx {render :template => 'map_bugs/get_bugs.gpx'}
format.gpx {render :template => 'map_bugs/get_bugs.gpx'}
end
end
@ -166,6 +166,7 @@ class MapBugsController < ApplicationController
format.rss
format.xml
format.json { render :json => @bug.to_json(:methods => [:lat, :lon], :only => [:id, :status, :date_created], :include => { :map_bug_comment => { :only => [:commenter_name, :date_created, :comment]}}) }
format.gpx
end
end
@ -200,7 +201,7 @@ class MapBugsController < ApplicationController
format.js
format.xml {render :template => 'map_bugs/get_bugs.xml'}
format.json { render :json => @bugs.to_json(:methods => [:lat, :lon], :only => [:id, :status, :date_created], :include => { :map_bug_comment => { :only => [:commenter_name, :date_created, :comment]}}) }
# format.gpx {render :template => 'map_bugs/get_bugs.gpx'}
format.gpx {render :template => 'map_bugs/get_bugs.gpx'}
end
end