2022-05-03 21:35:39 +08:00
|
|
|
|
<template>
|
2022-05-13 09:22:34 +08:00
|
|
|
|
<view class="content">
|
|
|
|
|
|
<view>
|
|
|
|
|
|
<view class="title">{{content.title}}</view>
|
|
|
|
|
|
<view class="time">发布时间:{{content.createtime}}</view>
|
|
|
|
|
|
<u-parse :content="content.content" @preview="preview" @navigate="navigate"></u-parse>
|
2022-05-03 21:35:39 +08:00
|
|
|
|
</view>
|
2022-05-13 09:22:34 +08:00
|
|
|
|
</view>
|
2022-05-03 21:35:39 +08:00
|
|
|
|
</template>
|
|
|
|
|
|
|
|
|
|
|
|
<script>
|
2022-05-13 09:22:34 +08:00
|
|
|
|
import {
|
|
|
|
|
|
mapState
|
|
|
|
|
|
} from "vuex";
|
|
|
|
|
|
import uParse from '@/components/u-parse/u-parse.vue'
|
|
|
|
|
|
export default {
|
|
|
|
|
|
data() {
|
|
|
|
|
|
return {
|
|
|
|
|
|
content: "",
|
|
|
|
|
|
url: null
|
|
|
|
|
|
}
|
|
|
|
|
|
},
|
|
|
|
|
|
components: {
|
|
|
|
|
|
uParse
|
|
|
|
|
|
},
|
|
|
|
|
|
computed: {
|
|
|
|
|
|
...mapState(["user", "appTheme"]),
|
|
|
|
|
|
},
|
|
|
|
|
|
onLoad(option) {
|
|
|
|
|
|
// 导航栏颜色
|
|
|
|
|
|
uni.setNavigationBarColor({
|
|
|
|
|
|
frontColor: '#ffffff',
|
|
|
|
|
|
backgroundColor: this.appTheme,
|
|
|
|
|
|
})
|
|
|
|
|
|
//
|
|
|
|
|
|
console.log(option)
|
|
|
|
|
|
if (option.id) {
|
|
|
|
|
|
this.getOrderDetail(option.id);
|
|
|
|
|
|
}
|
|
|
|
|
|
if (option.url) {
|
|
|
|
|
|
this.url = option.url
|
|
|
|
|
|
} else {
|
|
|
|
|
|
this.url = null
|
|
|
|
|
|
}
|
2022-05-03 21:35:39 +08:00
|
|
|
|
|
2022-05-13 09:22:34 +08:00
|
|
|
|
},
|
|
|
|
|
|
methods: {
|
|
|
|
|
|
getOrderDetail(orderno) {
|
|
|
|
|
|
this.$model.GetAdListDetail({
|
|
|
|
|
|
id: orderno
|
|
|
|
|
|
}).then(res => {
|
|
|
|
|
|
if (res.code != 0) return
|
|
|
|
|
|
this.content = res.data
|
|
|
|
|
|
console.log("资讯详情", res)
|
|
|
|
|
|
});
|
|
|
|
|
|
},
|
|
|
|
|
|
preview(src, e) {
|
|
|
|
|
|
// do something
|
|
|
|
|
|
},
|
|
|
|
|
|
navigate(href, e) {
|
|
|
|
|
|
// do something
|
|
|
|
|
|
}
|
2022-05-03 21:35:39 +08:00
|
|
|
|
}
|
2022-05-13 09:22:34 +08:00
|
|
|
|
}
|
2022-05-03 21:35:39 +08:00
|
|
|
|
</script>
|
|
|
|
|
|
|
|
|
|
|
|
<style scoped>
|
2022-05-13 09:22:34 +08:00
|
|
|
|
@import url("@/components/u-parse/u-parse.css");
|
2022-05-03 21:35:39 +08:00
|
|
|
|
|
2022-05-13 09:22:34 +08:00
|
|
|
|
.content {
|
|
|
|
|
|
padding: 30rpx;
|
|
|
|
|
|
}
|
2022-05-03 21:35:39 +08:00
|
|
|
|
|
2022-05-13 09:22:34 +08:00
|
|
|
|
.title {
|
|
|
|
|
|
width: 100%;
|
|
|
|
|
|
margin-bottom: 15px;
|
|
|
|
|
|
text-align: left;
|
|
|
|
|
|
font-size: 18px;
|
|
|
|
|
|
font-weight: bold;
|
|
|
|
|
|
}
|
2022-05-03 21:35:39 +08:00
|
|
|
|
|
2022-05-13 09:22:34 +08:00
|
|
|
|
.time {
|
|
|
|
|
|
width: 100%;
|
|
|
|
|
|
text-align: left;
|
|
|
|
|
|
margin-bottom: 15px;
|
|
|
|
|
|
color: #666;
|
|
|
|
|
|
}
|
2022-05-03 21:35:39 +08:00
|
|
|
|
</style>
|