def post(self):
try:
# Parse the arguments
parser = reqparse.RequestParser()
parser.add_argument('userid', type=str, help='ID of User that is sending vote')
parser.add_argument('eventid', type=str, help='ID of event user is in')
args = parser.parse_args()
_userID = args['userid']
_eventID = args['eventid']
db = Database()
print(_eventID)
print(_userID)
songs = db.getPlayedSongs(_eventID, _userID)
return json.dumps({'songs': songs})
except Exception as e:
return {'error': str(e)}
评论列表
文章目录