// components/house-item/house-item.js Component({ /** * 组件的属性列表 */ properties: { room: Object }, options: { addGlobalClass: true, }, /** * 组件的初始数据 */ data: { }, /** * 组件的方法列表 */ methods: { gotoWV(e) { let { id, index } = e.currentTarget.dataset console.log(id) let data = { id: id, index: index, } this.triggerEvent('gotoWV', data) } // toDetail () { // getApp().autoSubcrebe && getApp().autoSubcrebe() // getApp().globalData.lastHouse = this.properties.house // console.log(this.properties.house) // wx.navigateTo({ // url: `/pages/detail/detail?house_id=${this.properties.house.house_id}` // }) // } } })