Commit 466b8d2b authored by wangxl's avatar wangxl
parents 6c4b62e6 6d805f8f
...@@ -146,7 +146,7 @@ export default { ...@@ -146,7 +146,7 @@ export default {
} }
}, },
created() { created() {
//this.calTotalFee() this.calTotalFee()
}, },
methods: { methods: {
FeeChange (index) { FeeChange (index) {
...@@ -177,6 +177,16 @@ export default { ...@@ -177,6 +177,16 @@ export default {
this.FeeChange(index) this.FeeChange(index)
}, },
calTotalFee() { calTotalFee() {
if (!this.budgetList || this.budgetList.length < 9) {
this.totalYearValue1 = 0
this.totalYearValue2 = 0
this.totalYearValue3 = 0
this.totalYearValue4 = 0
this.totalYearValue5 = 0
this.totalFee = 0
return
}
this.totalYearValue1 = this.budgetList[0].yearValue1 + this.budgetList[1].yearValue1 + this.budgetList[2].yearValue1 + this.budgetList[8].yearValue1 this.totalYearValue1 = this.budgetList[0].yearValue1 + this.budgetList[1].yearValue1 + this.budgetList[2].yearValue1 + this.budgetList[8].yearValue1
this.totalYearValue2 = this.budgetList[0].yearValue2 + this.budgetList[1].yearValue2 + this.budgetList[2].yearValue2 + this.budgetList[8].yearValue2 this.totalYearValue2 = this.budgetList[0].yearValue2 + this.budgetList[1].yearValue2 + this.budgetList[2].yearValue2 + this.budgetList[8].yearValue2
this.totalYearValue3 = this.budgetList[0].yearValue3 + this.budgetList[1].yearValue3 + this.budgetList[2].yearValue3 + this.budgetList[8].yearValue3 this.totalYearValue3 = this.budgetList[0].yearValue3 + this.budgetList[1].yearValue3 + this.budgetList[2].yearValue3 + this.budgetList[8].yearValue3
...@@ -250,7 +260,9 @@ export default { ...@@ -250,7 +260,9 @@ export default {
budgetList: { budgetList: {
handler(budgetList) { handler(budgetList) {
this.calTotalFee() this.calTotalFee()
} },
deep: true,
immediate: true // 新增
} }
} }
} }
......
...@@ -111,7 +111,7 @@ export default { ...@@ -111,7 +111,7 @@ export default {
} }
}, },
created() { created() {
//this.calTotalFee() this.calTotalFee()
}, },
methods: { methods: {
FeeChange (index) { FeeChange (index) {
...@@ -142,6 +142,14 @@ export default { ...@@ -142,6 +142,14 @@ export default {
this.FeeChange(index) this.FeeChange(index)
}, },
calTotalFee() { calTotalFee() {
if (!this.budgetList || this.budgetList.length < 9) {
this.totalYearValue1 = 0
this.totalYearValue2 = 0
this.totalYearValue3 = 0
this.totalFee = 0
return
}
this.totalYearValue1 = this.budgetList[0].yearValue1 + this.budgetList[1].yearValue1 + this.budgetList[2].yearValue1 + this.budgetList[8].yearValue1 this.totalYearValue1 = this.budgetList[0].yearValue1 + this.budgetList[1].yearValue1 + this.budgetList[2].yearValue1 + this.budgetList[8].yearValue1
this.totalYearValue2 = this.budgetList[0].yearValue2 + this.budgetList[1].yearValue2 + this.budgetList[2].yearValue2 + this.budgetList[8].yearValue2 this.totalYearValue2 = this.budgetList[0].yearValue2 + this.budgetList[1].yearValue2 + this.budgetList[2].yearValue2 + this.budgetList[8].yearValue2
this.totalYearValue3 = this.budgetList[0].yearValue3 + this.budgetList[1].yearValue3 + this.budgetList[2].yearValue3 + this.budgetList[8].yearValue3 this.totalYearValue3 = this.budgetList[0].yearValue3 + this.budgetList[1].yearValue3 + this.budgetList[2].yearValue3 + this.budgetList[8].yearValue3
...@@ -206,7 +214,9 @@ export default { ...@@ -206,7 +214,9 @@ export default {
budgetList: { budgetList: {
handler(budgetList) { handler(budgetList) {
this.calTotalFee() this.calTotalFee()
} },
deep: true,
immediate: true // 新增
} }
} }
} }
......
...@@ -546,6 +546,12 @@ export default { ...@@ -546,6 +546,12 @@ export default {
} else { } else {
this.talentTypeId = 16 this.talentTypeId = 16
} }
if (talentType)
this.formData.talentType = talentType
else
this.formData.talentType = []
this.processBudgetType() this.processBudgetType()
}, },
processBudgetType () { processBudgetType () {
...@@ -556,8 +562,10 @@ export default { ...@@ -556,8 +562,10 @@ export default {
} else { } else {
this.budgetType = { type: 'RTTalent', trainingYear: this.talentTraningInfo.RTTrainingYear, EveryYearFee: this.talentTraningInfo.RTEveryYearFee } this.budgetType = { type: 'RTTalent', trainingYear: this.talentTraningInfo.RTTrainingYear, EveryYearFee: this.talentTraningInfo.RTEveryYearFee }
} }
if (!!!this.value.applyFund || this.value.applyFund == 0)
this.value.applyFund = this.budgetType.trainingYear * this.budgetType.EveryYearFee this.value.applyFund = this.budgetType.trainingYear * this.budgetType.EveryYearFee
this.FundChange()
} }
}, },
watch: { watch: {
......
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