12 lines
No EOL
205 B
Ruby
12 lines
No EOL
205 B
Ruby
class GeojsonService
|
|
def self.to_json_polygon coordinates
|
|
polygon = {
|
|
geo: {
|
|
type: "Polygon",
|
|
coordinates: [coordinates]
|
|
}
|
|
}
|
|
|
|
polygon.to_json
|
|
end
|
|
end |