Skip to content
This repository has been archived by the owner on Sep 18, 2019. It is now read-only.

Commit

Permalink
added uploadMedia to routes
Browse files Browse the repository at this point in the history
added an uploadMedia method to routes
  • Loading branch information
Albangalo committed May 6, 2017
1 parent 1f7cdf5 commit d7b436b
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions restapi/routes.py
Original file line number Diff line number Diff line change
Expand Up @@ -51,3 +51,13 @@ def getVideo(filename):
def getMusic(filename):
"""Return music of an event."""
return send_from_directory(app.config['MUSIC_FOLDER'], filename)


@app.route('/api/uploadMedia', methods=["POST"])
def uploadMedia():
""""""create an event and upload media to the host. return error if fails"""""""
mediaType = request.form['mediaType']
lat = request.form['lat']
lon = request.form['lng']
mediaID = request.form['mediaID']
media = request.files['media']

0 comments on commit d7b436b

Please sign in to comment.