Exemplo n.º 1
0
def post_dish():
    dish_name = request.form.get('name')
    dish_price = request.form.get('price')
    dish_price = int(dish_price)
    insert_food(dish_name, dish_price)
    menues = get_all()
    return render_template("menu.html", menues=menues)
Exemplo n.º 2
0
def get_moedas(moeda: str):
    for key, _ in cotacoes().items():
        if moeda.capitalize() == key:
            return jsonify(mongo.get_all(key))
    return Response('not found', status=404)
Exemplo n.º 3
0
def index():
    menues = get_all()
    return render_template("menu.html", menues=menues)
def index():
    return render_template("index.html", data=get_all())
Exemplo n.º 5
0
def index():
    # dish_name = request.args.get('name')
    return render_template('index.html', data=get_all())