mirror of
https://github.com/openfoodfoundation/openfoodnetwork
synced 2026-01-25 20:46:48 +00:00
Before it would display a gray/blank div instead of map because the map latitude, longitude couldn't be calculated without geocoded enterprises. This adds a setting so the default coordinates can be set even if no geocoded enterprises present.
20 lines
395 B
Ruby
20 lines
395 B
Ruby
# frozen_string_literal: true
|
|
|
|
module PreferenceSections
|
|
class MapSection
|
|
def name
|
|
I18n.t('admin.contents.edit.map')
|
|
end
|
|
|
|
def preferences
|
|
[
|
|
:open_street_map_enabled,
|
|
:open_street_map_provider_name,
|
|
:open_street_map_provider_options,
|
|
:open_street_map_default_latitude,
|
|
:open_street_map_default_longitude
|
|
]
|
|
end
|
|
end
|
|
end
|