|
|
@ -116,6 +116,9 @@ Page({ |
|
|
|
* 生命周期函数--监听页面加载 |
|
|
|
*/ |
|
|
|
onLoad: function (options) { |
|
|
|
wx.showLoading({ |
|
|
|
title: '加载中...', |
|
|
|
}) |
|
|
|
this.subType = options.key |
|
|
|
const { windowHeight } = wx.getSystemInfoSync() |
|
|
|
const pageHeight = windowHeight - 48 |
|
|
@ -151,11 +154,14 @@ Page({ |
|
|
|
}); |
|
|
|
|
|
|
|
|
|
|
|
wx.hideLoading() |
|
|
|
// wx.hideLoading()
|
|
|
|
|
|
|
|
}, |
|
|
|
|
|
|
|
getSubSystemPatrolAbout: function (options) { |
|
|
|
wx.showLoading({ |
|
|
|
title: '加载中...', |
|
|
|
}) |
|
|
|
// const userInfo=wx.getStorageSync('userInfo');
|
|
|
|
let that = this; |
|
|
|
const STime = moment('1970-01-01').format('YYYY-MM-DD') |
|
|
@ -167,6 +173,7 @@ Page({ |
|
|
|
const query = { STime, ETime, keywords } |
|
|
|
Request.get(getSubSystemPatrolAbout(query)).then(res => { |
|
|
|
if (res) { |
|
|
|
|
|
|
|
//求出最小时间
|
|
|
|
const minTimeObject = res.reduce((min, current) => { |
|
|
|
// 比较时间,选择最小的时间
|
|
|
@ -284,10 +291,10 @@ Page({ |
|
|
|
}] |
|
|
|
}; |
|
|
|
that.initECharts(option); |
|
|
|
wx.hideLoading(); |
|
|
|
|
|
|
|
wx.hideLoading() |
|
|
|
} else { |
|
|
|
wx.hideLoading(); |
|
|
|
// wx.hideLoading();
|
|
|
|
} |
|
|
|
}) |
|
|
|
}, |
|
|
@ -304,6 +311,7 @@ Page({ |
|
|
|
* 生命周期函数--监听页面显示 |
|
|
|
*/ |
|
|
|
onShow() { |
|
|
|
// wx.hideLoading()
|
|
|
|
|
|
|
|
}, |
|
|
|
|
|
|
|