|
|
|
|
@ -388,7 +388,7 @@ |
|
|
|
|
width="70%" :key="Math.random()"> |
|
|
|
|
<el-table :data="materialData" border style="width: 98%"> |
|
|
|
|
<el-table-column width="50" align="center" v-if="viewType == 'submit'"> |
|
|
|
|
<template slot="header" slot-scope="scope" > |
|
|
|
|
<template slot="header" slot-scope="scope"> |
|
|
|
|
<div @click="addColumn()" |
|
|
|
|
style="width:30px;height: 30px;background: #409eff;border-radius: 50%;cursor: pointer;display: flex;align-items: center;justify-content: center;"> |
|
|
|
|
<i style="color:#fff;font-size: 20px;" class="el-icon-plus"></i> |
|
|
|
|
@ -415,8 +415,8 @@ |
|
|
|
|
</el-table-column> |
|
|
|
|
<el-table-column prop="rule" align="center" label="规格" width="150"> |
|
|
|
|
<template slot-scope="scope"> |
|
|
|
|
<el-input v-if="scope.row.goodsName == '其他'" v-model="scope.row.rule" placeholder="请输入规格" |
|
|
|
|
style="width:98%;" size="mini"></el-input> |
|
|
|
|
<el-input v-if="scope.row.goodsName == '其他'" v-model="scope.row.rule" placeholder="请输入规格" style="width:98%;" |
|
|
|
|
size="mini"></el-input> |
|
|
|
|
<span v-else>{{ scope.row.rule }}</span> |
|
|
|
|
</template> |
|
|
|
|
</el-table-column> |
|
|
|
|
@ -436,8 +436,8 @@ |
|
|
|
|
</el-table-column> |
|
|
|
|
<el-table-column prop="unit" align="center" label="单位" width="150"> |
|
|
|
|
<template slot-scope="scope"> |
|
|
|
|
<el-input v-if="scope.row.goodsName == '其他'" v-model="scope.row.unit" placeholder="请输入单位" |
|
|
|
|
style="width:98%;" size="mini"></el-input> |
|
|
|
|
<el-input v-if="scope.row.goodsName == '其他'" v-model="scope.row.unit" placeholder="请输入单位" style="width:98%;" |
|
|
|
|
size="mini"></el-input> |
|
|
|
|
<span v-else>{{ scope.row.unit }}</span> |
|
|
|
|
</template> |
|
|
|
|
</el-table-column> |
|
|
|
|
@ -663,13 +663,13 @@ export default { |
|
|
|
|
const value = Number(curr); |
|
|
|
|
|
|
|
|
|
if (!isNaN(value)) { |
|
|
|
|
return Number(prev)+Number(curr); |
|
|
|
|
return Number(prev) + Number(curr); |
|
|
|
|
} else { |
|
|
|
|
return Number(prev); |
|
|
|
|
} |
|
|
|
|
}, 0); |
|
|
|
|
|
|
|
|
|
sums[columns.length - 1] = sums[columns.length - 1] > 0 ?Math.round(sums[columns.length - 1] * 100) / 100 : 0 |
|
|
|
|
sums[columns.length - 1] = sums[columns.length - 1] > 0 ? Math.round(sums[columns.length - 1] * 100) / 100 : 0 |
|
|
|
|
this.totalPrice = sums[columns.length - 1] |
|
|
|
|
sums[columns.length - 1] += ' 元'; |
|
|
|
|
} |
|
|
|
|
@ -1023,9 +1023,8 @@ export default { |
|
|
|
|
this.errorForm.approveResultManager = '' |
|
|
|
|
this.errorForm.approveRemarkManager = '' |
|
|
|
|
// 处理维修总金额 |
|
|
|
|
this.errorForm.actualAmount = (this.errorForm.totalPrice ? this.errorForm.totalPrice : 0) + this.errorForm.travelExpense ? Number(this.errorForm.travelExpense) : 0 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
let priceAll = this.errorForm.totalPrice ? this.errorForm.totalPrice + this.errorForm.travelExpense : 0 |
|
|
|
|
this.errorForm.actualAmount = Math.round(priceAll * 100) / 100 |
|
|
|
|
} |
|
|
|
|
}) |
|
|
|
|
}, |
|
|
|
|
|