54 行
894 B
Vue
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>
|