Browse Source

bug修改

master
王金鹏 6 years ago
parent
commit
dd49e64f1d
  1. 4
      src/views/modules/group/group-approve.vue
  2. 30
      src/views/modules/group/group-detail.vue
  3. 23
      src/views/modules/group/group.vue

4
src/views/modules/group/group-approve.vue

@ -51,10 +51,10 @@ export default {
processingOpinions: ''
},
options: [{
value: '5',
value: '10',
label: '审核通过'
}, {
value: '10',
value: '5',
label: '审核拒绝'
}]
}

30
src/views/modules/group/group-detail.vue

@ -2,13 +2,17 @@
<el-dialog :visible.sync="visible" :title="$t('look')" :close-on-click-modal="false" :close-on-press-escape="false">
<el-form :label-width="$i18n.locale === 'en-US' ? '100px' : '80px'">
<el-form-item label="群介绍:">
<div>{{dataForm.groupIntroduction}}</div>
<div>{{responseForm.groupIntroduction}}</div>
</el-form-item>
<el-form-item label="状态:">
<div>{{dataForm.state}}</div>
<div v-if="responseForm.state === 0">待审核</div>
<div v-if="responseForm.state === 5">审核不通过</div>
<div v-if="responseForm.state === 10">审核通过</div>
<div v-if="responseForm.state === 15">禁言</div>
<div v-if="responseForm.state === 20">已解散</div>
</el-form-item>
<el-form-item label="备注:">
<div>{{dataForm.processingOpinions}}</div>
<el-form-item label="备注:" v-if="responseForm.state === 5 || responseForm.state === 20">
<div>{{responseForm.processingOpinions}}</div>
</el-form-item>
</el-form>
<el-form :inline="true" :model="dataForm" ref="dataForm">
@ -55,9 +59,15 @@ export default {
},
visible: false,
dataForm: {
groupId: '',
nickname: '',
mobile: ''
},
responseForm: {
id: '',
mobile: '',
nickname: ''
groupIntroduction: '',
state: '',
processingOpinions: ''
}
}
},
@ -66,7 +76,7 @@ export default {
this.visible = true
this.$nextTick(() => {
this.$refs['dataForm'].resetFields()
if (this.dataForm.id) {
if (this.dataForm.groupId) {
this.getInfo()
this.getDataList()
}
@ -74,12 +84,12 @@ export default {
},
//
getInfo () {
this.$http.get(`/group/group/${this.dataForm.id}`).then(({ data: res }) => {
this.$http.get(`/group/group/${this.dataForm.groupId}`).then(({ data: res }) => {
if (res.code !== 0) {
return this.$message.error(res.msg)
}
this.dataForm = {
...this.dataForm,
this.responseForm = {
...this.responseForm,
...res.data
}
}).catch(() => {})

23
src/views/modules/group/group.vue

@ -165,14 +165,11 @@ export default {
if (res.code !== 0) {
return this.$message.error(res.msg)
}
this.getDataList()
this.$message({
message: this.$t('prompt.success'),
type: 'success',
duration: 500,
onClose: () => {
this.visible = false
this.$emit('refreshDataList')
}
duration: 500
})
}).catch(() => {})
},
@ -184,14 +181,11 @@ export default {
if (res.code !== 0) {
return this.$message.error(res.msg)
}
this.getDataList()
this.$message({
message: this.$t('prompt.success'),
type: 'success',
duration: 500,
onClose: () => {
this.visible = false
this.$emit('refreshDataList')
}
duration: 500
})
}).catch(() => {})
},
@ -203,21 +197,18 @@ export default {
if (res.code !== 0) {
return this.$message.error(res.msg)
}
this.getDataList()
this.$message({
message: this.$t('prompt.success'),
type: 'success',
duration: 500,
onClose: () => {
this.visible = false
this.$emit('refreshDataList')
}
duration: 500
})
}).catch(() => {})
},
look (id) {
this.groupDetailVisible = true
this.$nextTick(() => {
this.$refs.groupDetail.dataForm.id = id
this.$refs.groupDetail.dataForm.groupId = id
this.$refs.groupDetail.init()
})
},

Loading…
Cancel
Save