diff --git a/server/__pycache__/flask_app.cpython-313.pyc b/server/__pycache__/flask_app.cpython-313.pyc index ab35a93..95cfb06 100644 Binary files a/server/__pycache__/flask_app.cpython-313.pyc and b/server/__pycache__/flask_app.cpython-313.pyc differ diff --git a/server/flask_app.py b/server/flask_app.py index 17926a9..952db0e 100644 --- a/server/flask_app.py +++ b/server/flask_app.py @@ -28,6 +28,7 @@ def index(): return resp +@app.route("/rf-api/", methods=["GET", "POST"]) @app.route("/api/rf/", methods=["GET", "POST"]) def rf_api_proxy(rf_path: str): target = f"{RF_API_URL}/{rf_path.lstrip('/')}" diff --git a/server/static/index.html b/server/static/index.html index 1aca53d..e4eca02 100644 --- a/server/static/index.html +++ b/server/static/index.html @@ -2054,7 +2054,7 @@ } function defaultApiDebugBase() { - return '/api/rf'; + return '/rf-api'; } function apiDebugNumber(id, fallback = null) { @@ -2298,7 +2298,7 @@ } catch (e) { apiDebugSetStatus(`Ошибка запроса: ${e.message || e}`, true); apiDebugSetOutput(e.response || - 'Проверьте API base URL. По умолчанию используется same-origin proxy /api/rf.'); + 'Проверьте API base URL. По умолчанию используется same-origin proxy /rf-api.'); apiDebugSetSummary('Расчёт не выполнен.'); } } @@ -2406,7 +2406,7 @@ } catch (e) { apiDebugSetStatus(`Ошибка расчёта линии: ${e.message || e}`, true); apiDebugSetOutput(e.response || - 'Проверьте API base URL. По умолчанию используется same-origin proxy /api/rf.'); + 'Проверьте API base URL. По умолчанию используется same-origin proxy /rf-api.'); apiDebugSetSummary('Расчёт линии не выполнен.'); } }