|
@@ -69,14 +69,13 @@
|
|
|
|
|
|
<el-table-column label="操作" width="280px" align="center">
|
|
<el-table-column label="操作" width="280px" align="center">
|
|
<template slot-scope="{ row }">
|
|
<template slot-scope="{ row }">
|
|
- <audit-button-group type="audit" :is-dot="true" :margin-right="true" @click="onClick(row, $event)" />
|
|
|
|
- <!-- <el-button
|
|
|
|
- v-if="row.auditStatus !== 1"
|
|
|
|
- type="warning"
|
|
|
|
- size="mini"
|
|
|
|
- style="margin-right: 12px"
|
|
|
|
- @click="navigationTo(`/audit/club/club-detail?authId=${row.authId}`)"
|
|
|
|
- >审核</el-button> -->
|
|
|
|
|
|
+ <audit-button-group
|
|
|
|
+ :review="row.auditStatus !== 2"
|
|
|
|
+ :type="row.auditStatus === 1 ? 'result' : 'audit'"
|
|
|
|
+ :is-dot="row.checkFlag === 0"
|
|
|
|
+ :margin-right="true"
|
|
|
|
+ @click="onClick(row, $event)"
|
|
|
|
+ />
|
|
<el-badge :hidden="row.lowerAuditStatus === 1" :value="row.waitAuditNum" :max="99">
|
|
<el-badge :hidden="row.lowerAuditStatus === 1" :value="row.waitAuditNum" :max="99">
|
|
<el-button
|
|
<el-button
|
|
type="primary"
|
|
type="primary"
|
|
@@ -89,29 +88,24 @@
|
|
</el-table>
|
|
</el-table>
|
|
<!-- 表格区域END -->
|
|
<!-- 表格区域END -->
|
|
<!-- 页码 -->
|
|
<!-- 页码 -->
|
|
- <pagination :total="total" :page.sync="listQuery.pageNum" :limit.sync="listQuery.pageSize" @pagination="getList" />
|
|
|
|
|
|
+ <pagination
|
|
|
|
+ :total="total"
|
|
|
|
+ :page.sync="listQuery.pageNum"
|
|
|
|
+ :limit.sync="listQuery.pageSize"
|
|
|
|
+ @pagination="fecthAuthList"
|
|
|
|
+ />
|
|
<!-- 审核弹窗 -->
|
|
<!-- 审核弹窗 -->
|
|
- <el-dialog title="授权机构审核" :visible.sync="dialogVisible" width="450px" @close="dialogClosed">
|
|
|
|
|
|
+ <el-dialog title="驳回" :visible.sync="resultVisible" width="30%" @close="onDialogClose">
|
|
<div class="auth-info">
|
|
<div class="auth-info">
|
|
- <div class="auth-name">
|
|
|
|
- <i>授权机构:</i>
|
|
|
|
- <b>{{ dialogData.authParty }}</b>
|
|
|
|
- </div>
|
|
|
|
- <el-form ref="formRef" :model="dialogData" label-width="85px" :rules="dialogFormRules">
|
|
|
|
- <el-form-item label="审核状态:">
|
|
|
|
- <el-radio-group v-model="dialogData.auditStatus">
|
|
|
|
- <el-radio :label="1">通过</el-radio>
|
|
|
|
- <el-radio :label="0">不通过</el-radio>
|
|
|
|
- </el-radio-group>
|
|
|
|
- </el-form-item>
|
|
|
|
- <el-form-item v-if="dialogData.auditStatus === 0" label="原因:" prop="invalidReason">
|
|
|
|
- <el-input v-model="dialogData.invalidReason" type="textarea" placeholder="请说明原因" />
|
|
|
|
|
|
+ <el-form ref="formRef" :model="dialogData" label-width="80px" :rules="rules">
|
|
|
|
+ <el-form-item label="原因:" prop="invalidReason">
|
|
|
|
+ <el-input v-model="dialogData.invalidReason" type="textarea" rows="4" placeholder="请说明原因" />
|
|
</el-form-item>
|
|
</el-form-item>
|
|
</el-form>
|
|
</el-form>
|
|
</div>
|
|
</div>
|
|
<div slot="footer">
|
|
<div slot="footer">
|
|
- <el-button @click="dialogVisible = false">取 消</el-button>
|
|
|
|
- <el-button type="primary" @click="auditStatusHandle">确 定</el-button>
|
|
|
|
|
|
+ <el-button @click="resultVisible = false">取 消</el-button>
|
|
|
|
+ <el-button type="primary" @click="onSubmit">确 定</el-button>
|
|
</div>
|
|
</div>
|
|
</el-dialog>
|
|
</el-dialog>
|
|
</div>
|
|
</div>
|
|
@@ -119,12 +113,12 @@
|
|
|
|
|
|
<script>
|
|
<script>
|
|
import { fecthAuthList, auditAuth } from '@/api/auth'
|
|
import { fecthAuthList, auditAuth } from '@/api/auth'
|
|
-import { mapGetters, mapMutations } from 'vuex'
|
|
|
|
|
|
+import { mapGetters } from 'vuex'
|
|
export default {
|
|
export default {
|
|
data() {
|
|
data() {
|
|
return {
|
|
return {
|
|
// 是否显示dialog
|
|
// 是否显示dialog
|
|
- dialogVisible: false,
|
|
|
|
|
|
+ resultVisible: false,
|
|
listLoading: false,
|
|
listLoading: false,
|
|
// 查询参数
|
|
// 查询参数
|
|
listQuery: {
|
|
listQuery: {
|
|
@@ -138,18 +132,12 @@ export default {
|
|
},
|
|
},
|
|
total: 0,
|
|
total: 0,
|
|
dialogData: {
|
|
dialogData: {
|
|
- auditBy: '', // 审核人
|
|
|
|
authId: '', // 授权机构id
|
|
authId: '', // 授权机构id
|
|
- authParty: '', // 授权机构名称
|
|
|
|
- auditStatus: 1, // 审核状态
|
|
|
|
|
|
+ auditStatus: 0, // 审核状态
|
|
invalidReason: '' // 审核信息
|
|
invalidReason: '' // 审核信息
|
|
},
|
|
},
|
|
- dialogFormRules: {
|
|
|
|
- invalidReason: {
|
|
|
|
- required: true,
|
|
|
|
- message: '不通过原因不能为空',
|
|
|
|
- tigger: 'blur'
|
|
|
|
- }
|
|
|
|
|
|
+ rules: {
|
|
|
|
+ invalidReason: [{ required: true, message: '不通过原因不能为空', tigger: 'blur' }]
|
|
},
|
|
},
|
|
// 机构信息审核列表
|
|
// 机构信息审核列表
|
|
list: []
|
|
list: []
|
|
@@ -163,7 +151,26 @@ export default {
|
|
this.getList()
|
|
this.getList()
|
|
},
|
|
},
|
|
methods: {
|
|
methods: {
|
|
- ...mapMutations({ setMessageState: 'webSocket/SET_MESSAGE_STATE' }),
|
|
|
|
|
|
+ // 获取授权列表
|
|
|
|
+ async getList() {
|
|
|
|
+ this.listQuery.pageNum = 1
|
|
|
|
+ this.list = []
|
|
|
|
+ this.fecthAuthList()
|
|
|
|
+ },
|
|
|
|
+
|
|
|
|
+ async fecthAuthList() {
|
|
|
|
+ try {
|
|
|
|
+ this.listLoading = true
|
|
|
|
+ const res = await fecthAuthList(this.listQuery)
|
|
|
|
+ const { list, total } = res.data
|
|
|
|
+ this.list = list
|
|
|
|
+ this.total = total
|
|
|
|
+ } catch (error) {
|
|
|
|
+ console.log(error)
|
|
|
|
+ } finally {
|
|
|
|
+ this.listLoading = false
|
|
|
|
+ }
|
|
|
|
+ },
|
|
|
|
|
|
// 按钮组点击事件
|
|
// 按钮组点击事件
|
|
onClick(row, type) {
|
|
onClick(row, type) {
|
|
@@ -177,78 +184,47 @@ export default {
|
|
|
|
|
|
// 预览
|
|
// 预览
|
|
onReview(row) {
|
|
onReview(row) {
|
|
- console.log('预览')
|
|
|
|
this.$router.push(`/audit/club/club-detail?authId=${row.authId}&type=review`)
|
|
this.$router.push(`/audit/club/club-detail?authId=${row.authId}&type=review`)
|
|
},
|
|
},
|
|
// 驳回
|
|
// 驳回
|
|
onResult(row) {
|
|
onResult(row) {
|
|
- console.log('驳回')
|
|
|
|
|
|
+ this.resultVisible = true
|
|
|
|
+ this.dialogData.authId = row.authId
|
|
},
|
|
},
|
|
// 审核
|
|
// 审核
|
|
onAudit(row) {
|
|
onAudit(row) {
|
|
this.$router.push(`/audit/club/club-detail?authId=${row.authId}&type=audit`)
|
|
this.$router.push(`/audit/club/club-detail?authId=${row.authId}&type=audit`)
|
|
},
|
|
},
|
|
|
|
|
|
- // 获取授权列表
|
|
|
|
- getList() {
|
|
|
|
- this.listLoading = true
|
|
|
|
- fecthAuthList(this.listQuery)
|
|
|
|
- .then((response) => {
|
|
|
|
- if (response.code !== 0) return
|
|
|
|
- const { list, total } = response.data
|
|
|
|
- this.list = list
|
|
|
|
- this.total = total
|
|
|
|
- })
|
|
|
|
- .finally(() => {
|
|
|
|
- this.listLoading = false
|
|
|
|
- })
|
|
|
|
- },
|
|
|
|
// 审核
|
|
// 审核
|
|
- auditStatusHandle() {
|
|
|
|
- this.$refs.formRef.validate((valid) => {
|
|
|
|
- if (valid) {
|
|
|
|
- // 指定审核人
|
|
|
|
- this.dialogData.auditBy = this.authUserId
|
|
|
|
- // 提交审核信息
|
|
|
|
- auditAuth(this.dialogData)
|
|
|
|
- .then((res) => {
|
|
|
|
- if (res.code !== 0) return
|
|
|
|
- this.$message.success(res.data)
|
|
|
|
- this.setMessageState({ id: this.dialogData.authId, type: 1 })
|
|
|
|
- })
|
|
|
|
- .finally(() => {
|
|
|
|
- this.dialogVisible = false
|
|
|
|
- this.getList()
|
|
|
|
- })
|
|
|
|
- }
|
|
|
|
- })
|
|
|
|
|
|
+ async onSubmit() {
|
|
|
|
+ try {
|
|
|
|
+ await this.$refs.formRef.validate()
|
|
|
|
+ await this.onAuthResult()
|
|
|
|
+ } catch (error) {
|
|
|
|
+ console.log(error)
|
|
|
|
+ }
|
|
},
|
|
},
|
|
- // 审核对话框
|
|
|
|
- handleShowDialog(item) {
|
|
|
|
- console.log(item)
|
|
|
|
- this.dialogData.authParty = item.authParty
|
|
|
|
- this.dialogData.authId = item.authId
|
|
|
|
- this.dialogVisible = true
|
|
|
|
|
|
+
|
|
|
|
+ // 驳回
|
|
|
|
+ async onAuthResult() {
|
|
|
|
+ try {
|
|
|
|
+ await auditAuth(this.dialogData)
|
|
|
|
+ this.$message.success('驳回成功')
|
|
|
|
+ this.getList()
|
|
|
|
+ this.resultVisible = false
|
|
|
|
+ } catch (error) {
|
|
|
|
+ console.log(error)
|
|
|
|
+ }
|
|
},
|
|
},
|
|
- // 审核对话框关闭
|
|
|
|
- dialogClosed() {
|
|
|
|
- this.dialogData.authParty = ''
|
|
|
|
- this.dialogData.reviewStatus = 1
|
|
|
|
|
|
+
|
|
|
|
+ onDialogClose() {
|
|
|
|
+ this.$refs.formRef.resetFields()
|
|
},
|
|
},
|
|
|
|
+
|
|
indexMethod(index) {
|
|
indexMethod(index) {
|
|
return index + this.listQuery.pageSize * (this.listQuery.pageNum - 1) + 1
|
|
return index + this.listQuery.pageSize * (this.listQuery.pageNum - 1) + 1
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
</script>
|
|
</script>
|
|
-
|
|
|
|
-<style lang="scss" scoped>
|
|
|
|
-.auth-info {
|
|
|
|
- .auth-name {
|
|
|
|
- font-size: 16px;
|
|
|
|
- padding-bottom: 25px;
|
|
|
|
- border-bottom: 1px solid #ddd;
|
|
|
|
- margin-bottom: 25px;
|
|
|
|
- }
|
|
|
|
-}
|
|
|
|
-</style>
|
|
|