领料单

This commit is contained in:
liushuai
2020-02-06 17:19:39 +08:00
parent 5bd500cada
commit aedc8fd873
4 changed files with 91 additions and 79 deletions

View File

@@ -42,8 +42,8 @@ export function searchTable(...params) {
data: { data: {
type: '1', type: '1',
name: '车间装配管理_领料单_三表_查询数据', name: '车间装配管理_领料单_三表_查询数据',
param: `机床流水号_check=${params[0]}&机床流水号=${params[1]}&组件流水号_check=${params[2]}&组件流水号=${params[3]}&名称_check=${params[4]}&名称=${params[5]}&型号_check=${params[6]}&型号=${params[7]}&规格_check=${params[8]}&规格=${params[9]}&领料情况_check=${params[10]}&领料情况=${params[11]}&零件类型=${params[14]}`, param: `机床流水号_check=${params[0]}&机床流水号=${params[1]}&组件流水号_check=${params[2]}&组件流水号=${params[3]}&名称_check=${params[4]}&名称=${params[5]}&领料情况_check=${params[6]}&领料情况=${params[7]}&零件类型=${params[10]}`,
Pagination: params[12] + '&' + params[13] Pagination: params[8] + '&' + params[9]
} }
}) })
} }
@@ -54,20 +54,20 @@ export function searchPart(...params) {
data: { data: {
type: '1', type: '1',
name: '库存管理_离线外购件_出库查询', name: '库存管理_离线外购件_出库查询',
param: `物料名称_check=${params[0]}&物料名称=${params[1]}&物料规格_check=${params[2]}&物料规格=${params[3]}&物料型号_check=${params[4]}&物料型号=${params[5]}`, param: `物料名称_check=${params[0]}&物料名称=${params[1]}`,
Pagination: params[6] + '&' + params[7] Pagination: params[2] + '&' + params[3]
} }
}) })
} }
// 领料单查询 // 领料单查询
export function searchList(pageCurrent, pageSize, listNumber_check, listNumber, isElectrical) { export function searchList(pageCurrent, pageSize, listPeople_check, listPeople, isElectrical, check1, time1, time2) {
return request({ return request({
url: '', url: '',
method: 'post', method: 'post',
data: { data: {
type: '1', type: '1',
name: '车间装配管理_领料单_查询数据', name: '车间装配管理_领料单_查询数据',
param: '领料单编号_check=' + listNumber_check + '&领料单编号=' + listNumber + '&是否电气=' + isElectrical, param: '制单人_check=' + listPeople_check + '&制单人=' + listPeople + '&是否电气=' + isElectrical + '&时间段_check=' + check1 + '&开始时间=' + time1 + '&结束时间=' + time2,
Pagination: pageCurrent + '&' + pageSize Pagination: pageCurrent + '&' + pageSize
} }
}) })

View File

@@ -20,17 +20,14 @@
:label="item.label" :label="item.label"
:value="item.value"/> :value="item.value"/>
</el-select> </el-select>
<el-select v-model="PickingValue" placeholder="领料情况" size="small" style="width: 120px" clearable> <el-input v-model="Name" placeholder="物料名称、规格、型号" clearable style="width: 200px" size="small"/>
<el-option <el-switch
v-for="item in Picking" v-model="PickingValue"
:key="item.value" active-color="#13ce66"
:label="item.label" inactive-color="#ff4949"
:value="item.value"/> style="margin-left: 5px"/>
</el-select> <span>已领用</span>
<el-input v-model="Name" placeholder="名称" clearable style="width: 120px" size="small"/> <el-button size="small" type="primary" plain icon="el-icon-search" style="margin: 0 0 0 10px" @click="pageCurrent0=1;pageSize0=300;pageCurrent1=1;pageSize1=300;pageCurrent2=1;pageSize2=300;pageCurrent4=1;pageSize4=20;searchTable()">查询</el-button>
<el-input v-model="materialSpec" placeholder="物料规格" style="width: 120px" clearable size="small"/>
<el-input v-model="materialModel" placeholder="物料型号" style="width: 120px" clearable size="small"/>
<el-button size="small" type="success" icon="el-icon-search" style="margin: 0 0 0 10px" @click="pageCurrent0=1;pageSize0=300;pageCurrent1=1;pageSize1=300;pageCurrent2=1;pageSize2=300;pageCurrent4=1;pageSize4=20;searchTable()">查询</el-button>
</el-row> </el-row>
</div> </div>
<el-tabs v-model="PartType" type="card" @tab-click="searchTable()"> <el-tabs v-model="PartType" type="card" @tab-click="searchTable()">
@@ -254,13 +251,24 @@
<div slot="header"> <div slot="header">
<el-card> <el-card>
<el-row style="margin-top: 5px"> <el-row style="margin-top: 5px">
<el-input v-model="pickingListNumber" clearable size="small" placeholder="领料单编号" style="width:120px;margin-left: 10px" /> <el-date-picker
<el-button size="small" type="success" icon="el-icon-search" style="margin: 0 0 0 10px" @click="searchList()">查询</el-button> v-model="startTime"
<el-button size="small" type="primary" icon="el-icon-plus" style="margin: 0 0 0 10px" @click="createList()">创建领料单</el-button> size="small"
type="daterange"
align="center"
value-format="yyyy-MM-dd"
format="yyyy-MM-dd"
range-separator=""
style="width:250px"
start-placeholder="开始日期"
end-placeholder="结束日期"/>
<el-input v-model="pickingListPeople" clearable size="small" placeholder="制单人" style="width:120px;margin-left: 10px" />
<el-button size="small" type="primary" plain icon="el-icon-search" style="margin: 0 0 0 10px" @click="searchList()">查询</el-button>
<el-button size="small" type="warning" plain icon="el-icon-plus" style="margin: 0 0 0 10px" @click="createList()">创建领料单</el-button>
<el-tooltip :open-delay="1200" effect="dark" content="为所选领料单增加物料明细" placement="top"> <el-tooltip :open-delay="1200" effect="dark" content="为所选领料单增加物料明细" placement="top">
<el-button size="small" type="warning" icon="el-icon-bottom" style="margin: 0 0 5px 10px" @click="selectInto()">选入物料</el-button> <el-button size="small" type="success" plain icon="el-icon-bottom" style="margin: 0 0 5px 10px" @click="selectInto()">选入物料</el-button>
</el-tooltip> </el-tooltip>
<el-button :disabled="Number(审批情况)===1" size="small" type="danger" icon="el-icon-delete" style="margin: 0 0 0 10px" @click="dropList()">删除领料单</el-button> <el-button :disabled="Number(审批情况)===1" size="small" plain type="danger" icon="el-icon-delete" style="margin: 0 0 0 10px" @click="dropList()">删除领料单</el-button>
<el-button :disabled="Number(审批情况)===1" size="small" plain type="danger" icon="el-icon-delete" style="margin-right: 20px;float: right" @click="dropListDetail()">移除领料明细</el-button> <el-button :disabled="Number(审批情况)===1" size="small" plain type="danger" icon="el-icon-delete" style="margin-right: 20px;float: right" @click="dropListDetail()">移除领料明细</el-button>
</el-row> </el-row>
</el-card> </el-card>
@@ -273,7 +281,7 @@
{{ scope.row.领料单编号 }} {{ scope.row.领料单编号 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="领料人" prop="领料人" align="center" min-width="90px"> <el-table-column label="制单人" prop="制单人" align="center" min-width="90px">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.姓名 }} {{ scope.row.姓名 }}
</template> </template>
@@ -340,16 +348,16 @@
{{ scope.row.出库数量1 }} {{ scope.row.出库数量1 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column v-if="true" label="备料确认" align="center" prop="是否备料确认" min-width="75px"> <!--<el-table-column v-if="true" label="备料确认" align="center" prop="是否备料确认" min-width="75px">-->
<template slot-scope="scope"> <!--<template slot-scope="scope">-->
<el-tag v-if="Number(scope.row.是否备料确认)===1" type="success" size="mini">已备料</el-tag> <!--<el-tag v-if="Number(scope.row.是否备料确认)===1" type="success" size="mini">已备料</el-tag>-->
<el-tag v-else type="warning" size="mini">未备料</el-tag> <!--<el-tag v-else type="warning" size="mini">未备料</el-tag>-->
</template> <!--</template>-->
</el-table-column> <!--</el-table-column>-->
<el-table-column v-if="true" label="领料确认" align="center" prop="是否领料确认" width="75px"> <el-table-column v-if="true" label="领料确认" align="center" prop="是否领料确认" width="75px">
<template slot-scope="scope"> <template slot-scope="scope">
<el-tag v-if="(Number(scope.row.总数量) <= Number(scope.row.出库数量1)) || Number(scope.row.是否领料确认) === 1" type="success" size="mini">已领</el-tag> <el-tag v-if="(Number(scope.row.总数量) <= Number(scope.row.出库数量1)) || Number(scope.row.是否领料确认) === 1" type="success" size="mini">已领</el-tag>
<el-tag v-else-if="Number(scope.row.总数量) > Number(scope.row.出库数量1) && Number(scope.row.出库数量1) > 0" type="primary" size="mini">未领完</el-tag> <el-tag v-else-if="Number(scope.row.总数量) > Number(scope.row.出库数量1) && Number(scope.row.出库数量1) > 0" type="primary" size="mini">部分领用</el-tag>
<el-tag v-else-if="Number(scope.row.出库数量1) === 0" type="warning" size="mini">未领料</el-tag> <el-tag v-else-if="Number(scope.row.出库数量1) === 0" type="warning" size="mini">未领料</el-tag>
</template> </template>
</el-table-column> </el-table-column>
@@ -358,7 +366,7 @@
<el-popover placement="right" width="500" trigger="click"> <el-popover placement="right" width="500" trigger="click">
<el-table :data="gridData" highlight-current-row size="mini" show-summary> <el-table :data="gridData" highlight-current-row size="mini" show-summary>
<el-table-column width="50" align="center" type="index" label="序号"/> <el-table-column width="50" align="center" type="index" label="序号"/>
<el-table-column min-width="100" align="center" label="姓名"> <el-table-column min-width="100" align="center" label="领料人">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.姓名 }} {{ scope.row.姓名 }}
</template> </template>
@@ -384,7 +392,7 @@
<el-dialog v-el-drag-dialog :visible.sync="dialogFormVisible1" title="创建领料单" center width="380px"> <el-dialog v-el-drag-dialog :visible.sync="dialogFormVisible1" title="创建领料单" center width="380px">
<el-form ref="form1" :model="form1" :rules="rules1" label-position="left"> <el-form ref="form1" :model="form1" :rules="rules1" label-position="left">
<el-form-item label="领料人" prop="领料人流水号" label-width="100px" size="small"> <el-form-item label="制单人" prop="领料人流水号" label-width="100px" size="small">
<el-select v-model="form1.领料人流水号" placeholder="请选择" size="small" clearable filterable> <el-select v-model="form1.领料人流水号" placeholder="请选择" size="small" clearable filterable>
<el-option <el-option
v-for="item in pickPerson" v-for="item in pickPerson"
@@ -416,12 +424,13 @@ export default {
审批情况: '', 审批情况: '',
peopleName: '', peopleName: '',
ListMX: '', ListMX: '',
startTime: '',
PartType: '基本件', PartType: '基本件',
machineNumberValue: '', machineNumberValue: '',
machineNumber: [], machineNumber: [],
MachineNumber: '', MachineNumber: '',
tableDataBasic: [], tableDataBasic: [],
PickingValue: '', PickingValue: false,
Picking: [{ Picking: [{
value: 0, value: 0,
label: '未领' label: '未领'
@@ -462,10 +471,10 @@ export default {
领料单备注: '' 领料单备注: ''
}, },
rules1: { rules1: {
领料人流水号: [{ required: true, message: '请选择领料人' }] 领料人流水号: [{ required: true, message: '请选择制单人' }]
}, },
pickPerson: [], pickPerson: [],
pickingListNumber: '', // 领料单编号 pickingListPeople: '', // 制单人
pickingListNumberShow: '', // 领料单编号 pickingListNumberShow: '', // 领料单编号
pickingListNum: '', // 领料单流水号 pickingListNum: '', // 领料单流水号
multipleSelection: [], multipleSelection: [],
@@ -501,7 +510,6 @@ export default {
request(param).then(res => { request(param).then(res => {
if (res.data[0].result === '1') { if (res.data[0].result === '1') {
this.$message.success('操作成功') this.$message.success('操作成功')
this.pickingListNumber = ''
this.searchList() this.searchList()
} else { } else {
this.$message.error('操作失败') this.$message.error('操作失败')
@@ -580,67 +588,68 @@ export default {
}, },
// 标准件 // 标准件
searchTable0() { searchTable0() {
let check1, check2, check3, check4, check5, check6 let check1, check2, check3
this.machineNumberValue ? check1 = 1 : check1 = 0 this.machineNumberValue ? check1 = 1 : check1 = 0
this.groupNumberValue ? check2 = 1 : check2 = 0 this.groupNumberValue ? check2 = 1 : check2 = 0
this.Name ? check3 = 1 : check3 = 0 this.Name ? check3 = 1 : check3 = 0
this.materialModel ? check4 = 1 : check4 = 0 console.log(this.PickingValue, 111)
this.materialSpec ? check5 = 1 : check5 = 0 if (this.PickingValue === false) {
if (this.PickingValue !== 0 && this.PickingValue !== 1) { searchTable(check1, this.machineNumberValue, check2, this.groupNumberValue, check3, this.Name, 1, 0, this.pageCurrent0, this.pageSize0, 1).then(response => {
check6 = 0 this.tableData0 = response.data.rows
this.total0 = response.data.total
})
} else { } else {
check6 = 1 searchTable(check1, this.machineNumberValue, check2, this.groupNumberValue, check3, this.Name, 1, 1, this.pageCurrent0, this.pageSize0, 1).then(response => {
this.tableData0 = response.data.rows
this.total0 = response.data.total
})
} }
searchTable(check1, this.machineNumberValue, check2, this.groupNumberValue, check3, this.Name, check4, this.materialModel, check5, this.materialSpec, check6, this.PickingValue, this.pageCurrent0, this.pageSize0, 1).then(response => {
this.tableData0 = response.data.rows
this.total0 = response.data.total
})
}, },
// 外购件 // 外购件
searchTable1() { searchTable1() {
let check1, check2, check3, check4, check5, check6 let check1, check2, check3
this.machineNumberValue ? check1 = 1 : check1 = 0 this.machineNumberValue ? check1 = 1 : check1 = 0
this.groupNumberValue ? check2 = 1 : check2 = 0 this.groupNumberValue ? check2 = 1 : check2 = 0
this.Name ? check3 = 1 : check3 = 0 this.Name ? check3 = 1 : check3 = 0
this.materialModel ? check4 = 1 : check4 = 0 console.log(this.PickingValue, 111)
this.materialSpec ? check5 = 1 : check5 = 0 if (this.PickingValue === false) {
if (this.PickingValue !== 0 && this.PickingValue !== 1) { searchTable(check1, this.machineNumberValue, check2, this.groupNumberValue, check3, this.Name, 1, 0, this.pageCurrent1, this.pageSize1, 2).then(response => {
check6 = 0 this.tableData0 = response.data.rows
this.total0 = response.data.total
})
} else { } else {
check6 = 1 searchTable(check1, this.machineNumberValue, check2, this.groupNumberValue, check3, this.Name, 1, 1, this.pageCurrent1, this.pageSize1, 2).then(response => {
this.tableData0 = response.data.rows
this.total0 = response.data.total
})
} }
searchTable(check1, this.machineNumberValue, check2, this.groupNumberValue, check3, this.Name, check4, this.materialModel, check5, this.materialSpec, check6, this.PickingValue, this.pageCurrent1, this.pageSize1, 2).then(response => {
this.tableData1 = response.data.rows
this.total1 = response.data.total
})
}, },
// 基本件 // 基本件
searchTable2() { searchTable2() {
let check1, check2, check3, check4, check5, check6 let check1, check2, check3
this.machineNumberValue ? check1 = 1 : check1 = 0 this.machineNumberValue ? check1 = 1 : check1 = 0
this.groupNumberValue ? check2 = 1 : check2 = 0 this.groupNumberValue ? check2 = 1 : check2 = 0
this.Name ? check3 = 1 : check3 = 0 this.Name ? check3 = 1 : check3 = 0
this.materialModel ? check4 = 1 : check4 = 0 console.log(this.PickingValue, 111)
this.materialSpec ? check5 = 1 : check5 = 0 if (this.PickingValue === false) {
if (this.PickingValue !== 0 && this.PickingValue !== 1) { searchTable(check1, this.machineNumberValue, check2, this.groupNumberValue, check3, this.Name, 1, 0, this.pageCurrent2, this.pageSize2, 3).then(response => {
check6 = 0 this.tableData0 = response.data.rows
this.total0 = response.data.total
})
} else { } else {
check6 = 1 searchTable(check1, this.machineNumberValue, check2, this.groupNumberValue, check3, this.Name, 1, 1, this.pageCurrent2, this.pageSize2, 3).then(response => {
this.tableData0 = response.data.rows
this.total0 = response.data.total
})
} }
searchTable(check1, this.machineNumberValue, check2, this.groupNumberValue, check3, this.Name, check4, this.materialModel, check5, this.materialSpec, check6, this.PickingValue, this.pageCurrent2, this.pageSize2, 3).then(response => {
this.tableData2 = response.data.rows
this.total2 = response.data.total
})
}, },
// 离线采购件 // 离线采购件
searchTable4() { searchTable4() {
this.listLoading = true this.listLoading = true
this.tableDataBasic = [] this.tableDataBasic = []
let check1, check2, check3 let check1
this.Name ? check1 = 1 : check1 = 0 this.Name ? check1 = 1 : check1 = 0
this.materialSpec ? check2 = 1 : check2 = 0 searchPart(check1, this.Name, this.pageCurrent4, this.pageSize4).then(response => {
this.materialModel ? check3 = 1 : check3 = 0
searchPart(check1, this.Name, check2, this.materialSpec, check3, this.materialModel, this.pageCurrent4, this.pageSize4).then(response => {
this.tableDataBasic = response.data.rows this.tableDataBasic = response.data.rows
this.total4 = response.data.total this.total4 = response.data.total
this.listLoading = false this.listLoading = false
@@ -689,10 +698,11 @@ export default {
}, },
// 查询领料单列表 // 查询领料单列表
searchList() { searchList() {
let check, isElectrical let check, isElectrical, check1
this.pickingListNumber ? check = 1 : check = 0 this.pickingListPeople ? check = 1 : check = 0
this.startTime ? check1 = 1 : (check1 = 0, this.startTime = '')
Number(this.token) === 37 || Number(this.token) === 36 || Number(this.token) === 35 ? isElectrical = 1 : isElectrical = 0 // 35电工 36电气部长 37电气副部长 Number(this.token) === 37 || Number(this.token) === 36 || Number(this.token) === 35 ? isElectrical = 1 : isElectrical = 0 // 35电工 36电气部长 37电气副部长
searchList(this.pageCurrent3, this.pageSize3, check, this.pickingListNumber, isElectrical).then(response => { searchList(this.pageCurrent3, this.pageSize3, check, this.pickingListPeople, isElectrical, check1, this.startTime[0], this.startTime[1]).then(response => {
this.pickListTable1 = response.data.rows this.pickListTable1 = response.data.rows
this.total3 = response.data.total this.total3 = response.data.total
}) })
@@ -754,7 +764,6 @@ export default {
request(param).then(res => { request(param).then(res => {
if (res.data[0].result === '1') { if (res.data[0].result === '1') {
this.$message.success('操作成功') this.$message.success('操作成功')
this.pickingListNumber = ''
this.searchList() this.searchList()
} else { } else {
this.$message.error('操作失败') this.$message.error('操作失败')
@@ -793,6 +802,9 @@ export default {
handleSelectionChange(val) { handleSelectionChange(val) {
this.multipleSelection = val this.multipleSelection = val
}, },
handleSelectionChange1(val) {
this.multipleSelection1 = val
},
// 选入 // 选入
selectInto() { selectInto() {
if (this.PartType === '离线采购件') { if (this.PartType === '离线采购件') {

View File

@@ -105,7 +105,7 @@
width="80px" width="80px"
> >
<template slot-scope="scope" > <template slot-scope="scope" >
<el-button :disabled="scope.row.批次零件状态 === '2'" type="primary" plain size="mini" @click="handleEdit(scope.row)">停产</el-button> <el-button :disabled="scope.row.批次零件状态 === '2'" type="primary" plain size="mini" @click="handleEdit(scope.row)">报废</el-button>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
@@ -199,7 +199,7 @@
</el-col> </el-col>
</el-row> </el-row>
<el-card> <el-card>
<div style="margin-top: 10px">停产,将重新补投两种零件一种是接着加工(执行原来的加工计划)另一种是从第一序重新加工(重新制定零件的加工计划)补投的零件号后加B</div> <div style="margin-top: 10px">报废,将重新补投两种零件一种是接着加工(执行原来的加工计划)另一种是从第一序重新加工(重新制定零件的加工计划)补投的零件号后加B</div>
<div style="margin-top: 10px; display: block"> <div style="margin-top: 10px; display: block">
<span>补投接着加工零件数量</span> <span>补投接着加工零件数量</span>
<el-input v-model="inputA" auto-complete="off" style="width: 100px" size="small"/> <el-input v-model="inputA" auto-complete="off" style="width: 100px" size="small"/>

View File

@@ -25,8 +25,8 @@
:label="item.label" :label="item.label"
:value="item.value"/> :value="item.value"/>
</el-select> </el-select>
<el-button icon="el-icon-search" type="success" size="small" @click="pageCurrentWB = 1;pageSizeWB = 1000;pageCurrent = 1;pageSize = 1000;getTableData()">查询</el-button> <el-button icon="el-icon-search" type="primary" plain size="small" @click="pageCurrentWB = 1;pageSizeWB = 1000;pageCurrent = 1;pageSize = 1000;getTableData()">查询</el-button>
<el-button icon="el-icon-circle-plus-outline" type="primary" size="small" @click="openUrgentItem()">加急件</el-button> <el-button icon="el-icon-circle-plus-outline" type="warning" plain size="small" @click="openUrgentItem()">加急件</el-button>
</el-card> </el-card>
<el-card> <el-card>
<div v-for="(file, key) in hadFile" :key="key"> <div v-for="(file, key) in hadFile" :key="key">