修改工作台开户建筑必填和优化报错信息,账单支持峰谷

This commit is contained in:
2025-04-22 18:00:12 +08:00
parent 721937fa5b
commit fb9e727efd
9 changed files with 360 additions and 65 deletions

View File

@@ -1,5 +1,5 @@
import { getBillList } from "../../service/accounting"
import { alertInfo } from "../../utils/index";
import { alertInfo, loadingFunc } from "../../utils/index";
import request from '../../utils/request'
const { OK } = request;
@@ -17,11 +17,19 @@ Page({
* 生命周期函数--监听页面加载
*/
onLoad(options) {
this.init();
const that = this;
loadingFunc(async () => {
await that.init();
})
},
async init() {
const { page, list } = this.data;
const { code, data, message } = await getBillList(page)
if (code !== OK) {
alertInfo(message)
return;
}
if (!data?.length) {
alertInfo("没有更多了")
return;