修改抄表记录峰谷不显示的问题

This commit is contained in:
2025-06-17 17:30:51 +08:00
parent a36faa9bcb
commit 7bd4da3c84
5 changed files with 44 additions and 11 deletions

View File

@@ -356,6 +356,7 @@ Page({
case "year":
this.setData({ year: time, visible: false, }, () => {
loadingFunc(async () => {
await this.getParkInfo()
await this.init();
})
});
@@ -364,6 +365,7 @@ Page({
const [year, month] = time.split("-")
this.setData({ yearMonth: time, yearMonthStamp: new Date(Number(year), Number(month) - 1, 1).getTime(), visible: false }, () => {
loadingFunc(async () => {
await this.getParkInfo()
await this.init();
})
});
@@ -376,13 +378,16 @@ Page({
page: 1,
}, () => {
loadingFunc(async () => {
await this.getParkInfo()
await this.init();
})
})
break;
}
},
readingChangeTime(e) {
console.log('e', e.detail)
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
@@ -410,7 +415,7 @@ Page({
case 2:
time = year;
}
const { data, code, message } = await getParkInfoByTime(park?.id, `${time}`, `${timeType}`,)
const { park:parkInfo, code, message } = await getParkInfoByTime(park?.id, `${time}`, `${timeType}`,)
if (code !== OK) {
alertInfo(message)
return;
@@ -419,7 +424,7 @@ Page({
return new Promise((resolve) => {
that.setData({
parkInfo: data
parkInfo: parkInfo
}, () => {
resolve()
})