From 4a60d242636d261b8ecbea8c2ebf1e759a0e0f4a Mon Sep 17 00:00:00 2001 From: qsj <731458905@qq.com> Date: Wed, 13 Mar 2024 20:59:28 +0800 Subject: [PATCH] =?UTF-8?q?=E5=88=9D=E6=AC=A1=E6=8A=A4=E7=90=86=E5=BC=B9?= =?UTF-8?q?=E7=AA=97=E9=85=8D=E7=BD=AE=E8=A7=86=E9=A2=91=E6=97=B6=E6=97=A0?= =?UTF-8?q?=E6=B3=95=E6=92=AD=E6=94=BE=EF=BC=8C=E4=B8=94=E8=8B=A5=E6=B2=A1?= =?UTF-8?q?=E6=9C=89=E9=85=8D=E7=BD=AE=E8=A7=86=E9=A2=91=E6=97=B6=EF=BC=8C?= =?UTF-8?q?=E5=BA=94=E8=AF=A5=E4=B8=8D=E6=98=BE=E7=A4=BA=E5=BC=B9=E7=AA=97?= =?UTF-8?q?=E6=89=8D=E5=AF=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/moduleIOT/pages/iotCarePlan/iotCarePlan.tsx | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/src/moduleIOT/pages/iotCarePlan/iotCarePlan.tsx b/src/moduleIOT/pages/iotCarePlan/iotCarePlan.tsx index cdc576e..313ec7c 100644 --- a/src/moduleIOT/pages/iotCarePlan/iotCarePlan.tsx +++ b/src/moduleIOT/pages/iotCarePlan/iotCarePlan.tsx @@ -1887,13 +1887,20 @@ class IotCarePlan extends Component { let res = await InstrumentInfo.firstNurseInfo({ instrumentId: currentDevice.id, }); + console.log(res,'接口'); + if (res.data.code === 200) { let isFirstTipShow = getStorageSync( "first_instrument_" + currentDevice.id ); + console.log(isFirstTipShow,'查看返回值'); + if (!isFirstTipShow) { - // 首次进入页面:自动打开打卡介绍弹窗 - this.setState({ nurseInfo: res.data.data, isFirstTipShow: true }); + if(res.data.length !== 0){ + // 首次进入页面:自动打开打卡介绍弹窗 + this.setState({ nurseInfo: res.data.data, isFirstTipShow: true }); + } + setStorageSync("first_instrument_" + currentDevice.id, true); } else { this.setState({ nurseInfo: res.data.data });