Commit e362e5e5 authored by Sky's avatar Sky

修改部分场合重新开始训练时,tab定位不对的bug,删除训练数据页面的常亮设置

parent 69a7f454
......@@ -2,8 +2,6 @@ import brightness from '@system.brightness' //保持屏幕常亮
import app from '@system.app' //右滑退出
import router from '@system.router' //页面跳转
var timer;
export default {
data: {
acCalorie: "0", //卡路里
......@@ -21,18 +19,7 @@ export default {
_this.averHeartRate = _this.endAverHeartRate;
_this.maxHeartRate = _this.endMaxHeartRate;
},
onShow() {
let _this = this;
//保持屏幕常亮
_this.keepScreenOn();
timer = setInterval(function () {
_this.keepScreenOn();
},2 * 60 * 1000);
},
onDestroy() {
if (timer != null) {
clearInterval(timer);
}
//取消接收手机侧第三方应用发过来的消息
FeatureAbility.unsubscribeMsg();
},
......@@ -50,19 +37,6 @@ export default {
}
},
/**
*保持屏幕常亮
*/
keepScreenOn() {
brightness.setKeepScreenOn({
keepScreenOn: true,
success: function () {
},
fail: function (data, code) {
}
})
},
/**
*获取客户端短消息
*/
......
......@@ -162,6 +162,7 @@ export default {
switch (msg.eventFlg) {
case "0": //训练准备
_this.page = "0";
_this.tabIndex = "0";
break;
case "1": //训练准备后的倒计时
_this.countdownT = model.countdownT;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment