diff --git a/Service/BudgetService.cs b/Service/BudgetService.cs index 921db86..f3caf24 100644 --- a/Service/BudgetService.cs +++ b/Service/BudgetService.cs @@ -419,7 +419,9 @@ public class BudgetService( 【格式要求】 1. 使用HTML格式(移动端H5页面风格) 2. 生成清晰的报告标题(基于用户问题) - 3. 使用表格展示统计数据(table > thead/tbody > tr > th/td) + 3. 使用表格展示统计数据(table > thead/tbody > tr > th/td), + 3.1 table要求不能超过屏幕宽度,尽可能简洁明了,避免冗余信息 + 3.2 预算金额精确到整数即可,实际金额精确到小数点后1位 4. 使用合适的HTML标签:h2(标题)、h3(小节)、p(段落)、table(表格)、ul/li(列表)、strong(强调) 5. 支出金额用 金额 包裹 6. 收入金额用 金额 包裹 @@ -574,7 +576,18 @@ public class BudgetService( if (expenseItems.Count == 0) description.Append("

无支出预算

"); else { - description.Append(""); + description.Append(""" +
名称金额折算合计
+ + + + + + + + + + """); foreach (var item in expenseItems) { description.Append($""); diff --git a/Web/src/styles/rich-content.css b/Web/src/styles/rich-content.css index 58b0867..d605dad 100644 --- a/Web/src/styles/rich-content.css +++ b/Web/src/styles/rich-content.css @@ -71,7 +71,7 @@ .rich-html-content thead, .rich-html-content tbody { display: table; - width: 130%; + width: 100%; min-width: 400px; /* 确保窄屏下有足够宽度触发滚动 */ table-layout: fixed; /* 核心:强制列宽分配逻辑一致 */ }
名称金额折算合计
{item.Name}{item.Limit:N0}x{item.Factor:0.##}{item.Total:N0}