Closed hburgund closed 7 years ago
Further details from @hburgund regarding the asset-map
Hopefully you can use this to devise a unit test so we get better coverage. It’s really very simple and gets installed automatically. The file is here:
roundware/rw/templates/asset-map.html
and it can be accessed at:
http://localhost:8888/dashboard/asset-map?project=1
if you leave out the project_id parameter, it will include all projects. Once you hit that url, you can move the pin for the default asset by dragging it and then check in the admin to see if the coordinates changed accordingly.
The ‘savePosition’ function does a PATCH AJAX call to handle the coordinate change, so that’s probably one of the tests you’ll want to add along with the drawPoints function that uses the assetlocation API endpoint to get the data for displaying the current state of the markers.
Basically this is a visual, mapped version of the Asset list view editor of the Admin.
We already have a listen-map created which creates the display of assets on a map with all the radius and info window stuff. We just need to add to it the ability to move each asset and save the lat/lon for them. listen-map.html and associated files are in the roundware-web-base repo on bitbucket.
This will be amazingly useful for sculpting the audio experience holistically rather than one asset at a time.