| 345 | } |
| 346 | |
| 347 | function getConnectionName(connectionData) { |
| 348 | if (!connectionData.createdAt) return '未命名连接'; |
| 349 | |
| 350 | const date = new Date(connectionData.createdAt); |
| 351 | const year = date.getFullYear(); |
| 352 | const month = String(date.getMonth() + 1).padStart(2, '0'); |
| 353 | const day = String(date.getDate()).padStart(2, '0'); |
| 354 | const hours = String(date.getHours()).padStart(2, '0'); |
| 355 | const minutes = String(date.getMinutes()).padStart(2, '0'); |
| 356 | const seconds = String(date.getSeconds()).padStart(2, '0'); |
| 357 | return `${year}-${month}-${day} ${hours}:${minutes}:${seconds}`; |
| 358 | } |
| 359 | |
| 360 | // Connection management module |
| 361 | |