compliance/templates/history_detail.html
2025-06-27 18:26:20 +08:00

60 lines
2.6 KiB
HTML

<!DOCTYPE html>
<html lang="zh-CN">
<head>
<meta charset="UTF-8">
<title>测试详情 - {{ run_id }}</title>
<link rel="stylesheet" href="{{ url_for('static', filename='style.css') }}">
<link rel="stylesheet" href="{{ url_for('static', filename='history_style.css') }}">
</head>
<body>
<div class="container">
<div class="header">
<h1>测试详情: {{ run_id }}</h1>
<div class="header-controls">
<div class="user-info">
<a href="{{ url_for('list_history') }}">返回列表</a> |
<a href="{{ url_for('llm_config') }}">LLM 标准配置</a> |
<span>欢迎, {{ g.user['username'] }}</span> |
<a href="{{ url_for('logout') }}">登出</a>
</div>
<div class="download-actions">
<a href="{{ url_for('download_report', run_id=run_id, filename='summary.json') }}" class="button download-btn">下载JSON报告</a>
{% if has_md_report %}
<a href="{{ url_for('download_report', run_id=run_id, filename='api_call_details.md') }}" class="button download-btn">下载MD报告</a>
{% endif %}
{% if has_pdf_report %}
<a href="{{ url_for('download_report', run_id=run_id, filename='report_cn.pdf') }}" class="button download-btn">下载PDF报告</a>
{% endif %}
</div>
</div>
</div>
<div class="details-container">
{% if has_pdf_report %}
<h2 id="pdf-section">PDF 报告</h2>
<div class="pdf-container">
<iframe src="{{ url_for('view_pdf_report', run_id=run_id) }}" width="100%" height="800px" style="border:1px solid #ccc;"></iframe>
</div>
{% endif %}
<h2 id="summary-section">测试摘要 (JSON)</h2>
<pre class="json-output">{{ summary_content }}</pre>
<h2 id="details-section">API 调用详情</h2>
<div class="markdown-body">
{{ details_content|safe }}
</div>
</div>
<div class="floating-nav">
{% if has_pdf_report %}
<a href="#pdf-section" class="button nav-btn" title="跳转到PDF报告">PDF报告</a>
{% endif %}
<a href="#summary-section" class="button nav-btn" title="跳转到摘要">测试摘要</a>
<a href="#details-section" class="button nav-btn" title="跳转到详情">API调用详情</a>
</div>
</div>
</body>
</html>