减免申请问题修改

This commit is contained in:
cwchen 2025-03-18 18:23:57 +08:00
parent 5f31bb9f09
commit 5d87951337
2 changed files with 4946 additions and 8 deletions

4934
src/utils/decimal.js Normal file

File diff suppressed because it is too large Load Diff

View File

@ -38,10 +38,10 @@
</el-form-item>
<div>
<el-form-item prop="deviceName">
<el-form-item prop="maName">
<el-input
maxlength="50"
v-model="queryParams.deviceName"
v-model="queryParams.maName"
placeholder="请输入检索设备名称"
clearable
style="width: 240px"
@ -330,6 +330,7 @@ import {getReliefList,addRelief } from "@/api/cost/cost";
import {downloadFile, downloadFileData} from '@/utils/download'
import {getToken} from '@/utils/auth'
import Treeselect from "@riophae/vue-treeselect";
import Decimal from "@/utils/decimal";
import "@riophae/vue-treeselect/dist/vue-treeselect.css";
export default {
name: "",
@ -370,6 +371,8 @@ export default {
agreementId: '',
agreementCode: '',
time:null,
maName:null,
typeName:null,
},
//
@ -527,7 +530,7 @@ export default {
async getList() {
this.loading = true;
const params = {
deviceName: this.queryParams.deviceName,
maName: this.queryParams.maName,
typeName: this.queryParams.typeName,
agreementId: this.queryParams.agreementId,
startTime: this.queryParams.time && this.queryParams.time[0],
@ -537,11 +540,10 @@ export default {
getReliefList(params).then((response) => {
this.pushReviewList = response.data;
console.log('22222222',this.pushReviewList)
this.leaseAll = Number(
this.pushReviewList.reduce((total, item) => {
return total + Number(item.leaseMoney);
}, 0).toFixed(2)
);
this.leaseAll = this.pushReviewList.reduce((total, item) => {
// return total + Number(item.leaseMoney);
return new Decimal(total).add(new Decimal(item.leaseMoney)).toString();
}, 0);
let obj = {
id:null,
leaseMoney: this.leaseAll,
@ -559,6 +561,8 @@ export default {
projectId: null,
agreementId: '',
agreementCode: '',
maName:null,
typeName:null
}
this.resetForm('queryForm')
this.queryParams.time=[]