Browse Source

家访准备管理

zhanglei
yunuo970428 2 years ago
parent
commit
12a3271592
  1. 20
      anrui-riskcenter-ui/src/api/homevisitpreparation/homevisitpreparation.js
  2. 16
      anrui-riskcenter-ui/src/router/index.js
  3. 335
      anrui-riskcenter-ui/src/views/homevisitpreparation/homevisittobeprepared.vue
  4. 283
      anrui-riskcenter-ui/src/views/homevisitpreparation/thehomevisitisready.vue

20
anrui-riskcenter-ui/src/api/homevisitpreparation/homevisitpreparation.js

@ -0,0 +1,20 @@
import request from '@/utils/request'
export default {
// 查询分页列表
listPage: function(params) {
return request({
url: '/riskcenter/v1/loanhomevisitprep/listPage',
method: 'post',
data: params,
headers: { 'Content-Type': 'application/json' }
})
},
visit: function(data) {
return request({
url: '/riskcenter/v1/loanhomevisitprep/visit',
method: 'get',
params: data
})
}
}

16
anrui-riskcenter-ui/src/router/index.js

@ -187,6 +187,22 @@ export const constantRoutes = [
}
]
},
{
path: '/homevisitpreparation',
component: Layout,
redirect: '/homevisitpreparation',
meta: {
title: '家访准备管理'
},
children: [
{
path: '/homevisitpreparation/homevisittobeprepared',
component: () => import('@/views/homevisitpreparation/homevisittobeprepared.vue'),
name: 'HomeVisitToBePrepared',
meta: { title: '家访准备管理', noCache: true }
}
]
},
// 流程审批
// 金融产品政策报备--编辑

335
anrui-riskcenter-ui/src/views/homevisitpreparation/homevisittobeprepared.vue

@ -0,0 +1,335 @@
<template>
<div class="app-container">
<!-- Start 列表页面 -->
<div v-show="viewState == 1">
<button-bar view-title="家访准备管理" ref="btnbar" :btndisabled="btndisabled" @btnhandle="btnHandle"/>
<div class="main-content">
<div class="switch_btn">
<el-button :class="{btn_style:viewState === 1}">待准备</el-button>
<el-button class="" @click="handleClick">已准备</el-button>
</div>
<div class="searchcon">
<el-button size="small" class="searchbtn" @click="clicksearchShow">{{ searchxianshitit }}</el-button>
<div v-show="isSearchShow" class="search">
<el-form ref="listQueryform" :inline="true" :model="listQuery" class="tab-header">
<el-form-item label="分公司">
<el-input v-model="listQuery.params.useOrgName" clearable placeholder="" class="addinputw"></el-input>
</el-form-item>
<el-form-item label="销售部门">
<el-input v-model="listQuery.params.saleDeptName" clearable placeholder="" class="addinputw"></el-input>
</el-form-item>
<el-form-item label="销售专员">
<el-input v-model="listQuery.params.staffName" clearable placeholder="" class="addinputw"></el-input>
</el-form-item>
<el-form-item label="订单日期">
<el-date-picker v-model="listQuery.params.orderStartDate" type="date" clearable value-format="yyyy-MM-dd" placeholder="选择日期"/>
<span style="padding: 0 8px"></span>
<el-date-picker v-model="listQuery.params.orderEndDate" type="date" clearable value-format="yyyy-MM-dd" placeholder="选择日期"/>
</el-form-item>
<el-form-item label="买卖合同编号">
<el-input v-model="listQuery.params.contractNo" clearable placeholder="" class="addinputw"></el-input>
</el-form-item>
<el-form-item label="贷款人">
<el-input v-model="listQuery.params.loanPeoName" clearable placeholder="" class="addinputw"></el-input>
</el-form-item>
<el-form-item label="资方">
<el-input v-model="listQuery.params.capitalName" clearable placeholder="" class="addinputw"></el-input>
</el-form-item>
<el-form-item label="金融产品">
<el-input v-model="listQuery.params.policyName" clearable placeholder="" class="addinputw"></el-input>
</el-form-item>
</el-form>
<div class="btn" style="text-align: center;">
<el-button type="primary" icon="el-icon-search" @click="handleFilter" size="small">查询</el-button>
<el-button type="primary" icon="el-icon-refresh" @click="handleReset" size="small">重置</el-button>
</div>
</div>
</div>
<div class="listtop">
<div class="tit">待家访准备列表</div>
<pageye v-show="list.length > 0" :total="listQuery.total" :page.sync="listQuery.current" :limit.sync="listQuery.size" class="pagination" @pagination="getList"/>
</div>
<div class="">
<el-table :key="tableKey" v-loading="listLoading" :data="list" border style="width: 100%;" @selection-change="handleSelectionChange">
<el-table-column fixed width="50" type="selection" align="center"/>
<el-table-column fixed width="60" label="序号" type="index" :index="indexMethod" align="center"/>
<el-table-column label="操作" align="center" width="100">
<template slot-scope="scope">
<el-button type="primary" size="mini" @click="handleLook(scope.row)">查看订单</el-button>
</template>
</el-table-column>
<el-table-column label="订单日期" align="center" width="120">
<template slot-scope="scope">
<span>{{ scope.row.createDate }}</span>
</template>
</el-table-column>
<el-table-column label="分公司" align="center" width="120">
<template slot-scope="scope">
<span>{{ scope.row.useOrgName }}</span>
</template>
</el-table-column>
<el-table-column label="销售部门" align="center" width="150">
<template slot-scope="scope">
<span>{{ scope.row.orgName }}</span>
</template>
</el-table-column>
<el-table-column label="销售专员" align="center" width="120">
<template slot-scope="scope">
<span>{{ scope.row.staffName }}</span>
</template>
</el-table-column>
<el-table-column label="买卖合同编号" align="center" min-width="120">
<template slot-scope="scope">
<span>{{ scope.row.contractNo }}</span>
</template>
</el-table-column>
<el-table-column label="台数" align="center" width="80">
<template slot-scope="scope">
<span>{{ scope.row.vehCount }}</span>
</template>
</el-table-column>
<el-table-column label="贷款人" align="center" width="100">
<template slot-scope="scope">
<span>{{ scope.row.borrowerName }}</span>
</template>
</el-table-column>
<el-table-column label="手机号码" align="center" width="100">
<template slot-scope="scope">
<span>{{ scope.row.mobile }}</span>
</template>
</el-table-column>
<el-table-column label="资方" align="center" width="100">
<template slot-scope="scope">
<span>{{ scope.row.bankName }}</span>
</template>
</el-table-column>
<el-table-column label="金融产品" align="center" width="100">
<template slot-scope="scope">
<span>{{ scope.row.policyName }}</span>
</template>
</el-table-column>
<el-table-column label="合同" align="center" width="80">
<template slot-scope="scope">
<span class="bluezi">下载</span>
</template>
</el-table-column>
</el-table>
</div>
<div class="pages">
<!-- 翻页 -->
<pagination v-show="list.length > 0" :total="listQuery.total" :page.sync="listQuery.current" :limit.sync="listQuery.size" class="pagination" @pagination="getList"/>
</div>
</div>
</div>
<!-- End 列表页面 -->
<!-- 已选择列表 -->
<thehomevisitisready v-show="viewState == 2" ref="divSelect" @doback="resetState"/>
<!-- 查看销售订单 -->
<saleOrder v-show="viewState == 3" ref="divSale" @doback="resetState"/>
</div>
</template>
<script>
import req from '@/api/homevisitpreparation/homevisitpreparation'
import Pagination from '@/components/pagination'
import pageye from '@/components/pagination/pageye'
import ButtonBar from '@/components/ButtonBar'
import thehomevisitisready from './thehomevisitisready'
import saleOrder from '@/components/publicPage/salesOrder'
export default {
name: 'HomeVisitToBePrepared',
components: {
Pagination,
pageye,
ButtonBar,
thehomevisitisready,
saleOrder
},
data() {
return {
viewState: 1,
btndisabled: false,
btnList: [
{
type: 'primary',
size: 'small',
icon: '',
btnKey: 'tobeSelect',
btnLabel: '准备完毕'
},
{
type: 'primary',
size: 'small',
icon: '',
btnKey: 'toContract',
btnLabel: '生成合同'
},
{
type: 'info',
size: 'small',
icon: 'cross',
btnKey: 'doClose',
btnLabel: '关闭'
}
],
isSearchShow: false,
searchxianshitit: '显示查询条件',
// -----------
tableKey: 0,
list: [],
sids: [],
listLoading: false,
listQuery: {
params: {
capitalName: '',
contractNo: '',
loanPeoName: '',
menuUrl: '',
orderEndDate: '',
orderStartDate: '',
orgSidPath: '',
policyName: '',
saleDeptName: '',
staffName: '',
type: '1',
useOrgName: '',
userSid: ''
},
current: 1,
size: 10,
total: 0
},
rules: {}
}
},
created() {
//
this.getList()
},
mounted() {
this.$refs['btnbar'].setButtonList(this.btnList)
},
methods: {
//
clicksearchShow() {
this.isSearchShow = !this.isSearchShow
if (this.isSearchShow) {
this.searchxianshitit = '隐藏查询条件'
} else {
this.searchxianshitit = '显示查询条件'
}
},
btnHandle(btnKey) {
console.log('XXXXXXXXXXXXXXX ' + btnKey)
switch (btnKey) {
case 'tobeSelect':
this.tobeSelect()
break
case 'toContract':
this.toContract()
break
case 'doClose':
this.doClose()
break
default:
break
}
},
//
indexMethod(index) {
var pagestart = (this.listQuery.current - 1) * this.listQuery.size
var pageindex = index + 1 + pagestart
return pageindex
},
handleSelectionChange(row) {
const aa = []
row.forEach((element) => {
aa.push(element.sid)
})
this.sids = aa
},
//
getList() {
this.listLoading = true
this.listQuery.params.orgPath = window.sessionStorage.getItem('defaultOrgPath')
this.listQuery.params.menuUrl = this.$route.path
this.listQuery.params.userSid = window.sessionStorage.getItem('userSid')
req.listPage(this.listQuery).then((response) => {
this.listLoading = false
if (response.success) {
this.list = response.data.records
this.listQuery.total = response.data.total
} else {
this.list = []
this.listQuery.total = 0
}
})
},
tobeSelect() {
if (this.sids.length === 1) {
req.visit({ sid: this.sids[0] }).then((resp) => {
if (resp.success) {
this.$message({ showClose: true, type: 'success', message: '操作成功' })
this.getList()
}
})
} else {
this.$message({ showClose: true, type: 'error', message: '请选择一条记录进行操作' })
return
}
},
toContract() {},
handleLook(row) {
this.viewState = 3
this.$refs['divSale'].showInfo(row.saleOrderSid)
},
handleClick() {
this.viewState = 2
this.$refs['divSelect'].getList()
},
//
handleFilter() {
this.listQuery.current = 1
this.getList()
},
handleReset() {
this.listQuery = {
params: {
capitalName: '',
contractNo: '',
loanPeoName: '',
menuUrl: '',
orderEndDate: '',
orderStartDate: '',
orgSidPath: '',
policyName: '',
saleDeptName: '',
staffName: '',
type: '1',
useOrgName: '',
userSid: ''
},
current: 1,
size: 10,
total: 0
}
this.getList()
},
resetState() {
this.viewState = 1
},
doClose() {
this.$store.dispatch('tagsView/delView', this.$route)
this.$router.go(-1)
}
}
}
</script>
<style scoped>
.btn_style {
background-color: #018ad2;
color: white;
font-weight: 600;
}
</style>

283
anrui-riskcenter-ui/src/views/homevisitpreparation/thehomevisitisready.vue

@ -0,0 +1,283 @@
<template>
<div class="app-container">
<!-- Start 列表页面 -->
<div v-show="viewState == 1">
<button-bar view-title="家访准备管理" ref="btnbar" :btndisabled="btndisabled" @btnhandle="btnHandle"/>
<div class="main-content">
<div class="switch_btn">
<el-button class="" @click="handleClick">待准备</el-button>
<el-button :class="{btn_style:viewState === 1}">已准备</el-button>
</div>
<div class="searchcon">
<el-button size="small" class="searchbtn" @click="clicksearchShow">{{ searchxianshitit }}</el-button>
<div v-show="isSearchShow" class="search">
<el-form ref="listQueryform" :inline="true" :model="listQuery" class="tab-header">
<el-form-item label="分公司">
<el-input v-model="listQuery.params.useOrgName" clearable placeholder="" class="addinputw"></el-input>
</el-form-item>
<el-form-item label="销售部门">
<el-input v-model="listQuery.params.saleDeptName" clearable placeholder="" class="addinputw"></el-input>
</el-form-item>
<el-form-item label="销售专员">
<el-input v-model="listQuery.params.staffName" clearable placeholder="" class="addinputw"></el-input>
</el-form-item>
<el-form-item label="订单日期">
<el-date-picker v-model="listQuery.params.orderStartDate" type="date" clearable value-format="yyyy-MM-dd" placeholder="选择日期"/>
<span style="padding: 0 8px"></span>
<el-date-picker v-model="listQuery.params.orderEndDate" type="date" clearable value-format="yyyy-MM-dd" placeholder="选择日期"/>
</el-form-item>
<el-form-item label="买卖合同编号">
<el-input v-model="listQuery.params.contractNo" clearable placeholder="" class="addinputw"></el-input>
</el-form-item>
<el-form-item label="贷款人">
<el-input v-model="listQuery.params.loanPeoName" clearable placeholder="" class="addinputw"></el-input>
</el-form-item>
<el-form-item label="资方">
<el-input v-model="listQuery.params.capitalName" clearable placeholder="" class="addinputw"></el-input>
</el-form-item>
<el-form-item label="金融产品">
<el-input v-model="listQuery.params.policyName" clearable placeholder="" class="addinputw"></el-input>
</el-form-item>
</el-form>
<div class="btn" style="text-align: center;">
<el-button type="primary" icon="el-icon-search" @click="handleFilter" size="small">查询</el-button>
<el-button type="primary" icon="el-icon-refresh" @click="handleReset" size="small">重置</el-button>
</div>
</div>
</div>
<div class="listtop">
<div class="tit">已准备完成列表</div>
<pageye v-show="list.length > 0" :total="listQuery.total" :page.sync="listQuery.current" :limit.sync="listQuery.size" class="pagination" @pagination="getList"/>
</div>
<div class="">
<el-table :key="tableKey" v-loading="listLoading" :data="list" border style="width: 100%;">
<el-table-column width="60" label="序号" type="index" :index="indexMethod" align="center"/>
<el-table-column label="操作" align="center" width="180">
<template slot-scope="scope">
<el-button type="primary" size="mini">下载合同</el-button>
<el-button type="primary" size="mini" @click="lookSale(scope.row)">查看订单</el-button>
</template>
</el-table-column>
<el-table-column label="订单日期" align="center" width="120">
<template slot-scope="scope">
<span>{{ scope.row.createDate }}</span>
</template>
</el-table-column>
<el-table-column label="分公司" align="center" width="120">
<template slot-scope="scope">
<span>{{ scope.row.useOrgName }}</span>
</template>
</el-table-column>
<el-table-column label="销售部门" align="center" width="150">
<template slot-scope="scope">
<span>{{ scope.row.orgName }}</span>
</template>
</el-table-column>
<el-table-column label="销售专员" align="center" width="120">
<template slot-scope="scope">
<span>{{ scope.row.staffName }}</span>
</template>
</el-table-column>
<el-table-column label="买卖合同编号" align="center" min-width="120">
<template slot-scope="scope">
<span>{{ scope.row.contractNo }}</span>
</template>
</el-table-column>
<el-table-column label="台数" align="center" width="80">
<template slot-scope="scope">
<span>{{ scope.row.vehCount }}</span>
</template>
</el-table-column>
<el-table-column label="贷款人" align="center" width="100">
<template slot-scope="scope">
<span>{{ scope.row.borrowerName }}</span>
</template>
</el-table-column>
<el-table-column label="手机号码" align="center" width="100">
<template slot-scope="scope">
<span>{{ scope.row.mobile }}</span>
</template>
</el-table-column>
<el-table-column label="资方" align="center" width="100">
<template slot-scope="scope">
<span>{{ scope.row.bankName }}</span>
</template>
</el-table-column>
<el-table-column label="金融产品" align="center" width="100">
<template slot-scope="scope">
<span>{{ scope.row.policyName }}</span>
</template>
</el-table-column>
</el-table>
</div>
<div class="pages">
<!-- 翻页 -->
<pagination v-show="list.length > 0" :total="listQuery.total" :page.sync="listQuery.current" :limit.sync="listQuery.size" class="pagination" @pagination="getList"/>
</div>
</div>
</div>
<!-- End 列表页面 -->
<!-- 查看销售订单 -->
<salesOrder v-show="viewState == 2" ref="divSale" @doback="resetState"/>
</div>
</template>
<script>
import req from '@/api/homevisitpreparation/homevisitpreparation'
import Pagination from '@/components/pagination'
import pageye from '@/components/pagination/pageye'
import ButtonBar from '@/components/ButtonBar'
import salesOrder from '@/components/publicPage/salesOrder'
export default {
name: 'TheHomeVisitIsReady',
components: {
Pagination,
pageye,
ButtonBar,
salesOrder
},
data() {
return {
viewState: 1,
btndisabled: false,
btnList: [
{
type: 'info',
size: 'small',
icon: 'cross',
btnKey: 'doClose',
btnLabel: '关闭'
}
],
isSearchShow: false,
searchxianshitit: '显示查询条件',
// -----------
tableKey: 0,
list: [],
listLoading: false,
listQuery: {
params: {
capitalName: '',
contractNo: '',
loanPeoName: '',
menuUrl: '',
orderEndDate: '',
orderStartDate: '',
orgSidPath: '',
policyName: '',
saleDeptName: '',
staffName: '',
type: '2',
useOrgName: '',
userSid: ''
},
current: 1,
size: 10,
total: 0
},
rules: {}
}
},
mounted() {
this.$refs['btnbar'].setButtonList(this.btnList)
},
methods: {
//
clicksearchShow() {
this.isSearchShow = !this.isSearchShow
if (this.isSearchShow) {
this.searchxianshitit = '隐藏查询条件'
} else {
this.searchxianshitit = '显示查询条件'
}
},
btnHandle(btnKey) {
console.log('XXXXXXXXXXXXXXX ' + btnKey)
switch (btnKey) {
case 'tobeSelect':
this.tobeSelect()
break
case 'doClose':
this.doClose()
break
default:
break
}
},
//
indexMethod(index) {
var pagestart = (this.listQuery.current - 1) * this.listQuery.size
var pageindex = index + 1 + pagestart
return pageindex
},
//
getList() {
this.listLoading = true
this.listQuery.params.orgPath = window.sessionStorage.getItem('defaultOrgPath')
this.listQuery.params.menuUrl = this.$route.path
this.listQuery.params.userSid = window.sessionStorage.getItem('userSid')
req.listPage(this.listQuery).then((response) => {
console.log('列表查询结果:', response)
this.listLoading = false
if (response.success) {
this.list = response.data.records
this.listQuery.total = response.data.total
} else {
this.list = []
this.listQuery.total = 0
}
})
},
handleClick() {
this.$parent.resetState()
},
//
handleFilter() {
this.listQuery.current = 1
this.getList()
},
handleReset() {
this.listQuery = {
params: {
capitalName: '',
contractNo: '',
loanPeoName: '',
menuUrl: '',
orderEndDate: '',
orderStartDate: '',
orgSidPath: '',
policyName: '',
saleDeptName: '',
staffName: '',
type: '2',
useOrgName: '',
userSid: ''
},
current: 1,
size: 10,
total: 0
}
this.getList()
},
lookSale(row) {
this.viewState = 2
this.$refs['divSale'].showInfo({ sid: row.saleOrderSid })
},
resetState() {
this.viewState = 1
},
doClose() {
this.$store.dispatch('tagsView/delView', this.$route)
this.$router.go(-1)
}
}
}
</script>
<style scoped>
.btn_style {
background-color: #018ad2;
color: white;
font-weight: 600;
}
</style>
Loading…
Cancel
Save