From 6cf7ea7aa09553b9fe148f94ec6158dbb2b2c9bc Mon Sep 17 00:00:00 2001
From: xiangpei <xiangpei@timesnew.cn>
Date: 星期二, 08 四月 2025 18:22:19 +0800
Subject: [PATCH] v-show
---
src/views/projectEngineering/projectLibrary/component/investmentFunds.vue | 111 ++++++++++++++++++++++++++++++++++++++++++++++---------
1 files changed, 93 insertions(+), 18 deletions(-)
diff --git a/src/views/projectEngineering/projectLibrary/component/investmentFunds.vue b/src/views/projectEngineering/projectLibrary/component/investmentFunds.vue
index f628d84..97a0272 100644
--- a/src/views/projectEngineering/projectLibrary/component/investmentFunds.vue
+++ b/src/views/projectEngineering/projectLibrary/component/investmentFunds.vue
@@ -1,11 +1,11 @@
<template>
<div class="basic-info">
- <el-form ref="demoFormRef" :disabled="disabled" :model="investmentFundsForm" class="dialog_form">
+ <el-form ref="demoFormRef" :disabled="disabled" :model="investmentFundsForm" :rules="rules" class="dialog_form">
<!-- 淇濇寔鍘熸湁妯℃澘鍐呭涓嶅彉 -->
<el-row :gutter="20">
<el-col :span="6">
- <el-form-item label="椤圭洰鎬绘姇璧勯" label-width="130px" prop="fundsType" style="width: 100%">
- <el-input v-model.trim="investmentFundsForm.totalInvestment" class="item" clearable maxlength="255" style="width: 90%"
+ <el-form-item label="椤圭洰鎬绘姇璧勯" label-width="130px" prop="totalInvestment" required style="width: 100%">
+ <el-input v-model.trim="totalInvestment" class="item" clearable disabled style="width: 90%"
placeholder="璇疯緭鍏�"/>
<span class="money">涓囧厓</span>
</el-form-item>
@@ -30,7 +30,7 @@
<el-row :gutter="20">
<el-col :span="18">
<el-form-item label="锛堜竴锛変腑澶姇璧�" label-width="130px" prop="projectType" style="width: 100%">
- <el-input v-model.trim="investmentFundsForm.centralInvestmentTotal" class="item" clearable maxlength="255" style="width: 90%"
+ <el-input v-model.trim="centralInvestmentTotal" class="item" clearable disabled style="width: 90%"
placeholder="璇疯緭鍏�"/>
<span class="money">涓囧厓</span>
</el-form-item>
@@ -38,7 +38,7 @@
</el-row>
<el-row :gutter="20">
<el-col :span="6">
- <el-form-item label="1.涓ぎ棰勭畻鎶曡祫" label-width="130px" prop="fundsType" style="width: 100%">
+ <el-form-item label="1.涓ぎ棰勭畻鎶曡祫" label-width="160px" prop="fundsType" style="width: 100%">
<el-input v-model.trim="investmentFundsForm.centralBudgetInvestment" class="item" clearable maxlength="255" style="width: 90%"
placeholder="璇疯緭鍏�"/>
<span class="money">涓囧厓</span>
@@ -61,10 +61,24 @@
</el-col>
</el-row>
<el-row :gutter="20">
- <el-col :span="18">
- <el-form-item label="4.涓ぎ涓撻」寤鸿鍩洪噾" label-width="130px" prop="engineering" style="width: 100%">
+ <el-col :span="6">
+ <el-form-item label="4.涓ぎ涓撻」寤鸿鍩洪噾" label-width="180px" prop="engineering" style="width: 100%">
<el-input v-model.trim="investmentFundsForm.centralSpecialFundInvestment" class="item" clearable style="width: 90%"
maxlength="255" placeholder="璇疯緭鍏�"/>
+ <span class="money">涓囧厓</span>
+ </el-form-item>
+ </el-col>
+ <el-col :span="6">
+ <el-form-item label="5.瓒呴暱鏈熺壒鍒浗鍊鸿祫閲�" label-width="150px" prop="engineering" style="width: 100%">
+ <el-input v-model.trim="investmentFundsForm.nationalDebt" class="item" clearable maxlength="255" style="width: 90%"
+ placeholder="璇疯緭鍏�"/>
+ <span class="money">涓囧厓</span>
+ </el-form-item>
+ </el-col>
+ <el-col :span="6">
+ <el-form-item label="6.2023骞村鍙戝浗鍊鸿祫閲�" label-width="150px" prop="engineering" style="width: 100%">
+ <el-input v-model.trim="investmentFundsForm.additionalNationalDebt" class="item" clearable maxlength="255" style="width: 90%"
+ placeholder="璇疯緭鍏�"/>
<span class="money">涓囧厓</span>
</el-form-item>
</el-col>
@@ -72,15 +86,15 @@
<el-row :gutter="20">
<el-col :span="18">
<el-form-item label="锛堜簩锛夌渷绾ф姇璧�" label-width="130px" prop="engineering" style="width: 100%">
- <el-input v-model.trim="investmentFundsForm.provincialInvestmentTotal" class="item" clearable style="width: 90%"
- maxlength="255" placeholder="璇疯緭鍏�"/>
+ <el-input v-model.trim="provincialInvestmentTotal" class="item" clearable disabled style="width: 90%"
+ placeholder="璇疯緭鍏�"/>
<span class="money">涓囧厓</span>
</el-form-item>
</el-col>
</el-row>
<el-row :gutter="20">
<el-col :span="6">
- <el-form-item label="1.鐪侀绠楀唴鎶曡祫" label-width="130px" prop="fundsType" style="width: 100%">
+ <el-form-item label="1.鐪侀绠楀唴鎶曡祫" label-width="160px" prop="fundsType" style="width: 100%">
<el-input v-model.trim="investmentFundsForm.provincialBudgetInvestment" class="item" clearable style="width: 90%"
maxlength="255" placeholder="璇疯緭鍏�"/>
<span class="money">涓囧厓</span>
@@ -104,7 +118,7 @@
<el-row :gutter="20">
<el-col :span="18">
<el-form-item label="锛堜笁锛夊競(宸�)鎶曡祫" label-width="130px" prop="engineering" style="width: 100%">
- <el-input v-model.trim="investmentFundsForm.cityInvestmentTotal" class="item" clearable maxlength="255" style="width: 90%"
+ <el-input v-model.trim="cityInvestmentTotal" class="item" clearable disabled style="width: 90%"
placeholder="璇疯緭鍏�"/>
<span class="money">涓囧厓</span>
</el-form-item>
@@ -112,7 +126,7 @@
</el-row>
<el-row :gutter="20">
<el-col :span="6">
- <el-form-item label="1.甯�(宸�)棰勭畻鍐呮姇璧�" label-width="130px" prop="fundsType" style="width: 100%">
+ <el-form-item label="1.甯�(宸�)棰勭畻鍐呮姇璧�" label-width="170px" prop="fundsType" style="width: 100%">
<el-input v-model.trim="investmentFundsForm.cityBudgetInvestment" class="item" clearable maxlength="255" style="width: 90%"
placeholder="璇疯緭鍏�"/>
<span class="money">涓囧厓</span>
@@ -136,7 +150,7 @@
<el-row :gutter="20">
<el-col :span="18">
<el-form-item label="锛堝洓锛夊幙(甯傘�佸尯)鎶曡祫" label-width="130px" prop="engineering" style="width: 100%">
- <el-input v-model.trim="investmentFundsForm.countyInvestmentTotal" class="item" clearable maxlength="255" style="width: 90%"
+ <el-input v-model.trim="countyInvestmentTotal" class="item" disabled style="width: 90%"
placeholder="璇疯緭鍏�"/>
<span class="money">涓囧厓</span>
</el-form-item>
@@ -144,16 +158,16 @@
</el-row>
<el-row :gutter="20">
<el-col :span="6">
- <el-form-item label="1.鍖�(鍘�)棰勭畻鍐呮姇璧�" label-width="130px" prop="fundsType" style="width: 100%">
- <el-input v-model.trim="investmentFundsForm.countyBudgetInvestment" class="item" clearable maxlength="255" style="width: 90%"
+ <el-form-item label="1.鍖�(鍘�)棰勭畻鍐呮姇璧�" label-width="180px" prop="fundsType" style="width: 100%">
+ <el-input v-model.trim="investmentFundsForm.countyBudgetInvestment" class="item" clearable style="width: 90%"
placeholder="璇疯緭鍏�"/>
<span class="money">涓囧厓</span>
</el-form-item>
</el-col>
<el-col :span="6">
- <el-form-item class="items" label="2.鍖猴紙鍘匡級璐㈡斂鎬у缓璁捐祫閲�" label-width="130px" prop="investmentType"
+ <el-form-item label="2.鍖猴紙鍘匡級璐㈡斂鎬у缓璁捐祫閲�" label-width="170px" prop="investmentType"
style="width: 100%">
- <el-input v-model.trim="investmentFundsForm.countyFiscalInvestment" class="item" clearable maxlength="255" style="width: 90%"
+ <el-input v-model.trim="investmentFundsForm.countyFiscalInvestment" class="item" clearable style="width: 90%"
placeholder="璇疯緭鍏�"/>
<span class="money">涓囧厓</span>
</el-form-item>
@@ -161,7 +175,16 @@
<el-col :span="6">
<el-form-item label="3.鍖�(鍘�)涓撻」璧勯噾" label-width="130px" prop="investmentType" style="width: 100%">
<el-input v-model.trim="investmentFundsForm.countySpecialFundInvestment" class="item" clearable style="width: 90%"
- maxlength="255" placeholder="璇疯緭鍏�"/>
+ type="number" placeholder="璇疯緭鍏�"/>
+ <span class="money">涓囧厓</span>
+ </el-form-item>
+ </el-col>
+ </el-row>
+ <el-row :gutter="20">
+ <el-col :span="6">
+ <el-form-item label="4.鍦版柟鏀垮簻涓撻」鍊哄埜" label-width="180px" prop="engineering" style="width: 100%">
+ <el-input v-model.trim="investmentFundsForm.deptBond" class="item" clearable style="width: 90%"
+ placeholder="璇疯緭鍏�"/>
<span class="money">涓囧厓</span>
</el-form-item>
</el-col>
@@ -211,6 +234,7 @@
</el-form-item>
</el-col>
</el-row>
+
</el-form>
</div>
</template>
@@ -233,9 +257,60 @@
required: true
},
},
+ computed: {
+ totalInvestment() {
+ this.investmentFundsForm.totalInvestment =
+ parseFloat(this.investmentFundsForm.governmentInvestmentTotal ? this.investmentFundsForm.governmentInvestmentTotal : 0) +
+ this.centralInvestmentTotal +
+ this.provincialInvestmentTotal +
+ this.cityInvestmentTotal +
+ this.countyInvestmentTotal +
+ parseFloat(this.investmentFundsForm.domesticLoanTotal ? this.investmentFundsForm.domesticLoanTotal : 0) +
+ parseFloat(this.investmentFundsForm.bankLoan ? this.investmentFundsForm.bankLoan : 0) +
+ parseFloat(this.investmentFundsForm.foreignInvestmentTotal ? this.investmentFundsForm.foreignInvestmentTotal : 0) +
+ parseFloat(this.investmentFundsForm.enterpriseSelfRaisedTotal ? this.investmentFundsForm.enterpriseSelfRaisedTotal : 0) +
+ parseFloat(this.investmentFundsForm.otherInvestmentTotal ? this.investmentFundsForm.otherInvestmentTotal : 0)
+ return this.investmentFundsForm.totalInvestment;
+ },
+ centralInvestmentTotal() {
+ this.investmentFundsForm.centralInvestmentTotal =
+ parseFloat(this.investmentFundsForm.centralBudgetInvestment ? this.investmentFundsForm.centralBudgetInvestment : 0) +
+ parseFloat(this.investmentFundsForm.centralFiscalInvestment ? this.investmentFundsForm.centralFiscalInvestment : 0) +
+ parseFloat(this.investmentFundsForm.centralSpecialBondInvestment ? this.investmentFundsForm.centralSpecialBondInvestment : 0) +
+ parseFloat(this.investmentFundsForm.centralSpecialFundInvestment ? this.investmentFundsForm.centralSpecialFundInvestment : 0) +
+ parseFloat(this.investmentFundsForm.nationalDebt ? this.investmentFundsForm.nationalDebt : 0) +
+ parseFloat(this.investmentFundsForm.additionalNationalDebt ? this.investmentFundsForm.additionalNationalDebt : 0)
+ return this.investmentFundsForm.centralInvestmentTotal;
+ },
+ provincialInvestmentTotal() {
+ this.investmentFundsForm.provincialInvestmentTotal =
+ parseFloat(this.investmentFundsForm.provincialBudgetInvestment ? this.investmentFundsForm.provincialBudgetInvestment : 0) +
+ parseFloat(this.investmentFundsForm.provincialFiscalInvestment ? this.investmentFundsForm.provincialFiscalInvestment : 0) +
+ parseFloat(this.investmentFundsForm.provincialSpecialFundInvestment ? this.investmentFundsForm.provincialSpecialFundInvestment : 0)
+ return this.investmentFundsForm.provincialInvestmentTotal;
+ },
+ cityInvestmentTotal() {
+ this.investmentFundsForm.cityInvestmentTotal =
+ parseFloat(this.investmentFundsForm.cityBudgetInvestment ? this.investmentFundsForm.cityBudgetInvestment : 0) +
+ parseFloat(this.investmentFundsForm.cityFiscalInvestment ? this.investmentFundsForm.cityFiscalInvestment : 0) +
+ parseFloat(this.investmentFundsForm.citySpecialFundInvestment ? this.investmentFundsForm.citySpecialFundInvestment : 0)
+ return this.investmentFundsForm.cityInvestmentTotal;
+ },
+ countyInvestmentTotal() {
+ this.investmentFundsForm.countyInvestmentTotal =
+ parseFloat(this.investmentFundsForm.countyBudgetInvestment ? this.investmentFundsForm.countyBudgetInvestment : 0) +
+ parseFloat(this.investmentFundsForm.countyFiscalInvestment ? this.investmentFundsForm.countyFiscalInvestment : 0) +
+ parseFloat(this.investmentFundsForm.countySpecialFundInvestment ? this.investmentFundsForm.countySpecialFundInvestment : 0) +
+ parseFloat(this.investmentFundsForm.deptBond ? this.investmentFundsForm.deptBond : 0)
+ return this.investmentFundsForm.countyInvestmentTotal;
+ }
+ },
data() {
return {
projectForm: {},
+ rules: {
+
+ },
investmentFundsForm: {
// id: '',
// projectId: '',
--
Gitblit v1.8.0