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.
53 lines
1.1 KiB
53 lines
1.1 KiB
// components/issueDetailComponent1/issueDetailComponent.js
|
|
Component({
|
|
/**
|
|
* 组件的属性列表
|
|
*/
|
|
properties: {
|
|
detailData: { // 属性名
|
|
type: Object,
|
|
value: {}
|
|
},
|
|
issueState: {
|
|
type: Number,
|
|
value: ""
|
|
},
|
|
itemState: {
|
|
type: Number,
|
|
value: ""
|
|
}
|
|
},
|
|
|
|
/**
|
|
* 组件的初始数据
|
|
*/
|
|
data: {
|
|
|
|
},
|
|
|
|
/**
|
|
* 组件的方法列表
|
|
*/
|
|
methods: {
|
|
toComments(e) {
|
|
const eventId = this.data.detailData.eventId
|
|
wx.navigateTo({
|
|
url: `../../pages/comments/comments?eventId=${eventId}`
|
|
})
|
|
|
|
if (this.data.itemState == 1 || this.data.itemState == 2) {
|
|
wx.navigateTo({
|
|
url: `../../../pages/comments/comments?eventId=${eventId}`
|
|
})
|
|
}
|
|
},
|
|
//预览图片,放大预览
|
|
preview(event) {
|
|
let currentUrl = event.currentTarget.dataset.src
|
|
wx.previewImage({
|
|
current: currentUrl, // 当前显示图片的http链接
|
|
urls: this.data.detailData.images // 需要预览的图片http链接列表
|
|
})
|
|
}
|
|
}
|
|
})
|