Files
dvcp_v2_wxcp_app/src/apps/AppUniMsg/Detail.vue

93 lines
1.6 KiB
Vue
Raw Normal View History

2021-12-21 19:13:37 +08:00
<template>
<div class="Detail">
<div class="header-top">
<div class="titles">{{ data.title }}</div>
<div class="titles-bottom">
<span>发布单位</span>
<span>{{ data.publishUnitName }}</span>
</div>
</div>
<div class="header-middle">
<span class="contsnts">{{ data.content }}</span>
<img :src="item.url" alt="" v-for="(item, i) in data.images" :key="i" />
</div>
</div>
</template>
<script>
export default {
name: 'Detail',
components: {},
props: {},
data() {
return {
data: [],
id: '',
}
},
computed: {},
watch: {},
onLoad(o) {
this.id = o.id
this.getDetail()
},
mounted() {},
methods: {
getDetail() {
this.$http.post(`/app/appmininotice/queryDetailById?id=${this.id}`).then((res) => {
if (res?.data) {
this.data = res.data
if (res.data.images) {
this.data.images = JSON.parse(res.data.images || '[]')
}
}
})
},
},
}
</script>
<style scoped lang="scss">
uni-page-body {
height: 100%;
}
.Detail {
height: 100%;
padding: 0 32px;
background: #fff;
.header-top {
padding: 40px 0 32px 0;
.titles {
font-size: 48px;
font-weight: 600;
}
.titles-bottom {
margin-top: 16px;
font-size: 30px;
color: #999999;
.to-left {
margin-left: 32px;
}
}
}
.header-middle {
padding: 32px 0;
.contsnts {
font-size: 36px;
line-height: 1.5;
word-break: break-all;
}
img {
margin-top: 30px;
width: 686px;
height: 486px;
}
}
}
</style>