取水量bug修复

This commit is contained in:
710356044
2022-01-04 21:04:15 +08:00
parent 347230459d
commit 5f90df0716

View File

@@ -360,7 +360,7 @@ export default {
});
const id=record.drinkingWaterBillId;
const drinkingWaterBillId=record.drinkingWaterBillId;
// drinkingWaterList.drinkingWaterBillId=record.drinkingWaterBillId;
// 解析成对象数组
@@ -380,13 +380,14 @@ export default {
if (billData1.length > 0) {
updateWaterWithdrawal({
// drinkingWaterBillId:record.drinkingWaterBillId,
drinkingWaterBillId:id,
drinkingWaterList: billData1,
id:drinkingWaterBillId,
waterWithdrawals: billData1,
})
.then((res) => {
if (res.data.code == 0) {
Modal.success({
title: "导入成功",
content: `成功导入${billData1.length}条数据`,
});
this.$refs.water && this.$refs.water.reload();
} else {
@@ -408,40 +409,6 @@ export default {
});
}
// if (billData1.length > 0) {
// // 上传到服务器
// saveDrinkingWaterBill({
// billName: billName1,
// regionLevel: "县级",
// waterSourceType: 1,
// drinkingWaterType: 2,
// drinkingWaterList: billData1,
// // reportTime: new Date(`${this.year}-01-01 00:00:00`).getTime(),
// })
// .then((res) => {
// if (res.data.code == 0) {
// Modal.success({
// title: "导入成功",
// content: `成功导入${billData1.length}条数据`,
// });
// this.$refs.water && this.$refs.water.reload();
// } else {
// Modal.error({
// title: "导入失败",
// content: "数据上传出错",
// });
// }
// })
// .catch(() => {
// Modal.error({
// title: "导入失败",
// content: "数据上传出错",
// });
// })
// .finally(() => {
// hide();
// });
// }
} catch (error) {
hide();
Modal.error({