文件
NHCshopro/uniapp/pages/message/detail.vue
wikiboss f141d35f1c Add 'uniapp/' from commit '096e31448ca089004c78af69f2006c2b0324d8a4'
git-subtree-dir: uniapp
git-subtree-mainline: b87880e247
git-subtree-split: 096e31448c
2026-11-20 09:08:51 +08:00

54 行
894 B
Vue

<template>
<view class="padding">
<view class="padding-bottom solid-bottom">
<view class="text-bold" style="font-size: 40rpx;">{{detail.title}}</view>
<view class="margin-top text-gray text-sm">
{{detail.create_time}} 丨 {{detail.views}} 观看
</view>
</view>
<view class="padding-tb">
<u-parse :html="detail.content"></u-parse>
</view>
</view>
</template>
<script>
export default {
data() {
return {
content: '',
id: '',
detail: ''
}
},
onLoad(query) {
this.id = query.id
this.init()
},
methods: {
async init() {
uni.showLoading({
})
await this.getData()
uni.hideLoading()
},
getData() {
return this.$http('notice.detail', {
id: this.id
}).then(res => {
this.detail = res.data.detail
})
}
}
}
</script>
<style lang="scss">
page{
background: #fff;
}
</style>