This commit is contained in:
hailin 2025-05-20 13:56:32 +08:00
parent 1f15187e10
commit df5bb6d4f9
1 changed files with 4 additions and 3 deletions

View File

@ -431,9 +431,10 @@ export function DetailPageHeader({ data }: { data: any }) {
console.log("收到进度信息:", msg); console.log("收到进度信息:", msg);
setStatusText(msg); setStatusText(msg);
const match = msg.match(/进度[:]?\s*(\d+)%/); const percentMatch = msg.match(/(\d+)%/);
if (match && match[1]) { if (percentMatch && percentMatch[1]) {
setProgress(match[1] + "%"); setProgress(percentMatch[1] + "%");
}
if (match[1] === "100") { if (match[1] === "100") {
console.log("部署完成 ✅,重新拉取状态!"); console.log("部署完成 ✅,重新拉取状态!");