
56 changed files with 4721 additions and 149 deletions
@ -0,0 +1,147 @@ |
|||||
|
import request from '@/utils/request' |
||||
|
|
||||
|
// 简易订单订金可用列表查询
|
||||
|
export function listPage(data) { |
||||
|
return request({ |
||||
|
url: '/fin/fincollectionconfirmation/jyddkydjListPage', |
||||
|
data: data, |
||||
|
method: 'post', |
||||
|
headers: { |
||||
|
'Content-Type': 'application/json' |
||||
|
} |
||||
|
}) |
||||
|
} |
||||
|
|
||||
|
// 未出库车辆已认款项列表查询
|
||||
|
export function pagelist(data) { |
||||
|
return request({ |
||||
|
url: '/fin/finselectedreceivablesdetailed/noOutVehRecPageList', |
||||
|
data: data, |
||||
|
method: 'post', |
||||
|
headers: { |
||||
|
'Content-Type': 'application/json' |
||||
|
} |
||||
|
}) |
||||
|
} |
||||
|
|
||||
|
// 款项结转申请列表查询
|
||||
|
export function kxjzlist(data) { |
||||
|
return request({ |
||||
|
url: '/fin/v1/finfundscarriedforwardapply/listPage', |
||||
|
data: data, |
||||
|
method: 'post', |
||||
|
headers: { |
||||
|
'Content-Type': 'application/json' |
||||
|
} |
||||
|
}) |
||||
|
} |
||||
|
|
||||
|
// 详情回显 获取一条记录
|
||||
|
export function fetchDetailBySid(data) { |
||||
|
return request({ |
||||
|
url: '/fin/v1/finfundscarriedforwardapply/init', |
||||
|
method: 'post', |
||||
|
data: data, |
||||
|
headers: { |
||||
|
'Content-Type': 'application/json' |
||||
|
} |
||||
|
}) |
||||
|
} |
||||
|
|
||||
|
// 款项结转--保存
|
||||
|
export function saveOrUpdate(data) { |
||||
|
return request({ |
||||
|
url: '/fin/v1/finfundscarriedforwardapply/save', |
||||
|
data: data, |
||||
|
method: 'post', |
||||
|
headers: { |
||||
|
'Content-Type': 'application/json' |
||||
|
} |
||||
|
}) |
||||
|
} |
||||
|
|
||||
|
// 销售订单--编辑、详情初始化
|
||||
|
export function fetchDetails(data) { |
||||
|
return request({ |
||||
|
url: '/fin/v1/finfundscarriedforwardapply/fetchDetailsBySid/' + data, |
||||
|
method: 'get' |
||||
|
}) |
||||
|
} |
||||
|
|
||||
|
// 款项结转--删除
|
||||
|
export function delBySids(data) { |
||||
|
return request({ |
||||
|
url: '/fin/v1/finfundscarriedforwardapply/delBySids', |
||||
|
data: data, |
||||
|
method: 'DELETE', |
||||
|
headers: { |
||||
|
'Content-Type': 'application/json' |
||||
|
} |
||||
|
}) |
||||
|
} |
||||
|
|
||||
|
// 提交
|
||||
|
export function submit(data) { |
||||
|
return request({ |
||||
|
url: '/fin/v1/finfundscarriedforwardapply/submitFinFundsApply', |
||||
|
method: 'post', |
||||
|
data: data, |
||||
|
headers: { |
||||
|
'Content-Type': 'application/json' |
||||
|
} |
||||
|
}) |
||||
|
} |
||||
|
|
||||
|
// 流程审批(同意)
|
||||
|
export function complete(params) { |
||||
|
return request({ |
||||
|
url: '/fin/v1/finfundscarriedforwardapply/complete', |
||||
|
method: 'post', |
||||
|
data: params |
||||
|
}) |
||||
|
} |
||||
|
|
||||
|
// 流程审批(驳回)
|
||||
|
export function reject(params) { |
||||
|
return request({ |
||||
|
url: '/fin/v1/finfundscarriedforwardapply/reject', |
||||
|
method: 'post', |
||||
|
data: params |
||||
|
}) |
||||
|
} |
||||
|
|
||||
|
// 流程审批(终止)
|
||||
|
export function breakProcess(params) { |
||||
|
return request({ |
||||
|
url: '/fin/v1/finfundscarriedforwardapply/breakProcess', |
||||
|
method: 'post', |
||||
|
data: params |
||||
|
}) |
||||
|
} |
||||
|
|
||||
|
// 流程审批(撤回)
|
||||
|
export function revokeProcess(params) { |
||||
|
return request({ |
||||
|
url: '/fin/v1/finfundscarriedforwardapply/revokeProcess', |
||||
|
method: 'post', |
||||
|
data: params |
||||
|
}) |
||||
|
} |
||||
|
|
||||
|
// 审批流程(同意)获取下一环节
|
||||
|
export function getNextNodesForSubmit(data) { |
||||
|
return request({ |
||||
|
url: '/fin/v1/finfundscarriedforwardapply/getNextNodesForSubmit', |
||||
|
method: 'get', |
||||
|
params: data |
||||
|
}) |
||||
|
} |
||||
|
|
||||
|
// 审批流程(驳回)获取上一环节
|
||||
|
export function getPreviousNodesForReject(data) { |
||||
|
return request({ |
||||
|
url: '/fin/v1/finfundscarriedforwardapply/getPreviousNodesForReject', |
||||
|
method: 'get', |
||||
|
params: data |
||||
|
}) |
||||
|
} |
@ -0,0 +1,305 @@ |
|||||
|
<template> |
||||
|
<div class="app-container"> |
||||
|
<div v-show="viewState == 1"> |
||||
|
<button-bar view-title="未出库车辆已认款" ref="btnbar" :btndisabled="btndisabled" @btnhandle="btnHandle"/> |
||||
|
<div class="main-content"> |
||||
|
<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" label-width="100px" class="tab-header"> |
||||
|
<el-form-item label="销售部门"> |
||||
|
<el-input v-model="listQuery.params.staffDeptName" placeholder="" clearable class="addinputw"/> |
||||
|
</el-form-item> |
||||
|
<el-form-item label="销售专员"> |
||||
|
<el-input v-model="listQuery.params.staffName" placeholder="" clearable class="addinputw"/> |
||||
|
</el-form-item> |
||||
|
<el-form-item label="合同编号"> |
||||
|
<el-input v-model="listQuery.params.contractNo" placeholder="" clearable class="addinputw"/> |
||||
|
</el-form-item> |
||||
|
<el-form-item label="客户名称"> |
||||
|
<el-input v-model="listQuery.params.customerName" placeholder="" clearable class="addinputw"/> |
||||
|
</el-form-item> |
||||
|
<el-form-item label="联系电话"> |
||||
|
<el-input v-model="listQuery.params.mobile" placeholder="" clearable class="addinputw"/> |
||||
|
</el-form-item> |
||||
|
<el-form-item label="车架号"> |
||||
|
<el-input v-model="listQuery.params.vinNo" placeholder="" clearable class="addinputw"/> |
||||
|
</el-form-item> |
||||
|
<el-form-item label="可用金额"> |
||||
|
<el-input v-model="listQuery.params.balanceSmallMoney" placeholder="" clearable style="width: 160px"/> |
||||
|
<span style="padding: 0 8px">至</span> |
||||
|
<el-input v-model="listQuery.params.balanceBigMoney" placeholder="" clearable style="width: 160px"/> |
||||
|
</el-form-item> |
||||
|
</el-form> |
||||
|
<div class="btn" style="text-align: center;"> |
||||
|
<el-button type="primary" icon="el-icon-search" size="small" @click="handleFilter">查询</el-button> |
||||
|
<el-button type="primary" icon="el-icon-refresh" size="small" @click="handReset">重置</el-button> |
||||
|
</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 width="50" type="selection" align="center"/> |
||||
|
<el-table-column width="80px" label="序号" type="index" :index="indexMethod" align="center"/> |
||||
|
<el-table-column label="分公司" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.useOrgName }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="销售部门" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.staffDeptName }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="销售专员" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.staffName }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="合同编号" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.contractNo }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="销售类型" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.payType }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="客户名称" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.customerName }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="联系电话" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.customerPhone }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="车架号" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.vinNo }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="应收项目" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.receivablesName }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="认款日期" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.auditDate }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="认款金额" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.subscriptionMoney }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="剩余金额" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.reveivableMoney }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="款项状态" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.state }}</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> |
||||
|
</div> |
||||
|
<moneycarriedforwardAdd v-show="viewState == 2" ref="divAdd" @doback="resetState"/> |
||||
|
</div> |
||||
|
</template> |
||||
|
|
||||
|
<script> |
||||
|
import { pagelist } from '@/api/moneycarriedforward/moneycarriedforward' |
||||
|
import Pagination from '@/components/pagination' |
||||
|
import pageye from '@/components/pagination/pageye' |
||||
|
import ButtonBar from '@/components/ButtonBar' |
||||
|
import moneycarriedforwardAdd from './moneycarriedforwardAdd' |
||||
|
|
||||
|
export default { |
||||
|
name: 'AcceptedMoney', |
||||
|
components: { |
||||
|
Pagination, |
||||
|
pageye, |
||||
|
ButtonBar, |
||||
|
moneycarriedforwardAdd |
||||
|
}, |
||||
|
data() { |
||||
|
return { |
||||
|
isSearchShow: false, |
||||
|
btndisabled: false, |
||||
|
viewState: 1, |
||||
|
btnList: [ |
||||
|
{ |
||||
|
type: 'primary', |
||||
|
size: 'small', |
||||
|
icon: '', |
||||
|
btnKey: 'toCarryDown', |
||||
|
btnLabel: '款项结转申请' |
||||
|
}, |
||||
|
{ |
||||
|
type: 'primary', |
||||
|
size: 'small', |
||||
|
icon: '', |
||||
|
btnKey: 'toRefund', |
||||
|
btnLabel: '退款申请' |
||||
|
}, |
||||
|
{ |
||||
|
type: 'info', |
||||
|
size: 'small', |
||||
|
icon: 'cross', |
||||
|
btnKey: 'doClose', |
||||
|
btnLabel: '关闭' |
||||
|
} |
||||
|
], |
||||
|
searchxianshitit: '隐藏查询条件', |
||||
|
tableKey: 0, |
||||
|
list: [], |
||||
|
sids: [], |
||||
|
listLoading: false, |
||||
|
listQuery: { |
||||
|
current: 1, |
||||
|
size: 10, |
||||
|
params: { |
||||
|
staffDeptName: '', |
||||
|
staffName: '', |
||||
|
contractNo: '', |
||||
|
customerName: '', |
||||
|
mobile: '', |
||||
|
vinNo: '', |
||||
|
balanceSmallMoney: '', |
||||
|
balanceBigMoney: '', |
||||
|
userSid: '', |
||||
|
orgPath: '', |
||||
|
menuUrl: '' |
||||
|
}, |
||||
|
total: 0 |
||||
|
} |
||||
|
} |
||||
|
}, |
||||
|
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 'toCarryDown': |
||||
|
this.toCarryDown() |
||||
|
break |
||||
|
case 'toRefund': |
||||
|
this.toRefund() |
||||
|
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 |
||||
|
}, |
||||
|
// 获取数据sid |
||||
|
handleSelectionChange(row) { |
||||
|
const aa = [] |
||||
|
row.forEach(element => { |
||||
|
aa.push(element.sid) |
||||
|
}) |
||||
|
this.sids = aa |
||||
|
console.log('获取sids数组', this.sids) |
||||
|
}, |
||||
|
// 查询列表信息 |
||||
|
getList() { |
||||
|
this.listLoading = true |
||||
|
this.listQuery.params.orgPath = window.sessionStorage.getItem('defaultOrgPath') |
||||
|
this.listQuery.params.userSid = window.sessionStorage.getItem('userSid') |
||||
|
this.listQuery.params.menuUrl = this.$route.path |
||||
|
pagelist(this.listQuery).then((response) => { |
||||
|
this.listLoading = false |
||||
|
if (response.success) { |
||||
|
this.listQuery.total = response.data.total |
||||
|
this.list = response.data.records |
||||
|
} else { |
||||
|
this.listQuery.total = 0 |
||||
|
this.list = [] |
||||
|
} |
||||
|
}) |
||||
|
}, |
||||
|
// 查询按钮 |
||||
|
handleFilter() { |
||||
|
this.listQuery.current = 1 |
||||
|
this.getList() |
||||
|
}, |
||||
|
handReset() { |
||||
|
this.listQuery = { |
||||
|
current: 1, |
||||
|
size: 10, |
||||
|
params: { |
||||
|
staffDeptName: '', |
||||
|
staffName: '', |
||||
|
contractNo: '', |
||||
|
customerName: '', |
||||
|
mobile: '', |
||||
|
vinNo: '', |
||||
|
balanceSmallMoney: '', |
||||
|
balanceBigMoney: '', |
||||
|
userSid: '', |
||||
|
orgPath: '', |
||||
|
menuUrl: '' |
||||
|
}, |
||||
|
total: 0 |
||||
|
} |
||||
|
this.getList() |
||||
|
}, |
||||
|
toCarryDown() { |
||||
|
if (this.sids.length > 0) { |
||||
|
this.viewState = 2 |
||||
|
var title = '已认款' |
||||
|
this.$refs['divAdd'].showAdd(title, this.sids) |
||||
|
} else { |
||||
|
this.$message({ showClose: true, type: 'error', message: '请至少选择一条记录进行款项结转申请操作' }) |
||||
|
} |
||||
|
}, |
||||
|
toRefund() {}, |
||||
|
resetState() { |
||||
|
this.viewState = 1 |
||||
|
}, |
||||
|
doClose() { |
||||
|
this.$store.dispatch('tagsView/delView', this.$route) |
||||
|
this.$router.go(-1) |
||||
|
} |
||||
|
} |
||||
|
} |
||||
|
</script> |
||||
|
<style scoped> |
||||
|
</style> |
@ -0,0 +1,374 @@ |
|||||
|
<template> |
||||
|
<div class="app-container"> |
||||
|
<!--列表页面--> |
||||
|
<div v-show="viewState == 1"> |
||||
|
<button-bar view-title="款项结转申请管理" ref="btnbar" :btndisabled="btndisabled" @btnhandle="btnHandle"/> |
||||
|
<!--Start查询列表部分--> |
||||
|
<div class="main-content"> |
||||
|
<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" label-width="100px" class="tab-header"> |
||||
|
<el-form-item label="部门"> |
||||
|
<el-input v-model="listQuery.params.applyDeptName" placeholder="" clearable/> |
||||
|
</el-form-item> |
||||
|
<el-form-item label="申请人"> |
||||
|
<el-input v-model="listQuery.params.createByName" placeholder="" clearable/> |
||||
|
</el-form-item> |
||||
|
<el-form-item label="申请日期"> |
||||
|
<el-date-picker v-model="listQuery.params.applyStartDate" type="date" placeholder="选择日期"></el-date-picker> |
||||
|
<span style="padding: 0 8px">至</span> |
||||
|
<el-date-picker v-model="listQuery.params.applyEndDate" type="date" placeholder="选择日期"></el-date-picker> |
||||
|
</el-form-item> |
||||
|
<el-form-item label="结转金额"> |
||||
|
<el-input v-model="listQuery.params.jzSmallMoney" placeholder="" clearable style="width: 160px"/> |
||||
|
<span style="padding: 0 8px">至</span> |
||||
|
<el-input v-model="listQuery.params.jzBigMoney" placeholder="" clearable style="width: 160px"/> |
||||
|
</el-form-item> |
||||
|
</el-form> |
||||
|
<div class="btn" style="text-align: center;"> |
||||
|
<el-button type="primary" icon="el-icon-search" size="small" @click="handleFilter">查询</el-button> |
||||
|
<el-button type="primary" icon="el-icon-refresh" size="small" @click="handleReset">重置</el-button> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
<!--End查询列表部分--> |
||||
|
<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> |
||||
|
<!--Start 主页面主要部分 --> |
||||
|
<div class=""> |
||||
|
<el-table :key="tableKey" v-loading="listLoading" :data="list" :border="true" style="width: 100%;" @selection-change="handleSelectionChange"> |
||||
|
<el-table-column type="selection" align="center" width="50"/> |
||||
|
<el-table-column label="序号" type="index" width="80" :index="indexMethod" align="center"/> |
||||
|
<el-table-column label="操作" width="180" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
<el-button type="primary" size="mini" @click="toEdit(scope.row)" :disabled="scope.row.nodeState =='发起申请' ? false : scope.row.nodeState == '待提交' ? false : true">办理</el-button> |
||||
|
<el-button type="primary" v-show="scope.row.nodeState == '已办结'" size="mini" @click="toDownLoad(scope.row)">下载</el-button> |
||||
|
<el-button type="primary" size="mini" @click="toInfo(scope.row)">查看</el-button> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="状态" width="180px" header-align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span v-if="scope.row.nodeState=='待提交'" type="primary" size="mini">待提交</span> |
||||
|
<span v-else @click="flowRecord(scope.row)" class="bluezi">{{ scope.row.nodeState }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="申请部门" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.applyDeptName }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="申请人" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.createByName }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="申请日期" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.createTime }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="来源" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.source }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="结转金额" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.carryForwardMoney }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="备注" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.remarks }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
</el-table> |
||||
|
</div> |
||||
|
<!--End 主页面主要部分--> |
||||
|
<div class="pages"> |
||||
|
<div class="tit"/> |
||||
|
<!-- 翻页 --> |
||||
|
<pagination v-show="list.length > 0" :total="listQuery.total" :page.sync="listQuery.current" :limit.sync="listQuery.size" class="pagination" @pagination="getList"/> |
||||
|
</div> |
||||
|
<!--End查询列表部分--> |
||||
|
</div> |
||||
|
</div> |
||||
|
<!--款项结转新增及修改 --> |
||||
|
<moneycarriedforwardAdd v-show="viewState == 2" ref="divAdd" @doback="resetState" @reloadlist="getList"/> |
||||
|
<!--款项结转申请详情--> |
||||
|
<moneycarriedforwardInfo v-show="viewState == 3" ref="divInfo" @doback="resetState" /> |
||||
|
<!--流程记录--> |
||||
|
<el-dialog title="" :visible.sync="centerDialogVisible" width="78%" height="1%" :before-close="closeIt" center> |
||||
|
<iframe frameborder="0" id="iframe" style="width:100%;" scrolling="no" :src="this.centerDialogVisible === true ? url :''"></iframe> |
||||
|
</el-dialog> |
||||
|
</div> |
||||
|
</template> |
||||
|
|
||||
|
<script> |
||||
|
import Pagination from '@/components/pagination' |
||||
|
import pageye from '@/components/pagination/pageye' |
||||
|
import ButtonBar from '@/components/ButtonBar' |
||||
|
import { kxjzlist, delBySids } from '@/api/moneycarriedforward/moneycarriedforward' |
||||
|
import { getOrgSidByPath } from '@/api/jichuxinxi/dictcommons' |
||||
|
import { getStorage } from '@/utils/auth' |
||||
|
import moneycarriedforwardAdd from './moneycarriedforwardAdd' |
||||
|
import moneycarriedforwardInfo from './moneycarriedforwardInfo' |
||||
|
|
||||
|
export default { |
||||
|
name: 'MoneyCarriedForward', |
||||
|
components: { |
||||
|
Pagination, |
||||
|
pageye, |
||||
|
ButtonBar, |
||||
|
moneycarriedforwardAdd, |
||||
|
moneycarriedforwardInfo |
||||
|
}, |
||||
|
data() { |
||||
|
return { |
||||
|
url: '', |
||||
|
dialogHeight: '80%', |
||||
|
centerDialogVisible: false, |
||||
|
btndisabled: false, |
||||
|
btnList: [ |
||||
|
{ |
||||
|
type: 'danger', |
||||
|
size: 'small', |
||||
|
icon: 'del', |
||||
|
btnKey: 'doDel', |
||||
|
btnLabel: '删除' |
||||
|
}, |
||||
|
{ |
||||
|
type: 'info', |
||||
|
size: 'small', |
||||
|
icon: 'cross', |
||||
|
btnKey: 'doClose', |
||||
|
btnLabel: '关闭' |
||||
|
} |
||||
|
], |
||||
|
isSearchShow: false, |
||||
|
searchxianshitit: '显示查询条件', |
||||
|
viewState: 1, // 1、列表 2、新增 3、编辑 4、查看 |
||||
|
tableKey: 0, |
||||
|
list: [], |
||||
|
sids: [], // 用于导出的时候保存已选择的SIDs |
||||
|
FormLoading: false, |
||||
|
listLoading: false, |
||||
|
// 翻页 |
||||
|
listQuery: { |
||||
|
current: 1, |
||||
|
size: 10, |
||||
|
total: 0, |
||||
|
params: { |
||||
|
userSid: '', |
||||
|
createByName: '', |
||||
|
applyDeptName: '', |
||||
|
applyStartDate: '', |
||||
|
applyEndDate: '', |
||||
|
jzSmallMoney: '', |
||||
|
jzBigMoney: '', |
||||
|
orgSidPath: '', |
||||
|
menuUrl: '' |
||||
|
} |
||||
|
} |
||||
|
} |
||||
|
}, |
||||
|
created() { |
||||
|
// 初始化变量 |
||||
|
this.init() |
||||
|
}, |
||||
|
mounted() { |
||||
|
// 在外部vue的window上添加postMessage的监听,而且绑定处理函数handleMessage |
||||
|
window.addEventListener('message', this.handleMessage) |
||||
|
this.$refs['btnbar'].setButtonList(this.btnList) |
||||
|
}, |
||||
|
methods: { |
||||
|
async handleMessage(event) { |
||||
|
var code = '' |
||||
|
if (event.data.params !== null && event.data.params !== undefined) { |
||||
|
code = event.data.params.code |
||||
|
} |
||||
|
if (code === 1) { |
||||
|
this.init() |
||||
|
this.centerDialogVisible = false |
||||
|
} else if (code === 2) { |
||||
|
this.dialogHeight = event.data.params.data |
||||
|
this.setIframeHeight(document.getElementById('iframe')) |
||||
|
} |
||||
|
}, |
||||
|
closeIt() { |
||||
|
this.url = '' |
||||
|
this.centerDialogVisible = false |
||||
|
}, |
||||
|
setIframeHeight(iframe) { |
||||
|
iframe.height = this.dialogHeight |
||||
|
}, |
||||
|
flowRecord(row) { |
||||
|
this.centerDialogVisible = true |
||||
|
var params = { |
||||
|
deployId: row.procDefId, |
||||
|
procInsId: row.procInstSid, |
||||
|
token: getStorage() |
||||
|
} |
||||
|
this.url = '/#/flow/flowRecordForBusiness?data=' + encodeURI((JSON.stringify(params))) |
||||
|
}, |
||||
|
// 搜索条件效果 |
||||
|
clicksearchShow() { |
||||
|
this.isSearchShow = !this.isSearchShow |
||||
|
if (this.isSearchShow) { |
||||
|
this.searchxianshitit = '隐藏查询条件' |
||||
|
} else { |
||||
|
this.searchxianshitit = '显示查询条件' |
||||
|
} |
||||
|
}, |
||||
|
btnHandle(btnKey) { |
||||
|
console.log('XXXXXXXXXXXXXXX ' + btnKey) |
||||
|
switch (btnKey) { |
||||
|
case 'doDel': |
||||
|
this.doDel() |
||||
|
break |
||||
|
case 'doClose': |
||||
|
this.doClose() |
||||
|
break |
||||
|
default: |
||||
|
break |
||||
|
} |
||||
|
}, |
||||
|
init() { |
||||
|
getOrgSidByPath({ orgPath: window.sessionStorage.getItem('defaultOrgPath') }).then((resp) => { |
||||
|
if (resp.success) { |
||||
|
this.listQuery.params.useOrgSid = resp.data |
||||
|
this.getList() |
||||
|
} |
||||
|
}) |
||||
|
}, |
||||
|
// 信息条数 获取点击时当前的sid |
||||
|
handleSelectionChange(row) { |
||||
|
const aa = [] |
||||
|
row.forEach(element => { |
||||
|
aa.push(element.sid) |
||||
|
}) |
||||
|
this.sids = aa |
||||
|
}, |
||||
|
// 表中序号 |
||||
|
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.userSid = window.sessionStorage.getItem('userSid') |
||||
|
this.listQuery.params.menuUrl = this.$route.path |
||||
|
this.listQuery.params.orgSidPath = window.sessionStorage.getItem('defaultOrgPath') |
||||
|
kxjzlist(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 |
||||
|
} |
||||
|
}) |
||||
|
}, |
||||
|
// 查询按钮 |
||||
|
handleFilter() { |
||||
|
this.listQuery.current = 1 |
||||
|
this.getList() |
||||
|
}, |
||||
|
// 点击重置 |
||||
|
handleReset() { |
||||
|
this.listQuery = { |
||||
|
current: 1, |
||||
|
size: 10, |
||||
|
total: 0, |
||||
|
params: { |
||||
|
userSid: '', |
||||
|
createByName: '', |
||||
|
applyDeptName: '', |
||||
|
applyStartDate: '', |
||||
|
applyEndDate: '', |
||||
|
jzSmallMoney: '', |
||||
|
jzBigMoney: '', |
||||
|
orgSidPath: '', |
||||
|
menuUrl: '' |
||||
|
} |
||||
|
} |
||||
|
this.init() |
||||
|
}, |
||||
|
toEdit(row) { |
||||
|
this.viewState = 2 |
||||
|
this.$refs['divAdd'].showEdit(row) |
||||
|
}, |
||||
|
toInfo(row) { |
||||
|
this.viewState = 3 |
||||
|
this.$refs['divInfo'].showInfo(row) |
||||
|
}, |
||||
|
toDownLoad(row) { |
||||
|
var xhr = new XMLHttpRequest() |
||||
|
xhr.open('GET', process.env.VUE_APP_BASE_API + '/base/file/download?filePath=' + row.tzsqPath + '&outFileName=' + '调账申请', true) |
||||
|
xhr.setRequestHeader('token', getStorage()) |
||||
|
xhr.responseType = 'blob' |
||||
|
xhr.onload = function(e) { |
||||
|
// 如果请求执行成功 |
||||
|
var blob = this.response |
||||
|
var filename = '调账.pdf' |
||||
|
var a = document.createElement('a') |
||||
|
// blob.type="application/octet-stream"; |
||||
|
// 创键临时url对象 |
||||
|
var url = URL.createObjectURL(blob) |
||||
|
a.href = url |
||||
|
a.download = filename |
||||
|
a.click() |
||||
|
// 释放之前创建的URL对象 |
||||
|
window.URL.revokeObjectURL(url) |
||||
|
} |
||||
|
// 发送请求 |
||||
|
xhr.send() |
||||
|
}, |
||||
|
doDel() { |
||||
|
if (this.sids.length === 0) { |
||||
|
this.$message({ showClose: true, type: 'error', message: '请选择至少一条记录进行删除操作' }) |
||||
|
return |
||||
|
} |
||||
|
const tip = '请确认是否删除所选 ' + this.sids.length + ' 条记录?' |
||||
|
this.$confirm(tip, '提示', { |
||||
|
confirmButtonText: '确定', |
||||
|
cancelButtonText: '取消', |
||||
|
type: 'warning' |
||||
|
}).then(() => { |
||||
|
const loading = this.$loading({ |
||||
|
lock: true, |
||||
|
text: 'Loading', |
||||
|
spinner: 'el-icon-loading', |
||||
|
background: 'rgba(0, 0, 0, 0.7)' |
||||
|
}) |
||||
|
delBySids(this.sids).then(resp => { |
||||
|
if (resp.success) { |
||||
|
this.$message({ type: 'success', message: resp.msg, showClose: true }) |
||||
|
} |
||||
|
this.getList() |
||||
|
loading.close() |
||||
|
}).catch(e => { |
||||
|
loading.close() |
||||
|
}) |
||||
|
}).catch(() => { |
||||
|
}) |
||||
|
}, |
||||
|
// 修改、编辑、详情返回列表页面 |
||||
|
resetState() { |
||||
|
this.viewState = 1 |
||||
|
}, |
||||
|
doClose() { |
||||
|
this.$store.dispatch('tagsView/delView', this.$route) |
||||
|
this.$router.go(-1) |
||||
|
} |
||||
|
} |
||||
|
} |
||||
|
</script> |
||||
|
<style scoped> |
||||
|
</style> |
@ -0,0 +1,710 @@ |
|||||
|
<template> |
||||
|
<div class="app-container"> |
||||
|
<div v-show="viewState == 1"> |
||||
|
<div class="tab-header webtop"> |
||||
|
<div>{{ viewTitle }}</div> |
||||
|
<div> |
||||
|
<el-button type="primary" size="small" :disabled="submitdisabled" @click="saveOrUpdate()">保存 |
||||
|
</el-button> |
||||
|
<el-button type="primary" size="small" :disabled="submitdisabled" @click="submit()">提交 |
||||
|
</el-button> |
||||
|
<el-button type="info" size="small" @click="handleReturn()">关闭</el-button> |
||||
|
</div> |
||||
|
</div> |
||||
|
<div class="listconadd"> |
||||
|
<div class="titwu"><span>款项结转申请</span></div> |
||||
|
<el-form ref="form_obj" :model="formobj" :rules="rules" label-position="top" class="formadd"> |
||||
|
<el-row style="border-top: 1px solid #e0e3eb"> |
||||
|
<el-col :span="4" class="tleftb"> |
||||
|
<span>申请部门</span> |
||||
|
</el-col> |
||||
|
<el-col :span="4"> |
||||
|
<el-form-item> |
||||
|
<span>{{ formobj.applyDeptName }}</span> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="4" class="tleftb"> |
||||
|
<span>申请人</span> |
||||
|
</el-col> |
||||
|
<el-col :span="4"> |
||||
|
<el-form-item> |
||||
|
<span>{{ formobj.createByName }}</span> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="4" class="tleftb"> |
||||
|
<span>申请日期</span> |
||||
|
</el-col> |
||||
|
<el-col :span="4"> |
||||
|
<el-form-item> |
||||
|
<span>{{ formobj.createByDate }}</span> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="4" class="tleftb"> |
||||
|
<span>销售部门</span> |
||||
|
</el-col> |
||||
|
<el-col :span="4"> |
||||
|
<el-form-item> |
||||
|
<span>{{ formobj.saleDeptName }}</span> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="4" class="tleftb"> |
||||
|
<span>销售专员</span> |
||||
|
</el-col> |
||||
|
<el-col :span="4"> |
||||
|
<el-form-item> |
||||
|
<span>{{ formobj.staffName }}</span> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="4" class="tleftb"> |
||||
|
<span>来源</span> |
||||
|
</el-col> |
||||
|
<el-col :span="4"> |
||||
|
<el-form-item> |
||||
|
<span>{{ formobj.source }}</span> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-table border :key="tablebleKey" width="100%" :index="index" :data="formobj.finFundsCarriedForwardVehDetailsVos"> |
||||
|
<el-table-column fixed width="60" label="序号" type="index" :index="index + 1" align="center"/> |
||||
|
<el-table-column fixed label="操作" align="center" width="80"> |
||||
|
<template slot-scope="scope"> |
||||
|
<el-button type="danger" size="small" @click="handleDelete(scope.$index)">删除</el-button> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="合同编号/收款单编号" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.busBillNo }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="客户名称/付款人" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.customerName }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="车架号" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.vinNo }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="剩余金额" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.balance }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="本次使用金额" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
<el-input v-model="scope.row.thisUseMoney" clearable placeholder=""/> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
</el-table> |
||||
|
<el-row> |
||||
|
<el-col :span="4" class="tleftb" style="display: flex;flex-direction: row;justify-content: flex-end;align-items: center"> |
||||
|
<span>款项确认书</span> |
||||
|
</el-col> |
||||
|
<el-col :span="20" class="trightb"> |
||||
|
<el-form-item> |
||||
|
<upload ref="uploadImg" v-model="image_list1" :accept="accept" :limit="50" bucket="map" :upload-data="{ type: '0001' }"/> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="4" class="tleftb"> |
||||
|
<span>备注</span> |
||||
|
</el-col> |
||||
|
<el-col :span="20" class="trightb"> |
||||
|
<el-form-item> |
||||
|
<el-input v-model="formobj.remarks" style="width: 70%" placeholder="" clearable/> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="24" style="padding: 0px"> |
||||
|
<el-form ref="listQueryform" :inline="true" :model="listQuery" class="tab-header"> |
||||
|
<el-form-item label="采购系统:"> |
||||
|
<el-select :disabled="dialogStatus == 'edit'" v-model="formobj.purchaseSystemSid" placeholder="请选择" @change="changePurchase" filterable clearable> |
||||
|
<el-option v-for="item in purchase_list" :key="item.deptSid" :label="item.purchaseSystemName" :value="item.deptSid"/> |
||||
|
</el-select> |
||||
|
</el-form-item> |
||||
|
<el-form-item label="合同编号:"> |
||||
|
<el-input v-model="listQuery.contractNo" size="mini" placeholder="" style="width: 110px" clearable/> |
||||
|
</el-form-item> |
||||
|
<el-form-item label="客户名称:"> |
||||
|
<el-input v-model="listQuery.customerName" size="mini" placeholder="" style="width: 100px" clearable/> |
||||
|
</el-form-item> |
||||
|
<el-form-item label="联系电话:"> |
||||
|
<el-input v-model="listQuery.customerPhone" size="mini" placeholder="" style="width: 140px" clearable/> |
||||
|
</el-form-item> |
||||
|
<el-form-item label="车架号:"> |
||||
|
<el-input v-model="listQuery.vinNo" size="mini" placeholder="" style="width: 140px" clearable/> |
||||
|
</el-form-item> |
||||
|
</el-form> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="24"> |
||||
|
<div style="display: flex;flex-direction: row;justify-content: space-between;align-items: center;padding-top: 5px"> |
||||
|
<div style="padding-left: 30%"> |
||||
|
<el-button type="primary" size="mini" @click="handleFilter">查询</el-button> |
||||
|
<el-button type="primary" size="mini" @click="handReset">重置</el-button> |
||||
|
<el-button type="primary" size="mini" @click="handleSelect">选择已认款项</el-button> |
||||
|
</div> |
||||
|
<div> |
||||
|
<span >余额:{{ balaceCount() }}</span> |
||||
|
</div> |
||||
|
</div> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="10"> |
||||
|
<div> |
||||
|
<div class="tableTitle">应收未收款款项明细</div> |
||||
|
<el-table border :key="overduereceivableKey" width="100%" :data="overduereceivable_list"> |
||||
|
<el-table-column fixed label="操作" align="center" width="80"> |
||||
|
<template slot-scope="scope"> |
||||
|
<el-button type="primary" size="small" @click="handAdd(scope.row)">添加</el-button> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="合同编号" align="center" width="100"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.contractNo }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="车架号" align="center" width="90"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.VIN }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="客户/电话" align="center" width="100"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.customerName }} {{ scope.row.customerPhone }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="付款" align="center" width="70"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.payType }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="应收金额" align="center" width="100"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.reveivableMoney }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="应收项目" align="center" width="90"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.receivablesName }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="当前应收" align="center" width="100"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.currentReceivableMoney }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
</el-table> |
||||
|
</div> |
||||
|
</el-col> |
||||
|
<el-col :span="14"> |
||||
|
<div> |
||||
|
<div class="tableTitle">已选应收款项明细</div> |
||||
|
<el-table border :key="selectedreceivableKey" width="100%" :data="formobj.yxysFinFundsCarriedForwardYXYSKXVos"> |
||||
|
<el-table-column fixed label="操作" align="center" width="70"> |
||||
|
<template slot-scope="scope"> |
||||
|
<el-button type="danger" size="small" @click="handDelete(scope.row)">移除</el-button> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="合同编号" align="center" width="95"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.contractId }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="车架号" align="center" width="90"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.vin }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="客户/电话" align="center" width="100"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.name }} {{ scope.row.mobile }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="付款" align="center" width="70"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.payType }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="应收项目" align="center" width="90"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.projectName }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="当前应收" align="center" width="100"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.receivable }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="认款金额" align="center" width="130"> |
||||
|
<template slot-scope="scope"> |
||||
|
<el-input v-model="scope.row.confirmMoney" @input="changeMoney(scope.row)" @keyup.native="UpNumber" @keydown.native="UpNumber" placeholder="" clearable/> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="剩余应收" align="center" width="100"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.surplusReceivable }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="认款申请日期" align="center" width="120"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.confirmDate }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
</el-table> |
||||
|
</div> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
</el-form> |
||||
|
</div> |
||||
|
</div> |
||||
|
<amountpledged v-show="viewState == 2" ref="divSelect" @doback="resetState" @backData="backData"/> |
||||
|
</div> |
||||
|
</template> |
||||
|
|
||||
|
<script> |
||||
|
import { fetchDetailBySid, saveOrUpdate, fetchDetails, submit } from '@/api/moneycarriedforward/moneycarriedforward' |
||||
|
import { listAll } from '@/api/anruifinmanagement/paymentConfirmation' |
||||
|
import amountpledged from '../anruifinmanagement/paymentConfirmation/relation/amountpledged' |
||||
|
import { fetchDetailsByUseOrgSid, getOrgSidByPath } from '@/api/jichuxinxi/dictcommons' |
||||
|
import upload from '@/components/uploadFile/upload' |
||||
|
|
||||
|
export default { |
||||
|
name: 'MoneyCarriedForwardAdd', |
||||
|
components: { |
||||
|
upload, |
||||
|
amountpledged |
||||
|
}, |
||||
|
data() { |
||||
|
return { |
||||
|
viewTitle: '', |
||||
|
viewState: 1, |
||||
|
dialogStatus: '', |
||||
|
tablebleKey: 0, |
||||
|
index: 0, |
||||
|
overduereceivableKey: 1, |
||||
|
selectedreceivableKey: 2, |
||||
|
overduereceivable_list: [], |
||||
|
purchase_list: [], |
||||
|
image_list1: [], |
||||
|
accept: '.jpg,.jpeg,.png,.JPG,.JPEG', |
||||
|
formobj: { |
||||
|
applyDeptName: '', |
||||
|
applyDeptSid: '', |
||||
|
billNo: '', |
||||
|
createByDate: '', |
||||
|
createByName: '', |
||||
|
createBySid: '', |
||||
|
finFundsCarriedForwardVehDetailsVos: [], |
||||
|
kxqrsImages: [], |
||||
|
orgSidPath: '', |
||||
|
purchaseSystem: '', |
||||
|
purchaseSystemSid: '', |
||||
|
remarks: '', |
||||
|
saleDeptName: '', |
||||
|
saleDeptSid: '', |
||||
|
sid: '', |
||||
|
source: '', |
||||
|
staffName: '', |
||||
|
staffSid: '', |
||||
|
useOrgName: '', |
||||
|
useOrgSid: '', |
||||
|
yxysFinFundsCarriedForwardYXYSKXVos: [] |
||||
|
}, |
||||
|
listQuery: { |
||||
|
contractNo: '', |
||||
|
customerName: '', |
||||
|
customerPhone: '', |
||||
|
sids: [], |
||||
|
createBySid: '', |
||||
|
vinNo: '', |
||||
|
orgPath: '', |
||||
|
purchaseSystemSid: '' |
||||
|
}, |
||||
|
rules: {}, |
||||
|
submitdisabled: false, |
||||
|
} |
||||
|
}, |
||||
|
methods: { |
||||
|
UpNumber(e) { |
||||
|
e.target.value = e.target.value.replace(/[^\d.]/g, '') // 清除“数字”和“.”"-"以外的字符 |
||||
|
e.target.value = e.target.value.replace(/^00/, '0.') // 开头不能有两个0 |
||||
|
e.target.value = e.target.value.replace(/\.{2,}/g, '.') // 只保留第一个. 清除多余的 |
||||
|
e.target.value = e.target.value.replace('.', '$#$').replace(/\./g, '').replace('$#$', '.') // 只保留第一个- |
||||
|
e.target.value = e.target.value.replace(/^(\-)*(\d+)\.(\d\d).*$/, '$1$2.$3') // 只能输入两个小数 |
||||
|
if (e.target.value.indexOf('.') < 0 && e.target.value !== '') { |
||||
|
// 以上已经过滤,此处控制的是如果没有小数点,首位不能为类似于 01、02的金额 |
||||
|
console.log(e.target.value) |
||||
|
e.target.value = parseFloat(e.target.value) |
||||
|
} |
||||
|
}, |
||||
|
DataDictionary() { |
||||
|
getOrgSidByPath({ orgPath: window.sessionStorage.getItem('defaultOrgPath') }).then((res) => { |
||||
|
fetchDetailsByUseOrgSid(res.data).then((resp) => { |
||||
|
if (resp.success) { |
||||
|
this.purchase_list = resp.data |
||||
|
} |
||||
|
}) |
||||
|
}) |
||||
|
}, |
||||
|
// 已选明细表中计算剩余应收 |
||||
|
changeMoney(row) { |
||||
|
if (row.receivable !== '') { |
||||
|
row.surplusReceivable = parseFloat(row.receivable) - parseFloat(row.confirmMoney) |
||||
|
} else { |
||||
|
row.surplusReceivable = '' |
||||
|
} |
||||
|
}, |
||||
|
handleDelete(index) { |
||||
|
this.formobj.finFundsCarriedForwardVehDetailsVos.splice(index, 1) |
||||
|
}, |
||||
|
balaceCount() { |
||||
|
var money = '0' |
||||
|
if (this.formobj.finFundsCarriedForwardVehDetailsVos.length > 0) { |
||||
|
let useMoney = '0' |
||||
|
for (var i = 0; i < this.formobj.finFundsCarriedForwardVehDetailsVos.length; i++) { |
||||
|
if (this.formobj.finFundsCarriedForwardVehDetailsVos[i].thisUseMoney === '') { |
||||
|
useMoney = '1' |
||||
|
return |
||||
|
} |
||||
|
} |
||||
|
if (useMoney === '0') { |
||||
|
var list = [] |
||||
|
for (var b = 0; b < this.formobj.finFundsCarriedForwardVehDetailsVos.length; b++) { |
||||
|
list.push(this.formobj.finFundsCarriedForwardVehDetailsVos[b].thisUseMoney) |
||||
|
} |
||||
|
money = this.calculatedAmount(list) |
||||
|
} |
||||
|
} |
||||
|
if (this.formobj.yxysFinFundsCarriedForwardYXYSKXVos.length > 0) { |
||||
|
let confirmMoney = '0' |
||||
|
for (var p = 0; p < this.formobj.yxysFinFundsCarriedForwardYXYSKXVos.length; p++) { |
||||
|
if (this.formobj.yxysFinFundsCarriedForwardYXYSKXVos[p].confirmMoney === '') { |
||||
|
confirmMoney = '1' |
||||
|
return money |
||||
|
} |
||||
|
} |
||||
|
if (confirmMoney === '0') { |
||||
|
var list1 = [] |
||||
|
for (var l = 0; l < this.formobj.yxysFinFundsCarriedForwardYXYSKXVos.length; l++) { |
||||
|
list1.push(this.formobj.yxysFinFundsCarriedForwardYXYSKXVos[l].confirmMoney) |
||||
|
} |
||||
|
money = parseFloat(money) - parseFloat(this.calculatedAmount(list1)) |
||||
|
} |
||||
|
} |
||||
|
return money |
||||
|
}, |
||||
|
calculatedAmount(list) { |
||||
|
var sumNum = 0 |
||||
|
for (var k = 0; k < list.length; k++) { |
||||
|
// 替换掉字符串中的千分位分隔符并相加 |
||||
|
sumNum += Number(list[k].replace(/,/g, '')) |
||||
|
} |
||||
|
// 将总数四舍五入 |
||||
|
var f1 = Math.round(sumNum * 100) / 100 |
||||
|
// 转化为字符串 |
||||
|
var strNum = f1.toString() |
||||
|
// 将整数和小数点分割 |
||||
|
var rs = strNum.indexOf('.') |
||||
|
if (rs < 0) { |
||||
|
rs = strNum.length |
||||
|
strNum += '.' |
||||
|
} |
||||
|
while (strNum.length <= rs + 2) { |
||||
|
strNum += '0' |
||||
|
} |
||||
|
var resNum = strNum.replace(/\d+/, function(n) { |
||||
|
return n.replace(/(\d)(?=(\d{3})+$)/g, function(u) { |
||||
|
return u |
||||
|
}) |
||||
|
}) |
||||
|
return resNum |
||||
|
}, |
||||
|
getlist() { |
||||
|
if (this.formobj.purchaseSystemName === '') { |
||||
|
this.$message({ showClose: true, type: 'error', message: '请选择采购系统' }) |
||||
|
return |
||||
|
} |
||||
|
this.listQuery.createBySid = window.sessionStorage.getItem('userSid') |
||||
|
this.listQuery.orgPath = window.sessionStorage.getItem('defaultOrgPath') |
||||
|
listAll(this.listQuery).then((res) => { |
||||
|
if (res.code === '200') { |
||||
|
this.overduereceivable_list = res.data |
||||
|
} |
||||
|
}) |
||||
|
}, |
||||
|
handleFilter() { |
||||
|
this.getlist() |
||||
|
}, |
||||
|
changePurchase(value) { |
||||
|
if (this.formobj.finFundsCarriedForwardVehDetailsVos.length > 0) { |
||||
|
for (var i = 0; i < this.formobj.finFundsCarriedForwardVehDetailsVos.length; i++) { |
||||
|
if (this.formobj.finFundsCarriedForwardVehDetailsVos[i].thisUseMoney === '') { |
||||
|
this.$message({ showClose: true, type: 'error', message: '请检查本次使用金额是否已全部填写' }) |
||||
|
this.formobj.purchaseSystemSid = '' |
||||
|
return |
||||
|
} |
||||
|
} |
||||
|
} |
||||
|
if (value !== '') { |
||||
|
const choose = this.purchase_list.filter((item) => item.deptSid === value) |
||||
|
this.formobj.purchaseSystem = choose[0].purchaseSystemName |
||||
|
this.listQuery.purchaseSystemSid = this.formobj.purchaseSystemSid |
||||
|
this.getlist() |
||||
|
} else { |
||||
|
this.overduereceivable_list = [] |
||||
|
} |
||||
|
}, |
||||
|
handReset() { |
||||
|
this.listQuery.contractNo = '' |
||||
|
this.listQuery.customerName = '' |
||||
|
this.listQuery.customerPhone = '' |
||||
|
this.listQuery.vinNo = '' |
||||
|
this.listQuery.createBySid = '' |
||||
|
this.listQuery.orgPath = '' |
||||
|
this.getlist() |
||||
|
}, |
||||
|
showAdd(title, sids) { |
||||
|
this.DataDictionary() |
||||
|
this.viewTitle = '【新建】款项结转' |
||||
|
this.$nextTick(() => { |
||||
|
this.$refs['form_obj'].clearValidate() |
||||
|
}) |
||||
|
fetchDetailBySid({ userSid: window.sessionStorage.getItem('userSid'), orgSidPath: window.sessionStorage.getItem('defaultOrgPath'), source: title, busSids: sids }).then((res) => { |
||||
|
if (res.success) { |
||||
|
this.formobj = res.data |
||||
|
this.formobj.orgSidPath = window.sessionStorage.getItem('defaultOrgPath') |
||||
|
} |
||||
|
}) |
||||
|
}, |
||||
|
showEdit(row) { |
||||
|
this.DataDictionary() |
||||
|
this.viewTitle = '【编辑】款项结转' |
||||
|
this.dialogStatus = 'edit' |
||||
|
fetchDetails(row.sid).then(resp => { |
||||
|
if (resp.success) { |
||||
|
this.formobj = resp.data |
||||
|
this.formobj.instanceId = resp.data.procInsId |
||||
|
if (this.formobj.kxqrsImages !== null && this.formobj.kxqrsImages.length >0) { |
||||
|
this.formobj.kxqrsImages.forEach((e) => { |
||||
|
this.image_list1.push({ |
||||
|
name: '', |
||||
|
url: e |
||||
|
}) |
||||
|
}) |
||||
|
} |
||||
|
if (this.formobj.purchaseSystem !== '') { |
||||
|
this.listQuery.purchaseSystemSid = this.formobj.purchaseSystemSid |
||||
|
this.getlist() |
||||
|
} |
||||
|
this.$nextTick(() => { |
||||
|
this.$refs['form_obj'].clearValidate() |
||||
|
}) |
||||
|
} |
||||
|
}).catch(e => { |
||||
|
this.formobj = row |
||||
|
}) |
||||
|
}, |
||||
|
// 应收未收明细表添加数据到已选应收明细表 |
||||
|
handAdd(row) { |
||||
|
if (this.formobj.collectionMoney === '') { |
||||
|
this.$message({ showClose: true, type: 'error', message: '请先填写收款金额' }) |
||||
|
} else { |
||||
|
var nowDate = new Date() |
||||
|
var date = { |
||||
|
year: nowDate.getFullYear(), |
||||
|
month: nowDate.getMonth() + 1, |
||||
|
day: nowDate.getDate() |
||||
|
} |
||||
|
var dayDate = date.year + '-' + (date.month >= 10 ? date.month : '0' + date.month) + '-' + (date.day >= 10 ? date.day : '0' + date.day) |
||||
|
this.formobj.yxysFinFundsCarriedForwardYXYSKXVos.push({ |
||||
|
createByName: window.sessionStorage.getItem('name'), |
||||
|
contractSid: row.contractSid, |
||||
|
contractId: row.contractNo, |
||||
|
customerSid: row.customerSid, |
||||
|
name: row.customerName, |
||||
|
vin: row.VIN, |
||||
|
useOrgSid: '', |
||||
|
mobile: row.customerPhone, |
||||
|
projectName: row.receivablesName, |
||||
|
receivable: row.currentReceivableMoney, |
||||
|
lastSubscriptionMoney: '', |
||||
|
confirmMoney: '', |
||||
|
surplusReceivable: '', |
||||
|
subscribedOf: row.subscribedOf, |
||||
|
confirmDate: dayDate, |
||||
|
collSid: '', |
||||
|
receivablesSid: row.receivablesSid, |
||||
|
payType: row.payType, |
||||
|
payTypeKey: row.payTypeKey, |
||||
|
sid: row.sid |
||||
|
}) |
||||
|
this.listQuery.sids.push(row.sid) |
||||
|
this.balaceCount() |
||||
|
this.getlist() |
||||
|
} |
||||
|
}, |
||||
|
// 已选应收明细表移除 |
||||
|
handDelete(row) { |
||||
|
this.formobj.yxysFinFundsCarriedForwardYXYSKXVos.splice(this.formobj.yxysFinFundsCarriedForwardYXYSKXVos.indexOf(row), 1) |
||||
|
if (row.subscribedOf == 0) { |
||||
|
this.listQuery.sids.splice(this.listQuery.sids.indexOf(row.sid), 1) |
||||
|
this.getlist() |
||||
|
} |
||||
|
}, |
||||
|
// 跳转选择已认款项列表 |
||||
|
handleSelect() { |
||||
|
if (this.formobj.purchaseSystemSid === '') { |
||||
|
this.$message({ showClose: true, type: 'error', message: '请先选择采购系统' }) |
||||
|
return |
||||
|
} |
||||
|
this.viewState = 2 |
||||
|
this.$refs['divSelect'].showData(this.formobj.yxysFinFundsCarriedForwardYXYSKXVos, this.formobj.purchaseSystemSid) |
||||
|
}, |
||||
|
// 跳转选择已认款项列表--选择数据后返回 |
||||
|
backData(val) { |
||||
|
this.viewState = 1 |
||||
|
var nowDate = new Date() |
||||
|
var date = { |
||||
|
year: nowDate.getFullYear(), |
||||
|
month: nowDate.getMonth() + 1, |
||||
|
day: nowDate.getDate() |
||||
|
} |
||||
|
var dayDate = date.year + '-' + (date.month >= 10 ? date.month : '0' + date.month) + '-' + (date.day >= 10 ? date.day : '0' + date.day) |
||||
|
for (var i = 0; i < val.length; i++) { |
||||
|
this.formobj.yxysFinFundsCarriedForwardYXYSKXVos.push({ |
||||
|
createByName: window.sessionStorage.getItem('name'), |
||||
|
contractSid: val[i].contractSid, |
||||
|
contractId: val[i].contractNo, |
||||
|
customerSid: val[i].customerSid, |
||||
|
name: val[i].customerName, |
||||
|
vin: val[i].VIN, |
||||
|
useOrgSid: '', |
||||
|
mobile: val[i].customerPhone, |
||||
|
projectName: val[i].receivablesName, |
||||
|
receivable: val[i].currentReceivableMoney, |
||||
|
lastSubscriptionMoney: '', |
||||
|
confirmMoney: '', |
||||
|
surplusReceivable: '', |
||||
|
subscribedOf: val[i].subscribedOf, |
||||
|
confirmDate: dayDate, |
||||
|
collSid: '', |
||||
|
receivablesSid: val[i].sid, |
||||
|
payType: val[i].payType, |
||||
|
payTypeKey: val[i].payTypeKey, |
||||
|
sid: val[i].sid |
||||
|
}) |
||||
|
} |
||||
|
}, |
||||
|
resetState() { |
||||
|
this.viewState = 1 |
||||
|
}, |
||||
|
saveOrUpdate() { |
||||
|
if (this.image_list1.length > 0) { |
||||
|
var aa = [] |
||||
|
for (var i = 0; i < this.image_list1.length; i++) { |
||||
|
aa.push(this.image_list1[i].url) |
||||
|
} |
||||
|
this.formobj.kxqrsImages = aa |
||||
|
} |
||||
|
this.$refs['form_obj'].validate((valid) => { |
||||
|
if (valid) { |
||||
|
this.submitdisabled = true |
||||
|
saveOrUpdate(this.formobj).then((resp) => { |
||||
|
if (resp.success) { |
||||
|
this.$message({ showClose: true, type: 'success', message: resp.msg }) |
||||
|
this.handleReturn('true') |
||||
|
} else { |
||||
|
this.submitdisabled = false |
||||
|
} |
||||
|
}).catch(() => { |
||||
|
this.submitdisabled = false |
||||
|
}) |
||||
|
} |
||||
|
}) |
||||
|
}, |
||||
|
submit() { |
||||
|
if (this.image_list1.length > 0) { |
||||
|
var aa = [] |
||||
|
for (var i = 0; i < this.image_list1.length; i++) { |
||||
|
aa.push(this.image_list1[i].url) |
||||
|
} |
||||
|
this.formobj.kxqrsImages = aa |
||||
|
} |
||||
|
this.$refs['form_obj'].validate((valid) => { |
||||
|
if (valid) { |
||||
|
this.submitdisabled = true |
||||
|
submit(this.formobj).then((resp) => { |
||||
|
if (resp.success) { |
||||
|
this.$message({ showClose: true, type: 'success', message: resp.msg }) |
||||
|
this.handleReturn('true') |
||||
|
} else { |
||||
|
this.submitdisabled = false |
||||
|
} |
||||
|
}).catch(() => { |
||||
|
this.submitdisabled = false |
||||
|
}) |
||||
|
} |
||||
|
}) |
||||
|
}, |
||||
|
handleReturn(isreload) { |
||||
|
if (isreload === 'true') this.$emit('reloadlist') |
||||
|
this.formobj = { |
||||
|
applyDeptName: '', |
||||
|
applyDeptSid: '', |
||||
|
billNo: '', |
||||
|
createByDate: '', |
||||
|
createByName: '', |
||||
|
createBySid: '', |
||||
|
finFundsCarriedForwardVehDetailsVos: [], |
||||
|
kxqrsImages: [], |
||||
|
orgSidPath: '', |
||||
|
purchaseSystem: '', |
||||
|
purchaseSystemSid: '', |
||||
|
remarks: '', |
||||
|
saleDeptName: '', |
||||
|
saleDeptSid: '', |
||||
|
sid: '', |
||||
|
source: '', |
||||
|
staffName: '', |
||||
|
staffSid: '', |
||||
|
useOrgName: '', |
||||
|
useOrgSid: '', |
||||
|
yxysFinFundsCarriedForwardYXYSKXVos: [] |
||||
|
} |
||||
|
this.listQuery = { |
||||
|
contractNo: '', |
||||
|
customerName: '', |
||||
|
customerPhone: '', |
||||
|
sids: [], |
||||
|
createBySid: '' |
||||
|
} |
||||
|
this.image_list1 = [] |
||||
|
this.dialogStatus = '' |
||||
|
this.submitdisabled = false |
||||
|
this.$refs['form_obj'].resetFields() |
||||
|
this.$emit('doback') |
||||
|
} |
||||
|
} |
||||
|
} |
||||
|
</script> |
||||
|
|
||||
|
<style scoped> |
||||
|
.titwu { |
||||
|
padding: 0; |
||||
|
} |
||||
|
.tableTitle{ |
||||
|
border: 1px solid #e0e3eb; |
||||
|
line-height: 42px; |
||||
|
text-align: center; |
||||
|
font-weight: bold; |
||||
|
font-size: 18px; |
||||
|
} |
||||
|
</style> |
@ -0,0 +1,214 @@ |
|||||
|
<template> |
||||
|
<div class="app-container"> |
||||
|
<div class="tab-header webtop"> |
||||
|
<div>{{ viewTitle }}</div> |
||||
|
<div> |
||||
|
<el-button type="info" size="small" @click="handleReturn()">关闭</el-button> |
||||
|
</div> |
||||
|
</div> |
||||
|
<div class="listconadd"> |
||||
|
<div class="titwu"><span>款项结转申请</span></div> |
||||
|
<el-form ref="form_obj" :model="formobj" :rules="rules" label-position="top" class="formadd"> |
||||
|
<el-row style="border-top: 1px solid #e0e3eb"> |
||||
|
<el-col :span="4" class="tleftb"> |
||||
|
<span>申请部门</span> |
||||
|
</el-col> |
||||
|
<el-col :span="4"> |
||||
|
<el-form-item> |
||||
|
<span>{{ formobj.applyDeptName }}</span> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="4" class="tleftb"> |
||||
|
<span>申请人</span> |
||||
|
</el-col> |
||||
|
<el-col :span="4"> |
||||
|
<el-form-item> |
||||
|
<span>{{ formobj.createByName }}</span> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="4" class="tleftb"> |
||||
|
<span>申请日期</span> |
||||
|
</el-col> |
||||
|
<el-col :span="4"> |
||||
|
<el-form-item> |
||||
|
<span>{{ formobj.createByDate }}</span> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="4" class="tleftb"> |
||||
|
<span>销售部门</span> |
||||
|
</el-col> |
||||
|
<el-col :span="4" class="trightb"> |
||||
|
<el-form-item> |
||||
|
<span>{{ formobj.saleDeptName }}</span> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="4" class="tleftb"> |
||||
|
<span>销售专员</span> |
||||
|
</el-col> |
||||
|
<el-col :span="4" class="trightb"> |
||||
|
<el-form-item> |
||||
|
<span>{{ formobj.staffName }}</span> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="4" class="tleftb"> |
||||
|
<span>来源</span> |
||||
|
</el-col> |
||||
|
<el-col :span="4"> |
||||
|
<el-form-item> |
||||
|
<span>{{ formobj.source }}</span> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="4" class="tleftb"> |
||||
|
<el-form-item><span>结转金额合计</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="20" class="trightb"> |
||||
|
<el-form-item> |
||||
|
<span>{{ formobj.jzjehj }}</span> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="4" class="tleftb"> |
||||
|
<el-form-item><span>款项确认书</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="20" class="trightb"> |
||||
|
<el-form-item> |
||||
|
<el-image v-for="(item, index) in formobj.kxqrsImages" :key="index" :src="item" :preview-src-list="formobj.kxqrsImages"/> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="4" class="tleftb"> |
||||
|
<span>备注</span> |
||||
|
</el-col> |
||||
|
<el-col :span="20" class="trightb"> |
||||
|
<el-form-item> |
||||
|
<span>{{ formobj.remarks }}</span> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-table border :key="tablebleKey" width="100%" :index="index" :data="formobj.finFundsCarriedForwardVehDetailsVos"> |
||||
|
<el-table-column fixed width="60" label="序号" type="index" :index="index + 1" align="center"/> |
||||
|
<el-table-column label="合同编号/收款单编号" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.busBillNo }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="客户名称/付款人" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.customerName }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="车架号" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.vinNo }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="剩余金额" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.balance }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="本次使用金额" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.thisUseMoney }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
</el-table> |
||||
|
<el-table border :key="selectedreceivableKey" style="width: 100%" :data="formobj.yxysFinFundsCarriedForwardYXYSKXVos"> |
||||
|
<el-table-column label="合同编号" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.contractId }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="车架号" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.vin }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="客户名称" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.name }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="联系电话" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.mobile }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="付款方式" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.payType }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="应收项目" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.projectName }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="当前应收" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.receivable }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="认款金额" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.confirmMoney }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="认款申请日期" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.confirmDate }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="状态" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.state == 1 ? '待审核' : scope.row.state == 2 ? '已驳回' : scope.row.state == 3 ? '已审核' : '其他' }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
</el-table> |
||||
|
</el-form> |
||||
|
</div> |
||||
|
</div> |
||||
|
</template> |
||||
|
|
||||
|
<script> |
||||
|
import { fetchDetails } from '@/api/moneycarriedforward/moneycarriedforward' |
||||
|
|
||||
|
export default { |
||||
|
name: 'MoneyCarriedForwardInfo', |
||||
|
data() { |
||||
|
return { |
||||
|
viewTitle: '', |
||||
|
selectedreceivableKey: 0, |
||||
|
tablebleKey: 1, |
||||
|
index: 0, |
||||
|
formobj: {}, |
||||
|
rules: {} |
||||
|
} |
||||
|
}, |
||||
|
methods: { |
||||
|
showInfo(row) { |
||||
|
this.viewTitle = '款项结转详情' |
||||
|
fetchDetails(row.sid).then(resp => { |
||||
|
if (resp.success) { |
||||
|
this.formobj = resp.data |
||||
|
} |
||||
|
}).catch(e => { |
||||
|
this.formobj = row |
||||
|
}) |
||||
|
}, |
||||
|
handleReturn() { |
||||
|
this.formobj = {} |
||||
|
this.$emit('doback') |
||||
|
} |
||||
|
} |
||||
|
} |
||||
|
</script> |
||||
|
|
||||
|
<style scoped> |
||||
|
</style> |
@ -0,0 +1,290 @@ |
|||||
|
<template> |
||||
|
<div class="app-container"> |
||||
|
<div v-show="viewState == 1"> |
||||
|
<button-bar view-title="简易订单订金可用" ref="btnbar" :btndisabled="btndisabled" @btnhandle="btnHandle"/> |
||||
|
<div class="main-content"> |
||||
|
<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" label-width="100px" class="tab-header"> |
||||
|
<el-form-item label="销售部门"> |
||||
|
<el-input v-model="listQuery.params.staffDeptName" placeholder="" clearable/> |
||||
|
</el-form-item> |
||||
|
<el-form-item label="销售专员"> |
||||
|
<el-input v-model="listQuery.params.staffName" placeholder="" clearable/> |
||||
|
</el-form-item> |
||||
|
<el-form-item label="收款单编号"> |
||||
|
<el-input v-model="listQuery.params.billNo" placeholder="" clearable/> |
||||
|
</el-form-item> |
||||
|
<el-form-item label="付款人"> |
||||
|
<el-input v-model="listQuery.params.payerName" placeholder="" clearable/> |
||||
|
</el-form-item> |
||||
|
<el-form-item label="联系电话"> |
||||
|
<el-input v-model="listQuery.params.phone" placeholder="" clearable/> |
||||
|
</el-form-item> |
||||
|
<el-form-item label="收款日期" class="searchlist"> |
||||
|
<el-date-picker value-format="yyyy-MM-dd" v-model="listQuery.params.collectionStartDate" clearable style="width: 160px" type="date" placeholder="开始日期"/> |
||||
|
<span style="padding: 0 8px">至</span> |
||||
|
<el-date-picker value-format="yyyy-MM-dd" v-model="listQuery.params.collectionEndDate" clearable style="width: 160px" type="date" placeholder="结束日期"/> |
||||
|
</el-form-item> |
||||
|
<el-form-item label="可用金额"> |
||||
|
<el-input v-model="listQuery.params.collectionSmallMoney" placeholder="" clearable style="width: 160px"/> |
||||
|
<span style="padding: 0 8px">至</span> |
||||
|
<el-input v-model="listQuery.params.collectionBigMoney" placeholder="" clearable style="width: 160px"/> |
||||
|
</el-form-item> |
||||
|
</el-form> |
||||
|
<div class="btn" style="text-align: center;"> |
||||
|
<el-button type="primary" icon="el-icon-search" size="small" @click="handleFilter">查询</el-button> |
||||
|
<el-button type="primary" icon="el-icon-refresh" size="small" @click="handReset">重置</el-button> |
||||
|
</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 width="50" type="selection" align="center"/> |
||||
|
<el-table-column width="80px" label="序号" type="index" :index="indexMethod" align="center"/> |
||||
|
<el-table-column label="分公司" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.useOrgName }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="销售部门" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.staffDeptName }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="销售专员" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.staffName }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="收款单编号" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.billNo }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="付款人" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.payerName }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="联系电话" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.phone }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="收款日期" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.collectionDate }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="认款金额" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.collectionMoney }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="剩余金额" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.balance }}</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> |
||||
|
</div> |
||||
|
<!-- 款项结转 --> |
||||
|
<moneycarriedforwardAdd v-show="viewState == 2" ref="divAdd" @doback="resetState" @reloadlist="getList"/> |
||||
|
</div> |
||||
|
</template> |
||||
|
|
||||
|
<script> |
||||
|
import { listPage } from '@/api/moneycarriedforward/moneycarriedforward' |
||||
|
import Pagination from '@/components/pagination' |
||||
|
import pageye from '@/components/pagination/pageye' |
||||
|
import ButtonBar from '@/components/ButtonBar' |
||||
|
import moneycarriedforwardAdd from './moneycarriedforwardAdd' |
||||
|
|
||||
|
export default { |
||||
|
name: 'SimpleDeposit', |
||||
|
components: { |
||||
|
Pagination, |
||||
|
pageye, |
||||
|
ButtonBar, |
||||
|
moneycarriedforwardAdd |
||||
|
}, |
||||
|
data() { |
||||
|
return { |
||||
|
isSearchShow: false, |
||||
|
btndisabled: false, |
||||
|
viewState: 1, |
||||
|
btnList: [ |
||||
|
{ |
||||
|
type: 'primary', |
||||
|
size: 'small', |
||||
|
icon: '', |
||||
|
btnKey: 'toCarryDown', |
||||
|
btnLabel: '款项结转申请' |
||||
|
}, |
||||
|
{ |
||||
|
type: 'primary', |
||||
|
size: 'small', |
||||
|
icon: '', |
||||
|
btnKey: 'toRefund', |
||||
|
btnLabel: '退款申请' |
||||
|
}, |
||||
|
{ |
||||
|
type: 'info', |
||||
|
size: 'small', |
||||
|
icon: 'cross', |
||||
|
btnKey: 'doClose', |
||||
|
btnLabel: '关闭' |
||||
|
} |
||||
|
], |
||||
|
searchxianshitit: '隐藏查询条件', |
||||
|
tableKey: 0, |
||||
|
list: [], |
||||
|
sids: [], |
||||
|
listLoading: false, |
||||
|
listQuery: { |
||||
|
current: 1, |
||||
|
size: 10, |
||||
|
params: { |
||||
|
collectionStartDate: '', |
||||
|
collectionEndDate: '', |
||||
|
staffDeptName: '', |
||||
|
staffName: '', |
||||
|
billNo: '', |
||||
|
phone: '', |
||||
|
payerName: '', |
||||
|
collectionSmallMoney: '', |
||||
|
collectionBigMoney: '', |
||||
|
menuUrl: '', |
||||
|
createBySid: '', |
||||
|
orgPath: '' |
||||
|
}, |
||||
|
total: 0 |
||||
|
} |
||||
|
} |
||||
|
}, |
||||
|
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 'toCarryDown': |
||||
|
this.toCarryDown() |
||||
|
break |
||||
|
case 'toRefund': |
||||
|
this.toRefund() |
||||
|
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 |
||||
|
}, |
||||
|
// 获取数据sid |
||||
|
handleSelectionChange(row) { |
||||
|
const aa = [] |
||||
|
row.forEach(element => { |
||||
|
aa.push(element.sid) |
||||
|
}) |
||||
|
this.sids = aa |
||||
|
console.log('获取sids数组', this.sids) |
||||
|
}, |
||||
|
// 查询列表信息 |
||||
|
getList() { |
||||
|
this.listLoading = true |
||||
|
this.listQuery.params.orgPath = window.sessionStorage.getItem('defaultOrgPath') |
||||
|
this.listQuery.params.createBySid = window.sessionStorage.getItem('userSid') |
||||
|
this.listQuery.params.menuUrl = this.$route.path |
||||
|
listPage(this.listQuery).then((response) => { |
||||
|
this.listLoading = false |
||||
|
if (response.success) { |
||||
|
this.listQuery.total = response.data.total |
||||
|
this.list = response.data.records |
||||
|
} else { |
||||
|
this.listQuery.total = 0 |
||||
|
this.list = [] |
||||
|
} |
||||
|
}) |
||||
|
}, |
||||
|
// 查询按钮 |
||||
|
handleFilter() { |
||||
|
this.listQuery.current = 1 |
||||
|
this.getList() |
||||
|
}, |
||||
|
handReset() { |
||||
|
this.listQuery = { |
||||
|
current: 1, |
||||
|
size: 10, |
||||
|
params: { |
||||
|
collectionStartDate: '', |
||||
|
collectionEndDate: '', |
||||
|
staffDeptName: '', |
||||
|
staffName: '', |
||||
|
billNo: '', |
||||
|
phone: '', |
||||
|
payerName: '', |
||||
|
collectionSmallMoney: '', |
||||
|
collectionBigMoney: '', |
||||
|
menuUrl: '', |
||||
|
createBySid: '', |
||||
|
orgPath: '' |
||||
|
}, |
||||
|
total: 0 |
||||
|
} |
||||
|
this.getList() |
||||
|
}, |
||||
|
toCarryDown() { |
||||
|
if (this.sids.length > 0) { |
||||
|
this.viewState = 2 |
||||
|
var title = '简易订单订金' |
||||
|
this.$refs['divAdd'].showAdd(title, this.sids) |
||||
|
} else { |
||||
|
this.$message({ showClose: true, type: 'error', message: '请至少选择一条记录进行款项结转申请操作' }) |
||||
|
} |
||||
|
}, |
||||
|
toRefund() {}, |
||||
|
resetState() { |
||||
|
this.viewState = 1 |
||||
|
}, |
||||
|
doClose() { |
||||
|
this.$store.dispatch('tagsView/delView', this.$route) |
||||
|
this.$router.go(-1) |
||||
|
} |
||||
|
} |
||||
|
} |
||||
|
</script> |
||||
|
<style scoped> |
||||
|
</style> |
@ -0,0 +1,413 @@ |
|||||
|
<template> |
||||
|
<div class="app-container"> |
||||
|
<div class="tab-header webtop"> |
||||
|
<div>{{ viewTitle }}</div> |
||||
|
<div> |
||||
|
<el-button type="primary" size="small" @click="openAgree('同意')">同 意</el-button> |
||||
|
<el-button type="danger" size="small" @click="openReject('驳回')">驳 回</el-button> |
||||
|
<el-button type="danger" size="small" @click="openStop('终止')">终 止</el-button> |
||||
|
</div> |
||||
|
</div> |
||||
|
<div class=""> |
||||
|
<div class="titwu"><span>款项结转申请</span></div> |
||||
|
<el-form ref="form_obj" :model="formobj" :rules="rules" label-position="top" class="formadd"> |
||||
|
<el-row style="border-top: 1px solid #e0e3eb"> |
||||
|
<el-col :span="4" class="tleftb"> |
||||
|
<span>申请部门</span> |
||||
|
</el-col> |
||||
|
<el-col :span="4"> |
||||
|
<el-form-item> |
||||
|
<span>{{ formobj.applyDeptName }}</span> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="4" class="tleftb"> |
||||
|
<span>申请人</span> |
||||
|
</el-col> |
||||
|
<el-col :span="4"> |
||||
|
<el-form-item> |
||||
|
<span>{{ formobj.createByName }}</span> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="4" class="tleftb"> |
||||
|
<span>申请日期</span> |
||||
|
</el-col> |
||||
|
<el-col :span="4"> |
||||
|
<el-form-item> |
||||
|
<span>{{ formobj.createByDate }}</span> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="4" class="tleftb"> |
||||
|
<span>销售部门</span> |
||||
|
</el-col> |
||||
|
<el-col :span="4" class="trightb"> |
||||
|
<el-form-item> |
||||
|
<span>{{ formobj.saleDeptName }}</span> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="4" class="tleftb"> |
||||
|
<span>销售专员</span> |
||||
|
</el-col> |
||||
|
<el-col :span="4" class="trightb"> |
||||
|
<el-form-item> |
||||
|
<span>{{ formobj.staffName }}</span> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="4" class="tleftb"> |
||||
|
<span>来源</span> |
||||
|
</el-col> |
||||
|
<el-col :span="4"> |
||||
|
<el-form-item> |
||||
|
<span>{{ formobj.source }}</span> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="4" class="tleftb"> |
||||
|
<el-form-item><span>结转金额合计</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="20" class="trightb"> |
||||
|
<el-form-item> |
||||
|
<span>{{ formobj.jzjehj }}</span> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="4" class="tleftb"> |
||||
|
<el-form-item><span>款项确认书</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="20" class="trightb"> |
||||
|
<el-form-item> |
||||
|
<el-image v-for="(item, index) in formobj.kxqrsImages" :key="index" :src="item" :preview-src-list="formobj.kxqrsImages"/> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="4" class="tleftb"> |
||||
|
<span>备注</span> |
||||
|
</el-col> |
||||
|
<el-col :span="20" class="trightb"> |
||||
|
<el-form-item> |
||||
|
<span>{{ formobj.remarks }}</span> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-table border :key="tablebleKey" width="100%" :index="index" :data="formobj.finFundsCarriedForwardVehDetailsVos"> |
||||
|
<el-table-column fixed width="60" label="序号" type="index" :index="index + 1" align="center"/> |
||||
|
<el-table-column label="合同编号/收款单编号" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.busBillNo }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="客户名称/付款人" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.customerName }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="车架号" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.vinNo }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="剩余金额" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.balance }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="本次使用金额" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.thisUseMoney }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
</el-table> |
||||
|
<el-table border :key="selectedreceivableKey" style="width: 100%" :data="formobj.yxysFinFundsCarriedForwardYXYSKXVos"> |
||||
|
<el-table-column label="合同编号" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.contractId }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="车架号" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.vin }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="客户名称" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.name }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="联系电话" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.mobile }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="付款方式" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.payType }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="应收项目" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.projectName }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="当前应收" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.receivable }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="认款金额" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.confirmMoney }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="认款申请日期" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.confirmDate }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="状态" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.state == 1 ? '待审核' : scope.row.state == 2 ? '已驳回' : scope.row.state == 3 ? '已审核' : '其他' }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
</el-table> |
||||
|
</el-form> |
||||
|
</div> |
||||
|
<!-- 选择待办人 的弹出框--> |
||||
|
<el-dialog title="选择待办人" :visible.sync="nodeDialogVisible" width="80%"> |
||||
|
<el-form label-position="right" class="formadd" > |
||||
|
<el-row v-show="currentLink" style="border-top: 1px solid #e0e3eb"> |
||||
|
<el-col :span="4" class="tleftb">当前环节</el-col> |
||||
|
<el-col :span="20"> |
||||
|
<el-form-item prop="purchasingUnitName"><span>{{ current.taskName }}->{{ nextNode.name }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row :class="{ rowClass:!currentLink }"> |
||||
|
<el-col :span="4" class="tleftb">意见</el-col> |
||||
|
<el-col :span="20"> |
||||
|
<el-form-item> |
||||
|
<el-input size="small" v-model="dialogList.comment" placeholder="审批意见" clearable ></el-input> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<div style="text-align:center;margin-top: 20px;"> |
||||
|
<el-button type="primary" size="mini" @click="reject">确 定</el-button> |
||||
|
<el-button type="info " size="mini" @click="nodeDialogVisible = false">取 消</el-button> |
||||
|
</div> |
||||
|
</el-form> |
||||
|
</el-dialog> |
||||
|
</div> |
||||
|
</template> |
||||
|
|
||||
|
<script> |
||||
|
import { fetchDetails, complete, reject,breakProcess, getPreviousNodesForReject, getNextNodesForSubmit } from '@/api/moneycarriedforward/moneycarriedforward' |
||||
|
|
||||
|
export default { |
||||
|
name: 'MoneyCarriedForwardDaiBanInfo', |
||||
|
data() { |
||||
|
return { |
||||
|
viewTitle: '', |
||||
|
selectedreceivableKey: 0, |
||||
|
tablebleKey: 1, |
||||
|
index: 0, |
||||
|
formobj: {}, |
||||
|
rules: {}, |
||||
|
dialogList: { |
||||
|
comment: '' |
||||
|
}, |
||||
|
operation: '', // 点击操作按钮 |
||||
|
current: { |
||||
|
taskDefKey: '', |
||||
|
taskName: '' // 当前环节名称 |
||||
|
}, |
||||
|
nextNode: {}, // 下一环节 |
||||
|
nodeDialogVisible: false, |
||||
|
currentLink: true, |
||||
|
// 环节所需参数 |
||||
|
linkByParameter: { |
||||
|
businessSid: '', |
||||
|
comment: '', |
||||
|
instanceId: '', |
||||
|
taskId: '', |
||||
|
orgSidPath: '', |
||||
|
taskDefKey: '', |
||||
|
userSid: '' |
||||
|
} |
||||
|
} |
||||
|
}, |
||||
|
created() { |
||||
|
console.log('url:' + window.location.href) |
||||
|
// ===获取参数 |
||||
|
var one = window.location.href.indexOf('&data') + 6 |
||||
|
const data = window.location.href.substr(one) // url解码unescape()已从web中移除,尽量不使用 |
||||
|
const obj = JSON.parse(decodeURIComponent(data)) |
||||
|
// 点击(同意、终止、驳回、驳回)操作时所需的参数 |
||||
|
this.linkByParameter.businessSid = obj.businessSid |
||||
|
this.linkByParameter.instanceId = obj.instanceId |
||||
|
this.linkByParameter.taskId = obj.taskId |
||||
|
this.linkByParameter.taskDefKey = obj.taskDefKey |
||||
|
this.linkByParameter.userSid = window.sessionStorage.getItem('userSid') |
||||
|
this.current.taskDefKey = obj.taskDefKey |
||||
|
this.current.taskName = obj.taskName |
||||
|
// 加载表单数据 |
||||
|
this.showInfo(obj.businessSid) |
||||
|
}, |
||||
|
mounted() { |
||||
|
window.parent.postMessage({ |
||||
|
cmd: 'returnHeight', |
||||
|
params: { |
||||
|
// 告诉父级页面,子页面的弹框高度。 |
||||
|
code: 2, |
||||
|
data: document.body.scrollHeight + 'px' |
||||
|
} |
||||
|
}, '*') |
||||
|
}, |
||||
|
methods: { |
||||
|
showInfo(sid) { |
||||
|
this.viewTitle = '款项结转详情' |
||||
|
fetchDetails(sid).then(resp => { |
||||
|
if (resp.success) { |
||||
|
this.formobj = resp.data |
||||
|
} |
||||
|
}).catch(e => { |
||||
|
this.formobj = {} |
||||
|
}) |
||||
|
}, |
||||
|
// 同意 |
||||
|
openAgree(val) { |
||||
|
this.operation = val |
||||
|
this.currentLink = true |
||||
|
this.dialogList.comment = '同意' |
||||
|
getNextNodesForSubmit({ taskDefKey: this.current.taskDefKey, businessSid: this.linkByParameter.businessSid }).then((resp) => { |
||||
|
if (resp.success) { |
||||
|
var arr = resp.data |
||||
|
this.nextNode = arr[0] |
||||
|
this.nodeDialogVisible = true |
||||
|
} |
||||
|
this.submitdisabled = false |
||||
|
}) |
||||
|
}, |
||||
|
// 驳回 |
||||
|
openReject(val) { |
||||
|
this.operation = val |
||||
|
this.currentLink = true |
||||
|
this.dialogList.comment = '' |
||||
|
getPreviousNodesForReject({ taskDefKey: this.current.taskDefKey, businessSid: this.linkByParameter.businessSid }).then((resp) => { |
||||
|
if (resp.success) { |
||||
|
var arr = resp.data |
||||
|
this.nextNode = arr[0] |
||||
|
this.nodeDialogVisible = true |
||||
|
} |
||||
|
this.submitdisabled = false |
||||
|
}) |
||||
|
}, |
||||
|
// 终止 |
||||
|
openStop(val) { |
||||
|
this.operation = val |
||||
|
this.dialogList.comment = '' |
||||
|
this.currentLink = false |
||||
|
this.nodeDialogVisible = true |
||||
|
}, |
||||
|
reject() { |
||||
|
if (this.operation === '同意') { |
||||
|
this.handleAgree() |
||||
|
} else if (this.operation === '驳回') { |
||||
|
if (this.dialogList.comment === '') { |
||||
|
this.$message({ showClose: true, type: 'error', message: '请填写审批意见' }) |
||||
|
} else { |
||||
|
this.handleReject() |
||||
|
} |
||||
|
} else if (this.operation === '终止') { |
||||
|
if (this.dialogList.comment === '') { |
||||
|
this.$message({ showClose: true, type: 'error', message: '请填写审批意见' }) |
||||
|
} else { |
||||
|
this.handleStop() |
||||
|
} |
||||
|
} |
||||
|
}, |
||||
|
/** 同意任务 */ |
||||
|
handleAgree() { |
||||
|
this.linkByParameter.comment = this.dialogList.comment |
||||
|
complete(this.linkByParameter).then((response) => { |
||||
|
if (response.success) { |
||||
|
this.$notify({ |
||||
|
title: '提示', |
||||
|
message: '执行成功', |
||||
|
type: 'success', |
||||
|
duration: 2000 |
||||
|
}) |
||||
|
this.nodeDialogVisible = false |
||||
|
// 子页面向父级页面传递值 |
||||
|
window.parent.postMessage({ |
||||
|
cmd: 'returnHeight', |
||||
|
params: { |
||||
|
// 操作成功,告诉父级页面关闭弹框 |
||||
|
code: 1 |
||||
|
} |
||||
|
}, '*') |
||||
|
} |
||||
|
}) |
||||
|
}, |
||||
|
/** 驳回任务 */ |
||||
|
handleReject() { |
||||
|
this.linkByParameter.comment = this.dialogList.comment |
||||
|
reject(this.linkByParameter).then((response) => { |
||||
|
if (response.success) { |
||||
|
this.$notify({ |
||||
|
title: '提示', |
||||
|
message: '执行成功', |
||||
|
type: 'success', |
||||
|
duration: 2000 |
||||
|
}) |
||||
|
this.nodeDialogVisible = false |
||||
|
// 子页面向父级页面传递值 |
||||
|
window.parent.postMessage({ |
||||
|
cmd: 'returnHeight', |
||||
|
params: { |
||||
|
// 操作成功,告诉父级页面关闭弹框 |
||||
|
code: 1 |
||||
|
} |
||||
|
}, '*') |
||||
|
} |
||||
|
}) |
||||
|
}, |
||||
|
/** 终止任务 */ |
||||
|
handleStop() { |
||||
|
this.linkByParameter.comment = this.dialogList.comment |
||||
|
console.log(this.stopList, 99999) |
||||
|
breakProcess(this.linkByParameter).then((response) => { |
||||
|
if (response.success) { |
||||
|
this.$notify({ |
||||
|
title: '提示', |
||||
|
message: '执行成功', |
||||
|
type: 'success', |
||||
|
duration: 2000 |
||||
|
}) |
||||
|
this.nodeDialogVisible = false |
||||
|
// 子页面向父级页面传递值 |
||||
|
window.parent.postMessage({ |
||||
|
cmd: 'returnHeight', |
||||
|
params: { |
||||
|
// 操作成功,告诉父级页面关闭弹框 |
||||
|
code: 1 |
||||
|
} |
||||
|
}, '*') |
||||
|
} |
||||
|
}) |
||||
|
} |
||||
|
} |
||||
|
} |
||||
|
</script> |
||||
|
|
||||
|
<style scoped> |
||||
|
.titwu { |
||||
|
font-size: 28px; |
||||
|
text-align: center; |
||||
|
padding: 30px 0 20px 0; |
||||
|
} |
||||
|
.rowClass { |
||||
|
border-top: 1px solid #e0e3eb; |
||||
|
} |
||||
|
</style> |
@ -0,0 +1,688 @@ |
|||||
|
<template> |
||||
|
<div class="app-container"> |
||||
|
<div v-show="viewState == 1"> |
||||
|
<div class="tab-header webtop"> |
||||
|
<div>{{ viewTitle }}</div> |
||||
|
<div> |
||||
|
<el-button type="primary" size="small" :disabled="submitdisabled" @click="saveOrUpdate()">保存 |
||||
|
</el-button> |
||||
|
<el-button type="primary" size="small" :disabled="submitdisabled" @click="submit()">提交 |
||||
|
</el-button> |
||||
|
</div> |
||||
|
</div> |
||||
|
<div class=""> |
||||
|
<div class="titwu"><span>款项结转申请</span></div> |
||||
|
<el-form ref="form_obj" :model="formobj" :rules="rules" label-position="top" class="formadd"> |
||||
|
<el-row style="border-top: 1px solid #e0e3eb"> |
||||
|
<el-col :span="4" class="tleftb"> |
||||
|
<span>申请部门</span> |
||||
|
</el-col> |
||||
|
<el-col :span="4"> |
||||
|
<el-form-item> |
||||
|
<span>{{ formobj.applyDeptName }}</span> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="4" class="tleftb"> |
||||
|
<span>申请人</span> |
||||
|
</el-col> |
||||
|
<el-col :span="4"> |
||||
|
<el-form-item> |
||||
|
<span>{{ formobj.createByName }}</span> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="4" class="tleftb"> |
||||
|
<span>申请日期</span> |
||||
|
</el-col> |
||||
|
<el-col :span="4"> |
||||
|
<el-form-item> |
||||
|
<span>{{ formobj.createByDate }}</span> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="4" class="tleftb"> |
||||
|
<span>销售部门</span> |
||||
|
</el-col> |
||||
|
<el-col :span="4"> |
||||
|
<el-form-item> |
||||
|
<span>{{ formobj.saleDeptName }}</span> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="4" class="tleftb"> |
||||
|
<span>销售专员</span> |
||||
|
</el-col> |
||||
|
<el-col :span="4"> |
||||
|
<el-form-item> |
||||
|
<span>{{ formobj.staffName }}</span> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="4" class="tleftb"> |
||||
|
<span>来源</span> |
||||
|
</el-col> |
||||
|
<el-col :span="4"> |
||||
|
<el-form-item> |
||||
|
<span>{{ formobj.source }}</span> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-table border :key="tablebleKey" width="100%" :index="index" :data="formobj.finFundsCarriedForwardVehDetailsVos"> |
||||
|
<el-table-column fixed width="60" label="序号" type="index" :index="index + 1" align="center"/> |
||||
|
<el-table-column fixed label="操作" align="center" width="80"> |
||||
|
<template slot-scope="scope"> |
||||
|
<el-button type="danger" size="small" @click="handleDelete(scope.$index)">删除</el-button> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="合同编号/收款单编号" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.busBillNo }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="客户名称/付款人" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.customerName }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="车架号" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.vinNo }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="剩余金额" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.balance }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="本次使用金额" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
<el-input v-model="scope.row.thisUseMoney" clearable placeholder=""/> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
</el-table> |
||||
|
<el-row> |
||||
|
<el-col :span="4" class="tleftb" style="display: flex;flex-direction: row;justify-content: flex-end;align-items: center"> |
||||
|
<span>款项确认书</span> |
||||
|
</el-col> |
||||
|
<el-col :span="20" class="trightb"> |
||||
|
<el-form-item> |
||||
|
<upload ref="uploadImg" v-model="image_list1" :accept="accept" :limit="50" bucket="map" :upload-data="{ type: '0001' }"/> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="4" class="tleftb"> |
||||
|
<span>备注</span> |
||||
|
</el-col> |
||||
|
<el-col :span="20" class="trightb"> |
||||
|
<el-form-item> |
||||
|
<el-input v-model="formobj.remarks" style="width: 70%" placeholder="" clearable/> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="24" style="padding: 0px"> |
||||
|
<el-form ref="listQueryform" :inline="true" :model="listQuery" class="tab-header"> |
||||
|
<el-form-item label="采购系统:"> |
||||
|
<el-select :disabled="dialogStatus == 'edit'" v-model="formobj.purchaseSystemSid" placeholder="请选择" @change="changePurchase" filterable clearable> |
||||
|
<el-option v-for="item in purchase_list" :key="item.deptSid" :label="item.purchaseSystemName" :value="item.deptSid"/> |
||||
|
</el-select> |
||||
|
</el-form-item> |
||||
|
<el-form-item label="合同编号:"> |
||||
|
<el-input v-model="listQuery.contractNo" size="mini" placeholder="" style="width: 110px" clearable/> |
||||
|
</el-form-item> |
||||
|
<el-form-item label="客户名称:"> |
||||
|
<el-input v-model="listQuery.customerName" size="mini" placeholder="" style="width: 100px" clearable/> |
||||
|
</el-form-item> |
||||
|
<el-form-item label="联系电话:"> |
||||
|
<el-input v-model="listQuery.customerPhone" size="mini" placeholder="" style="width: 140px" clearable/> |
||||
|
</el-form-item> |
||||
|
<el-form-item label="车架号:"> |
||||
|
<el-input v-model="listQuery.vinNo" size="mini" placeholder="" style="width: 140px" clearable/> |
||||
|
</el-form-item> |
||||
|
</el-form> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="24"> |
||||
|
<div style="display: flex;flex-direction: row;justify-content: space-between;align-items: center;padding-top: 5px"> |
||||
|
<div style="padding-left: 30%"> |
||||
|
<el-button type="primary" size="mini" @click="handleFilter">查询</el-button> |
||||
|
<el-button type="primary" size="mini" @click="handReset">重置</el-button> |
||||
|
<el-button type="primary" size="mini" @click="handleSelect">选择已认款项</el-button> |
||||
|
</div> |
||||
|
<div> |
||||
|
<span >余额:{{ balaceCount() }}</span> |
||||
|
</div> |
||||
|
</div> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="10"> |
||||
|
<div> |
||||
|
<div class="tableTitle">应收未收款款项明细</div> |
||||
|
<el-table border :key="overduereceivableKey" width="100%" :data="overduereceivable_list"> |
||||
|
<el-table-column fixed label="操作" align="center" width="80"> |
||||
|
<template slot-scope="scope"> |
||||
|
<el-button type="primary" size="small" @click="handAdd(scope.row)">添加</el-button> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="合同编号" align="center" width="100"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.contractNo }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="车架号" align="center" width="90"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.VIN }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="客户/电话" align="center" width="100"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.customerName }} {{ scope.row.customerPhone }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="付款" align="center" width="70"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.payType }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="应收金额" align="center" width="100"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.reveivableMoney }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="应收项目" align="center" width="90"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.receivablesName }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="当前应收" align="center" width="100"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.currentReceivableMoney }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
</el-table> |
||||
|
</div> |
||||
|
</el-col> |
||||
|
<el-col :span="14"> |
||||
|
<div> |
||||
|
<div class="tableTitle">已选应收款项明细</div> |
||||
|
<el-table border :key="selectedreceivableKey" width="100%" :data="formobj.yxysFinFundsCarriedForwardYXYSKXVos"> |
||||
|
<el-table-column fixed label="操作" align="center" width="70"> |
||||
|
<template slot-scope="scope"> |
||||
|
<el-button type="danger" size="small" @click="handDelete(scope.row)">移除</el-button> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="合同编号" align="center" width="95"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.contractId }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="车架号" align="center" width="90"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.vin }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="客户/电话" align="center" width="100"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.name }} {{ scope.row.mobile }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="付款" align="center" width="70"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.payType }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="应收项目" align="center" width="90"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.projectName }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="当前应收" align="center" width="100"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.receivable }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="认款金额" align="center" width="130"> |
||||
|
<template slot-scope="scope"> |
||||
|
<el-input v-model="scope.row.confirmMoney" @input="changeMoney(scope.row)" @keyup.native="UpNumber" @keydown.native="UpNumber" placeholder="" clearable/> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="剩余应收" align="center" width="100"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.surplusReceivable }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="认款申请日期" align="center" width="120"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.confirmDate }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
</el-table> |
||||
|
</div> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
</el-form> |
||||
|
</div> |
||||
|
</div> |
||||
|
<amountpledged v-show="viewState == 2" ref="divSelect" @doback="resetState" @backData="backData"/> |
||||
|
</div> |
||||
|
</template> |
||||
|
|
||||
|
<script> |
||||
|
import { saveOrUpdate, fetchDetails, submit } from '@/api/moneycarriedforward/moneycarriedforward' |
||||
|
import { listAll } from '@/api/anruifinmanagement/paymentConfirmation' |
||||
|
import amountpledged from './relation/amountpledged' |
||||
|
import { fetchDetailsByUseOrgSid, getOrgSidByPath } from '@/api/jichuxinxi/dictcommons' |
||||
|
import upload from '@/components/uploadFile/upload' |
||||
|
|
||||
|
export default { |
||||
|
name: 'MoneyCarriedForwardEdit', |
||||
|
components: { |
||||
|
upload, |
||||
|
amountpledged |
||||
|
}, |
||||
|
data() { |
||||
|
return { |
||||
|
viewTitle: '', |
||||
|
viewState: 1, |
||||
|
dialogStatus: '', |
||||
|
tablebleKey: 0, |
||||
|
index: 0, |
||||
|
overduereceivableKey: 1, |
||||
|
selectedreceivableKey: 2, |
||||
|
overduereceivable_list: [], |
||||
|
purchase_list: [], |
||||
|
image_list1: [], |
||||
|
accept: '.jpg,.jpeg,.png,.JPG,.JPEG', |
||||
|
formobj: { |
||||
|
applyDeptName: '', |
||||
|
applyDeptSid: '', |
||||
|
billNo: '', |
||||
|
createByDate: '', |
||||
|
createByName: '', |
||||
|
createBySid: '', |
||||
|
finFundsCarriedForwardVehDetailsVos: [], |
||||
|
kxqrsImages: [], |
||||
|
orgSidPath: '', |
||||
|
purchaseSystem: '', |
||||
|
purchaseSystemSid: '', |
||||
|
remarks: '', |
||||
|
saleDeptName: '', |
||||
|
saleDeptSid: '', |
||||
|
sid: '', |
||||
|
source: '', |
||||
|
staffName: '', |
||||
|
staffSid: '', |
||||
|
useOrgName: '', |
||||
|
useOrgSid: '', |
||||
|
yxysFinFundsCarriedForwardYXYSKXVos: [] |
||||
|
}, |
||||
|
listQuery: { |
||||
|
contractNo: '', |
||||
|
customerName: '', |
||||
|
customerPhone: '', |
||||
|
sids: [], |
||||
|
createBySid: '', |
||||
|
vinNo: '', |
||||
|
orgPath: '', |
||||
|
purchaseSystemSid: '' |
||||
|
}, |
||||
|
rules: {}, |
||||
|
submitdisabled: false, |
||||
|
} |
||||
|
}, |
||||
|
created() { |
||||
|
console.log('url:' + window.location.href) |
||||
|
var one = window.location.href.indexOf('&data') + 6 |
||||
|
const data = window.location.href.substr(one) // url解码unescape()已从web中移除,尽量不使用 |
||||
|
const obj = JSON.parse(decodeURIComponent(data)) |
||||
|
this.showInfo(obj.businessSid) |
||||
|
}, |
||||
|
mounted() { |
||||
|
window.parent.postMessage({ |
||||
|
cmd: 'returnHeight', |
||||
|
params: { |
||||
|
// 告诉父级页面,子页面的弹框高度。 |
||||
|
code: 2, |
||||
|
data: document.body.scrollHeight + 'px' |
||||
|
} |
||||
|
}, '*') |
||||
|
}, |
||||
|
methods: { |
||||
|
UpNumber(e) { |
||||
|
e.target.value = e.target.value.replace(/[^\d.]/g, '') // 清除“数字”和“.”"-"以外的字符 |
||||
|
e.target.value = e.target.value.replace(/^00/, '0.') // 开头不能有两个0 |
||||
|
e.target.value = e.target.value.replace(/\.{2,}/g, '.') // 只保留第一个. 清除多余的 |
||||
|
e.target.value = e.target.value.replace('.', '$#$').replace(/\./g, '').replace('$#$', '.') // 只保留第一个- |
||||
|
e.target.value = e.target.value.replace(/^(\-)*(\d+)\.(\d\d).*$/, '$1$2.$3') // 只能输入两个小数 |
||||
|
if (e.target.value.indexOf('.') < 0 && e.target.value !== '') { |
||||
|
// 以上已经过滤,此处控制的是如果没有小数点,首位不能为类似于 01、02的金额 |
||||
|
console.log(e.target.value) |
||||
|
e.target.value = parseFloat(e.target.value) |
||||
|
} |
||||
|
}, |
||||
|
// 已选明细表中计算剩余应收 |
||||
|
changeMoney(row) { |
||||
|
if (row.receivable !== '') { |
||||
|
row.surplusReceivable = parseFloat(row.receivable) - parseFloat(row.confirmMoney) |
||||
|
} else { |
||||
|
row.surplusReceivable = '' |
||||
|
} |
||||
|
}, |
||||
|
handleDelete(index) { |
||||
|
this.formobj.finFundsCarriedForwardVehDetailsVos.splice(index, 1) |
||||
|
}, |
||||
|
balaceCount() { |
||||
|
var money = '0' |
||||
|
if (this.formobj.finFundsCarriedForwardVehDetailsVos.length > 0) { |
||||
|
let useMoney = '0' |
||||
|
for (var i = 0; i < this.formobj.finFundsCarriedForwardVehDetailsVos.length; i++) { |
||||
|
if (this.formobj.finFundsCarriedForwardVehDetailsVos[i].thisUseMoney === '') { |
||||
|
useMoney = '1' |
||||
|
return |
||||
|
} |
||||
|
} |
||||
|
if (useMoney === '0') { |
||||
|
var list = [] |
||||
|
for (var b = 0; b < this.formobj.finFundsCarriedForwardVehDetailsVos.length; b++) { |
||||
|
list.push(this.formobj.finFundsCarriedForwardVehDetailsVos[b].thisUseMoney) |
||||
|
} |
||||
|
money = this.calculatedAmount(list) |
||||
|
} |
||||
|
} |
||||
|
if (this.formobj.yxysFinFundsCarriedForwardYXYSKXVos.length > 0) { |
||||
|
let confirmMoney = '0' |
||||
|
for (var p = 0; p < this.formobj.yxysFinFundsCarriedForwardYXYSKXVos.length; p++) { |
||||
|
if (this.formobj.yxysFinFundsCarriedForwardYXYSKXVos[p].confirmMoney === '') { |
||||
|
confirmMoney = '1' |
||||
|
return money |
||||
|
} |
||||
|
} |
||||
|
if (confirmMoney === '0') { |
||||
|
var list1 = [] |
||||
|
for (var l = 0; l < this.formobj.yxysFinFundsCarriedForwardYXYSKXVos.length; l++) { |
||||
|
list1.push(this.formobj.yxysFinFundsCarriedForwardYXYSKXVos[l].confirmMoney) |
||||
|
} |
||||
|
money = parseFloat(money) - parseFloat(this.calculatedAmount(list1)) |
||||
|
} |
||||
|
} |
||||
|
return money |
||||
|
}, |
||||
|
calculatedAmount(list) { |
||||
|
var sumNum = 0 |
||||
|
for (var k = 0; k < list.length; k++) { |
||||
|
// 替换掉字符串中的千分位分隔符并相加 |
||||
|
sumNum += Number(list[k].replace(/,/g, '')) |
||||
|
} |
||||
|
// 将总数四舍五入 |
||||
|
var f1 = Math.round(sumNum * 100) / 100 |
||||
|
// 转化为字符串 |
||||
|
var strNum = f1.toString() |
||||
|
// 将整数和小数点分割 |
||||
|
var rs = strNum.indexOf('.') |
||||
|
if (rs < 0) { |
||||
|
rs = strNum.length |
||||
|
strNum += '.' |
||||
|
} |
||||
|
while (strNum.length <= rs + 2) { |
||||
|
strNum += '0' |
||||
|
} |
||||
|
var resNum = strNum.replace(/\d+/, function(n) { |
||||
|
return n.replace(/(\d)(?=(\d{3})+$)/g, function(u) { |
||||
|
return u |
||||
|
}) |
||||
|
}) |
||||
|
return resNum |
||||
|
}, |
||||
|
getlist() { |
||||
|
if (this.formobj.purchaseSystemName === '') { |
||||
|
this.$message({ showClose: true, type: 'error', message: '请选择采购系统' }) |
||||
|
return |
||||
|
} |
||||
|
this.listQuery.createBySid = this.formobj.createBySid |
||||
|
this.listQuery.orgPath = this.formobj.orgSidPath |
||||
|
listAll(this.listQuery).then((res) => { |
||||
|
if (res.code === '200') { |
||||
|
this.overduereceivable_list = res.data |
||||
|
} |
||||
|
}) |
||||
|
}, |
||||
|
handleFilter() { |
||||
|
this.getlist() |
||||
|
}, |
||||
|
changePurchase(value) { |
||||
|
if (this.formobj.finFundsCarriedForwardVehDetailsVos.length > 0) { |
||||
|
for (var i = 0; i < this.formobj.finFundsCarriedForwardVehDetailsVos.length; i++) { |
||||
|
if (this.formobj.finFundsCarriedForwardVehDetailsVos[i].thisUseMoney === '') { |
||||
|
this.$message({ showClose: true, type: 'error', message: '请检查本次使用金额是否已全部填写' }) |
||||
|
this.formobj.purchaseSystemSid = '' |
||||
|
return |
||||
|
} |
||||
|
} |
||||
|
} |
||||
|
if (value !== '') { |
||||
|
const choose = this.purchase_list.filter((item) => item.deptSid === value) |
||||
|
this.formobj.purchaseSystem = choose[0].purchaseSystemName |
||||
|
this.listQuery.purchaseSystemSid = this.formobj.purchaseSystemSid |
||||
|
this.getlist() |
||||
|
} else { |
||||
|
this.overduereceivable_list = [] |
||||
|
} |
||||
|
}, |
||||
|
handReset() { |
||||
|
this.listQuery.contractNo = '' |
||||
|
this.listQuery.customerName = '' |
||||
|
this.listQuery.customerPhone = '' |
||||
|
this.listQuery.vinNo = '' |
||||
|
this.listQuery.createBySid = '' |
||||
|
this.listQuery.orgPath = '' |
||||
|
this.getlist() |
||||
|
}, |
||||
|
showInfo(sid) { |
||||
|
this.viewTitle = '【编辑】款项结转' |
||||
|
this.dialogStatus = 'edit' |
||||
|
fetchDetails(sid).then(resp => { |
||||
|
if (resp.success) { |
||||
|
this.formobj = resp.data |
||||
|
this.formobj.instanceId = resp.data.procInsId |
||||
|
getOrgSidByPath({ orgPath: this.formobj.orgSidPath }).then((res) => { |
||||
|
fetchDetailsByUseOrgSid(res.data).then((resp) => { |
||||
|
if (resp.success) { |
||||
|
this.purchase_list = resp.data |
||||
|
} |
||||
|
}) |
||||
|
}) |
||||
|
if (this.formobj.kxqrsImages !== null && this.formobj.kxqrsImages.length >0) { |
||||
|
this.formobj.kxqrsImages.forEach((e) => { |
||||
|
this.image_list1.push({ |
||||
|
name: '', |
||||
|
url: e |
||||
|
}) |
||||
|
}) |
||||
|
} |
||||
|
if (this.formobj.purchaseSystem !== '') { |
||||
|
this.listQuery.purchaseSystemSid = this.formobj.purchaseSystemSid |
||||
|
this.getlist() |
||||
|
} |
||||
|
this.$nextTick(() => { |
||||
|
this.$refs['form_obj'].clearValidate() |
||||
|
}) |
||||
|
} |
||||
|
}).catch(e => { |
||||
|
this.formobj = {} |
||||
|
}) |
||||
|
}, |
||||
|
// 应收未收明细表添加数据到已选应收明细表 |
||||
|
handAdd(row) { |
||||
|
if (this.formobj.collectionMoney === '') { |
||||
|
this.$message({ showClose: true, type: 'error', message: '请先填写收款金额' }) |
||||
|
} else { |
||||
|
var nowDate = new Date() |
||||
|
var date = { |
||||
|
year: nowDate.getFullYear(), |
||||
|
month: nowDate.getMonth() + 1, |
||||
|
day: nowDate.getDate() |
||||
|
} |
||||
|
var dayDate = date.year + '-' + (date.month >= 10 ? date.month : '0' + date.month) + '-' + (date.day >= 10 ? date.day : '0' + date.day) |
||||
|
this.formobj.yxysFinFundsCarriedForwardYXYSKXVos.push({ |
||||
|
createByName: window.sessionStorage.getItem('name'), |
||||
|
contractSid: row.contractSid, |
||||
|
contractId: row.contractNo, |
||||
|
customerSid: row.customerSid, |
||||
|
name: row.customerName, |
||||
|
vin: row.VIN, |
||||
|
useOrgSid: '', |
||||
|
mobile: row.customerPhone, |
||||
|
projectName: row.receivablesName, |
||||
|
receivable: row.currentReceivableMoney, |
||||
|
lastSubscriptionMoney: '', |
||||
|
confirmMoney: '', |
||||
|
surplusReceivable: '', |
||||
|
subscribedOf: row.subscribedOf, |
||||
|
confirmDate: dayDate, |
||||
|
collSid: '', |
||||
|
receivablesSid: row.receivablesSid, |
||||
|
payType: row.payType, |
||||
|
payTypeKey: row.payTypeKey, |
||||
|
sid: row.sid |
||||
|
}) |
||||
|
this.listQuery.sids.push(row.sid) |
||||
|
this.balaceCount() |
||||
|
this.getlist() |
||||
|
} |
||||
|
}, |
||||
|
// 已选应收明细表移除 |
||||
|
handDelete(row) { |
||||
|
this.formobj.yxysFinFundsCarriedForwardYXYSKXVos.splice(this.formobj.yxysFinFundsCarriedForwardYXYSKXVos.indexOf(row), 1) |
||||
|
if (row.subscribedOf == 0) { |
||||
|
this.listQuery.sids.splice(this.listQuery.sids.indexOf(row.sid), 1) |
||||
|
this.getlist() |
||||
|
} |
||||
|
}, |
||||
|
// 跳转选择已认款项列表 |
||||
|
handleSelect() { |
||||
|
if (this.formobj.purchaseSystemSid === '') { |
||||
|
this.$message({ showClose: true, type: 'error', message: '请先选择采购系统' }) |
||||
|
return |
||||
|
} |
||||
|
this.viewState = 2 |
||||
|
this.$refs['divSelect'].showData(this.formobj.yxysFinFundsCarriedForwardYXYSKXVos, this.formobj.purchaseSystemSid) |
||||
|
}, |
||||
|
// 跳转选择已认款项列表--选择数据后返回 |
||||
|
backData(val) { |
||||
|
this.viewState = 1 |
||||
|
var nowDate = new Date() |
||||
|
var date = { |
||||
|
year: nowDate.getFullYear(), |
||||
|
month: nowDate.getMonth() + 1, |
||||
|
day: nowDate.getDate() |
||||
|
} |
||||
|
var dayDate = date.year + '-' + (date.month >= 10 ? date.month : '0' + date.month) + '-' + (date.day >= 10 ? date.day : '0' + date.day) |
||||
|
for (var i = 0; i < val.length; i++) { |
||||
|
this.formobj.yxysFinFundsCarriedForwardYXYSKXVos.push({ |
||||
|
createByName: window.sessionStorage.getItem('name'), |
||||
|
contractSid: val[i].contractSid, |
||||
|
contractId: val[i].contractNo, |
||||
|
customerSid: val[i].customerSid, |
||||
|
name: val[i].customerName, |
||||
|
vin: val[i].VIN, |
||||
|
useOrgSid: '', |
||||
|
mobile: val[i].customerPhone, |
||||
|
projectName: val[i].receivablesName, |
||||
|
receivable: val[i].currentReceivableMoney, |
||||
|
lastSubscriptionMoney: '', |
||||
|
confirmMoney: '', |
||||
|
surplusReceivable: '', |
||||
|
subscribedOf: val[i].subscribedOf, |
||||
|
confirmDate: dayDate, |
||||
|
collSid: '', |
||||
|
receivablesSid: val[i].sid, |
||||
|
payType: val[i].payType, |
||||
|
payTypeKey: val[i].payTypeKey, |
||||
|
sid: val[i].sid |
||||
|
}) |
||||
|
} |
||||
|
}, |
||||
|
resetState() { |
||||
|
this.viewState = 1 |
||||
|
}, |
||||
|
saveOrUpdate() { |
||||
|
if (this.image_list1.length > 0) { |
||||
|
var aa = [] |
||||
|
for (var i = 0; i < this.image_list1.length; i++) { |
||||
|
aa.push(this.image_list1[i].url) |
||||
|
} |
||||
|
this.formobj.kxqrsImages = aa |
||||
|
} |
||||
|
this.$refs['form_obj'].validate((valid) => { |
||||
|
if (valid) { |
||||
|
this.submitdisabled = true |
||||
|
saveOrUpdate(this.formobj).then((resp) => { |
||||
|
if (resp.success) { |
||||
|
this.$message({ showClose: true, type: 'success', message: resp.msg }) |
||||
|
// 子页面向父级页面传递值 |
||||
|
window.parent.postMessage({ |
||||
|
cmd: 'returnHeight', |
||||
|
params: { |
||||
|
// 操作成功,告诉父级页面关闭弹框 |
||||
|
code: 1 |
||||
|
} |
||||
|
}, '*') |
||||
|
} else { |
||||
|
this.submitdisabled = false |
||||
|
} |
||||
|
}).catch(() => { |
||||
|
this.submitdisabled = false |
||||
|
}) |
||||
|
} |
||||
|
}) |
||||
|
}, |
||||
|
submit() { |
||||
|
if (this.image_list1.length > 0) { |
||||
|
var aa = [] |
||||
|
for (var i = 0; i < this.image_list1.length; i++) { |
||||
|
aa.push(this.image_list1[i].url) |
||||
|
} |
||||
|
this.formobj.kxqrsImages = aa |
||||
|
} |
||||
|
this.$refs['form_obj'].validate((valid) => { |
||||
|
if (valid) { |
||||
|
this.submitdisabled = true |
||||
|
submit(this.formobj).then((resp) => { |
||||
|
if (resp.success) { |
||||
|
this.$message({ showClose: true, type: 'success', message: resp.msg }) |
||||
|
// 子页面向父级页面传递值 |
||||
|
window.parent.postMessage({ |
||||
|
cmd: 'returnHeight', |
||||
|
params: { |
||||
|
// 操作成功,告诉父级页面关闭弹框 |
||||
|
code: 1 |
||||
|
} |
||||
|
}, '*') |
||||
|
} else { |
||||
|
this.submitdisabled = false |
||||
|
} |
||||
|
}).catch(() => { |
||||
|
this.submitdisabled = false |
||||
|
}) |
||||
|
} |
||||
|
}) |
||||
|
} |
||||
|
} |
||||
|
} |
||||
|
</script> |
||||
|
|
||||
|
<style scoped> |
||||
|
.titwu { |
||||
|
font-size: 28px; |
||||
|
text-align: center; |
||||
|
padding: 30px 0 20px 0; |
||||
|
} |
||||
|
.tableTitle{ |
||||
|
border: 1px solid #e0e3eb; |
||||
|
line-height: 42px; |
||||
|
text-align: center; |
||||
|
font-weight: bold; |
||||
|
font-size: 18px; |
||||
|
} |
||||
|
</style> |
@ -0,0 +1,287 @@ |
|||||
|
<template> |
||||
|
<div class="app-container"> |
||||
|
<div class="tab-header webtop"> |
||||
|
<div>{{ viewTitle }}</div> |
||||
|
<div> |
||||
|
<el-button type="danger" size="small" @click="openRevoke()">撤回 </el-button> |
||||
|
</div> |
||||
|
</div> |
||||
|
<div class=""> |
||||
|
<div class="titwu"><span>款项结转申请</span></div> |
||||
|
<el-form ref="form_obj" :model="formobj" :rules="rules" label-position="top" class="formadd"> |
||||
|
<el-row style="border-top: 1px solid #e0e3eb"> |
||||
|
<el-col :span="4" class="tleftb"> |
||||
|
<span>申请部门</span> |
||||
|
</el-col> |
||||
|
<el-col :span="4"> |
||||
|
<el-form-item> |
||||
|
<span>{{ formobj.applyDeptName }}</span> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="4" class="tleftb"> |
||||
|
<span>申请人</span> |
||||
|
</el-col> |
||||
|
<el-col :span="4"> |
||||
|
<el-form-item> |
||||
|
<span>{{ formobj.createByName }}</span> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="4" class="tleftb"> |
||||
|
<span>申请日期</span> |
||||
|
</el-col> |
||||
|
<el-col :span="4"> |
||||
|
<el-form-item> |
||||
|
<span>{{ formobj.createByDate }}</span> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="4" class="tleftb"> |
||||
|
<span>销售部门</span> |
||||
|
</el-col> |
||||
|
<el-col :span="4" class="trightb"> |
||||
|
<el-form-item> |
||||
|
<span>{{ formobj.saleDeptName }}</span> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="4" class="tleftb"> |
||||
|
<span>销售专员</span> |
||||
|
</el-col> |
||||
|
<el-col :span="4" class="trightb"> |
||||
|
<el-form-item> |
||||
|
<span>{{ formobj.staffName }}</span> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="4" class="tleftb"> |
||||
|
<span>来源</span> |
||||
|
</el-col> |
||||
|
<el-col :span="4"> |
||||
|
<el-form-item> |
||||
|
<span>{{ formobj.source }}</span> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="4" class="tleftb"> |
||||
|
<el-form-item><span>结转金额合计</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="20" class="trightb"> |
||||
|
<el-form-item> |
||||
|
<span>{{ formobj.jzjehj }}</span> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="4" class="tleftb"> |
||||
|
<el-form-item><span>款项确认书</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="20" class="trightb"> |
||||
|
<el-form-item> |
||||
|
<el-image v-for="(item, index) in formobj.kxqrsImages" :key="index" :src="item" :preview-src-list="formobj.kxqrsImages"/> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="4" class="tleftb"> |
||||
|
<span>备注</span> |
||||
|
</el-col> |
||||
|
<el-col :span="20" class="trightb"> |
||||
|
<el-form-item> |
||||
|
<span>{{ formobj.remarks }}</span> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-table border :key="tablebleKey" width="100%" :index="index" :data="formobj.finFundsCarriedForwardVehDetailsVos"> |
||||
|
<el-table-column fixed width="60" label="序号" type="index" :index="index + 1" align="center"/> |
||||
|
<el-table-column label="合同编号/收款单编号" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.busBillNo }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="客户名称/付款人" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.customerName }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="车架号" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.vinNo }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="剩余金额" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.balance }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="本次使用金额" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.thisUseMoney }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
</el-table> |
||||
|
<el-table border :key="selectedreceivableKey" style="width: 100%" :data="formobj.yxysFinFundsCarriedForwardYXYSKXVos"> |
||||
|
<el-table-column label="合同编号" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.contractId }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="车架号" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.vin }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="客户名称" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.name }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="联系电话" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.mobile }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="付款方式" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.payType }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="应收项目" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.projectName }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="当前应收" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.receivable }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="认款金额" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.confirmMoney }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="认款申请日期" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.confirmDate }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="状态" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
{{ scope.row.state == 1 ? '待审核' : scope.row.state == 2 ? '已驳回' : scope.row.state == 3 ? '已审核' : '其他' }} |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
</el-table> |
||||
|
</el-form> |
||||
|
</div> |
||||
|
</div> |
||||
|
</template> |
||||
|
|
||||
|
<script> |
||||
|
import { fetchDetails, revokeProcess } from '@/api/moneycarriedforward/moneycarriedforward' |
||||
|
|
||||
|
export default { |
||||
|
name: 'MoneyCarriedForwardYiBanInfo', |
||||
|
data() { |
||||
|
return { |
||||
|
viewTitle: '', |
||||
|
selectedreceivableKey: 0, |
||||
|
tablebleKey: 1, |
||||
|
index: 0, |
||||
|
formobj: {}, |
||||
|
rules: {}, |
||||
|
// 环节所需参数 |
||||
|
linkByParameter: { |
||||
|
businessSid: '', |
||||
|
comment: '', |
||||
|
instanceId: '', |
||||
|
taskId: '', |
||||
|
orgSidPath: '', |
||||
|
taskDefKey: '', |
||||
|
userSid: '' |
||||
|
} |
||||
|
} |
||||
|
}, |
||||
|
created() { |
||||
|
console.log('url:' + window.location.href) |
||||
|
// ===获取参数 |
||||
|
var one = window.location.href.indexOf('&data') + 6 |
||||
|
const data = window.location.href.substr(one) // url解码unescape()已从web中移除,尽量不使用 |
||||
|
const obj = JSON.parse(decodeURIComponent(data)) |
||||
|
// 点击(同意、终止、驳回、驳回)操作时所需的参数 |
||||
|
this.linkByParameter.businessSid = obj.businessSid |
||||
|
this.linkByParameter.instanceId = obj.instanceId |
||||
|
this.linkByParameter.taskId = obj.taskId |
||||
|
this.linkByParameter.taskDefKey = obj.taskDefKey |
||||
|
this.linkByParameter.orgSidPath = window.sessionStorage.getItem('orgSidPath') |
||||
|
this.linkByParameter.userSid = window.sessionStorage.getItem('userSid') |
||||
|
// 加载表单数据 |
||||
|
this.showInfo(obj.businessSid) |
||||
|
}, |
||||
|
mounted() { |
||||
|
window.parent.postMessage({ |
||||
|
cmd: 'returnHeight', |
||||
|
params: { |
||||
|
// 告诉父级页面,子页面的弹框高度。 |
||||
|
code: 2, |
||||
|
data: document.body.scrollHeight + 'px' |
||||
|
} |
||||
|
}, '*') |
||||
|
}, |
||||
|
methods: { |
||||
|
showInfo(sid) { |
||||
|
this.viewTitle = '款项结转详情' |
||||
|
fetchDetails(sid).then(resp => { |
||||
|
if (resp.success) { |
||||
|
this.formobj = resp.data |
||||
|
} |
||||
|
}).catch(e => { |
||||
|
this.formobj = {} |
||||
|
}) |
||||
|
}, |
||||
|
/** 确认撤回任务 */ |
||||
|
openRevoke() { |
||||
|
this.$confirm('是否确认执行撤回操作', '提示', { |
||||
|
confirmButtonText: '确定', |
||||
|
cancelButtonText: '取消', |
||||
|
type: 'warning' |
||||
|
}).then(() => { |
||||
|
this.handleRevoke() |
||||
|
}).catch(() => { |
||||
|
this.$message({ |
||||
|
type: 'info', |
||||
|
message: '已取消撤回' |
||||
|
}) |
||||
|
}) |
||||
|
}, |
||||
|
/** 撤回任务 */ |
||||
|
handleRevoke() { |
||||
|
revokeProcess(this.linkByParameter).then((response) => { |
||||
|
if (response.success) { |
||||
|
this.$notify({ |
||||
|
title: '提示', |
||||
|
message: '执行成功', |
||||
|
type: 'success', |
||||
|
duration: 2000 |
||||
|
}) |
||||
|
// 子页面向父级页面传递值 |
||||
|
window.parent.postMessage({ |
||||
|
cmd: 'returnHeight', |
||||
|
params: { |
||||
|
// 操作成功,告诉父级页面关闭弹框 |
||||
|
code: 1 |
||||
|
} |
||||
|
}, '*') |
||||
|
} |
||||
|
}) |
||||
|
} |
||||
|
} |
||||
|
} |
||||
|
</script> |
||||
|
|
||||
|
<style scoped> |
||||
|
.titwu { |
||||
|
font-size: 28px; |
||||
|
text-align: center; |
||||
|
padding: 30px 0 20px 0; |
||||
|
} |
||||
|
</style> |
@ -0,0 +1,232 @@ |
|||||
|
<template> |
||||
|
<div class="app-container"> |
||||
|
<div> |
||||
|
<div class="tab-header webtop"> |
||||
|
<div>已认款完成的车款或首付款及费用</div> |
||||
|
<div> |
||||
|
<el-button type="primary" size="small" @click="AddUpdateReturn">确定</el-button> |
||||
|
<el-button type="info" size="small" @click="handleReturn()">关闭</el-button> |
||||
|
</div> |
||||
|
</div> |
||||
|
<div class=""> |
||||
|
<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.contractNo" placeholder="" clearable class="filter-item"/> |
||||
|
</el-form-item> |
||||
|
<el-form-item label="客户名称"> |
||||
|
<el-input v-model="listQuery.params.customerName" placeholder="" clearable class="filter-item"/> |
||||
|
</el-form-item> |
||||
|
<el-form-item label="联系电话"> |
||||
|
<el-input v-model="listQuery.params.mobile" placeholder="" clearable class="filter-item"/> |
||||
|
</el-form-item> |
||||
|
<el-form-item label="车架号"> |
||||
|
<el-input v-model="listQuery.params.vinNo" placeholder="" clearable class="filter-item"/> |
||||
|
</el-form-item> |
||||
|
</el-form> |
||||
|
<div class="btn" style="text-align: center"> |
||||
|
<el-button type="primary" icon="el-icon-search" size="small" @click="handleFilter">查询</el-button> |
||||
|
<el-button type="primary" icon="el-icon-refresh" size="small" @click="handresetting">重置</el-button> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
<div class=""> |
||||
|
<el-table :key="tableKey" ref="multipleTable" v-loading="listLoading" :data="list" border style="width: 100%" @selection-change="handleSelectionChange"> |
||||
|
<el-table-column width="50px" type="selection" align="center"/> |
||||
|
<el-table-column width="80px" label="编号" type="index" :index="indexMethod" align="center"/> |
||||
|
<el-table-column label="合同编号" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.contractNo }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="车架号" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.VIN }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="客户/电话" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.customerName }}/{{ scope.row.customerPhone }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="销售类型" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.payType }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="应收项目" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.receivablesName }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="当前应收" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.currentReceivableMoney }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="认款金额" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.subscriptionMoney }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="剩余应收" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.reveivableMoney }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column label="认款申请日期" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span>{{ scope.row.subscriptionDate }}</span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
</el-table> |
||||
|
</div> |
||||
|
<div class="pages"> |
||||
|
<div class="tit"/> |
||||
|
<!-- 翻页 --> |
||||
|
<pagination v-show="list.length > 0" :total="listQuery.total" :page.sync="listQuery.current" :limit.sync="listQuery.size" class="pagination" @pagination="getList"/> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
</template> |
||||
|
|
||||
|
<script> |
||||
|
import Pagination from '@/components/pagination' |
||||
|
import { selectPageList } from '@/api/anruifinmanagement/paymentConfirmation.js' |
||||
|
export default { |
||||
|
name: 'AmountPledged', |
||||
|
components: { |
||||
|
Pagination |
||||
|
}, |
||||
|
data() { |
||||
|
return { |
||||
|
isSearchShow: false, |
||||
|
searchxianshitit: '隐藏查询条件', |
||||
|
tableKey: 0, |
||||
|
sids: [], |
||||
|
list: [], |
||||
|
listLoading: false, |
||||
|
listQuery: { |
||||
|
current: 1, |
||||
|
size: 10, |
||||
|
params: { |
||||
|
contractNo: '', |
||||
|
customerName: '', |
||||
|
mobile: '', |
||||
|
orgPath: '', |
||||
|
userSid: '', |
||||
|
purchaseSystemSid: '', |
||||
|
vinNo: '', |
||||
|
sids: [] |
||||
|
}, |
||||
|
total: 0 |
||||
|
} |
||||
|
} |
||||
|
}, |
||||
|
methods: { |
||||
|
// 搜索条件效果 |
||||
|
clicksearchShow() { |
||||
|
this.isSearchShow = !this.isSearchShow |
||||
|
if (this.isSearchShow) { |
||||
|
this.searchxianshitit = '隐藏查询条件' |
||||
|
} else { |
||||
|
this.searchxianshitit = '显示查询条件' |
||||
|
} |
||||
|
}, |
||||
|
indexMethod(index) { |
||||
|
var pagestart = (this.listQuery.current - 1) * this.listQuery.size |
||||
|
var pageindex = index + 1 + pagestart |
||||
|
return pageindex |
||||
|
}, |
||||
|
// 返回 |
||||
|
handleReturn() { |
||||
|
this.$emit('doback') |
||||
|
}, |
||||
|
// 查询列表信息 |
||||
|
getList() { |
||||
|
this.listLoading = true |
||||
|
this.listQuery.params.userSid = window.sessionStorage.getItem('userSid') |
||||
|
this.listQuery.params.orgPath = window.sessionStorage.getItem('defaultOrgPath') |
||||
|
selectPageList(this.listQuery).then((response) => { |
||||
|
this.listLoading = false |
||||
|
if (response.success) { |
||||
|
this.listQuery.total = response.data.total |
||||
|
this.list = response.data.records |
||||
|
} |
||||
|
}) |
||||
|
}, |
||||
|
// 查询按钮 |
||||
|
handleFilter() { |
||||
|
this.getList() |
||||
|
}, |
||||
|
// 重置按钮 |
||||
|
handresetting() { |
||||
|
this.listQuery.params.contractNo = '' |
||||
|
this.listQuery.params.customerName = '' |
||||
|
this.listQuery.params.mobile = '' |
||||
|
this.listQuery.params.vinNo = '' |
||||
|
this.listQuery.params.orgPath = '' |
||||
|
this.listQuery.params.userSid = '' |
||||
|
this.listQuery.current = 1 |
||||
|
this.listQuery.size = 5 |
||||
|
this.listQuery.total = 0 |
||||
|
this.getList() |
||||
|
}, |
||||
|
handleSelectionChange(row) { |
||||
|
this.sids = [] |
||||
|
const aa = [] |
||||
|
row.forEach((element) => { |
||||
|
aa.push({ |
||||
|
contractSid: element.contractSid, |
||||
|
contractNo: element.contractNo, |
||||
|
customerSid: element.customerSid, |
||||
|
customerName: element.customerName, |
||||
|
customerPhone: element.customerPhone, |
||||
|
receivablesName: element.receivablesName, |
||||
|
currentReceivableMoney: element.currentReceivableMoney, |
||||
|
subscribedOf: element.subscribedOf, |
||||
|
sid: element.sid, |
||||
|
VIN: element.VIN, |
||||
|
payType: element.payType, |
||||
|
payTypeKey: element.payTypeKey |
||||
|
}) |
||||
|
}) |
||||
|
this.sids = aa |
||||
|
}, |
||||
|
showData(value, purchaseSystemSid) { |
||||
|
const aa = [] |
||||
|
if (value.length > 0) { |
||||
|
for (var i = 0; i < value.length; i++) { |
||||
|
aa.push(value[i].sid) |
||||
|
} |
||||
|
this.listQuery.params.sids = aa |
||||
|
} else { |
||||
|
this.listQuery.params.sids = [] |
||||
|
} |
||||
|
this.listQuery.current = 1 |
||||
|
this.listQuery.total = 0 |
||||
|
this.listQuery.size = 5 |
||||
|
this.listQuery.params.purchaseSystemSid = purchaseSystemSid |
||||
|
this.getList() |
||||
|
}, |
||||
|
// 添加修改返回 |
||||
|
AddUpdateReturn() { |
||||
|
if (this.sids.length > 0) { |
||||
|
this.$emit('backData', this.sids) |
||||
|
} else { |
||||
|
this.$notify({ |
||||
|
title: '提示', |
||||
|
message: '请选择至少一条记录!', |
||||
|
type: 'error', |
||||
|
duration: 2000 |
||||
|
}) |
||||
|
} |
||||
|
} |
||||
|
} |
||||
|
} |
||||
|
</script> |
||||
|
<style scoped> |
||||
|
</style> |
@ -0,0 +1,19 @@ |
|||||
|
package com.yxt.anrui.portal.api.sysuser; |
||||
|
|
||||
|
import lombok.Data; |
||||
|
|
||||
|
import java.util.ArrayList; |
||||
|
import java.util.List; |
||||
|
|
||||
|
/** |
||||
|
* @description: |
||||
|
* @author: dimengzhe |
||||
|
* @date: 2023/7/10 |
||||
|
**/ |
||||
|
@Data |
||||
|
public class UserssQuery { |
||||
|
|
||||
|
private List<String> candidateGroups = new ArrayList<>(); |
||||
|
|
||||
|
private String orgSidPath; |
||||
|
} |
@ -0,0 +1,18 @@ |
|||||
|
package com.yxt.anrui.riskcenter.api.loanfinbank; |
||||
|
|
||||
|
import com.yxt.common.core.vo.Vo; |
||||
|
import lombok.Data; |
||||
|
|
||||
|
/** |
||||
|
* @description: |
||||
|
* @author: dimengzhe |
||||
|
* @date: 2023/7/10 |
||||
|
**/ |
||||
|
@Data |
||||
|
public class LoanFinBanksVo implements Vo { |
||||
|
private static final long serialVersionUID = -2396821681988455147L; |
||||
|
|
||||
|
private String sid; |
||||
|
|
||||
|
private String name; |
||||
|
} |
@ -0,0 +1,56 @@ |
|||||
|
package com.yxt.anrui.riskcenter.api.loanfinpolicy; |
||||
|
|
||||
|
import com.yxt.common.core.vo.Vo; |
||||
|
import io.swagger.annotations.ApiModelProperty; |
||||
|
import lombok.Data; |
||||
|
|
||||
|
/** |
||||
|
* @description: |
||||
|
* @author: dimengzhe |
||||
|
* @date: 2023/7/7 |
||||
|
**/ |
||||
|
@Data |
||||
|
public class LoanFinPolicyVos implements Vo { |
||||
|
private static final long serialVersionUID = 7126087240752513932L; |
||||
|
private String sid; |
||||
|
@ApiModelProperty("报备状态") |
||||
|
private String filingStateValue; |
||||
|
@ApiModelProperty("风控状态") |
||||
|
private String riskStateValue; |
||||
|
@ApiModelProperty("适用状态") |
||||
|
private String useSateValue; |
||||
|
@ApiModelProperty("有效期至") |
||||
|
private String validDateTo; |
||||
|
@ApiModelProperty("分公司") |
||||
|
private String useOrgName; |
||||
|
@ApiModelProperty("适用销售部门") |
||||
|
private String useDeptNames; |
||||
|
@ApiModelProperty("产品政策名称") |
||||
|
private String policyName; |
||||
|
@ApiModelProperty("业务类型") |
||||
|
private String busTypeValue; |
||||
|
@ApiModelProperty("车辆大类") |
||||
|
private String vehCategoryValue; |
||||
|
@ApiModelProperty("车辆功能") |
||||
|
private String vehTypeValue; |
||||
|
@ApiModelProperty("期数") |
||||
|
private int period; |
||||
|
@ApiModelProperty("标准年利率") |
||||
|
private String yearRatio; |
||||
|
@ApiModelProperty("服务费类型") |
||||
|
private String serviceAmountTypeValue; |
||||
|
@ApiModelProperty("服务费") |
||||
|
private String serviceAmount; |
||||
|
@ApiModelProperty("最低首付比例") |
||||
|
private String downPayRatioLeast; |
||||
|
@ApiModelProperty("单车意外险") |
||||
|
private String vehAccidentAmount; |
||||
|
@ApiModelProperty("保险保证金") |
||||
|
private String depositPremium; |
||||
|
@ApiModelProperty("落户保证金") |
||||
|
private String depositSettle; |
||||
|
@ApiModelProperty("名义/留购价款") |
||||
|
private String nominalPrice; |
||||
|
@ApiModelProperty("是否有其他融") |
||||
|
private boolean isOtherProduct; |
||||
|
} |
@ -0,0 +1,17 @@ |
|||||
|
package com.yxt.anrui.riskcenter.api.loanfinpolicy; |
||||
|
|
||||
|
import com.yxt.common.core.dto.Dto; |
||||
|
import lombok.Data; |
||||
|
|
||||
|
/** |
||||
|
* @description: |
||||
|
* @author: dimengzhe |
||||
|
* @date: 2023/7/7 |
||||
|
**/ |
||||
|
@Data |
||||
|
public class UseDept implements Dto { |
||||
|
private static final long serialVersionUID = 1169329632455670625L; |
||||
|
|
||||
|
private String deptSid; |
||||
|
private String deptName; |
||||
|
} |
@ -1,4 +1,44 @@ |
|||||
<?xml version="1.0" encoding="UTF-8" ?> |
<?xml version="1.0" encoding="UTF-8" ?> |
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
||||
<mapper namespace="com.yxt.anrui.riskcenter.biz.loanfinpolicy.LoanFinPolicyMapper"> |
<mapper namespace="com.yxt.anrui.riskcenter.biz.loanfinpolicy.LoanFinPolicyMapper"> |
||||
|
<select id="pagerList" resultType="com.yxt.anrui.riskcenter.api.loanfinpolicy.LoanFinPolicyVos"> |
||||
|
select lfp.sid, |
||||
|
case lfp.filingState |
||||
|
when 1 then '已报备' |
||||
|
when 2 then '报备中' |
||||
|
when 0 then '未报备' end as filingStateValue, |
||||
|
case lfp.riskState |
||||
|
when 1 then '禁用' |
||||
|
when 0 then '正常' |
||||
|
end as riskStateValue, |
||||
|
case lfp.useSate |
||||
|
when 1 then '禁用' |
||||
|
when 0 then '正常' |
||||
|
end as useSateValue, |
||||
|
lfp.validDateTo, |
||||
|
lfp.useOrgName, |
||||
|
lfp.useDeptNames, |
||||
|
lfp.policyName, |
||||
|
lfp.busTypeValue, |
||||
|
lfp.vehCategoryValue, |
||||
|
lfp.vehTypeValue, |
||||
|
lfp.period, |
||||
|
lfp.yearRatio, |
||||
|
lfp.serviceAmountTypeKey, |
||||
|
lfp.serviceAmount, |
||||
|
lfp.downPayRatioLeast, |
||||
|
lfp.vehAccidentAmount, |
||||
|
lfp.depositPremium, |
||||
|
lfp.depositSettle, |
||||
|
lfp.nominalPrice, |
||||
|
case lfp.isOtherProduct |
||||
|
when 1 then true |
||||
|
when 0 then false |
||||
|
end as isOtherProduct |
||||
|
from loan_fin_policy lfp |
||||
|
left join loan_fin_otherpolicy lfop on lfp.sid = lfop.mainPolicySid |
||||
|
<where> |
||||
|
${ew.sqlSegment} |
||||
|
</where> |
||||
|
</select> |
||||
</mapper> |
</mapper> |
Loading…
Reference in new issue