From 865228a9d9afc46b5265c938071ec99b2439739a Mon Sep 17 00:00:00 2001 From: liuwei Date: Fri, 23 May 2025 10:21:48 +0800 Subject: [PATCH] =?UTF-8?q?=E5=8A=A0=E5=85=A5=E6=8E=A5=E5=8F=A3=E6=96=87?= =?UTF-8?q?=E6=A1=A3=E9=A1=B5=E9=9D=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- admin/dashboard/blueprints/system.py | 5 ++- admin/dashboard/templates/api_docs.html | 53 +++++++++++++++++++++++++ admin/dashboard/templates/base.html | 5 +++ 3 files changed, 62 insertions(+), 1 deletion(-) create mode 100644 admin/dashboard/templates/api_docs.html diff --git a/admin/dashboard/blueprints/system.py b/admin/dashboard/blueprints/system.py index 3356f77..32482b9 100644 --- a/admin/dashboard/blueprints/system.py +++ b/admin/dashboard/blueprints/system.py @@ -13,7 +13,10 @@ system_bp = Blueprint('system', __name__) # 记录应用启动时间 APP_START_TIME = time.time() - +@app.route('/api_docs') +@login_required +def api_docs(): + return render_template('api_docs.html') # 页面路由 @system_bp.route('/wx_logs') @login_required diff --git a/admin/dashboard/templates/api_docs.html b/admin/dashboard/templates/api_docs.html new file mode 100644 index 0000000..caa4ceb --- /dev/null +++ b/admin/dashboard/templates/api_docs.html @@ -0,0 +1,53 @@ +{% extends "base.html" %} + +{% block title %}接口文档 - 机器人管理后台{% endblock %} + +{% block content %} + +
+ + + +
+ 接口文档 +
+
+ +
+
+
+
+
+{% endblock %} + +{% block scripts %} + + + +{% endblock %} \ No newline at end of file diff --git a/admin/dashboard/templates/base.html b/admin/dashboard/templates/base.html index 6e572e5..05c29c7 100644 --- a/admin/dashboard/templates/base.html +++ b/admin/dashboard/templates/base.html @@ -171,6 +171,11 @@ 虚拟群组 + + + + 接口文档 +