Commit e20f3ce7 authored by 郭小龙-DEL's avatar 郭小龙-DEL

Merge branch 'func_eccs_2334' into 'master'

Func eccs 2334 增加账单总金额

See merge request !59
parents 6953673c 7ac265f6
......@@ -96,10 +96,10 @@ export default [
path: "report",
title: "报表管理",
children: [
{
path: "/report/bi",
title: "财务账单报表",
},
// {
// path: "/report/bi",
// title: "财务账单报表",
// },
{
path: "/report/returnedMoney",
title: "账单回款报表",
......
......@@ -60,7 +60,7 @@
<!--分页-->
<BurtPagination :pagination="pagination" @pageChange="_getChargeListDetail" />
<div class="title-div">费用支付明细</div>
<!-- <div class="title-div">费用支付明细</div>
<a-table :columns="payColumns" :data-source="payDataList" :scroll="{ x: true }" :pagination="false" class="payTable">
<template slot="paymentType" slot-scope="text">
<a-button class="danger">{{ text | payStyleFilters }}</a-button>
......@@ -75,7 +75,7 @@
<Icon name="ssidayinji_o" :size="14" />打印</a-button>
</div>
</a-col>
</a-row>
</a-row> -->
<a-modal title="编辑" :visible="dialogShow" width="700px" :maskClosable="false"
okText="确定" cancelText="取消"
......
......@@ -108,7 +108,16 @@
<a-row :gutter="30">
<a-col :sm="24" class="none-label">
<div class="btn-div flex">
<span></span>
<div class="total-div flex">
<div>
<span>记账总单数:</span>
<span>{{ totalListNum + selectedRowKeys.length }}</span>
</div>
<div>
<span>账单总金额:</span>
<span>{{ totalAmount }}</span>
</div>
</div>
<a-form-model-item label="button">
<a-button type="primary" @click="handlerSearch">
<Icon name="ssisearch_active" :size="14" />查询
......@@ -193,7 +202,8 @@
import Goback from "@/components/CUSTOMER/goback";
import BurtPagination from "@/components/CUSTOMER/pagation";
import moment from 'moment'
import { numValid } from "@/utils/index"
import Big from 'big.js';
// import { numValid } from "@/utils/index"
export default {
data() {
......@@ -246,7 +256,10 @@ export default {
name: '有效',
code: 1
}
]
],
totalActualAmount: 0,
totalListNum: 0,
selectActualAmount: 0
};
},
components: {
......@@ -254,6 +267,11 @@ export default {
BurtPagination,
},
computed: {
totalAmount(){
console.log(this.totalActualAmount,this.selectActualAmount,Number(this.totalActualAmount * 100) + this.selectActualAmount * 100)
return Big(this.totalActualAmount).plus(this.selectActualAmount)
},
columns() {
const base = [
{ title: "账单日期", dataIndex: "receiptDate", width: 120,fixed: "left",scopedSlots: { customRender: "receiptDate" } },
......@@ -296,6 +314,7 @@ export default {
moment,
onSelectChange(selectedRowKeys) {
let arr = [];
this.selectActualAmount = 0
for(let i=0; i<selectedRowKeys.length; i++){
let idx = selectedRowKeys[i];
if(this.dataList[idx].sendBatchNo){
......@@ -303,6 +322,8 @@ export default {
this.$message.warning('寄送批号已存在')
}else{
arr.push(idx);
this.selectActualAmount = Big(this.selectActualAmount).plus(this.dataList[idx].actualAmount)
}
}
this.selectedRowKeys = arr;
......@@ -337,11 +358,25 @@ export default {
this.pagination.total = content.total || 0;
this.dataList = content.list || [];
this.cacheDataList[filter.pageNum] = this.dataList
this.getTotal()
} else {
this.$message.error(res.returnMsg);
}
});
},
// 计算总保费
getTotal(){
let totalNum = 0
let totalMoney= 0
if(this.dataList.length>0){
this.dataList.forEach((item)=>{
totalNum++
totalMoney += Number(item.actualAmount)
})
}
this.totalActualAmount = totalMoney.toFixed(2)
this.totalListNum = totalNum
},
// 获取保险公司下拉选项
_getCompanyOptions() {
this.$apis.GETCOMPANYOPTIONS().then((res) => {
......@@ -545,13 +580,13 @@ export default {
}
})
}
for(let i = 0; i < ciReceiptSendVos.length; i ++) {
const selfpaidAmount = ciReceiptSendVos[i].selfpaidAmount
if(selfpaidAmount && !numValid.test(selfpaidAmount)){
this.$message.warning("请输入正确的客户自付金额");
return false;
}
}
// for(let i = 0; i < ciReceiptSendVos.length; i ++) {
// const selfpaidAmount = ciReceiptSendVos[i].selfpaidAmount
// if(selfpaidAmount && !numValid.test(selfpaidAmount)){
// this.$message.warning("请输入正确的客户自付金额");
// return false;
// }
// }
return {
...this.form,
ciReceiptSendVos: ciReceiptSendVos,
......@@ -603,4 +638,12 @@ export default {
.btn-div{
justify-content: space-between;
}
.total-div{
gap:20px;
div span:first-child{
font-weight: bold;
font-family: PingFangSC-Medium, PingFang SC;
font-size: 14px;
}
}
</style>
......@@ -2114,6 +2114,11 @@ big.js@^5.2.2:
resolved "https://registry.yarnpkg.com/big.js/-/big.js-5.2.2.tgz#65f0af382f578bcdc742bd9c281e9cb2d7768328"
integrity sha512-vyL2OymJxmarO8gxMr0mhChsO9QGwhynfuu4+MHTAW6czfq9humCB7rKpUjDd9YUiDPU4mzpyupFSvOClAwbmQ==
big.js@^6.2.1:
version "6.2.1"
resolved "https://registry.npmmirror.com/big.js/-/big.js-6.2.1.tgz#7205ce763efb17c2e41f26f121c420c6a7c2744f"
integrity sha512-bCtHMwL9LeDIozFn+oNhhFoq+yQ3BNdnsLSASUxLciOb1vgvpHsIO1dsENiGMgbb4SkP5TrzWzRiLddn8ahVOQ==
binary-extensions@^1.0.0:
version "1.13.1"
resolved "https://registry.yarnpkg.com/binary-extensions/-/binary-extensions-1.13.1.tgz#598afe54755b2868a5330d2aff9d4ebb53209b65"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment