修复了一些功能

This commit is contained in:
MengMengCode
2026-06-08 15:44:35 +08:00
parent b58a6b1030
commit 608b50f18a
6 changed files with 113 additions and 10 deletions
+1 -2
View File
@@ -456,10 +456,9 @@ export const getWebSSHUrl = (containerName: string) => {
return `${protocol}//${window.location.host}/api/ssh?${params.toString()}`
}
export const getWebVNCUrl = (containerName: string, ticket?: string) => {
export const getWebVNCUrl = (containerName: string) => {
const protocol = window.location.protocol === 'https:' ? 'wss:' : 'ws:'
const params = new URLSearchParams({ container: containerName })
if (ticket) params.set('ticket', ticket)
return `${protocol}//${window.location.host}/api/vnc?${params.toString()}`
}