2024-07-29 09:16:58 +08:00

33 lines
807 B
TypeScript

// e:\project\dy_video_all\初晴剧场\pages\consumption\consumption.ts
import { httpRequest } from "../../utils/httpReques";
Page({
data: {
moneyLogList: [],
moneyFlag: false
},
onLoad() {
// options
},
onShow() {
httpRequest('/moneylog', 'POST').then((res: any) => {
console.log(res, "moneylogmoneylog")
if (res.status == 1 && Array.isArray(res.data)) {
this.setData({
moneyFlag: true,
moneyLogList: res.data,
})
} else {
this.setData({
moneyFlag: true,
})
}
})
},
toPathVideo(ev: any) {
const sid = ev.currentTarget.dataset.sid;
const id = ev.currentTarget.dataset.id;
tt.navigateTo({
url: `/pages/videoDetail/videoDetail?sid=${sid}&id=${id || ''}`,
});
},
})