|
|
@@ -0,0 +1,262 @@ |
|
|
|
<template> |
|
|
|
<div> |
|
|
|
<crud-template ref="crudRef" class="as-weight" :homeData="field" :tableData="tableData" @btnSearch="btnSearch" |
|
|
|
@unitClick="unitClick" @handleEdit="handleEdit" @handleInfo="handleInfo" @cancel="cancel" |
|
|
|
@CurrentChange="handleCurrentChange" @refreshLeft="refreshLeft" @submit="submit"> |
|
|
|
<template #search> |
|
|
|
<el-input maxlength="60" v-trim clearable v-model="searchForm.customerId" style="width: 200px" |
|
|
|
placeholder="请输入用户编号"/> |
|
|
|
<el-input maxlength="60" v-trim clearable v-model="searchForm.customerName" style="width: 200px" |
|
|
|
placeholder="请输入用户名称"/> |
|
|
|
<el-select clearable v-model="searchForm.customerIdType" style="width: 200px;" placeholder="请选择用户证件号类型"> |
|
|
|
<el-option v-for="item in CERTIFICATE_TYPE" :key="item.value" :label="item.label" :value="item.value"/> |
|
|
|
</el-select> |
|
|
|
<el-input maxlength="60" v-trim clearable v-model="searchForm.customerIdNum" style="width: 200px" |
|
|
|
placeholder="请输入用户证件号码"/> |
|
|
|
<el-input maxlength="60" v-trim clearable v-model="searchForm.customerTel" style="width: 200px" |
|
|
|
placeholder="请输入用户手机号"/> |
|
|
|
</template> |
|
|
|
|
|
|
|
<template #operation="{ scope }"> |
|
|
|
<el-button type="success" size="small" class="code-btn" @click="showInfo(scope.row)">详情</el-button> |
|
|
|
<el-button v-if="scope.row.auditStatus !== 'COMPLETE'" type="primary" size="small" class="code-btn" @click="audit(scope.row)">审核</el-button> |
|
|
|
</template> |
|
|
|
|
|
|
|
</crud-template> |
|
|
|
|
|
|
|
</div> |
|
|
|
</template> |
|
|
|
<!-- 用户信息修改审核 --> |
|
|
|
<script setup lang="ts"> |
|
|
|
import {ref, toRaw, onMounted, computed, reactive, onUnmounted} from "vue"; |
|
|
|
// @ts-ignore crudFrom模板 |
|
|
|
import CrudTemplate from "@/crud/index.vue"; |
|
|
|
import $storeinitData from "@/store/initData"; //引入tab vuex |
|
|
|
import BaseService from "@/utils/baseService"; //引入接口请求 |
|
|
|
import {ElMessage} from "element-plus"; //提示 |
|
|
|
import {useRoute} from 'vue-router'; |
|
|
|
import {IsPermission} from "@/router/routerUtil"; |
|
|
|
import {dataDesensitization, changeAddress} from "@/utils/utils"; |
|
|
|
//或取路由传入过来的对象数据 |
|
|
|
const route = useRoute(); |
|
|
|
|
|
|
|
const crudRef = ref(); |
|
|
|
//启用状态 |
|
|
|
const VEHICLE_COLOR_TYPE = computed(() => { |
|
|
|
return $storeinitData.state.dictData["VEHICLE_COLOR_TYPE"] || []; |
|
|
|
}); |
|
|
|
|
|
|
|
//用户证件类型 |
|
|
|
const CERTIFICATE_TYPE = computed(() => { |
|
|
|
return $storeinitData.state.dictData["ID_TYPE"] || []; |
|
|
|
}); |
|
|
|
|
|
|
|
//审核状态 |
|
|
|
const AUDIT_STATUS = computed(() => { |
|
|
|
return $storeinitData.state.dictData["AUDIT_STATUS"] || []; |
|
|
|
}); |
|
|
|
|
|
|
|
//用户类型 |
|
|
|
const USER_TYPE = computed(() => { |
|
|
|
return $storeinitData.state.dictData["ETC_USER_TYPE"] || []; |
|
|
|
}); |
|
|
|
|
|
|
|
//查询参数 |
|
|
|
const searchForm = ref({ |
|
|
|
customerId: '', // 用户编号 |
|
|
|
customerName: '', // 用户名称 |
|
|
|
customerIdType: '', // 用户证件号类型 |
|
|
|
customerIdNum: '', // 用户证件号码 |
|
|
|
customerTel: '', // 用户手机号 |
|
|
|
}); |
|
|
|
|
|
|
|
let tableData: any = ref([]); |
|
|
|
const typeOption = ref(""); |
|
|
|
|
|
|
|
onMounted(() => { |
|
|
|
getList(); |
|
|
|
}); |
|
|
|
|
|
|
|
// 搜索按钮 |
|
|
|
function btnSearch() { |
|
|
|
field.value.paging.currentPage = 1; |
|
|
|
getList(); |
|
|
|
} |
|
|
|
|
|
|
|
const userType = ref() // 用户类型 1个人 2单位 |
|
|
|
|
|
|
|
// 编辑按钮 |
|
|
|
function handleEdit(idx: any, row: any) { |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
// 取消 |
|
|
|
function cancel() { |
|
|
|
crudRef.value.reset(); |
|
|
|
} |
|
|
|
|
|
|
|
//分页 |
|
|
|
function handleCurrentChange(val: number) { |
|
|
|
field.value.paging.currentPage = val; |
|
|
|
getList(); |
|
|
|
} |
|
|
|
|
|
|
|
// 搜索重置 |
|
|
|
function refreshLeft() { |
|
|
|
searchForm.value = { |
|
|
|
customerId: '', |
|
|
|
customerName: '', |
|
|
|
customerIdType: '', |
|
|
|
customerIdNum: '', |
|
|
|
customerTel: '', |
|
|
|
}; |
|
|
|
field.value.paging.currentPage = 1; |
|
|
|
getList(); |
|
|
|
} |
|
|
|
|
|
|
|
// 详情 |
|
|
|
function handleInfo(idx: any, row: any) { |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
//编辑与添加提交 |
|
|
|
function submit(data: any) { |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
//获取列表 |
|
|
|
function getList() { |
|
|
|
let falg = false |
|
|
|
let params: any = { |
|
|
|
pageNo: field.value.paging.currentPage, |
|
|
|
pageSize: field.value.paging.pageSize, |
|
|
|
} |
|
|
|
let searchFormList = {...searchForm.value}; |
|
|
|
for (let key in searchFormList) { |
|
|
|
if (searchFormList[key]) { |
|
|
|
falg = true |
|
|
|
params[key] = searchFormList[key]; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
crudRef.value.tableLoding = true; |
|
|
|
BaseService.postN('/managew/CustomerInfoChange/page', params).then((res: any) => { |
|
|
|
if (res && res.statusCode === 0) { |
|
|
|
//数据转换 |
|
|
|
let bizContent = res |
|
|
|
let data = bizContent.data.result || []; |
|
|
|
//数据渲染 |
|
|
|
tableData.value = data; |
|
|
|
crudRef.value.tableLoding = false; |
|
|
|
field.value.paging.total = bizContent.data.totalCount; |
|
|
|
} |
|
|
|
}).catch((error) => { |
|
|
|
crudRef.value.tableLoding = false; |
|
|
|
}); |
|
|
|
} |
|
|
|
|
|
|
|
function getLabel(item, selectedValue) { |
|
|
|
let data = item; |
|
|
|
let selectedLabel = "未知"; |
|
|
|
for (var i = 0; i < data.length; i++) { |
|
|
|
if (data[i].code == selectedValue) { |
|
|
|
selectedLabel = data[i].name; |
|
|
|
break; |
|
|
|
} |
|
|
|
} |
|
|
|
return selectedLabel; |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
let formLabelWidth = "180px"; |
|
|
|
|
|
|
|
//表单数据配置 |
|
|
|
let field: any = ref({ |
|
|
|
dialogInfo: false, //是否展示详情 (默认false) |
|
|
|
dialogCustom: true, |
|
|
|
border: true, //是否添加边框(默认false) |
|
|
|
searchShow: IsPermission(route, 'QUERY_BASE'), //搜索展示 |
|
|
|
crudChildShow: true, |
|
|
|
operateFixed: true, |
|
|
|
paginStart: true, //是否显示分页查询 (默认false) |
|
|
|
dialogWidth: "60%", |
|
|
|
operateWidth: "130", //操作栏宽度 |
|
|
|
operateTitle: '操作', //操作栏标题(默认为"") |
|
|
|
crud: { |
|
|
|
add: false, |
|
|
|
}, |
|
|
|
operate: { |
|
|
|
info: false, |
|
|
|
edit: false, |
|
|
|
delete: false, //是否删除(默认true) |
|
|
|
remark: false, // 查看 |
|
|
|
announcement: false, // 公告 |
|
|
|
forbidden: false, // 禁用 |
|
|
|
enable: false, // 启用 |
|
|
|
authorization: false, // 授权 |
|
|
|
cancel: false, // 取消订单 |
|
|
|
}, |
|
|
|
tableSize: -1, |
|
|
|
paging: { |
|
|
|
pageSize: 10, |
|
|
|
currentPage: 1, |
|
|
|
total: 0, |
|
|
|
}, |
|
|
|
extend: [ |
|
|
|
{ |
|
|
|
label: "序号", |
|
|
|
type: "index", |
|
|
|
width: "50px", |
|
|
|
}, |
|
|
|
], |
|
|
|
field: [ |
|
|
|
{ |
|
|
|
prop: "customerName", |
|
|
|
label: "用户名称", |
|
|
|
}, |
|
|
|
{ |
|
|
|
width: '150', |
|
|
|
prop: "customerId", |
|
|
|
label: "用户编号", |
|
|
|
}, |
|
|
|
{ |
|
|
|
width: '100', |
|
|
|
prop: "customerTel", |
|
|
|
label: "手机号", |
|
|
|
}, |
|
|
|
{ |
|
|
|
width: '150', |
|
|
|
prop: "customerIdNum", |
|
|
|
label: "证件号码", |
|
|
|
}, |
|
|
|
{ |
|
|
|
width: '100', |
|
|
|
prop: "orderType", |
|
|
|
label: "业务类型", |
|
|
|
}, |
|
|
|
{ |
|
|
|
width: '140', |
|
|
|
prop: "applyTime", |
|
|
|
label: "申请时间", |
|
|
|
}, |
|
|
|
{ |
|
|
|
prop: "auditStatus", |
|
|
|
label: "审核状态", |
|
|
|
listData: AUDIT_STATUS, |
|
|
|
}, |
|
|
|
{ |
|
|
|
width: '80', |
|
|
|
prop: "auditName", |
|
|
|
label: "审核人", |
|
|
|
}, |
|
|
|
{ |
|
|
|
width: '140', |
|
|
|
prop: "auditTime", |
|
|
|
label: "审核时间", |
|
|
|
}, |
|
|
|
], |
|
|
|
}); |
|
|
|
</script> |
|
|
|
<style scoped> |
|
|
|
|
|
|
|
</style> |