断开异常

This commit is contained in:
yy 2024-05-29 17:14:48 +08:00
parent 78aaffe4e1
commit d22fcb51f9
2 changed files with 2 additions and 4 deletions

View File

@ -83,7 +83,7 @@ export const useRemoteWsStore = defineStore("remoteWs", {
Session.set("remoteTasks", this.remoteTasks) Session.set("remoteTasks", this.remoteTasks)
}, },
getActiveRemoteTask() { getActiveRemoteTask() {
let index = 0; let index = 0
for (let i = 0; i < this.remoteTasks.length; i++) { for (let i = 0; i < this.remoteTasks.length; i++) {
if (this.remoteTasks[i].isRemote) index = i if (this.remoteTasks[i].isRemote) index = i
} }

View File

@ -202,9 +202,7 @@ const breakRemote = () => {
remoteWsStore.getRemoteTask()[currentIndex] remoteWsStore.getRemoteTask()[currentIndex]
remoteWsStore.disconnect(remoteItem.value.patient, remoteItem.value.patientId, remoteItem.value.date, currentIndex) remoteWsStore.disconnect(remoteItem.value.patient, remoteItem.value.patientId, remoteItem.value.date, currentIndex)
remoteWsStore.resetRemoteTask(currentIndex) remoteWsStore.resetRemoteTask(currentIndex)
if (remoteWsStore.getActiveRemoteTask()) { showData(remoteWsStore.getActiveRemoteTask())
showData(remoteWsStore.getActiveRemoteTask())
}
emit('breakRemote') emit('breakRemote')
} }