Make the location of the GPX traces configurable.
This commit is contained in:
parent
3336fd9469
commit
6d7e69d4d3
2 changed files with 8 additions and 5 deletions
|
@ -58,18 +58,16 @@ class Trace < ActiveRecord::Base
|
|||
data
|
||||
end
|
||||
|
||||
# FIXME change to permanent filestore area
|
||||
def large_picture_name
|
||||
"/home/osm/icons/#{id}.gif"
|
||||
"#{GPX_IMAGE_DIR}/#{id}.gif"
|
||||
end
|
||||
|
||||
# FIXME change to permanent filestore area
|
||||
def icon_picture_name
|
||||
"/home/osm/icons/#{id}_icon.gif"
|
||||
"#{GPX_IMAGE_DIR}/#{id}_icon.gif"
|
||||
end
|
||||
|
||||
def trace_name
|
||||
"/home/osm/gpx/#{id}.gpx"
|
||||
"#{GPX_TRACE_DIR}/#{id}.gpx"
|
||||
end
|
||||
|
||||
def mime_type
|
||||
|
|
5
config/initializers/gpx.rb
Normal file
5
config/initializers/gpx.rb
Normal file
|
@ -0,0 +1,5 @@
|
|||
# Set location of GPX trace files
|
||||
GPX_TRACE_DIR = "/home/osm/traces"
|
||||
|
||||
# Set location of GPX image files
|
||||
GPX_IMAGE_DIR = "/home/osm/images"
|
Loading…
Add table
Add a link
Reference in a new issue