linwe
2024-08-08 3c738f4fe2762bba8087e5a22fc0dc06560eab0e
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
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
<template>
    <view class="">
        <z-paging ref="paging" v-model="list" @query="queryList" :refresher-enabled="false"
            loading-more-no-more-text="没有更多了">
            <view class="list" v-for="(i,k) in list">
                <view class="f-24 c-99 mb-20">
                    {{i.createTime}}
                </view>
                <view class="f-28 mb-20">
                    {{i.content}}
                </view>
                <view class="list-box f-28" v-if="i.title" @click="navTo(i.articleId)">
                    {{i.title}}
                </view>
            </view>
        </z-paging>
    </view>
</template>
 
<script>
    import {
        getTenementComment
    } from "@/api/grid/grid.js"
    import {
        getCommentList
    } from '@/api/article/article.js'
    export default {
        data() {
            return {
                tabList: [
 
                    {
                        name: "物业公司"
                    },
                    {
                        name: "通知公告"
                    },
                ],
                tabIndex: 0,
                list: []
            }
        },
 
        methods: {
            queryList(pageNo, pageSize) {
                getCommentList({
                    page: pageNo,
                    size: pageSize
                }).then(res => {
                    this.$refs.paging.complete(res.data.records);
                })
            },
 
            navTo(id) {
                uni.navigateTo({
                    url: `/subPackage/article/detail?id=${id}`
                })
            },
 
        }
    }
</script>
 
<style lang="scss">
    page {
        background-color: #f5f5f5;
    }
 
    .list {
        padding: 20rpx;
        margin: 20rpx;
        border-radius: 12rpx;
        background-color: #fff;
 
        .list-box {
            padding: 20rpx;
            background-color: #f5f5f5;
            border-radius: 6rpx;
        }
    }
</style>