|
@@ -1,40 +1,54 @@
|
|
|
<template>
|
|
|
<div class="app-container">
|
|
|
<div class="filter-container">
|
|
|
- <span>机构名称:</span>
|
|
|
- <el-input v-model="listQuery.authParty" placeholder="授权机构" style="width: 280px;" class="filter-item" @keyup.enter.native="handleFilter" />
|
|
|
- <span>审核状态:</span>
|
|
|
- <el-select
|
|
|
- v-model="listQuery.auditStatus"
|
|
|
- placeholder="审核状态"
|
|
|
- clearable
|
|
|
- style="width: 200px"
|
|
|
- class="filter-item"
|
|
|
- @change="getList"
|
|
|
- >
|
|
|
- <el-option label="全部" value="" />
|
|
|
- <el-option label="待审核" :value="2" />
|
|
|
- <el-option label="审核通过" :value="1" />
|
|
|
- <el-option label="审核未通过" :value="0" />
|
|
|
- </el-select>
|
|
|
- <span>上线状态:</span>
|
|
|
- <el-select
|
|
|
- v-model="listQuery.status"
|
|
|
- placeholder="上线状态"
|
|
|
- clearable
|
|
|
- style="width: 200px"
|
|
|
- class="filter-item"
|
|
|
- @change="getList"
|
|
|
- >
|
|
|
- <el-option label="全部" value="" />
|
|
|
- <el-option label="已上线" :value="1" />
|
|
|
- <el-option label="待上线" :value="2" />
|
|
|
- <el-option label="未上线" :value="0" />
|
|
|
- </el-select>
|
|
|
- <el-button icon="el-icon-search" type="primary" @click="getList">查询</el-button>
|
|
|
- <!-- <el-button icon="el-icon-upload" type="primary" @click="improtDialogVisible = true">导入</el-button> -->
|
|
|
- <el-button icon="el-icon-document" type="primary" @click="handleExportExcel">导出</el-button>
|
|
|
- <!-- <el-button icon="el-icon-document-copy" type="primary" @click="downLoadExportExcel">获取导入模板</el-button> -->
|
|
|
+ <div class="filter-control">
|
|
|
+ <span>机构名称:</span>
|
|
|
+ <el-input
|
|
|
+ v-model="listQuery.authParty"
|
|
|
+ placeholder="授权机构"
|
|
|
+ style="width: 280px;"
|
|
|
+ class="filter-item"
|
|
|
+ @keyup.enter.native="handleFilter"
|
|
|
+ />
|
|
|
+ </div>
|
|
|
+ <div class="filter-control">
|
|
|
+ <span>审核状态:</span>
|
|
|
+ <el-select
|
|
|
+ v-model="listQuery.auditStatus"
|
|
|
+ placeholder="审核状态"
|
|
|
+ clearable
|
|
|
+ style="width: 200px"
|
|
|
+ class="filter-item"
|
|
|
+ @change="getList"
|
|
|
+ >
|
|
|
+ <el-option label="全部" value="" />
|
|
|
+ <el-option label="待审核" :value="2" />
|
|
|
+ <el-option label="审核通过" :value="1" />
|
|
|
+ <el-option label="审核未通过" :value="0" />
|
|
|
+ </el-select>
|
|
|
+ </div>
|
|
|
+ <div class="filter-control">
|
|
|
+ <span>上线状态:</span>
|
|
|
+ <el-select
|
|
|
+ v-model="listQuery.status"
|
|
|
+ placeholder="上线状态"
|
|
|
+ clearable
|
|
|
+ style="width: 200px"
|
|
|
+ class="filter-item"
|
|
|
+ @change="getList"
|
|
|
+ >
|
|
|
+ <el-option label="全部" value="" />
|
|
|
+ <el-option label="已上线" :value="1" />
|
|
|
+ <el-option label="待上线" :value="2" />
|
|
|
+ <el-option label="未上线" :value="0" />
|
|
|
+ </el-select>
|
|
|
+ </div>
|
|
|
+ <div class="filter-control">
|
|
|
+ <el-button icon="el-icon-search" type="primary" @click="getList">查询</el-button>
|
|
|
+ <!-- <el-button icon="el-icon-upload" type="primary" @click="improtDialogVisible = true">导入</el-button> -->
|
|
|
+ <el-button icon="el-icon-document" type="primary" @click="handleExportExcel">导出</el-button>
|
|
|
+ <!-- <el-button icon="el-icon-document-copy" type="primary" @click="downLoadExportExcel">获取导入模板</el-button> -->
|
|
|
+ </div>
|
|
|
</div>
|
|
|
<!-- 表格区域 -->
|
|
|
<el-table
|
|
@@ -58,13 +72,7 @@
|
|
|
<!-- 未通过原因展示 -->
|
|
|
<template v-if="row.auditStatus === 0">
|
|
|
<!-- <span class="status danger">审核未通过 </span> -->
|
|
|
- <el-popover
|
|
|
- placement="top-start"
|
|
|
- title="审核说明"
|
|
|
- width="400"
|
|
|
- trigger="hover"
|
|
|
- :content="row.invalidReason"
|
|
|
- >
|
|
|
+ <el-popover placement="top-start" title="审核说明" width="400" trigger="hover" :content="row.invalidReason">
|
|
|
<el-tag slot="reference" size="small" type="danger" class="reason">
|
|
|
<span>审核未通过</span>
|
|
|
<span class="el-icon-question status danger " />
|
|
@@ -76,7 +84,7 @@
|
|
|
</el-table-column>
|
|
|
|
|
|
<el-table-column label="上线状态" width="140px" align="center">
|
|
|
- <template slot-scope="{row}">
|
|
|
+ <template slot-scope="{ row }">
|
|
|
<!-- 只有审核通过了才能操作上下线 auditStatus :审核状态 -->
|
|
|
<template v-if="row.auditStatus === 1">
|
|
|
<template v-if="row.status === 0">
|
|
@@ -94,18 +102,26 @@
|
|
|
</el-table-column>
|
|
|
|
|
|
<el-table-column label="创建时间" class-name="status-col" width="360px">
|
|
|
- <template slot-scope="{row}">
|
|
|
+ <template slot-scope="{ row }">
|
|
|
<span>{{ row.createTime | formatTime }}</span>
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
|
|
|
<!-- <el-table-column label="创建人" class-name="status-col" width="160px" prop="createBy" /> -->
|
|
|
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
|
|
|
- <template slot-scope="{row}">
|
|
|
- <el-button type="primary" size="mini" @click="$_navigationTo(`club-detail?id=${row.authId}&authParty=${row.authParty}`)">
|
|
|
+ <template slot-scope="{ row }">
|
|
|
+ <el-button
|
|
|
+ type="primary"
|
|
|
+ size="mini"
|
|
|
+ @click="$_navigationTo(`club-detail?id=${row.authId}&authParty=${row.authParty}`)"
|
|
|
+ >
|
|
|
查看
|
|
|
</el-button>
|
|
|
- <el-button type="primary" size="mini" @click="$_navigationTo(`club-device-list?id=${row.authId}&authParty=${row.authParty}`)">
|
|
|
+ <el-button
|
|
|
+ type="primary"
|
|
|
+ size="mini"
|
|
|
+ @click="$_navigationTo(`club-device-list?id=${row.authId}&authParty=${row.authParty}`)"
|
|
|
+ >
|
|
|
查看设备认证
|
|
|
</el-button>
|
|
|
</template>
|
|
@@ -113,7 +129,13 @@
|
|
|
</el-table>
|
|
|
|
|
|
<!-- 页码 -->
|
|
|
- <pagination v-show="total>0" :total="total" :page.sync="listQuery.pageNum" :limit.sync="listQuery.pageSize" @pagination="getList" />
|
|
|
+ <pagination
|
|
|
+ v-show="total > 0"
|
|
|
+ :total="total"
|
|
|
+ :page.sync="listQuery.pageNum"
|
|
|
+ :limit.sync="listQuery.pageSize"
|
|
|
+ @pagination="getList"
|
|
|
+ />
|
|
|
</div>
|
|
|
</template>
|
|
|
|
|
@@ -161,7 +183,8 @@ export default {
|
|
|
fileUrl: [
|
|
|
{
|
|
|
required: true,
|
|
|
- message: '请选择文件', trigger: 'change'
|
|
|
+ message: '请选择文件',
|
|
|
+ trigger: 'change'
|
|
|
}
|
|
|
]
|
|
|
},
|
|
@@ -186,7 +209,9 @@ export default {
|
|
|
methods: {
|
|
|
// 下载模板
|
|
|
downLoadExportExcel() {
|
|
|
- downLoadWithATag(`${process.env.VUE_APP_BASE_API}/download/file?ossName=%E6%AD%A3%E5%93%81%E8%81%94%E7%9B%9F%E6%9C%BA%E6%9E%84%E3%80%81%E5%95%86%E5%93%81%E5%AF%BC%E5%85%A5%E6%A8%A1%E6%9D%BF.xlsx&fileName=%E6%AD%A3%E5%93%81%E8%81%94%E7%9B%9F%E6%9C%BA%E6%9E%84%E3%80%81%E5%95%86%E5%93%81%E5%AF%BC%E5%85%A5%E6%A8%A1%E6%9D%BF.xlsx`)
|
|
|
+ downLoadWithATag(
|
|
|
+ `${process.env.VUE_APP_BASE_API}/download/file?ossName=%E6%AD%A3%E5%93%81%E8%81%94%E7%9B%9F%E6%9C%BA%E6%9E%84%E3%80%81%E5%95%86%E5%93%81%E5%AF%BC%E5%85%A5%E6%A8%A1%E6%9D%BF.xlsx&fileName=%E6%AD%A3%E5%93%81%E8%81%94%E7%9B%9F%E6%9C%BA%E6%9E%84%E3%80%81%E5%95%86%E5%93%81%E5%AF%BC%E5%85%A5%E6%A8%A1%E6%9D%BF.xlsx`
|
|
|
+ )
|
|
|
},
|
|
|
|
|
|
// 导出为Excel
|
|
@@ -221,7 +246,9 @@ export default {
|
|
|
this.improtDialogVisible = false
|
|
|
this.getList()
|
|
|
})
|
|
|
- .catch(err => { console.log(err) })
|
|
|
+ .catch(err => {
|
|
|
+ console.log(err)
|
|
|
+ })
|
|
|
.finally(() => {
|
|
|
this.requestLoading = false
|
|
|
})
|
|
@@ -229,19 +256,22 @@ export default {
|
|
|
// 获取授权列表
|
|
|
getList() {
|
|
|
this.listLoading = true
|
|
|
- fecthAuthList(this.listQuery).then(response => {
|
|
|
- if (response.code !== 0) {
|
|
|
+ fecthAuthList(this.listQuery)
|
|
|
+ .then(response => {
|
|
|
+ if (response.code !== 0) {
|
|
|
+ return this.$message.error('授权列表信息获取失败')
|
|
|
+ }
|
|
|
+ const { list, total } = response.data
|
|
|
+ this.list = list
|
|
|
+ this.total = total
|
|
|
+ })
|
|
|
+ .catch(err => {
|
|
|
+ console.log(err)
|
|
|
return this.$message.error('授权列表信息获取失败')
|
|
|
- }
|
|
|
- const { list, total } = response.data
|
|
|
- this.list = list
|
|
|
- this.total = total
|
|
|
- }).catch(err => {
|
|
|
- console.log(err)
|
|
|
- return this.$message.error('授权列表信息获取失败')
|
|
|
- }).finally(() => {
|
|
|
- this.listLoading = false
|
|
|
- })
|
|
|
+ })
|
|
|
+ .finally(() => {
|
|
|
+ this.listLoading = false
|
|
|
+ })
|
|
|
},
|
|
|
// 过滤列表
|
|
|
handleFilter() {
|
|
@@ -257,21 +287,5 @@ export default {
|
|
|
</script>
|
|
|
|
|
|
<style lang="scss" scoped>
|
|
|
-.filter-container{
|
|
|
- span{
|
|
|
- display: inline-block;
|
|
|
- margin-bottom: 10px;
|
|
|
- vertical-align: middle;
|
|
|
- font-size: 14px;
|
|
|
- }
|
|
|
- .el-button{
|
|
|
- display: inline-block;
|
|
|
- margin-bottom: 10px;
|
|
|
- vertical-align: middle;
|
|
|
- }
|
|
|
- .el-input,.el-select{
|
|
|
- margin-right: 10px;
|
|
|
- margin-left: 10px;
|
|
|
- }
|
|
|
-}
|
|
|
+
|
|
|
</style>
|