Commit 200a9754 authored by wangxl's avatar wangxl
parents cb8e2abf ef40cc57
...@@ -69,8 +69,8 @@ export default { ...@@ -69,8 +69,8 @@ export default {
data() { data() {
return { return {
invisibleTotalBudget: [], invisibleTotalBudget: [],
invisibleApplyFunds: [0, 3, 4], invisibleApplyFunds: [0, 2, 3, 4],
invisibleSelfFunds: [0, 3, 4], invisibleSelfFunds: [0, 1, 3, 4],
}; };
}, },
props: { props: {
......
...@@ -90,12 +90,12 @@ ...@@ -90,12 +90,12 @@
</a-col> </a-col>
<a-col :span="2"> <a-col :span="2">
<a-form-model-item :prop="'equipments.' + index + '.unitPrice'" :rules="{required: true, message: '*', trigger: 'blur',}"> <a-form-model-item :prop="'equipments.' + index + '.unitPrice'" :rules="{required: true, message: '*', trigger: 'blur',}">
<a-input-number v-model="item.unitPrice" @change="outUnitPriceChange(index)" :min="0" :step="0.01" style="width: 80%" /> <a-input-number v-model="item.unitPrice" @change="outUnitPriceChange(index)" :min="0" :step="0.01" style="width: 90%" />
</a-form-model-item> </a-form-model-item>
</a-col> </a-col>
<a-col :span="1"> <a-col :span="1">
<a-form-model-item :prop="'equipments.' + index + '.quantity'" :rules="{required: true, message: '*', trigger: 'blur',}"> <a-form-model-item :prop="'equipments.' + index + '.quantity'" :rules="{required: true, message: '*', trigger: 'blur',}">
<a-input-number v-model="item.quantity" @change="outNumberChange(index)" :min="1" :step="1" style="width: 80%" /> <a-input-number v-model="item.quantity" @change="outNumberChange(index)" :min="1" :step="1" style="width: 90%" />
</a-form-model-item> </a-form-model-item>
</a-col> </a-col>
<a-col :span="2"> <a-col :span="2">
...@@ -114,27 +114,27 @@ ...@@ -114,27 +114,27 @@
</a-form-model-item> </a-form-model-item>
</a-col> </a-col>
<a-col :span="2"> <a-col :span="2">
<a-form-model-item :prop="'equipments.' + index + '.equipmentType'" :rules="{required: true, message: '*', trigger: 'blur',}"> <a-form-model-item :prop="'equipments.' + index + '.equipmentType'" :rules="{required: false, message: '*', trigger: 'blur',}">
<a-input v-model="item.equipmentType" :maxLength="100" style="width: 90%;" /> <a-input v-model="item.equipmentType" :maxLength="100" style="width: 90%;" />
</a-form-model-item> </a-form-model-item>
</a-col> </a-col>
<a-col :span="2"> <a-col :span="2">
<a-form-model-item :prop="'equipments.' + index + '.manufacturer'" :rules="{required: true, message: '*', trigger: 'blur',}"> <a-form-model-item :prop="'equipments.' + index + '.manufacturer'" :rules="{required: false, message: '*', trigger: 'blur',}">
<a-input v-model="item.manufacturer" :maxLength="100" style="width: 90%;" /> <a-input v-model="item.manufacturer" :maxLength="100" style="width: 90%;" />
</a-form-model-item> </a-form-model-item>
</a-col> </a-col>
<a-col :span="2"> <a-col :span="2">
<a-form-model-item :prop="'equipments.' + index + '.specificationType'" :rules="{required: true, message: '*', trigger: 'blur',}"> <a-form-model-item :prop="'equipments.' + index + '.specificationType'" :rules="{required: false, message: '*', trigger: 'blur',}">
<a-input v-model="item.specificationType" :maxLength="100" style="width: 90%;" /> <a-input v-model="item.specificationType" :maxLength="100" style="width: 90%;" />
</a-form-model-item> </a-form-model-item>
</a-col> </a-col>
<a-col :span="2"> <a-col :span="2">
<a-form-model-item :prop="'equipments.' + index + '.sharedScope'" :rules="{required: true, message: '*', trigger: 'blur',}"> <a-form-model-item :prop="'equipments.' + index + '.sharedScope'" :rules="{required: false, message: '*', trigger: 'blur',}">
<a-input v-model="item.sharedScope" :maxLength="100" style="width: 90%;" /> <a-input v-model="item.sharedScope" :maxLength="100" style="width: 90%;" />
</a-form-model-item> </a-form-model-item>
</a-col> </a-col>
<a-col :span="2"> <a-col :span="2">
<a-form-model-item :prop="'equipments.' + index + '.useFrom'" :rules="{required: true, message: '*', trigger: 'blur',}"> <a-form-model-item :prop="'equipments.' + index + '.useFrom'" :rules="{required: false, message: '*', trigger: 'blur',}">
<a-input v-model="item.useFrom" :maxLength="200" style="width: 90%;" /> <a-input v-model="item.useFrom" :maxLength="200" style="width: 90%;" />
</a-form-model-item> </a-form-model-item>
</a-col> </a-col>
...@@ -342,5 +342,13 @@ export default { ...@@ -342,5 +342,13 @@ export default {
this.calNumberAmount() this.calNumberAmount()
}, },
}, },
watch: {
equipments: {
handler (equipments) {
if (!!equipments)
this.calNumberAmount()
},
},
}
}; };
</script> </script>
\ No newline at end of file
...@@ -89,7 +89,7 @@ ...@@ -89,7 +89,7 @@
</a-col> </a-col>
<a-col :span="2"> <a-col :span="2">
<a-form-model-item :prop="'unitPayment.' + index + '.unitRole'" :rules="{required: true, message: '*', trigger: 'blur',}"> <a-form-model-item :prop="'unitPayment.' + index + '.unitRole'" :rules="{required: true, message: '*', trigger: 'blur',}">
<a-input v-model="item.unitRole" :maxLength="100" style="width: 90%;" /> <para-select v-model="item.unitRole" :typeId="65" :isAll="true" :width="110" />
</a-form-model-item> </a-form-model-item>
</a-col> </a-col>
<a-col :span="4"> <a-col :span="4">
...@@ -151,6 +151,8 @@ ...@@ -151,6 +151,8 @@
</template> </template>
<script> <script>
import paraSelect from '@/views/components/common/paraSelect'
const Payment = { const Payment = {
id: "", id: "",
objectId: "", objectId: "",
...@@ -168,6 +170,9 @@ const Payment = { ...@@ -168,6 +170,9 @@ const Payment = {
export default { export default {
name: "UnitPaymentEdit", name: "UnitPaymentEdit",
components: {
paraSelect
},
props: { props: {
unitPayment: { unitPayment: {
type: Array, type: Array,
...@@ -184,6 +189,8 @@ export default { ...@@ -184,6 +189,8 @@ export default {
TselfAmount: 0.00, TselfAmount: 0.00,
}; };
}, },
created() {
},
methods: { methods: {
addArrey() { addArrey() {
this.unitPayment.push(Object.assign({ ...Payment })) this.unitPayment.push(Object.assign({ ...Payment }))
...@@ -220,5 +227,13 @@ export default { ...@@ -220,5 +227,13 @@ export default {
}) })
} }
}, },
watch: {
unitPayment: {
handler (unitPayment) {
if (!!unitPayment)
this.calTotalAmount()
},
},
}
}; };
</script> </script>
\ No newline at end of file
...@@ -166,6 +166,8 @@ export default { ...@@ -166,6 +166,8 @@ export default {
TselfAmount: 0.00, TselfAmount: 0.00,
}; };
}, },
created() {
},
methods: { methods: {
outAmountChange(index) { outAmountChange(index) {
this.unitPayment[index].totalAmount = this.unitPayment[index].fundAmount + this.unitPayment[index].selfAmount this.unitPayment[index].totalAmount = this.unitPayment[index].fundAmount + this.unitPayment[index].selfAmount
...@@ -193,5 +195,13 @@ export default { ...@@ -193,5 +195,13 @@ export default {
}) })
} }
}, },
watch: {
unitPayment: {
handler (unitPayment) {
if (!!unitPayment)
this.calTotalAmount()
},
},
}
}; };
</script> </script>
\ No newline at end of file
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