lx
This commit is contained in:
@@ -76,6 +76,7 @@
|
||||
<template slot-scope="scope">
|
||||
<el-button type="primary" size="mini" class="el-icon-success" @click="Innumber">入库</el-button>
|
||||
<el-button
|
||||
:disabled="scope.row.是否禁用"
|
||||
size="mini"
|
||||
type="danger"
|
||||
class="el-icon-delete"
|
||||
@@ -90,7 +91,7 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { searchTable, insertOne, getinventory, getlocate } from '@/api/Inventory/GenneralPart'
|
||||
import { searchTable, insertOne, getinventory, getlocate } from '@/api/Inventory/Inboundscanning'
|
||||
import { mapGetters } from 'vuex'
|
||||
import { wsuri, name } from '@/utils/request'
|
||||
import print from '@/vendor/print'
|
||||
@@ -178,6 +179,8 @@ export default {
|
||||
if (response.data.length === 0) {
|
||||
this.listLoading = false
|
||||
this.$message.warning('无此零件')
|
||||
} else if (response.data[0].剩余数量 === 0) {
|
||||
this.$message.warning('该零件已入库完毕')
|
||||
} else {
|
||||
for (let i = 0; i < this.tableData.length; i++) {
|
||||
if (response.data[0].工艺计划流水号 === this.tableData[i].工艺计划流水号) {
|
||||
@@ -212,18 +215,26 @@ export default {
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
for (let i = 0; i < this.tableData.length; i++) {
|
||||
if (this.tableData[i].innumber > this.tableData[i].plannumber) {
|
||||
this.tableData[i].innumber = this.tableData[i].plannumber
|
||||
if (this.locateNumber === '') {
|
||||
this.$message.error('请选择货位')
|
||||
} else {
|
||||
for (let i = 0; i < this.tableData.length; i++) {
|
||||
if (this.tableData[i].innumber === '0') {
|
||||
this.$message.error('请输入正确数量')
|
||||
} else {
|
||||
if (this.tableData[i].innumber > this.tableData[i].plannumber) {
|
||||
this.tableData[i].innumber = this.tableData[i].plannumber
|
||||
}
|
||||
insertOne(this.tableData[i].工艺计划流水号, this.tableData[i].innumber, this.PeopleNumber, this.tableData[i].capture, this.inventoryNumber, this.locateNumber, this.tableData[i].note).then(response => {
|
||||
this.$message({
|
||||
type: 'success',
|
||||
message: '零件入库成功!'
|
||||
})
|
||||
}).then(() => {
|
||||
this.Empty()
|
||||
})
|
||||
}
|
||||
}
|
||||
insertOne(this.tableData[i].工艺计划流水号, this.tableData[i].innumber, this.PeopleNumber, this.tableData[i].capture, this.inventoryNumber, this.locateNumber, this.tableData[i].note).then(response => {
|
||||
this.$message({
|
||||
type: 'success',
|
||||
message: '零件入库成功!'
|
||||
})
|
||||
}).then(() => {
|
||||
this.Empty()
|
||||
})
|
||||
}
|
||||
}).catch(() => {
|
||||
this.$message({
|
||||
|
||||
@@ -91,7 +91,7 @@
|
||||
{{ scope.row.仓库名称 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="追溯码" width="150">
|
||||
<el-table-column align="center" label="二维码" width="150">
|
||||
<template slot-scope="scope">
|
||||
<canvas :id="canvas[scope.$index]" class="code"/>
|
||||
</template>
|
||||
|
||||
Reference in New Issue
Block a user