| | |
| | | > |
| | | <template slot-scope="{row}"> |
| | | <div class="operationClass"> |
| | | <el-button v-show="row.isVisible===1" type="text" @click="saveRow(row)">保存</el-button> |
| | | <el-button v-show="row.isVisible===1" type="text" @click="cancelRow(row)">取消</el-button> |
| | | <el-button v-show="row.isVisible===0" type="text" @click="editRow(row)">编辑</el-button> |
| | | <el-button v-show="row.isVisible===0" type="text" @click="copyRow(row)">复制</el-button> |
| | | <el-button v-if="row.isVisible===1" type="text" @click="saveRow(row)">保存</el-button> |
| | | <el-button v-if="row.isVisible===1" type="text" @click="cancelRow(row)">取消</el-button> |
| | | <el-button v-if="row.isVisible===0" type="text" @click="editRow(row)">编辑</el-button> |
| | | <el-button v-if="row.isVisible===0" type="text" @click="copyRow(row)">复制</el-button> |
| | | </div> |
| | | </template> |
| | | </el-table-column> |
| | |
| | | }, |
| | | // 保存行 |
| | | async saveRow(row) { |
| | | if (parseFloat(row.unprice) <= 0) { |
| | | return this.$message.info('计件单价必须大于零!') |
| | | } |
| | | const data = { |
| | | partcode: this.eqpTable.partcode, // 产品编码 |
| | | routecode: this.eqpTable.routecode, // 工艺路线编码 |
| | |
| | | // 取消行 |
| | | cancelRow(row) { |
| | | this.getEqpTable() |
| | | this.radioChange(this.radioChangeTempValue) |
| | | this.dialogForm.stepcode = this.radioChangeTempValue |
| | | this.isEqpTableEdit = true |
| | | }, |
| | | // 编辑行 |