From b7b1d4a0559d460a4ddba7e9a000bc99736f8c82 Mon Sep 17 00:00:00 2001 From: rongweikang <1174906669@qq.com> Date: Tue, 27 Feb 2024 17:44:27 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96=E6=A0=B7=E5=BC=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/pages/index/index.less | 5 +++++ src/pages/index/index.tsx | 27 ++++++++++++++++++++------- 2 files changed, 25 insertions(+), 7 deletions(-) diff --git a/src/pages/index/index.less b/src/pages/index/index.less index 0b760b7..12513f1 100644 --- a/src/pages/index/index.less +++ b/src/pages/index/index.less @@ -2,6 +2,11 @@ page { background: #f3f3f3; } +.mb10{ + margin-bottom: 20rpx; + font-size: 32rpx; +} + /* 隐藏横向滚动条 */ ::-webkit-scrollbar { width: 0; diff --git a/src/pages/index/index.tsx b/src/pages/index/index.tsx index 8baa274..ee9e03e 100644 --- a/src/pages/index/index.tsx +++ b/src/pages/index/index.tsx @@ -138,6 +138,8 @@ class Index extends Component { } async onLoad() { + console.log(1123131233); + // 仅非扫码进入页面时,校验跳转欢迎页 if (!this.$instance.router?.params?.q) { const isFirst = Taro.getStorageSync("isWelcome"); @@ -145,9 +147,15 @@ class Index extends Component { go("/pages/initiate/initiate"); } } + if (Taro.getStorageSync("skip")) { + this.setState({ showEquipment: true }) + Taro.removeStorageSync('skip'); + } } - componentDidMount() { } + componentDidMount() { + + } componentWillUnmount() { } @@ -638,7 +646,12 @@ class Index extends Component { go("/pages/iotCarePlan/iotCarePlan"); // 画页面直接跳转 // return; } - + onUnloginConfirm() { + this.setState({ showEquipment: false }) + } + onUnloginClose() { + this.setState({ showEquipment: false }) + } //连接完成时数据的回调 offlineChange = async (e) => { console.log("offlineChange", e); @@ -854,16 +867,16 @@ class Index extends Component { title='提示' content={ - 仪器:小紫单美容仪 - 序列号:uniquie14231 - 您需要完成注册登录才能进行一起绑定 + 仪器:小紫单美容仪 + 序列号:uniquie14231 + 您需要完成注册登录才能进行一起绑定 } confirmButtonText='知道了' textAlgin='center' isClose={false} - close={this.onBindErrorClose} - confirm={this.onBindErrorConfirm} + close={this.onUnloginClose.bind(this)} + confirm={this.onUnloginConfirm.bind(this)} > {/*