From 0bd258cbb9b99ef369a33d8a331f37a5979c0ed7 Mon Sep 17 00:00:00 2001 From: xy <271556543@qq.com> Date: Tue, 18 Jul 2023 17:06:34 +0800 Subject: [PATCH] 2023-7-18 --- .../components/paymentRegistration.vue | 16 ++- src/views/contract/contractProgress.vue | 2 + src/views/inOut/expenseAccount.vue | 110 ++++++++++++++---- 3 files changed, 104 insertions(+), 24 deletions(-) diff --git a/src/views/contract/components/paymentRegistration.vue b/src/views/contract/components/paymentRegistration.vue index f407e63..a4f4c98 100644 --- a/src/views/contract/components/paymentRegistration.vue +++ b/src/views/contract/components/paymentRegistration.vue @@ -19,13 +19,13 @@
-
合同名称
+
{{ nameFormat($route.path.split('_')[1]) }}名称
{{ contract.name }}
-
合同金额
+
{{ nameFormat($route.path.split('_')[1]) }}金额
{{ priceFormat(contract.money) }} (元)
@@ -521,6 +521,18 @@ export default { .replace(/(\d)(?=(\d{3})+\.)/g, "$1,"); }; }, + + nameFormat () { + return function(index) { + if (index == 2) { + return '报销' + } + if (index == 3) { + return '其他支出' + } + return '合同' + } + } }, watch: { isShowPaymentRegistration(newVal) { diff --git a/src/views/contract/contractProgress.vue b/src/views/contract/contractProgress.vue index 5fea905..0ed049c 100644 --- a/src/views/contract/contractProgress.vue +++ b/src/views/contract/contractProgress.vue @@ -375,6 +375,7 @@ export default { startDate: "", endDate: "", type: "", + outcome_type: 1, department_id: "", purchaseModality: "", purchaseMethods: "", @@ -398,6 +399,7 @@ export default { startDate: "", endDate: "", type: "", + outcome_type: 1, department_id: "", purchaseModality: "", purchaseMethods: "", diff --git a/src/views/inOut/expenseAccount.vue b/src/views/inOut/expenseAccount.vue index beec901..89018f1 100644 --- a/src/views/inOut/expenseAccount.vue +++ b/src/views/inOut/expenseAccount.vue @@ -185,7 +185,66 @@ $refs['addExpenseAccount'].show(); } " - > + > + +
+ + +
@@ -223,9 +285,11 @@ import { getparameter } from "@/api/system/dictionary"; import { listdeptNoAuth } from "@/api/system/department"; import addExpenseAccount from "@/views/inOut/component/addExpenseAccount.vue"; +import detailContract from '@/views/contract/components/detailContract.vue'; +import paymentRegistration from '@/views/contract/components/paymentRegistration.vue' export default { components: { - addExpenseAccount, + addExpenseAccount,detailContract,paymentRegistration }, data() { return { @@ -277,39 +341,41 @@ export default { }, { prop: "money", - label: this.$route.path.split("_")[1] == 2 ? "报销金额(元)" : "支出金额(元)", + label: + this.$route.path.split("_")[1] == 2 + ? "报销金额(元)" + : "支出金额(元)", width: 140, align: "right", }, { prop: "use_money_total", - label: this.$route.path.split("_")[1] == 2 ? "实际报销金额(元)" : "实际支出金额(元)", + label: + this.$route.path.split("_")[1] == 2 + ? "实际报销金额(元)" + : "实际支出金额(元)", width: 140, align: "right", - customFn:row => { - let total = 0 - row.plans?.forEach(i => { - total += Number(i.money) || 0 - }) - return ( - { total } - ) - } + customFn: (row) => { + let total = 0; + row.plans?.forEach((i) => { + total += Number(i.money) || 0; + }); + return {total}; + }, }, { prop: "has_money_total", label: "已付金额", width: 140, align: "right", - customFn:row => { - let total = 0 - row.plans?.forEach(i => { - total += Number(i.end_money) || 0 - }) - return ( - { total } - ) - } + customFn: (row) => { + let total = 0; + row.plans?.forEach((i) => { + total += Number(i.end_money) || 0; + }); + return {total}; + }, }, { prop: "department.name",