You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
project/pages/index/index.ts

25 lines
655 B

// index.ts
// 获取应用实例
const app = getApp<IAppOption>()
Page({
data: {
taskList: [],
motto: 'Hello World',
},
onShow() {
// let list = [
// { id: 1, title: "任务一", startTime: "2022-10-01", endTime: "1020-20-22", end: "40" },
// { id: 2, title: "任务二", startTime: "2022-10-01", endTime: "1020-20-22", end: "40" },
// { id: 3, title: "任务三", startTime: "2022-10-01", endTime: "1020-20-22", end: "40" }
// ]
this.setData({
taskList: wx.getStorageSync("taskList") || []
});
},
onLoad() {
this.setData({
taskList: wx.getStorageSync("taskList") || []
});
},
})