This commit is contained in:
Vergil
2020-02-06 12:01:58 +08:00
3 changed files with 26 additions and 25 deletions

View File

@@ -113,7 +113,7 @@
{{ scope.row.零件名称 }}
</template>
</el-table-column>
<el-table-column label="规格" prop="规格" align="center">
<el-table-column label="规格" prop="规格" align="center" width="170">
<template slot-scope="scope">
{{ scope.row.规格 }}
</template>
@@ -148,17 +148,19 @@
{{ scope.row.零件类型名称 }}
</template>
</el-table-column>
<el-table-column label="操作" width="200px" fixed="right" align="center">
<el-table-column label="操作" width="170px" fixed="right" align="center">
<template slot-scope="scope">
<el-button
:disabled="checked_hebing"
size="mini"
type="primary"
style="padding: 4px 8px"
plain
@click="handleEdit(scope.$index, scope.row, 'form')">分批投产</el-button>
<el-button
size="mini"
type="primary"
style="padding: 4px 8px"
plain
@click="handleEditNumber(scope.$index, scope.row)">更改数量</el-button>
</template>
@@ -456,27 +458,27 @@ export default {
'id'
])
},
watch: {
// 如果路由有变化,会再次执行该方法
'$route'(to) {
const _this = this
console.log(to, 2222)
if (to.name === 'InitialProduction') {
_this.typeChange()
}
}
// '$route': {
// handler(route) {
// const _this = this
// console.log(route.name)
// if (route.name === 'InitialProduction') {
// _this.typeChange()
// }
// }
// }
},
// watch: {
// // 如果路由有变化,会再次执行该方法
// '$route'(to) {
// const _this = this
// console.log(to, 2222)
// if (to.name === 'InitialProduction') {
// _this.typeChange()
// }
// }
// // '$route': {
// // handler(route) {
// // const _this = this
// // console.log(route.name)
// // if (route.name === 'InitialProduction') {
// // _this.typeChange()
// // }
// // }
// // }
// },
created() {
// this.typeChange()
this.typeChange()
this.getCurrentTime()
this.getNowTime()
},

View File

@@ -36,7 +36,6 @@
height="750"
highlight-current-row
border
stripe
@selection-change="handleSelectionChange">
<el-table-column align="center" type="selection"/>
<el-table-column align="center" label="零件号" prop="零件号" width="160">

View File

@@ -245,7 +245,7 @@
<el-button
:disabled="Number(id)!==0"
size="mini"
plsin
plain
type="danger"
icon="el-icon-delete"
@click="handleDelete(scope.row)">删除</el-button>
@@ -290,7 +290,7 @@
<el-input v-model="form.零件名称" placeholder="零件名称" size="small" style="width:200px" clearable/>
</el-form-item>
<el-form-item label="零件数量" prop="零件数量" style="margin-left: 70px">
<el-input v-model="form.零件数量" placeholder="零件数量" size="small" style="width:200px" clearable/>
<el-input-number v-model="form.零件数量" :step="1" :min="0" size="mini" style="width:200px"/>
</el-form-item>
<el-form-item label="零件备注" prop="零件备注" style="margin-left: 70px">
<el-input v-model="form.零件备注" placeholder="零件备注" size="small" style="width:200px" clearable/>