diff --git a/pages/analysis/sample/sample-work-detail.vue b/pages/analysis/sample/sample-work-detail.vue index 2859075..3431887 100644 --- a/pages/analysis/sample/sample-work-detail.vue +++ b/pages/analysis/sample/sample-work-detail.vue @@ -1053,11 +1053,7 @@ const listenDeviceData = () => { uni.$on('deviceData', res => { switch (res.deviceType) { case 'balance': - console.log(res.deviceId) - if (currentAuncel.value.id === res.deviceId) { - console.log(res) - currentAuncel.value.weightData = res.weightData currentAuncel.value.weightUnit = res.weightUnit currentAuncel.value.weightStable = res.weightStable @@ -1084,7 +1080,7 @@ const listenDeviceData = () => { }) //控制设备状态 uni.$on('controlDevice', res => { - if (currentAuncel.value.id === res.deviceId) { + if (currentAuncel.value.id === res.deviceId && !res.isControl) { currentAuncel.value.id = '' currentAuncel.value.name = '' currentAuncel.value.code = ''