刘洋 hai 7 meses
pai
achega
a754bad72e
Modificáronse 1 ficheiros con 3 adicións e 3 borrados
  1. 3 3
      src/features/OnlineExam/CheckComputer.vue

+ 3 - 3
src/features/OnlineExam/CheckComputer.vue

@@ -28,13 +28,13 @@ let current = $ref(1);
 // });
 
 let downlink = $ref(100);
-let rtt = $ref(0);
+let rtt = $ref(-1);
 const network = $computed(() => {
   return {
     downlink,
     downlinkStatus: downlink > 0.1,
     rrt: rtt,
-    rrtStatus: rtt < 1000,
+    rrtStatus: rtt < 1000 && rtt >= 0,
   };
 });
 
@@ -391,7 +391,7 @@ function next() {
               </tr>
               <tr>
                 <td>电脑当前网络延迟</td>
-                <td>{{ network.rrt }}毫秒</td>
+                <td>{{ network.rrt >= 0 ? network.rrt : "" }}毫秒</td>
                 <td>
                   <div v-if="network.rrtStatus">
                     <n-icon class="pass-check" :component="Checkmark" />