Commit bfce2981 authored by wangxl's avatar wangxl

33

parent 14ad9199
...@@ -97,14 +97,14 @@ ...@@ -97,14 +97,14 @@
<script> <script>
export default { export default {
name: "FundPlanEdit", name: "FundPlanEdit",
data() { data () {
return { return {
invisibleYearValue1: [0], invisibleYearValue1: [0],
invisibleYearValue2: [0], invisibleYearValue2: [0],
invisibleYearValue3: [0], invisibleYearValue3: [0],
invisibleYearValue4: [0], invisibleYearValue4: [0],
invisibleYearValue5: [0], invisibleYearValue5: [0],
invisibleTotalAmount: [ 0, 1, 2 ], invisibleTotalAmount: [0, 1, 2],
}; };
}, },
props: { props: {
...@@ -115,19 +115,20 @@ export default { ...@@ -115,19 +115,20 @@ export default {
}, },
}, },
}, },
created() {}, created () { },
methods: { methods: {
calYearValue() { calYearValue () {
this.fundPlan[0].yearValue1 = this.fundPlan[1].yearValue1 + this.fundPlan[2].yearValue1 this.fundPlan[0].yearValue1 = this.fundPlan[1].yearValue1 + this.fundPlan[2].yearValue1
this.fundPlan[0].yearValue2 = this.fundPlan[1].yearValue2 + this.fundPlan[2].yearValue2 this.fundPlan[0].yearValue2 = this.fundPlan[1].yearValue2 + this.fundPlan[2].yearValue2
this.fundPlan[0].yearValue3 = this.fundPlan[1].yearValue3 + this.fundPlan[2].yearValue3 this.fundPlan[0].yearValue3 = this.fundPlan[1].yearValue3 + this.fundPlan[2].yearValue3
this.fundPlan[0].yearValue4 = this.fundPlan[1].yearValue4 + this.fundPlan[2].yearValue4 this.fundPlan[0].yearValue4 = this.fundPlan[1].yearValue4 + this.fundPlan[2].yearValue4
this.fundPlan[0].yearValue5 = this.fundPlan[1].yearValue5 + this.fundPlan[2].yearValue5 this.fundPlan[0].yearValue5 = this.fundPlan[1].yearValue5 + this.fundPlan[2].yearValue5
}, },
outNumberChange(index) { outNumberChange (index) {
this.fundPlan[index].totalAmount = this.fundPlan[index].yearValue1 + this.fundPlan[index].yearValue2 + this.fundPlan[index].yearValue3 + this.fundPlan[index].yearValue4 + this.fundPlan[index].yearValue5 this.fundPlan[index].totalAmount = this.fundPlan[index].yearValue1 + this.fundPlan[index].yearValue2 + this.fundPlan[index].yearValue3 + this.fundPlan[index].yearValue4 + this.fundPlan[index].yearValue5
this.calYearValue() this.calYearValue()
this.fundPlan[0].totalAmount = this.fundPlan[0].yearValue1 + this.fundPlan[0].yearValue2 + this.fundPlan[0].yearValue3 + this.fundPlan[0].yearValue4 + this.fundPlan[0].yearValue5 this.fundPlan[0].totalAmount = this.fundPlan[0].yearValue1 + this.fundPlan[0].yearValue2 + this.fundPlan[0].yearValue3 + this.fundPlan[0].yearValue4 + this.fundPlan[0].yearValue5
this.$emit('save', [this.fundPlan[0].totalAmount, this.fundPlan[1].totalAmount, this.fundPlan[2].totalAmount])
}, },
}, },
}; };
......
...@@ -438,8 +438,8 @@ ...@@ -438,8 +438,8 @@
</div> </div>
</a-col> </a-col>
</a-row> </a-row>
<!-- 项目绩效指标 --> <!-- 经费预算 -->
<project-kpi-edit :projectKPI.sync="formData.projectKPI" /> <budget-edit :budget.sync="formData.budget" />
<a-row type="flex"> <a-row type="flex">
<a-col :span="24" style="text-align: center;"> <a-col :span="24" style="text-align: center;">
<div class="special-middle"> <div class="special-middle">
...@@ -447,8 +447,8 @@ ...@@ -447,8 +447,8 @@
</div> </div>
</a-col> </a-col>
</a-row> </a-row>
<!-- 经费预算 --> <!-- 分年度用款计划 -->
<budget-edit :budget.sync="formData.budget" /> <fund-plan-edit :fundPlan.sync="formData.fundPlan" @save="planSave" />
<a-row type="flex"> <a-row type="flex">
<a-col :span="24" style="text-align: center;"> <a-col :span="24" style="text-align: center;">
<div class="special-middle"> <div class="special-middle">
...@@ -456,8 +456,8 @@ ...@@ -456,8 +456,8 @@
</div> </div>
</a-col> </a-col>
</a-row> </a-row>
<!-- 分年度用款计划 --> <!-- 项目绩效指标 -->
<fund-plan-edit :fundPlan.sync="formData.fundPlan" /> <project-kpi-edit :projectKPI.sync="formData.projectKPI" />
<a-row type="flex"> <a-row type="flex">
<a-col :span="24" style="text-align: center;"> <a-col :span="24" style="text-align: center;">
<div class="special-middle"> <div class="special-middle">
...@@ -561,7 +561,7 @@ import cascaderSelect from '@/views/components/common/cascaderSelect' ...@@ -561,7 +561,7 @@ import cascaderSelect from '@/views/components/common/cascaderSelect'
export default { export default {
name: 'projectEdit', name: 'projectEdit',
components: { components: {
projectMemberEdit, cooperativeUnitsEdit, budgetEdit, fundPlanEdit, projectKpiEdit, fileEdit, previewFile, documentView,cascaderSelect projectMemberEdit, cooperativeUnitsEdit, budgetEdit, fundPlanEdit, projectKpiEdit, fileEdit, previewFile, documentView, cascaderSelect
}, },
props: { props: {
value: { value: {
...@@ -754,7 +754,7 @@ export default { ...@@ -754,7 +754,7 @@ export default {
return true return true
} }
}, },
projNameChange(value) { projNameChange (value) {
this.formData.projectKPI.projName = this.formData.projName this.formData.projectKPI.projName = this.formData.projName
}, },
startDateChange (value, dateString) { startDateChange (value, dateString) {
...@@ -772,9 +772,14 @@ export default { ...@@ -772,9 +772,14 @@ export default {
}, },
govFundingChange () { govFundingChange () {
this.formData.projectKPI.applyFunds = this.formData.govFunding this.formData.projectKPI.applyFunds = this.formData.govFunding
},
planSave (e) {
if (!!e && e.length == 3) {
this.formData.projectKPI.yearTotal = e[0]
this.formData.projectKPI.yearApply = e[1]
this.formData.projectKPI.yearSelf = e[2]
} }
}, },
watch: {
} }
} }
</script> </script>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment