维基小程序
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.
 
 
 

70 lines
1.2 KiB

<template>
<view>
<view class="polict-content">
<rich-text :nodes="content"></rich-text>
</view>
</view>
</template>
<script>
import { updateStatus } from 'api/updateStatus'
import { queryMsgDetail } from 'api/queryMsgDetail'
export default {
onShareAppMessage(res) {
if (res.from === 'button') {// 来自页面内分享按钮
console.log(res.target)
}
return {
title: '',
path: '/pages/MessaegPage/MessaegPage'
}
},
async onLoad(option){
// console.log(option.id)
const that = this
try{
const params = {
param:{
id: option.id,
readStatus: 1
}
}
await updateStatus(params)
const params1 = {
param:{
id: option.id
}
}
const data = await queryMsgDetail(params1)
// console.log(data.content)
that.content = data.content
}catch(err){
//TODO handle the exception
console.log(err)
}
},
data() {
return {
content: '',
}
},
methods: {
collection(){
this.state = !this.state
}
}
}
</script>
<style lang="scss">
.polict-content{
background-color: $white;
margin-left: 30upx;
width: 690upx;
height: auto;
font-size: 16px;
padding: 20upx;
margin-top: 30upx;
border-radius: 5px;
}
</style>