展示报告

This commit is contained in:
gongwenxin
2025-06-27 18:26:20 +08:00
parent fca20523ca
commit 864a36fe61
6 changed files with 179 additions and 2 deletions
+17
View File
@@ -19,15 +19,28 @@
</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 }}
@@ -35,7 +48,11 @@
</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>