创建备料单备料到货
This commit is contained in:
@@ -44,7 +44,7 @@ export function edit2(num1) {
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '2',
|
||||
name: '车间生产管理工艺_备料单导出_状态更改',
|
||||
name: '车间生产管理工艺_备料单导出_外购备料',
|
||||
param: '工艺计划流水号=' + num1
|
||||
}
|
||||
})
|
||||
|
||||
@@ -48,3 +48,14 @@ export function change(Number, code, num) {
|
||||
}
|
||||
})
|
||||
}
|
||||
export function change2(Number, code, num) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '2',
|
||||
name: '车间生产管理工艺_外购备料到货更改',
|
||||
param: '工序流水号组=' + Number + '&工作者考勤编号=' + code + '&工艺计划流水号组=' + num
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
<el-checkbox v-model="all" size="mini">查询全部</el-checkbox>
|
||||
<el-button type="primary" size="small" icon="el-icon-download" style="margin-left:10px" @click="exportTable('BL')">导出备料单</el-button>
|
||||
<el-button type="primary" size="small" icon="el-icon-success" style="margin-left:10px" @click="edit()">自家备料</el-button>
|
||||
<el-button type="primary" size="small" icon="el-icon-success" style="margin-left:10px" @click="edit()">外购备料</el-button>
|
||||
<el-button type="primary" size="small" icon="el-icon-success" style="margin-left:10px" @click="edit2()">外购备料</el-button>
|
||||
</el-row>
|
||||
</el-card>
|
||||
|
||||
|
||||
@@ -5,8 +5,9 @@
|
||||
<span>零件图号:</span>
|
||||
<el-input v-model="partName" placeholder="零件图号" size="small" clearable style="width:200px"/>
|
||||
<el-button size="small" icon="el-icon-search" type="success" style="margin-left: 10px" @click="pageSize=10; pageCurrent=1;searchTable()">查询</el-button>
|
||||
<el-checkbox v-model="all" size="mini" @change="searchTable">查询全部</el-checkbox>
|
||||
<el-button :disabled="all" size="small" icon="el-icon-success" type="primary" style="margin-left: 10px" @click="edit()">到货</el-button>
|
||||
<!--<el-checkbox v-model="all" size="mini" @change="searchTable">查询全部</el-checkbox>-->
|
||||
<el-button :disabled="all" size="small" icon="el-icon-success" type="primary" style="margin-left: 10px" @click="edit()">自家备料出库</el-button>
|
||||
<el-button :disabled="all" size="small" icon="el-icon-success" type="primary" style="margin-left: 10px" @click="edit2()">外购备料出库</el-button>
|
||||
<!--<el-button size="small" icon="el-icon-refresh" type="success" style="margin-left: 10px" @click="pageSize=10; pageCurrent=1;searchTable()">刷新</el-button>-->
|
||||
</el-row>
|
||||
</el-card>
|
||||
@@ -51,12 +52,52 @@
|
||||
@current-change="handleCurrentChange"/>
|
||||
</div>
|
||||
</el-card>
|
||||
<el-card>
|
||||
<el-table v-loading="loading" :data="tableData" height="580" style="width: 100%;" border element-loading-text="拼命加载中" @selection-change="handleSelectionChange">
|
||||
<el-table-column
|
||||
type="selection"
|
||||
width="55"
|
||||
align="center"/>
|
||||
<el-table-column label="到货状态" width="100" align="center">
|
||||
<template slot-scope="scope">
|
||||
<el-tag v-if="scope.row.备料到货==='1'" type="success" size="small">已到货</el-tag>
|
||||
<el-tag v-if="scope.row.备料到货==='0'" type="warning" size="small">未到货</el-tag>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="零件名称" align="center" width="220px">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.零件名称 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="零件图号" align="center" width="240px">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.零件图号 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="备料" align="center">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.工艺要求 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<div class="block">
|
||||
<el-pagination
|
||||
v-if="!loading"
|
||||
:current-page="pageCurrent"
|
||||
:page-sizes="[10, 20, 30, 40, 100]"
|
||||
:page-size="pageSize"
|
||||
:total="total"
|
||||
layout="total, sizes, prev, pager, next, jumper"
|
||||
@size-change="handleSizeChange"
|
||||
@current-change="handleCurrentChange"/>
|
||||
</div>
|
||||
</el-card>
|
||||
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { searchtable, searchtable2, change } from '@/api/ManufacturingCenter/MaterialArrivalManagement'
|
||||
import { searchtable, searchtable2, change, change2 } from '@/api/ManufacturingCenter/MaterialArrivalManagement'
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
@@ -114,6 +155,8 @@ export default {
|
||||
this.arrest = val
|
||||
},
|
||||
edit() {
|
||||
this.bianliang1 = []
|
||||
this.bianliang2 = []
|
||||
if (this.arrest.length === 0) {
|
||||
this.$message.warning('请选择零件')
|
||||
} else {
|
||||
@@ -126,6 +169,21 @@ export default {
|
||||
})
|
||||
}
|
||||
},
|
||||
edit2() {
|
||||
this.bianliang1 = []
|
||||
this.bianliang2 = []
|
||||
if (this.arrest.length === 0) {
|
||||
this.$message.warning('请选择零件')
|
||||
} else {
|
||||
for (let i = 0; i < this.arrest.length; i++) {
|
||||
this.bianliang1.push(this.arrest[i].工艺计划流水号)
|
||||
this.bianliang2.push(this.arrest[i].工序流水号)
|
||||
}
|
||||
change2(this.bianliang2, '0000', this.bianliang1).then(() => {
|
||||
this.searchTable()
|
||||
})
|
||||
}
|
||||
},
|
||||
// 分页
|
||||
handleSizeChange(val) {
|
||||
this.pageCurrent = 1
|
||||
|
||||
Reference in New Issue
Block a user