diff --git a/web/static/css/style.css b/web/static/css/style.css index 8e84ec82..032e4f2a 100644 --- a/web/static/css/style.css +++ b/web/static/css/style.css @@ -3273,7 +3273,12 @@ header { } .pagination-container { - margin-top: 10px; + margin-top: 0; +} + +/* 漏洞管理页面的分页栏间距优化 */ +#vulnerability-pagination.pagination-fixed { + margin-top: 12px; } /* Skills管理页面分页优化 */ @@ -3310,6 +3315,9 @@ header { /* 确保底部左右角都是圆角 */ border-bottom-left-radius: 8px; border-bottom-right-radius: 8px; + /* 添加边框和阴影,使圆角更明显 */ + border: 1px solid var(--border-color); + box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05); } .pagination-fixed .pagination { @@ -3331,6 +3339,8 @@ header { /* 确保底部左右角都是圆角 */ border-bottom-left-radius: 8px; border-bottom-right-radius: 8px; + /* 移除顶部边框,因为外层容器已有边框 */ + border-top: none; } /* 左侧:信息显示和每页数量选择器 - 更自然的设计 */ @@ -3453,7 +3463,7 @@ header { white-space: nowrap; font-weight: 400; /* 添加圆角设计,四个角都是圆的 */ - border-radius: 6px !important; + border-radius: 8px !important; background: var(--bg-secondary) !important; border: 1px solid var(--border-color) !important; display: inline-flex !important; @@ -7754,6 +7764,7 @@ header { display: flex; flex-direction: column; gap: 16px; + margin-bottom: 0; } .vulnerability-card { @@ -9576,6 +9587,7 @@ header { /* 限制标题最多显示2行 */ display: -webkit-box; -webkit-line-clamp: 2; + line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; } @@ -9593,6 +9605,7 @@ header { /* 限制描述的最大行数,保持卡片整洁 */ display: -webkit-box; -webkit-line-clamp: 3; + line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; } diff --git a/web/static/js/chat.js b/web/static/js/chat.js index a78c7d63..621f3888 100644 --- a/web/static/js/chat.js +++ b/web/static/js/chat.js @@ -1260,7 +1260,8 @@ function renderProcessDetails(messageId, processDetails) { addTimelineItem(timeline, eventType, { title: itemTitle, message: detail.message || '', - data: data + data: data, + createdAt: detail.createdAt // 传递实际的事件创建时间 }); }); @@ -1980,6 +1981,16 @@ async function deleteConversation(conversationId, skipConfirm = false) { addAttackChainButton(null); } + // 更新缓存 - 立即删除,确保后续加载时能正确识别 + delete conversationGroupMappingCache[conversationId]; + // 同时从待保留映射中移除 + delete pendingGroupMappings[conversationId]; + + // 如果当前在分组详情页面,重新加载分组对话 + if (currentGroupId) { + await loadGroupConversations(currentGroupId); + } + // 刷新对话列表 loadConversations(); } catch (error) { diff --git a/web/static/js/monitor.js b/web/static/js/monitor.js index cc90a9b0..c86b9aa9 100644 --- a/web/static/js/monitor.js +++ b/web/static/js/monitor.js @@ -835,7 +835,26 @@ function addTimelineItem(timeline, type, options) { item.id = itemId; item.className = `timeline-item timeline-item-${type}`; - const time = new Date().toLocaleTimeString('zh-CN', { hour: '2-digit', minute: '2-digit', second: '2-digit' }); + // 使用传入的createdAt时间,如果没有则使用当前时间(向后兼容) + let eventTime; + if (options.createdAt) { + // 处理字符串或Date对象 + if (typeof options.createdAt === 'string') { + eventTime = new Date(options.createdAt); + } else if (options.createdAt instanceof Date) { + eventTime = options.createdAt; + } else { + eventTime = new Date(options.createdAt); + } + // 如果解析失败,使用当前时间 + if (isNaN(eventTime.getTime())) { + eventTime = new Date(); + } + } else { + eventTime = new Date(); + } + + const time = eventTime.toLocaleTimeString('zh-CN', { hour: '2-digit', minute: '2-digit', second: '2-digit' }); let content = `