zycp-ddxcx/pages/start/start.js

31 lines
520 B
JavaScript
Raw Normal View History

2022-03-09 07:06:54 +00:00
Page({
data: {
timeNumber: 3
},
onShow(){
setTimeout(() => {
this.setData({
timeNumber:2
})
}, 1000);
setTimeout(() => {
this.setData({
timeNumber:1
})
}, 2000);
setTimeout(() => {
2022-03-09 08:39:27 +00:00
if(dd.$toolAll.getCache('userData')){
2022-03-09 07:48:29 +00:00
// 前往首页
dd.redirectTo({url:'/pages/home/home'});
}else{
// 前往登录页
dd.redirectTo({url:'/pages/login/login'});
}
2022-03-09 07:06:54 +00:00
}, 3000);
},
onLoad() {
},
});