def update_item(): item = request.args.get('myitem2', 0, type=str) num = request.args.get('mynum', 0, type=int) pythonToDb.updateItem(item, str(num)) # call to db to update the item's stock return jsonify(result="")
def submit_order(): item = request.args.get('myitem', 0, type=str) num = request.args.get('mynum', 0, type=int) pythonToDb.updateItem(item, str(num)) return jsonify(result="")