锦水居民端小程序
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.

34 lines
750 B

6 years ago
const api = require('../../../../utils/home')
import util from '../../../../utils/util'
import { getTimestamp } from '../../../../utils/common'
Page({
data: {
noticeObj: {},
noticeObjContent: ""
},
onLoad (options) {
this.getNoticeDetail(options.id)
this.browseNotice(options.id)
},
getNoticeDetail (id) {
let that = this
api.getNoticeDetail(id).then(res => {
that.setData({
noticeObj: res.data,
noticeObjContent: util.formatRichText(res.data.noticeContent)
})
}).catch(err => {
console.log(err)
})
},
browseNotice (id) {
let para = {
noticeId: id
}
api.browseNotice(para).then(res => {
}).catch(err => {
console.log(err)
})
}
})