取消3秒刷新

pull/4/head
pangdundun 2023-10-07 18:36:07 +08:00
parent 58160ca38a
commit 97ab8e6518
3 changed files with 16 additions and 14 deletions

View File

@ -224,7 +224,7 @@
indexs: 1,
inputData1: [],
timer: null
// timer: null
};
},
watch: {
@ -234,13 +234,13 @@
this.deviceId = option.id
this.dataInit()
let that = this
this.timer = setInterval(function() {
that.dataInit();
that.getReg();
}, 3000);
// this.timer = setInterval(function() {
// that.dataInit();
// that.getReg();
// }, 3000);
},
onUnload() {
clearTimeout(this.timer)
// clearTimeout(this.timer)
},
onPullDownRefresh() {
uni.showLoading({

File diff suppressed because one or more lines are too long

View File

@ -412,22 +412,24 @@ var _default = {
left1Act: -1,
topActive: 0,
indexs: 1,
inputData1: [],
timer: null
inputData1: []
// timer: null
};
},
watch: {},
onLoad: function onLoad(option) {
this.deviceId = option.id;
this.dataInit();
var that = this;
this.timer = setInterval(function () {
that.dataInit();
that.getReg();
}, 3000);
// this.timer = setInterval(function() {
// that.dataInit();
// that.getReg();
// }, 3000);
},
onUnload: function onUnload() {
clearTimeout(this.timer);
// clearTimeout(this.timer)
},
onPullDownRefresh: function onPullDownRefresh() {
uni.showLoading({