村民圈
This commit is contained in:
@@ -6,20 +6,20 @@
|
||||
|
||||
<div class="middle">
|
||||
<div class="cardTop">
|
||||
<img :src="avatarUrl" alt="" />
|
||||
<img :src="avatarUrl || user.avatarUrl" alt="" />
|
||||
|
||||
<div class="rightTop">
|
||||
<div class="leftStaus">
|
||||
<span class="names">{{ detail.createUserName }}</span>
|
||||
|
||||
<span class="titless">{{ $dict.getLabel('villagerCircleTopic', detail.topic) }} | {{ detail.status }}</span>
|
||||
<span class="titless">{{ $dict.getLabel('villagerCircleTopic', detail.topic) }} | {{ detail.createTime }}</span>
|
||||
</div>
|
||||
|
||||
<div class="statusDele">
|
||||
<div class="status status0" :class="detail.auditStatus == 0 ? 'status0' : detail.auditStatus == 1 ? 'status1' : 'status2'">{{ $dict.getLabel('auditStatus', detail.status) }}</div>
|
||||
|
||||
<div class="dels" @click.stop=";(modalShow = true), (deleId = detail.id)">删除</div>
|
||||
<!-- <img src="https://cdn.cunwuyun.cn/dvcp/AppVillager4.png" alt="" @click.stop="delShow = true" class="dels" /> -->
|
||||
<!-- <img src="https://cdn.cunwuyun.cn/dvcp/AppVillager/4.png" alt="" @click.stop="delShow = true" class="dels" /> -->
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -38,30 +38,28 @@
|
||||
|
||||
<div class="icones">
|
||||
<div class="img1">
|
||||
<img src="https://cdn.cunwuyun.cn/dvcp/AppVillager1.png" alt="" class="img11" />
|
||||
<img src="https://cdn.cunwuyun.cn/dvcp/AppVillager/1.png" alt="" class="img11" />
|
||||
</div>
|
||||
|
||||
<div class="rightFlex">
|
||||
<img src="https://cdn.cunwuyun.cn/dvcp/AppVillager2.png" alt="" class="img2" @click="poupShow = true" />
|
||||
<img src="https://cdn.cunwuyun.cn/dvcp/AppVillager3.png" alt="" class="img3" @click="like" />
|
||||
<img src="https://cdn.cunwuyun.cn/dvcp/AppVillager/2.png" alt="" class="img2" @click="poupShow = true" />
|
||||
<img src="https://cdn.cunwuyun.cn/dvcp/AppVillager/3.png" alt="" class="img3" @click="like" />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="reply">
|
||||
<div class="replyTop" @click="deleShowBtn(item)">
|
||||
<img src="https://cdn.cunwuyun.cn/dvcp/AppVillager3.png" alt="" />
|
||||
<span class="people">张三、李四、陶白白等12人</span>
|
||||
<img src="https://cdn.cunwuyun.cn/dvcp/AppVillager/3.png" alt="" />
|
||||
<span class="people">
|
||||
<span v-for="(items, index) in detail.comments || detail.villagerCircleInfo.comments" :key="index" v-if="index < 3">{{ items.replyUserName }}</span>
|
||||
等{{ detail.villagerCircleInfo ? detail.villagerCircleInfo.comments.length : detail.comments.length }}人</span
|
||||
>
|
||||
</div>
|
||||
|
||||
<div class="replyCont" @click="deleShowBtn(item)">
|
||||
<span class="nameLeft">张三:</span>
|
||||
<span class="contRight">非常不错!</span>
|
||||
</div>
|
||||
|
||||
<div class="replyCont" @click="deleShowBtn(item)">
|
||||
<span class="nameLeft">张三:</span>
|
||||
<span class="contRight">为什么不带上我呢!为什么不带上我呢!为什么不带上我呢!</span>
|
||||
<div class="replyCont" @click="deleShowBtn(item)" v-for="(item, i) in detail.comments || detail.villagerCircleInfo.comments" :key="i">
|
||||
<span class="nameLeft">{{ item.replyUserName }} : </span>
|
||||
<span class="contRight"> {{ item.content }}</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -101,7 +99,7 @@ export default {
|
||||
return {
|
||||
id: '',
|
||||
avatarUrl: '',
|
||||
data: {},
|
||||
detail: {},
|
||||
poupShow: false,
|
||||
content: '',
|
||||
flag: false,
|
||||
@@ -109,34 +107,35 @@ export default {
|
||||
deleShow: false,
|
||||
modalShow: false,
|
||||
deleId: '',
|
||||
flagLike: false,
|
||||
tabCurrent1: '',
|
||||
}
|
||||
},
|
||||
computed: { ...mapState(['user']) },
|
||||
watch: {},
|
||||
onLoad(o) {
|
||||
this.$dict.load('villagerCircleTopic').then(() => {
|
||||
console.log(o)
|
||||
this.id = o.id
|
||||
this.avatarUrl = o.avatarUrl
|
||||
this.tabCurrent1 = o.tabCurrent1
|
||||
this.getDetail()
|
||||
})
|
||||
},
|
||||
onShow() {},
|
||||
methods: {
|
||||
getDetail() {
|
||||
this.$instance.post(`/app/appvillagercircleinfo/queryDetailById?id=${this.id}`).then((res) => {
|
||||
if (res.code == 0) {
|
||||
this.detail = res.data
|
||||
this.getReplyList()
|
||||
}
|
||||
})
|
||||
},
|
||||
|
||||
getReplyList() {
|
||||
this.$instance.post(`/app/appvillagercirclecomment/list?id=${detail.id}&size=999`).then((res) => {
|
||||
if (res.code == 0) {
|
||||
this.replylist = res.data.records
|
||||
}
|
||||
})
|
||||
this.$instance
|
||||
.post(this.tabCurrent1 == 0 ? '/app/appvillagercircleinfo/queryDetailById' : '/app/appvillagercirclecomment/queryDetailById', null, {
|
||||
params: {
|
||||
id: this.id,
|
||||
},
|
||||
})
|
||||
.then((res) => {
|
||||
if (res.code == 0) {
|
||||
this.detail = res.data
|
||||
}
|
||||
})
|
||||
},
|
||||
|
||||
send() {
|
||||
@@ -151,7 +150,7 @@ export default {
|
||||
replyUserResidentId: this.user.id,
|
||||
replyUserName: this.user.name,
|
||||
areaId: this.$areaId,
|
||||
id: '888',
|
||||
vcId: this.detail.id,
|
||||
})
|
||||
.then((res) => {
|
||||
if (res?.code == 0) {
|
||||
@@ -159,24 +158,30 @@ export default {
|
||||
this.flag = false
|
||||
this.content = ''
|
||||
this.poupShow = false
|
||||
// this.getDetail()
|
||||
this.getDetail()
|
||||
}
|
||||
})
|
||||
},
|
||||
|
||||
like() {
|
||||
var id = '88'
|
||||
if (this.flagLike) return
|
||||
|
||||
this.flagLike = true
|
||||
this.$instance
|
||||
.post(`/app/appvillagediscussmessage/suport?id=${id}&userId=${this.user.id}`)
|
||||
.post(`/app/appvillagercircleinfo/up?id=${this.detail.id}&userId=${this.user.id}`)
|
||||
.then((res) => {
|
||||
this.$hideLoading()
|
||||
if (res.code === 0) {
|
||||
this.$u.toast('点赞成功')
|
||||
this.$u.toast(detail.upFlag == 0 ? '点赞成功' : '取消点赞成功')
|
||||
this.getDetail()
|
||||
setTimeout(() => {
|
||||
this.flagLike = false
|
||||
}, 600)
|
||||
}
|
||||
})
|
||||
.catch((err) => {
|
||||
this.$u.toast(err)
|
||||
this.flagLike = false
|
||||
})
|
||||
},
|
||||
|
||||
@@ -235,10 +240,9 @@ export default {
|
||||
}
|
||||
|
||||
.middle {
|
||||
padding-bottom: 48px;
|
||||
padding: 32px 0 48px 0;
|
||||
.cardTop {
|
||||
display: flex;
|
||||
margin-top: 32px;
|
||||
img {
|
||||
width: 96px;
|
||||
height: 96px;
|
||||
@@ -282,7 +286,7 @@ export default {
|
||||
.dels {
|
||||
margin-left: 20px;
|
||||
width: 68px;
|
||||
height: 68px;
|
||||
// height: 68px;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -363,6 +367,7 @@ export default {
|
||||
font-weight: 500;
|
||||
.nameLeft {
|
||||
color: #485d87;
|
||||
margin-right: 12px;
|
||||
}
|
||||
.contRight {
|
||||
color: #485d87;
|
||||
|
||||
Reference in New Issue
Block a user