<template>
|
|
<!-- 0文化遗产详情、1申遗历程详情、2非遗体验详情 三合一 -->
|
|
<view class="page">
|
|
<navbar title="新闻详情" leftClick @leftClick="$utils.navigateBack" />
|
|
|
|
<view class=""
|
|
style="padding: 20rpx;">
|
|
<uv-parse :content="detail.newsContent"></uv-parse>
|
|
</view>
|
|
|
|
</view>
|
|
</template>
|
|
|
|
<script>
|
|
export default {
|
|
components : {
|
|
},
|
|
data() {
|
|
return {
|
|
detail : {},
|
|
id : 0,
|
|
type : '',
|
|
dict : {},
|
|
collectonFlag : false,
|
|
}
|
|
},
|
|
onLoad(args) {
|
|
this.id = args.id
|
|
},
|
|
onShow() {
|
|
this.queryArticleById()
|
|
},
|
|
onPullDownRefresh(){
|
|
this.queryArticleById()
|
|
},
|
|
methods: {
|
|
queryArticleById(){
|
|
let data = {
|
|
newsId : this.id,
|
|
}
|
|
// if(uni.getStorageSync('token')){
|
|
// data.token = uni.getStorageSync('token')
|
|
// }
|
|
this.$api('queryNewsById', data, res => {
|
|
uni.stopPullDownRefresh()
|
|
if(res.code == 200){
|
|
this.detail = res.result
|
|
}
|
|
})
|
|
},
|
|
}
|
|
}
|
|
</script>
|
|
|
|
<style scoped lang="scss">
|
|
.page{
|
|
|
|
}
|
|
</style>
|