import {url} from '../../request' Page({ data: { list:[], show:false, picture:[{ image:'/image/20250407154233.jpg' }, { image:'/image/20250407154300.png' }, { image:'/image/20250407154310.png' } ], selectedIndex: 0, }, xiangqing(e){ const item = e.currentTarget.dataset.item; const id = item.id console.log(item); wx.navigateTo({ url: `/pages/xiangqing/xiangqing?id=${id}`, }) }, onLoad(options) { }, /** * 生命周期函数--监听页面初次渲染完成 */ onReady() { }, /** * 生命周期函数--监听页面显示 */ onShow() { const that =this wx.request({ url: url + '/project/query/card', method: 'POST', data: { }, header: { 'content-type': 'application/json' }, success(res) { console.log('查询成功', res); that.setData({ list:res.data.data }) }, fail(err) { console.error('请求失败', err); } }); }, /** * 生命周期函数--监听页面隐藏 */ onHide() { }, /** * 生命周期函数--监听页面卸载 */ onUnload() { }, /** * 页面相关事件处理函数--监听用户下拉动作 */ onPullDownRefresh() { }, /** * 页面上拉触底事件的处理函数 */ onReachBottom() { }, /** * 用户点击右上角分享 */ onShareAppMessage() { } })