htilt / strabo

Interactive mapping site with database
1 stars 3 forks source link

Retrieve GPS coordinates from Leaflet map. #20

Open htilt opened 9 years ago

htilt commented 9 years ago

Add capabilities for retrieving GPS coordinates from the leaflet map in the interest point uploader view. As it stands, the database can only manage a latitude and longitude, and cannot manage the list of coordinates that result from a polygon or polyline. This issue deserves some thought. A couple possible implementations:

  1. GPS coordinates are stored in different columns depending on the feature type. A new 'feature_type' column should be added to the interest_points table. To create a GeoJSON feature collection from the features, the script will determine the feature type of an interest point and query the db for the corresponding coordinates column.
  2. GPS coordinate column holds a list containing an arbitrary number of coordinates. A new 'feature_type' column should be added to the interest_points table. To create a GeoJSON feature collection from the features, the script will determine the feature type of an interest point and process the coordinates accordingly.
htilt commented 9 years ago

Built most of this. Would ideally still figure out how to post uploads from Zach's admin side to public side via AJAX.