You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
111 lines
2.5 KiB
111 lines
2.5 KiB
|
3 years ago
|
<template>
|
||
|
|
<div>
|
||
|
|
<!--查询-->
|
||
|
|
<div>
|
||
|
|
<div ref="lxHeader">
|
||
|
|
<lx-header icon="md-apps" style="margin-bottom: 10px; border: 0px; margin-top: 15px" text="客户列表">
|
||
|
|
<div slot="content"></div>
|
||
|
|
|
||
|
|
<slot>
|
||
|
|
<div>
|
||
|
|
<Input placeholder="关键字搜索" style="width: 200px; margin-right: 10px"/>
|
||
|
|
|
||
|
|
<Button style="margin-left: 10px" type="primary">查询</Button>
|
||
|
|
<Button style="margin-left: 10px" type="primary"
|
||
|
|
@click="$refs['addCustomer'].type = 'add',$refs['addCustomer'].isShow = true">录入客户
|
||
|
|
</Button>
|
||
|
|
</div>
|
||
|
|
</slot>
|
||
|
|
</lx-header>
|
||
|
|
</div>
|
||
|
|
</div>
|
||
|
|
|
||
|
|
<xy-table ref="table" :list="list" :table-item="tableItem" @editor="editor">
|
||
|
|
</xy-table>
|
||
|
|
|
||
|
|
<add-customer ref="addCustomer" :disability-level="disabilityLevel" @refresh="getCustomers"></add-customer>
|
||
|
|
</div>
|
||
|
|
</template>
|
||
|
|
|
||
|
|
<script>
|
||
|
|
import {getList} from '@/api/customer'
|
||
|
|
import {getparameter} from '@/api/system/dictionary'
|
||
|
|
|
||
|
|
import addCustomer from "@/views/customer/component/addCustomer";
|
||
|
|
|
||
|
|
export default {
|
||
|
|
components: {
|
||
|
|
addCustomer
|
||
|
|
},
|
||
|
|
data() {
|
||
|
|
return {
|
||
|
|
select: {
|
||
|
|
page: 1,
|
||
|
|
page_size: 10,
|
||
|
|
keyword: ''
|
||
|
|
},
|
||
|
|
disabilityLevel: [],
|
||
|
|
|
||
|
|
total: 0,
|
||
|
|
list: [],
|
||
|
|
tableItem: [
|
||
|
|
{
|
||
|
|
prop: "id",
|
||
|
|
label: "序号"
|
||
|
|
},
|
||
|
|
{
|
||
|
|
prop: "name",
|
||
|
|
label: "申请人",
|
||
|
|
minWidth: "180"
|
||
|
|
},
|
||
|
|
{
|
||
|
|
prop: "real_address",
|
||
|
|
label: "居住信息",
|
||
|
|
minWidth: "190"
|
||
|
|
},
|
||
|
|
{
|
||
|
|
prop: "insurance_count",
|
||
|
|
label: "其他信息",
|
||
|
|
width: "120"
|
||
|
|
},
|
||
|
|
{
|
||
|
|
label: "委托人信息",
|
||
|
|
width: "180"
|
||
|
|
},
|
||
|
|
{
|
||
|
|
label: "销售",
|
||
|
|
width: "140"
|
||
|
|
}
|
||
|
|
]
|
||
|
|
}
|
||
|
|
},
|
||
|
|
methods: {
|
||
|
|
async getDisabilityLevel() {
|
||
|
|
const res = await getparameter({number: 'disabilityLevel'})
|
||
|
|
this.disabilityLevel = res.detail
|
||
|
|
},
|
||
|
|
|
||
|
|
async getCustomers() {
|
||
|
|
const res = await getList(this.select)
|
||
|
|
this.list = res.data.data
|
||
|
|
this.total = res.data.total
|
||
|
|
},
|
||
|
|
|
||
|
|
editor(row){
|
||
|
|
this.$refs['addCustomer'].id = row.id
|
||
|
|
this.$refs['addCustomer'].type = 'editor'
|
||
|
|
this.$refs['addCustomer'].isShow = true
|
||
|
|
}
|
||
|
|
},
|
||
|
|
mounted() {
|
||
|
|
this.getDisabilityLevel()
|
||
|
|
this.getCustomers()
|
||
|
|
}
|
||
|
|
}
|
||
|
|
</script>
|
||
|
|
|
||
|
|
<style lang="scss" scoped>
|
||
|
|
|
||
|
|
</style>
|
||
|
|
|