cshenfu
2023-06-14 de93aa62c83d6afb9f70cd5a22838375db0a8cbc
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
<template>
    <view>
        <view v-if="content" style="padding: 30rpx;">
            <u-parse :content="content" :lazyLoad="true"></u-parse>
        </view>
    </view>
</template>
 
<script>
    export default {
        data() {
            return {
                content: "",
                title: ""
            }
        },
        onLoad(op) {
            if (op.content_id) {
                this.$request('/api/Content/detail', 'POST', {
                    content_id: op.content_id
                }).then(res => {
                    console.log(res)
                    this.content = res.data.content
                    if (res.data.title) {
                        this.title = res.data.title
                        uni.setNavigationBarTitle({
                            title: res.data.title
                        })
                    }
                })
            }
        },
        onShareAppMessage() {
            return {
                title: this.title
            }
        },
        methods: {
            
        }
    }
</script>
 
<style>
 
</style>