670完成
This commit is contained in:
File diff suppressed because it is too large
Load Diff
@ -59,7 +59,7 @@ var mqttClient=null;
|
||||
videoDuration: 2,
|
||||
|
||||
hexArray: [],
|
||||
reSendNumber:""
|
||||
reSendNumber:""
|
||||
}
|
||||
},
|
||||
onLoad() {
|
||||
@ -401,7 +401,7 @@ reSendNumber:""
|
||||
}).catch(err => {
|
||||
console.log("完成指令发送失败");
|
||||
});
|
||||
},500)
|
||||
},1500)
|
||||
|
||||
},
|
||||
sendData(buffer) {
|
||||
|
@ -33,7 +33,7 @@
|
||||
url: '6155_V1'
|
||||
},
|
||||
{
|
||||
name: "/pages/BlueTooth/ModeSetting/HBY670",
|
||||
name: "/pages/BlueTooth/ModeSetting/HBY670V1",
|
||||
url: 'HBY670'
|
||||
},
|
||||
|
||||
|
@ -69,6 +69,29 @@
|
||||
showAgreement: false, // 控制弹窗显示
|
||||
}
|
||||
},
|
||||
onLoad(){
|
||||
if(uni.getStorageSync("token") && uni.getStorageSync("clientID")){//免登陆
|
||||
|
||||
let time=uni.getStorageSync("tokenTime");
|
||||
if(!time){
|
||||
time=0;
|
||||
}
|
||||
let currTime=new Date().getTime();
|
||||
if(currTime<time){
|
||||
console.log("登陆过,并且没过期,自动进入设备页");
|
||||
uni.switchTab({
|
||||
url: '/pages/common/index/index'
|
||||
});
|
||||
return;
|
||||
}else{
|
||||
//token过期了
|
||||
uni.removeStorageSync("token")
|
||||
uni.removeStorageSync("clientID")
|
||||
uni.removeStorageSync("tokenTime")
|
||||
}
|
||||
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
// 获取验证码
|
||||
async getPhoneCode() {
|
||||
@ -148,26 +171,7 @@
|
||||
|
||||
|
||||
console.log('44444');
|
||||
if(uni.getStorageSync("token") && uni.getStorageSync("clientID")){//免登陆
|
||||
|
||||
let time=uni.getStorageSync("tokenTime");
|
||||
if(!time){
|
||||
time=0;
|
||||
}
|
||||
let currTime=new Date().getTime();
|
||||
if(currTime<time){
|
||||
uni.switchTab({
|
||||
url: '/pages/common/index/index'
|
||||
});
|
||||
return;
|
||||
}else{
|
||||
//token过期了
|
||||
uni.removeStorageSync("token")
|
||||
uni.removeStorageSync("clientID")
|
||||
uni.removeStorageSync("tokenTime")
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
uni.showLoading({
|
||||
title: '登录中...'
|
||||
})
|
||||
|
Reference in New Issue
Block a user