sdf
This commit is contained in:
parent
ed5b73f12c
commit
f2370bf4e5
Binary file not shown.
Binary file not shown.
|
|
@ -29,6 +29,7 @@ def get_image(filename):
|
||||||
|
|
||||||
@main.route("/orders/api_payments", methods=["POST", "GET"])
|
@main.route("/orders/api_payments", methods=["POST", "GET"])
|
||||||
def index1():
|
def index1():
|
||||||
|
DB_PATH = "./files/rokky.db"
|
||||||
# Получаем все GET-параметры
|
# Получаем все GET-параметры
|
||||||
params = request.args.to_dict()
|
params = request.args.to_dict()
|
||||||
logging.warn(f"newOrder: {params}")
|
logging.warn(f"newOrder: {params}")
|
||||||
|
|
@ -42,11 +43,11 @@ def index1():
|
||||||
date = params.get("date")
|
date = params.get("date")
|
||||||
# всё остальное сохраняем как JSON
|
# всё остальное сохраняем как JSON
|
||||||
content = json.dumps(params, ensure_ascii=False)
|
content = json.dumps(params, ensure_ascii=False)
|
||||||
|
send_telegram(content)
|
||||||
|
|
||||||
message = f"🔹Спасибо за покупку в WST Keys (West Store Trusted Keys)\n\n ⏳ Ваш заказ обрабатывается и будет доставлен автоматически"
|
message = f"🔹Спасибо за покупку в WST Keys (West Store Trusted Keys)\n\n ⏳ Ваш заказ обрабатывается и будет доставлен автоматически"
|
||||||
create_messagea(id_i, message)
|
create_messagea(id_i, message)
|
||||||
name_p, im = get_product(id_d)
|
# name_p, im = get_product(id_d)
|
||||||
sku_rokky, price_rokky = get_sku(id_d)
|
sku_rokky, price_rokky = get_sku(id_d)
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -77,6 +78,7 @@ def index1():
|
||||||
|
|
||||||
@main.route("/newOrder", methods=["POST"])
|
@main.route("/newOrder", methods=["POST"])
|
||||||
def new_order():
|
def new_order():
|
||||||
|
|
||||||
if not request.is_json:
|
if not request.is_json:
|
||||||
return jsonify({"error": "Invalid content type"}), 400
|
return jsonify({"error": "Invalid content type"}), 400
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue