diff --git a/plugins/message_summary/main.py b/plugins/message_summary/main.py index 3bb9b4c..5c1b16c 100644 --- a/plugins/message_summary/main.py +++ b/plugins/message_summary/main.py @@ -17,7 +17,7 @@ class MessageSummaryPlugin(MessagePluginInterface): @property def name(self) -> str: - return "message_summary" + return "群聊消息总结" @property def version(self) -> str: diff --git a/plugins/stats_collector/main.py b/plugins/stats_collector/main.py index 69474ab..b27e23f 100644 --- a/plugins/stats_collector/main.py +++ b/plugins/stats_collector/main.py @@ -17,7 +17,7 @@ class StatsCollectorPlugin(PluginInterface): @property def name(self) -> str: - return "command collector" + return "群聊指令数据记录" @property def version(self) -> str: diff --git a/plugins/stats_dashboard/templates/index.html b/plugins/stats_dashboard/templates/index.html index 53c316e..2c995ed 100644 --- a/plugins/stats_dashboard/templates/index.html +++ b/plugins/stats_dashboard/templates/index.html @@ -56,7 +56,7 @@ 平均响应时间
- {{ avgResponseTime.toFixed(2) }} ms + {{ typeof avgResponseTime === 'number' ? avgResponseTime.toFixed(2) : '0.00' }} ms
@@ -136,7 +136,7 @@ successRate: 0, activeUsers: 0, activeGroups: 0, - avgResponseTime: 0, + avgResponseTime: 0, // 确保这里初始化为数字 topUsers: [], topGroups: [], topPlugins: [], @@ -163,7 +163,7 @@ this.successRate = parseFloat(data.success_rate) || 0; this.activeUsers = data.active_users || 0; this.activeGroups = data.active_groups || 0; - this.avgResponseTime = data.avg_response_time || 0; + this.avgResponseTime = parseFloat(data.avg_response_time) || 0; this.topUsers = data.top_users || []; this.topGroups = data.top_groups || []; this.topPlugins = data.top_plugins || [];