diff --git a/src/apps/AppVillagersCircle/Reject.vue b/src/apps/AppVillagersCircle/Reject.vue index c05b83a9..63097ff8 100644 --- a/src/apps/AppVillagersCircle/Reject.vue +++ b/src/apps/AppVillagersCircle/Reject.vue @@ -18,30 +18,52 @@ export default { value: '', id: '', pass: '', + flag: '', // 0 驳回信息 1 驳回评论 }; }, onShow() { document.title = '村民圈审核' }, onLoad(o) { + console.log(o); this.id = o.id this.pass = o.pass + this.flag = o.flag }, methods: { submit() { - this.$http.post('/app/appvillagercircleinfo/examine',null, { - params: { - id: this.id, - pass: this.pass, - opinion: this.value - } - }).then(() => { - this.$u.toast('保存成功') - uni.$emit('update') - setTimeout(()=>{ - uni.navigateBack() + + if(this.flag == 0) { + this.$http.post('/app/appvillagercircleinfo/examine',null, { + params: { + id: this.id, + pass: this.pass, + opinion: this.value + } + }).then(() => { + this.$u.toast('保存成功') + uni.$emit('update') + setTimeout(()=>{ + uni.navigateBack({delta: 2}) + },600) }) - }) + } + if(this.flag == 1) { + this.$http.post('/app/appvillagercirclecomment/examine',null, { + params: { + id: this.id, + pass: this.pass, + opinion: this.value + } + }).then(() => { + this.$u.toast('保存成功') + uni.$emit('update') + setTimeout(()=>{ + uni.navigateBack({delta: 2}) + },600) + }) + } + } }, }; diff --git a/src/apps/AppVillagersCircle/commentDetail.vue b/src/apps/AppVillagersCircle/commentDetail.vue index dea3de2a..233f145a 100644 --- a/src/apps/AppVillagersCircle/commentDetail.vue +++ b/src/apps/AppVillagersCircle/commentDetail.vue @@ -5,35 +5,52 @@
-
- {{ data.createUserName }} +
+ {{ data.villagerCircleInfo.createUserName }}
- {{ $dict.getLabel('villagerCircleTopic',data.topic) }} - {{ data.createTime }} + {{ $dict.getLabel('villagerCircleTopic',data.villagerCircleInfo.topic) }} + {{ data.villagerCircleInfo.createTime }}
-
{{ data.content }}
-
- +
{{ data.villagerCircleInfo.content }}
+
+
-
+
- {{ data.gpsDesc }} + {{ data.villagerCircleInfo.gpsDesc }}
-
+
评论:
- 桃白白:为什么不带上我 + {{ data.replyUserName }}:{{ data.content }}
-
+ +
+
+
审核结果
+
通过
+
+
+
审核人
+
{{ data.auditUserName }}
+
+
+
审核时间
+
{{ data.auditTime }}
+
+
+ + +
审核结果
不通过
@@ -71,13 +88,13 @@ export default { status: 0, id: '', data: {}, + flag: 1 } }, onLoad(o) { this.$dict.load('villagerCircleTopic').then(()=>{ this.id = o.id this.getDetail() - // this.getComment() }) }, methods: { @@ -88,17 +105,18 @@ export default { }) }, getDetail() { - this.$http.post(`/app/appvillagercircleinfo/queryDetailById?id=${this.id}`).then(res => { - if(res.code==0){ + this.$http.post(`/app/appvillagercirclecomment/queryDetailById?id=${this.id}`).then(res => { + if(res?.data){ this.data = res.data + this.$forceUpdate() } }) }, toReject() { - uni.navigateTo({url: `./Reject?id=${this.data.id}&pass=0`}) + uni.navigateTo({url: `./Reject?id=${this.data.id}&pass=0&flag=1`}) }, agree() { - this.$http.post('/app/appvillagercircleinfo/examine',null, { + this.$http.post('/app/appvillagercirclecomment/examine',null, { params: { id: this.id, pass: 1, @@ -108,7 +126,7 @@ export default { uni.$emit('update') setTimeout(()=>{ uni.navigateBack() - }) + },600) }) } }, diff --git a/src/apps/AppVillagersCircle/commentList.vue b/src/apps/AppVillagersCircle/commentList.vue index 28f5e369..d0bcfed2 100644 --- a/src/apps/AppVillagersCircle/commentList.vue +++ b/src/apps/AppVillagersCircle/commentList.vue @@ -11,16 +11,18 @@
-
-
-
{{ item.content }}
+
+
+
{{ item.villagerCircleInfo.content }}
-
发布信息
-
{{$dict.getLabel('villagerCircleTopic',item.topic)}}
-
{{ item.createTime }}
+
{{$dict.getLabel('villagerCircleTopic',item.villagerCircleInfo.topic)}}
+
{{ item.villagerCircleInfo.createTime }}
-
{{$dict.getLabel('auditStatus',item.auditType)}}
+
+ {{ item.replyUserName}}:{{ item.content }} +
+
{{$dict.getLabel('auditStatus',item.status)}}
@@ -42,16 +44,20 @@ export default { showType: false, content: '', typeList: [], - villagerList: [], current: 1, topic: '', topicType: '', + data: {} } }, - onLoad() { + created() { + this.getList() this.$dict.load('villagerCircleTopic','auditStatus').then(()=>{ - this.current = 1 - this.getList() + this.$on('update',()=>{ + this.current = 1 + this.getList() + }) + }) }, methods: { @@ -60,26 +66,26 @@ export default { this.current = 1, this.topic = '', this.topicType = '', - this.villagerList = [], + this.data = [], this.getList() }, + getList() { - this.$http.post('app/appvillagercircleinfo/list',null,{ + this.$http.post('/app/appvillagercirclecomment/list?current=1&size=10',null,{ params: { current: 1, size: 10, - auditType: this.tabIndex == 0 ? '': this.tabIndex == 1 ? 0 : 1, - topic: this.topic, - content: this.content + auditType: this.tabIndex==0? '': this.tabIndex==1? 0 : 1 } }).then(res=>{ if(res?.data) { - this.villagerList = this.current >1 ? [...this.villagerList,...res.data.records] : res.data.records + this.data = this.current >1 ? [...this.data, ...this.res.data.records] : res.data.records } }) }, confirmTypeSelect(e) { + console.log(e); this.topic = e[0].value, this.topicType = e[0].label this.current = 1, @@ -88,11 +94,11 @@ export default { }, toDetail(item) { - uni.navigateTo({url: `./infoDetail?id=${item.id}`}) + uni.navigateTo({url: `./commentDetail?id=${item.id}`}) } }, onShow() { - document.title = '发布信息审核' + document.title = '发布评论审核' }, } @@ -186,22 +192,22 @@ export default { } .card-type { + display: flex; + justify-content: space-between; margin-top: 30px; font-size: 28px; - .num { - font-size: 34px; - color: #E6736E; + .comment { + width: 70%; + overflow:hidden; + text-overflow:ellipsis; + white-space:nowrap; } - .status0 { - color: #FF9B2B; + .type { + width: 20%; + text-align: right; } - - .status1 { - color: #4181FF; - } - } } } diff --git a/src/apps/AppVillagersCircle/infoDetail.vue b/src/apps/AppVillagersCircle/infoDetail.vue index 36a429b3..ca8544e5 100644 --- a/src/apps/AppVillagersCircle/infoDetail.vue +++ b/src/apps/AppVillagersCircle/infoDetail.vue @@ -24,14 +24,7 @@ {{ data.gpsDesc }}
- +
审核结果
@@ -70,6 +63,7 @@ export default { status: 0, id: '', data: {}, + flag: 0 } }, onLoad(o) { @@ -94,7 +88,7 @@ export default { }) }, toReject() { - uni.navigateTo({url: `./Reject?id=${this.data.id}&pass=0`}) + uni.navigateTo({url: `./Reject?id=${this.data.id}&pass=0&flag=0`}) }, agree() { this.$http.post('/app/appvillagercircleinfo/examine',null, { diff --git a/src/apps/AppVillagersCircle/infoList.vue b/src/apps/AppVillagersCircle/infoList.vue index d12f13a8..9cae8ab5 100644 --- a/src/apps/AppVillagersCircle/infoList.vue +++ b/src/apps/AppVillagersCircle/infoList.vue @@ -16,7 +16,6 @@
{{ item.content }}
-
{{$dict.getLabel('villagerCircleTopic',item.topic)}}
{{ item.createTime }}
@@ -69,7 +68,7 @@ export default { params: { current: 1, size: 10, - auditStatus: this.tabIndex == 0 ? '': this.tabIndex == 1 ? 0 : 1, + auditType: this.tabIndex == 0 ? '': this.tabIndex == 1 ? 0 : 1, topic: this.topic, content: this.content }