|
|
|
@ -28,7 +28,7 @@ |
|
|
|
size="small" |
|
|
|
multiple |
|
|
|
filterable |
|
|
|
:multiple-limit=2 |
|
|
|
:multiple-limit="2" |
|
|
|
style="width: 90px" |
|
|
|
> |
|
|
|
<el-option |
|
|
|
@ -125,9 +125,11 @@ |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
<div |
|
|
|
style="display: flex; |
|
|
|
style=" |
|
|
|
display: flex; |
|
|
|
justify-content: space-between; |
|
|
|
position: relative;" |
|
|
|
position: relative; |
|
|
|
" |
|
|
|
id="domTable" |
|
|
|
> |
|
|
|
<div |
|
|
|
@ -171,7 +173,10 @@ |
|
|
|
prop="patientName" |
|
|
|
label="姓名" |
|
|
|
></el-table-column> |
|
|
|
<el-table-column prop="sexName" label="性别"></el-table-column> |
|
|
|
<el-table-column |
|
|
|
prop="sexName" |
|
|
|
label="性别" |
|
|
|
></el-table-column> |
|
|
|
<el-table-column prop="age" label="年龄"></el-table-column> |
|
|
|
<el-table-column |
|
|
|
prop="asbitemName" |
|
|
|
@ -185,7 +190,10 @@ |
|
|
|
prop="charePrice" |
|
|
|
label="实收金额" |
|
|
|
></el-table-column> |
|
|
|
<el-table-column prop="discount" label="折扣"></el-table-column> |
|
|
|
<el-table-column |
|
|
|
prop="discount" |
|
|
|
label="折扣" |
|
|
|
></el-table-column> |
|
|
|
<el-table-column |
|
|
|
prop="bookKeepingName" |
|
|
|
label="记账人" |
|
|
|
@ -240,7 +248,10 @@ |
|
|
|
prop="patientName" |
|
|
|
label="姓名" |
|
|
|
></el-table-column> |
|
|
|
<el-table-column prop="sexName" label="性别"></el-table-column> |
|
|
|
<el-table-column |
|
|
|
prop="sexName" |
|
|
|
label="性别" |
|
|
|
></el-table-column> |
|
|
|
<el-table-column prop="age" label="年龄"></el-table-column> |
|
|
|
<el-table-column |
|
|
|
prop="asbitemName" |
|
|
|
@ -254,7 +265,10 @@ |
|
|
|
prop="charePrice" |
|
|
|
label="实收金额" |
|
|
|
></el-table-column> |
|
|
|
<el-table-column prop="discount" label="折扣"></el-table-column> |
|
|
|
<el-table-column |
|
|
|
prop="discount" |
|
|
|
label="折扣" |
|
|
|
></el-table-column> |
|
|
|
<el-table-column |
|
|
|
prop="bookKeepingName" |
|
|
|
label="记账人" |
|
|
|
@ -456,7 +470,7 @@ export default { |
|
|
|
feesummarychargeMoney: 0, |
|
|
|
feesummarydiscountMoney: 0, |
|
|
|
feesummaryreceivedChargeMoney: 0, |
|
|
|
feesummarytotalReceivedChargeMoney:0, |
|
|
|
feesummarytotalReceivedChargeMoney: 0, |
|
|
|
pages: { |
|
|
|
SkipCount: 0, |
|
|
|
MaxResultCount: 1000, |
|
|
|
@ -566,12 +580,12 @@ export default { |
|
|
|
} |
|
|
|
}, |
|
|
|
tableRowClassName({ row, column, rowIndex, columnIndex }) { |
|
|
|
if (row.medicalTimes == "合计") { |
|
|
|
if (row.asbitemName == "合计") { |
|
|
|
return { backgroundColor: "#F5F7FA" }; |
|
|
|
} |
|
|
|
}, |
|
|
|
feesummarytableRowClassName({ row, column, rowIndex, columnIndex }) { |
|
|
|
if (row.patientNo == "合计") { |
|
|
|
if (row.payModeName == "合计") { |
|
|
|
return { backgroundColor: "#F5F7FA" }; |
|
|
|
} |
|
|
|
}, |
|
|
|
@ -655,19 +669,19 @@ export default { |
|
|
|
feesummaryTableData(tableData) { |
|
|
|
const newData = [...tableData]; // 创建一个新的数组,避免修改原始数据 |
|
|
|
const totalRows = { |
|
|
|
chargeId:"", |
|
|
|
patientNo: "合计", |
|
|
|
chargeId: "", |
|
|
|
patientNo: "", |
|
|
|
patientName: "", |
|
|
|
sexName: "", |
|
|
|
age: "", |
|
|
|
chargeMoney: 0, |
|
|
|
discountMoney: 0, |
|
|
|
totalReceivedChargeMoney:0, |
|
|
|
totalReceivedChargeMoney: 0, |
|
|
|
bookKeepingName: "", |
|
|
|
bookkeepingTiem: "", |
|
|
|
chargeFlagName: "", |
|
|
|
payModeName:"", |
|
|
|
receivedChargeMoney:0 |
|
|
|
payModeName: "合计", |
|
|
|
receivedChargeMoney: 0, |
|
|
|
}; // 合计行的数据 |
|
|
|
let obj = {}; |
|
|
|
for (let i = 0; i < tableData.length; i++) { |
|
|
|
@ -680,10 +694,19 @@ export default { |
|
|
|
tableData.forEach((item) => { |
|
|
|
if (item.chargeId == key) { |
|
|
|
totalRow.chargeId = item.chargeId; |
|
|
|
totalRow.chargeMoney =item.chargeMoney |
|
|
|
totalRow.discountMoney =item.discountMoney |
|
|
|
totalRow.totalReceivedChargeMoney =item.totalReceivedChargeMoney |
|
|
|
totalRow.receivedChargeMoney =(Number(totalRow.receivedChargeMoney)+Number(item.receivedChargeMoney)).toFixed(2) |
|
|
|
totalRow.chargeMoney = ( |
|
|
|
Number(totalRow.chargeMoney) + Number(item.chargeMoney) |
|
|
|
).toFixed(2); |
|
|
|
totalRow.discountMoney = ( |
|
|
|
Number(totalRow.discountMoney) + Number(item.discountMoney) |
|
|
|
).toFixed(2); |
|
|
|
totalRow.totalReceivedChargeMoney = ( |
|
|
|
Number(totalRow.totalReceivedChargeMoney) + Number(item.totalReceivedChargeMoney) |
|
|
|
).toFixed(2); |
|
|
|
totalRow.receivedChargeMoney = ( |
|
|
|
Number(totalRow.receivedChargeMoney) + |
|
|
|
Number(item.receivedChargeMoney) |
|
|
|
).toFixed(2); |
|
|
|
} |
|
|
|
}); |
|
|
|
newData.push(totalRow); |
|
|
|
@ -704,11 +727,11 @@ export default { |
|
|
|
const newData = [...tableData]; // 创建一个新的数组,避免修改原始数据 |
|
|
|
const totalRows = { |
|
|
|
patientNo: "", |
|
|
|
medicalTimes: "合计", |
|
|
|
medicalTimes: "", |
|
|
|
patientName: "", |
|
|
|
sexName: "", |
|
|
|
age: "", |
|
|
|
asbitemName: "", |
|
|
|
asbitemName: "合计", |
|
|
|
standardPrice: 0, |
|
|
|
charePrice: 0, |
|
|
|
discount: "", |
|
|
|
@ -727,8 +750,12 @@ export default { |
|
|
|
if (item.patientNo == key) { |
|
|
|
totalRow.patientNo = item.patientNo; |
|
|
|
totalRow.patientName = item.patientName; |
|
|
|
totalRow.standardPrice =(Number(totalRow.standardPrice)+Number(item.standardPrice)).toFixed(2) |
|
|
|
totalRow.charePrice =(Number(totalRow.charePrice)+Number(item.charePrice)).toFixed(2) |
|
|
|
totalRow.standardPrice = ( |
|
|
|
Number(totalRow.standardPrice) + Number(item.standardPrice) |
|
|
|
).toFixed(2); |
|
|
|
totalRow.charePrice = ( |
|
|
|
Number(totalRow.charePrice) + Number(item.charePrice) |
|
|
|
).toFixed(2); |
|
|
|
} |
|
|
|
}); |
|
|
|
newData.push(totalRow); |
|
|
|
@ -743,11 +770,11 @@ export default { |
|
|
|
const newData = [...tableData]; // 创建一个新的数组,避免修改原始数据 |
|
|
|
const totalRows = { |
|
|
|
patientNo: "", |
|
|
|
medicalTimes: "合计", |
|
|
|
medicalTimes: "", |
|
|
|
patientName: "", |
|
|
|
sexName: "", |
|
|
|
age: "", |
|
|
|
asbitemName: "", |
|
|
|
asbitemName: "合计", |
|
|
|
standardPrice: 0, |
|
|
|
charePrice: 0, |
|
|
|
discount: "", |
|
|
|
@ -763,7 +790,6 @@ export default { |
|
|
|
var item = tableData[i].patientNo; |
|
|
|
obj[item] = obj[item] + 1 || 1; |
|
|
|
} |
|
|
|
|
|
|
|
Object.keys(obj).forEach((key) => { |
|
|
|
let totalRow = JSON.parse(JSON.stringify(totalRows)); |
|
|
|
let pie = JSON.parse(JSON.stringify(pies)); |
|
|
|
@ -772,8 +798,12 @@ export default { |
|
|
|
totalRow.patientNo = item.patientNo; |
|
|
|
totalRow.patientName = item.patientName; |
|
|
|
pie.name = item.patientName; |
|
|
|
totalRow.standardPrice =(Number(totalRow.standardPrice)+Number(item.standardPrice)).toFixed(2) |
|
|
|
totalRow.charePrice =(Number(totalRow.charePrice)+Number(item.charePrice)).toFixed(2) |
|
|
|
totalRow.standardPrice = ( |
|
|
|
Number(totalRow.standardPrice) + Number(item.standardPrice) |
|
|
|
).toFixed(2); |
|
|
|
totalRow.charePrice = ( |
|
|
|
Number(totalRow.charePrice) + Number(item.charePrice) |
|
|
|
).toFixed(2); |
|
|
|
pie.value = totalRow.charePrice; |
|
|
|
} |
|
|
|
}); |
|
|
|
@ -831,84 +861,78 @@ export default { |
|
|
|
this.setStandardDates(this.standardTableData); |
|
|
|
}, |
|
|
|
setStandardDates(arr) { |
|
|
|
var obj = {}, |
|
|
|
k, |
|
|
|
arr1 = []; |
|
|
|
if (arr.length !== 0) { |
|
|
|
this.arr1 = []; |
|
|
|
for (var i = 0, len = arr.length; i < len; i++) { |
|
|
|
k = arr[i].patientNo; //需要合并的字段 |
|
|
|
if (obj[k]) obj[k]++; |
|
|
|
else obj[k] = 1; |
|
|
|
} |
|
|
|
//保存结果{el-'元素',count-出现次数} |
|
|
|
for (var o in obj) { |
|
|
|
for (let i = 0; i < obj[o]; i++) { |
|
|
|
if (i === 0) { |
|
|
|
this.arr1.push(obj[o]); |
|
|
|
let pos = 0; |
|
|
|
arr.forEach((item, index) => { |
|
|
|
if (index === 0) { |
|
|
|
this.arr1.push(1); |
|
|
|
} else { |
|
|
|
if (item.patientNo === arr[index - 1].patientNo) { |
|
|
|
this.arr1[pos] += 1; |
|
|
|
this.arr1.push(0); |
|
|
|
} else { |
|
|
|
pos = index; |
|
|
|
this.arr1.push(1); |
|
|
|
} |
|
|
|
} |
|
|
|
}); |
|
|
|
} |
|
|
|
}, |
|
|
|
feesummarysetStandardDates(arr) { |
|
|
|
var obj = {}, |
|
|
|
k, |
|
|
|
arr1 = []; |
|
|
|
if (arr.length !== 0) { |
|
|
|
this.arr3 = []; |
|
|
|
for (var i = 0, len = arr.length; i < len; i++) { |
|
|
|
k = arr[i].chargeId; //需要合并的字段 |
|
|
|
if (obj[k]) obj[k]++; |
|
|
|
else obj[k] = 1; |
|
|
|
} |
|
|
|
//保存结果{el-'元素',count-出现次数} |
|
|
|
for (var o in obj) { |
|
|
|
for (let i = 0; i < obj[o]; i++) { |
|
|
|
if (i === 0) { |
|
|
|
this.arr3.push(obj[o]); |
|
|
|
let pos = 0; |
|
|
|
arr.forEach((item, index) => { |
|
|
|
if (index === 0) { |
|
|
|
this.arr3.push(1); |
|
|
|
} else { |
|
|
|
if (item.chargeId === arr[index - 1].chargeId) { |
|
|
|
this.arr3[pos] += 1; |
|
|
|
this.arr3.push(0); |
|
|
|
} else { |
|
|
|
pos = index; |
|
|
|
this.arr3.push(1); |
|
|
|
} |
|
|
|
} |
|
|
|
}); |
|
|
|
} |
|
|
|
}, |
|
|
|
refundsetStandardDates(arr) { |
|
|
|
var obj = {}, |
|
|
|
k, |
|
|
|
arr1 = []; |
|
|
|
if (arr.length !== 0) { |
|
|
|
this.arr2 = []; |
|
|
|
for (var i = 0, len = arr.length; i < len; i++) { |
|
|
|
k = arr[i].patientNo; //需要合并的字段 |
|
|
|
if (obj[k]) obj[k]++; |
|
|
|
else obj[k] = 1; |
|
|
|
} |
|
|
|
//保存结果{el-'元素',count-出现次数} |
|
|
|
for (var o in obj) { |
|
|
|
for (let i = 0; i < obj[o]; i++) { |
|
|
|
if (i === 0) { |
|
|
|
this.arr2.push(obj[o]); |
|
|
|
let pos = 0; |
|
|
|
arr.forEach((item, index) => { |
|
|
|
if (index === 0) { |
|
|
|
this.arr2.push(1); |
|
|
|
} else { |
|
|
|
if (item.patientNo === arr[index - 1].patientNo) { |
|
|
|
this.arr2[pos] += 1; |
|
|
|
this.arr2.push(0); |
|
|
|
} else { |
|
|
|
pos = index; |
|
|
|
this.arr2.push(1); |
|
|
|
} |
|
|
|
} |
|
|
|
}); |
|
|
|
} |
|
|
|
}, |
|
|
|
objectStandardSpanMethod({ row, column, rowIndex, columnIndex }) { |
|
|
|
if (columnIndex === 0) { |
|
|
|
if (columnIndex < 5) { |
|
|
|
let _row = this.arr1[rowIndex]; |
|
|
|
let _col = this.arr1[rowIndex] > 0 ? 1 : 0; |
|
|
|
return [_row, _col]; |
|
|
|
} |
|
|
|
}, |
|
|
|
refundobjectStandardSpanMethod({ row, column, rowIndex, columnIndex }) { |
|
|
|
if (columnIndex === 0) { |
|
|
|
if (columnIndex < 5) { |
|
|
|
let _row = this.arr2[rowIndex]; |
|
|
|
let _col = this.arr2[rowIndex] > 0 ? 1 : 0; |
|
|
|
return [_row, _col]; |
|
|
|
} |
|
|
|
}, |
|
|
|
feesummaryobjectStandardSpanMethod({ row, column, rowIndex, columnIndex }) { |
|
|
|
if (columnIndex === 0) { |
|
|
|
if (columnIndex < 5) { |
|
|
|
let _row = this.arr3[rowIndex]; |
|
|
|
let _col = this.arr3[rowIndex] > 0 ? 1 : 0; |
|
|
|
return [_row, _col]; |
|
|
|
@ -920,11 +944,7 @@ export default { |
|
|
|
} else if (this.format == 1) { |
|
|
|
exportToExcel("#tableData", "个人退费明细统计报表", false); |
|
|
|
} else { |
|
|
|
exportToExcel( |
|
|
|
"#projectTableData", |
|
|
|
"个人收费汇总统计报表", |
|
|
|
false |
|
|
|
); |
|
|
|
exportToExcel("#projectTableData", "个人收费汇总统计报表", false); |
|
|
|
} |
|
|
|
}, |
|
|
|
onPrint() { |
|
|
|
@ -1054,7 +1074,7 @@ page-break-before: avoid;}}`, // 去除页眉页脚 |
|
|
|
this.$refs.chart2.setOption(option2); |
|
|
|
}, |
|
|
|
getList() { |
|
|
|
getapi("/api/identity/users/getlist",this.pages).then((res) => { |
|
|
|
getapi("/api/identity/users/getlist", this.pages).then((res) => { |
|
|
|
if (res.code != -1) { |
|
|
|
this.registrardata = [...res.data.items]; |
|
|
|
} |
|
|
|
@ -1136,7 +1156,7 @@ page-break-before: avoid;}}`, // 去除页眉页脚 |
|
|
|
/* ::v-deep .el-table__fixed-body-wrapper .el-table__body { |
|
|
|
padding-right: 6px; |
|
|
|
} */ |
|
|
|
.query:last-child{ |
|
|
|
.query:last-child { |
|
|
|
margin-right: 0; |
|
|
|
} |
|
|
|
</style> |