商户审核

This commit is contained in:
1154079537 2024-05-06 14:50:19 +08:00
parent 5ffd91762a
commit 4e05aac46e

View File

@ -4,29 +4,32 @@
<el-form :model="tableFrom" ref="searchForm" size="small" label-width="85px" :inline="true">
<el-form-item label="状态:" prop="status">
<el-select v-model="tableFrom.status" clearable placeholder="请选择" class="selWidth" @change="getList(1)">
<el-option label="全部" value="" />
<el-option label="待审核" value="0" />
<el-option label="审核通过" value="1" />
<el-option label="审核未通过" value="-1" />
<el-option label="全部" value=""/>
<el-option label="待审核" value="0"/>
<el-option label="审核通过" value="1"/>
<el-option label="审核未通过" value="-1"/>
</el-select>
</el-form-item>
<el-form-item label="选择时间:">
<el-date-picker v-model="timeVal" type="daterange" placeholder="选择日期" format="yyyy/MM/dd"
value-format="yyyy/MM/dd" :picker-options="pickerOptions" @change="onchangeTime" style="width: 280px" />
value-format="yyyy/MM/dd" :picker-options="pickerOptions" @change="onchangeTime"
style="width: 280px"/>
</el-form-item>
<el-form-item label="商户分类:" prop="category_id">
<el-select v-model="tableFrom.category_id" clearable placeholder="请选择" class="selWidth" @change="getList(1)">
<el-option v-for="item in merCateList" :key="item.value" :label="item.label" :value="item.value" />
<el-select v-model="tableFrom.category_id" clearable placeholder="请选择" class="selWidth"
@change="getList(1)">
<el-option v-for="item in merCateList" :key="item.value" :label="item.label" :value="item.value"/>
</el-select>
</el-form-item>
<el-form-item label="店铺类型:" prop="type_id">
<el-select v-model="tableFrom.type_id" clearable placeholder="请选择" class="selWidth" @change="getList(1)">
<el-option v-for="item in storeType" :key="item.value" :label="item.label" :value="item.value" />
<el-option v-for="item in storeType" :key="item.value" :label="item.label" :value="item.value"/>
</el-select>
</el-form-item>
<el-form-item label="关键字:" prop="keyword">
<el-input v-model="tableFrom.keyword" @keyup.enter.native="getList(1)" placeholder="请输入商户名称关键字/联系电话"
class="selWidth" clearable />
<el-input v-model="tableFrom.keyword" @keyup.enter.native="getList(1)"
placeholder="请输入商户名称关键字/联系电话"
class="selWidth" clearable/>
</el-form-item>
<el-form-item>
<el-button type="primary" size="small" @click="getList(1)">搜索</el-button>
@ -36,18 +39,18 @@
</div>
<el-card class="mt14">
<el-table v-loading="listLoading" :data="tableData.data" size="small" highlight-current-row class="switchTable">
<el-table-column prop="mer_intention_id" label="ID" min-width="60" />
<el-table-column prop="mer_name" label="商户名称" min-width="150" />
<el-table-column prop="category_name" label="商户分类" min-width="150" />
<el-table-column prop="type_name" label="店铺类型" min-width="150" />
<el-table-column prop="name" label="商户姓名" min-width="100" />
<el-table-column prop="phone" label="联系方式" min-width="100" />
<el-table-column prop="create_time" label="申请时间" min-width="150" />
<el-table-column prop="mer_intention_id" label="ID" min-width="60"/>
<el-table-column prop="mer_name" label="商户名称" min-width="150"/>
<el-table-column prop="category_name" label="商户分类" min-width="150"/>
<el-table-column prop="type_name" label="店铺类型" min-width="150"/>
<el-table-column prop="name" label="商户姓名" min-width="100"/>
<el-table-column prop="phone" label="联系方式" min-width="100"/>
<el-table-column prop="create_time" label="申请时间" min-width="150"/>
<el-table-column prop="create_time" label="资质图片" min-width="150">
<template slot-scope="scope">
<div class="demo-image__preview">
<el-image v-for="(item, index) in scope.row.images" :key="index" :src="item" class="mr5"
:preview-src-list="[item]" />
:preview-src-list="[item]"/>
</div>
</template>
</el-table-column>
@ -59,11 +62,12 @@
<div v-if="scope.row.status == 2">原因{{ scope.row.fail_msg }}</div>
</template>
</el-table-column>
<el-table-column prop="mark" label="备注" min-width="150" />
<el-table-column prop="mark" label="备注" min-width="150"/>
<el-table-column label="操作" min-width="170" fixed="right" align="center">
<template slot-scope="scope">
<el-button v-if="scope.row.status == 0" type="text" size="small"
@click="onchangeIsShow(scope.row)">审核</el-button>
@click="onchangeIsShow(scope.row)">审核
</el-button>
<el-button type="text" size="small" @click="onEdit(scope.row.mer_intention_id)">备注</el-button>
<el-button type="text" size="small" @click="handleView(scope.row)">查看</el-button>
<el-button type="text" size="small" @click="handleDelete(scope.row.mer_intention_id)">删除</el-button>
@ -72,20 +76,21 @@
</el-table>
<div class="block">
<el-pagination background :page-size="tableFrom.limit" :current-page="tableFrom.page"
layout="total, prev, pager, next, jumper" :total="tableData.total" @size-change="handleSizeChange"
@current-change="pageChange" />
layout="total, prev, pager, next, jumper" :total="tableData.total"
@size-change="handleSizeChange"
@current-change="pageChange"/>
</div>
</el-card>
<!-- 审核状态 -->
<el-dialog title="修改审核状态" :visible.sync="statusAuditVisible" width="60%">
<el-form ref="statusAuditForm" :model="statusAuditForm" label-width="120px" @submit.native.prevent>
<el-form ref="statusAuditForm" :model="statusAuditForm" label-width="120px">
<el-row>
<el-col :span="12">
<el-form-item label="审核状态:">
<el-select v-model="statusAuditForm.state" placeholder="请选择审核状态" @change="statusChange">
<el-option label="同意" :value="1"> </el-option>
<el-option label="拒绝" :value="2"> </el-option>
<el-option label="同意" :value="1"></el-option>
<el-option label="拒绝" :value="2"></el-option>
</el-select>
</el-form-item>
</el-col>
@ -99,8 +104,8 @@
</el-col>
<el-col :span="24" v-if="statusAuditForm.state == 2">
<el-form-item label="拒绝原因:" prop="fail_msg">
<el-input type="textarea" :rows="2" placeholder="请输入拒绝原因" v-model="statusAuditForm.fail_msg">
<el-form-item label="拒绝原因:">
<el-input type="textarea" :rows="3" placeholder="请输入拒绝原因" v-model="statusAuditForm.fail_msg">
</el-input>
</el-form-item>
</el-col>
@ -108,67 +113,67 @@
<el-row>
<el-col :span="12">
<el-form-item label="申请类型:">
<el-input readony :value="statusAuditForm.type == 1 ? '商户入驻申请' : '商户开通交易申请'" />
<el-input readony :value="statusAuditForm.type == 1 ? '商户入驻申请' : '商户开通交易申请'"/>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="商户名称:">
<el-input readony :value="statusAuditForm.mer_name" />
<el-input readony :value="statusAuditForm.mer_name"/>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="商户分类:">
<el-input readony :value="statusAuditForm.category_name" />
<el-input readony :value="statusAuditForm.category_name"/>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="店铺类型:">
<el-input readony :value="statusAuditForm.type_name" />
<el-input readony :value="statusAuditForm.type_name"/>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="商户姓名:">
<el-input readony :value="statusAuditForm.name" />
<el-input readony :value="statusAuditForm.name"/>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="联系方式:">
<el-input readony :value="statusAuditForm.phone" />
<el-input readony :value="statusAuditForm.phone"/>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="申请时间:">
<el-input readony :value="statusAuditForm.create_time" />
<el-input readony :value="statusAuditForm.create_time"/>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="法人姓名:">
<el-input readony :value="statusAuditForm.name" />
<el-input readony :value="statusAuditForm.name"/>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="社会代码:">
<el-input readony :value="statusAuditForm.social_credit_code" />
<el-input readony :value="statusAuditForm.social_credit_code"/>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="公司名称:">
<el-input readony :value="statusAuditForm.company_name" />
<el-input readony :value="statusAuditForm.company_name"/>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="公司性质:">
<el-input readony :value="statusAuditForm.is_company == 1 ? '对公户' : '个体户'" />
<el-input readony :value="statusAuditForm.is_company == 1 ? '对公户' : '个体户'"/>
</el-form-item>
</el-col>
@ -176,15 +181,15 @@
<el-form-item label="资质:">
<div class="demo-image__preview">
<el-image style="width: 80px;height: 60px;margin-right: 10px;"
v-for="(ii, index) in statusAuditForm.images" :key="index" :src="ii" class="preview"
:preview-src-list="[ii]" />
v-for="(ii, index) in statusAuditForm.images" :key="index" :src="ii" class="preview"
:preview-src-list="[ii]"/>
</div>
</el-form-item>
</el-col>
<el-col :span="24">
<el-form-item label="备注:">
<el-input v-mode ="statusAuditForm.mark" />
<el-input v-model="statusAuditForm.mark" placeholder="请输入备注"/>
</el-form-item>
</el-col>
</el-row>
@ -200,67 +205,67 @@
<el-row>
<el-col :span="12">
<el-form-item label="申请类型:">
<el-input readony :value="statusAuditForm.type == 1 ? '商户入驻申请' : '商户开通交易申请'" />
<el-input readony :value="statusAuditForm.type == 1 ? '商户入驻申请' : '商户开通交易申请'"/>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="商户名称:">
<el-input readony :value="statusAuditForm.mer_name" />
<el-input readony :value="statusAuditForm.mer_name"/>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="商户分类:">
<el-input readony :value="statusAuditForm.category_name" />
<el-input readony :value="statusAuditForm.category_name"/>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="店铺类型:">
<el-input readony :value="statusAuditForm.type_name" />
<el-input readony :value="statusAuditForm.type_name"/>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="商户姓名:">
<el-input readony :value="statusAuditForm.name" />
<el-input readony :value="statusAuditForm.name"/>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="联系方式:">
<el-input readony :value="statusAuditForm.phone" />
<el-input readony :value="statusAuditForm.phone"/>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="申请时间:">
<el-input readony :value="statusAuditForm.create_time" />
<el-input readony :value="statusAuditForm.create_time"/>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="法人姓名:">
<el-input readony :value="statusAuditForm.name" />
<el-input readony :value="statusAuditForm.name"/>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="社会代码:">
<el-input readony :value="statusAuditForm.social_credit_code" />
<el-input readony :value="statusAuditForm.social_credit_code"/>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="公司名称:">
<el-input readony :value="statusAuditForm.company_name" />
<el-input readony :value="statusAuditForm.company_name"/>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="公司性质:">
<el-input readony :value="statusAuditForm.is_company == 1 ? '对公户' : '个体户'" />
<el-input readony :value="statusAuditForm.is_company == 1 ? '对公户' : '个体户'"/>
</el-form-item>
</el-col>
@ -268,15 +273,15 @@
<el-form-item label="资质:">
<div class="demo-image__preview">
<el-image style="width: 80px;height: 60px;margin-right: 10px;"
v-for="(ii, index) in statusAuditForm.images" :key="index" :src="ii" class="preview"
:preview-src-list="[ii]" />
v-for="(ii, index) in statusAuditForm.images" :key="index" :src="ii" class="preview"
:preview-src-list="[ii]"/>
</div>
</el-form-item>
</el-col>
<el-col :span="24">
<el-form-item label="备注:">
<el-input readony :value="statusAuditForm.mark" />
<el-input readony :value="statusAuditForm.mark"/>
</el-form-item>
</el-col>
</el-row>
@ -285,7 +290,6 @@
<el-button type="primary" plain class="submission" size="small" @click="formShow = false">关闭</el-button>
</div>
</el-dialog>
</div>
</template>
@ -308,9 +312,10 @@ import {
getMerCateApi,
updateStatus
} from "@/api/merchant";
import { fromList, statusList } from "@/libs/constants.js";
import { roterPre } from "@/settings";
import {fromList, statusList} from "@/libs/constants.js";
import {roterPre} from "@/settings";
import timeOptions from '@/utils/timeOptions';
export default {
name: "MerchantApplication",
data() {
@ -384,11 +389,7 @@ export default {
this.$refs.searchForm.resetFields()
this.getList(1)
},
// statusChange(tab) {
// this.tableFrom.status = tab;
// this.tableFrom.page = 1;
// this.getList("");
// },
//
onchangeTime(e) {
this.timeVal = e;
@ -396,6 +397,7 @@ export default {
this.tableFrom.page = 1;
this.getList("");
},
//
getMerCategory() {
getMerCateApi().then(res => {
@ -404,6 +406,7 @@ export default {
this.$message.error(res.message)
})
},
/**获取店铺类型 */
getStoreType() {
getstoreTypeApi().then(res => {
@ -412,25 +415,26 @@ export default {
this.$message.error(res.message)
})
},
//
getList(num) {
this.listLoading = true;
this.tableFrom.page = num ? num : this.tableFrom.page;
intentionLstApi(this.tableFrom)
.then((res) => {
this.tableData.data = res.data.list;
this.tableData.total = res.data.count;
this.listLoading = false;
})
.catch((res) => {
this.listLoading = false;
this.$message.error(res.message);
});
intentionLstApi(this.tableFrom).then((res) => {
this.tableData.data = res.data.list;
this.tableData.total = res.data.count;
this.listLoading = false;
}).catch((res) => {
this.listLoading = false;
this.$message.error(res.message);
});
},
pageChange(page) {
this.tableFrom.page = page;
this.getList("");
},
handleSizeChange(val) {
this.tableFrom.limit = val;
this.getList(1);
@ -439,13 +443,12 @@ export default {
//
onchangeIsShow(item) {
this.statusAuditVisible = true;
this.statusAuditForm = Object.assign(this.statusAuditForm,item)
this.statusAuditForm = JSON.parse(JSON.stringify(item));
this.$set(this.statusAuditForm, 'state', 1);
this.$set(this.statusAuditForm, 'create_mer', 1);
this.$set(this.statusAuditForm, 'mark', '');
},
//
//
handleSubmit() {
if (this.statusAuditForm.state == 2 && !this.statusAuditForm.fail_msg) {
@ -455,12 +458,13 @@ export default {
updateStatus(this.statusAuditForm.mer_intention_id, {
status: this.statusAuditForm.state,
create_mer: this.statusAuditForm.create_mer,
fail_msg: this.statusAuditForm.fail_msg
fail_msg: this.statusAuditForm.fail_msg,
mark: this.statusAuditForm.mark
}).then(res => {
this.statusAuditVisible = false;
this.$message.success(res.message);
this.getList("");
}).catch(({ message }) => {
}).catch(({message}) => {
this.$message.error(message);
});
},
@ -480,17 +484,15 @@ export default {
//
handleDelete(id) {
this.$deleteSure().then(() => {
intentionDelte(id)
.then(({ message }) => {
this.$message.success(message);
this.getList("");
})
.catch(({ message }) => {
this.$message.error(message);
});
intentionDelte(id).then(({message}) => {
this.$message.success(message);
this.getList("");
}).catch(({message}) => {
this.$message.error(message);
});
});
},
},
}
}
};
</script>