Page({
data: {
ellipsis: false,
ellipsis1: false,
},
onLoad: function (options) {
const postsData = require('../localData/localData.js');
var id = options.id;
var adapterSource = postsData.adapterSource[id];
this.setData({
adapterSource: adapterSource
})
},
f1: function (event) {
wx.navigateTo({
url: '/pages/list/list'
})
},
tel: function () {
wx.makePhoneCall({
phoneNumber: '17623030926',
})
},
data: {
},
wz: function (event) {
console.log(adapterSource);
wx.getLocation({
type: 'gcj02',
success: function (res) {
var latitude = res.latitude
var longitude = res.longitude
wx.openLocation({
latitude: latitude,
longitude: longitude,
scale: 28
})
}
})
},
ellipsis: function () {
var value = !this.data.ellipsis;
this.setData({
ellipsis: value
})
},
ellipsis1: function () {
var value = !this.data.ellipsis1;
this.setData({
ellipsis1: value
})
},
})
这里是AppData里显示的