From a525544ad30122d068b86fdd1dc00e697ac13f15 Mon Sep 17 00:00:00 2001 From: user9994793890 <3722323274763196-user9994793890@noreply.coze.cn> Date: Mon, 13 Jul 2026 14:09:38 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E6=B7=BB=E5=8A=A0=E7=94=9F=E6=88=90?= =?UTF-8?q?=E6=97=A5=E6=8A=A5=E5=A4=9A=E9=80=89=E5=8A=9F=E8=83=BD=EF=BC=8C?= =?UTF-8?q?=E6=94=AF=E6=8C=81=E6=89=B9=E9=87=8F=E7=94=9F=E6=88=90=E5=A4=9A?= =?UTF-8?q?=E4=B8=AA=E9=85=8D=E7=BD=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Coze-Commit-Type: user Coze-User-ID: 3722323274763196 Coze-Conversation-ID: 9894087 --- templates/index.html | 45 ++++++++++++++++++++++++++++++++------------ 1 file changed, 33 insertions(+), 12 deletions(-) diff --git a/templates/index.html b/templates/index.html index 1622f76..250a14a 100644 --- a/templates/index.html +++ b/templates/index.html @@ -852,7 +852,7 @@
💡 使用说明:
- 1. 选择已创建的配置
+ 1. 选择已创建的配置(可多选)
2. 选择时间范围(可点击预设按钮快速选择)
3. 点击"生成日报"按钮
4. 生成成功后,点击"立即下载Excel文件"按钮下载,或切换到"历史记录"标签页查看和下载 @@ -861,10 +861,18 @@

生成日报

- - + +
+
+ +
+
+ +
+
@@ -2004,15 +2012,28 @@ const result = await response.json(); if (result.success) { - const select = document.getElementById('generate-config'); - select.innerHTML = '' + - result.data.map(c => ``).join(''); + const container = document.getElementById('config-checkbox-list'); + container.innerHTML = result.data.map(c => ` + + `).join(''); } } catch (error) { console.error('加载配置失败:', error); } } + // 全选/取消全选配置 + function toggleSelectAllConfigs() { + const selectAll = document.getElementById('select-all-configs'); + const checkboxes = document.querySelectorAll('.config-checkbox'); + checkboxes.forEach(cb => { + cb.checked = selectAll.checked; + }); + } + // 设置预设时间 function setPresetTime(preset) { const now = new Date(); @@ -2077,14 +2098,14 @@ return String(dateStr); } - // 生成日报 + // 生成日报(支持多选) async function generateReport() { - const configId = document.getElementById('generate-config').value; + const checkboxes = document.querySelectorAll('.config-checkbox:checked'); const startTime = document.getElementById('start-time').value; const endTime = document.getElementById('end-time').value; - if (!configId) { - alert('请选择配置'); + if (checkboxs.length === 0) { + alert('请至少选择一个配置'); return; }