예제 #1
0
def update_user_skills():
    data = request.get_json()
    user_id = database.get_user_id_from_email(current_user['email'])
    database.remove_all_user_skills(user_id)
    database.add_user_skills(user_id, data['skillIds'])
    return jsonify("SUCESS")
예제 #2
0
def update_user():
    user_id = database.get_user_id_from_email(current_user['email'])
    database.edit_user(user_id, request.get_json())
    return jsonify("SUCCESS")
예제 #3
0
def get_current_user_skills():
    user_id = database.get_user_id_from_email(current_user['email'])
    skills = database.get_user_skills(user_id)
    return jsonify(skills)
예제 #4
0
def get_current_user():
    user_id = database.get_user_id_from_email(current_user['email'])
    return get_user(user_id)