更新
This commit is contained in:
@@ -210,7 +210,7 @@ export function editPurchaseData(num, num1) {
|
||||
}
|
||||
})
|
||||
}
|
||||
export function editBasicParts(num, num1) {
|
||||
export function editBasicParts(num, num1, num2, num3, num4) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
@@ -219,7 +219,7 @@ export function editBasicParts(num, num1) {
|
||||
ModularID: router.currentRoute.path,
|
||||
type: '2',
|
||||
name: 'PDM_零件明细表_基本件_编辑数据',
|
||||
param: '基本件流水号=' + num + '&零件数量=' + num1
|
||||
param: '基本件流水号=' + num + '&零件数量=' + num1 + '&零件名称=' + num2 + '&零件图号=' + num3 + '&材料=' + num4
|
||||
}
|
||||
})
|
||||
}
|
||||
@@ -329,3 +329,43 @@ export function editGroupBasicPartNum(num, num1) {
|
||||
}
|
||||
})
|
||||
}
|
||||
export function getmaterial() {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
UserID: state.state.user.id,
|
||||
ModularID: router.currentRoute.path,
|
||||
type: '1',
|
||||
name: '零件明细表_材料_查询'
|
||||
}
|
||||
})
|
||||
}
|
||||
// 查询物料
|
||||
export function searchAllMaterial(check1, MaterialName, check2, MaterialSpec, check3, MaterialModel, pageCurrent, pageSize) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
UserID: state.state.user.id,
|
||||
ModularID: router.currentRoute.path,
|
||||
type: '1',
|
||||
name: '库存管理_物料主文件_基本_查询数据_分页',
|
||||
param: `物料名称_check=${check1}&物料名称=${MaterialName}&物料规格_check=${check2}&物料规格=${MaterialSpec}&物料型号_check=${check3}&物料型号=${MaterialModel}&PageCurrent=${pageCurrent}=int&PageSize=${pageSize}=int&PageCount=1=int=output&ItemCount=1=int=output`
|
||||
}
|
||||
})
|
||||
}
|
||||
// 物料变更
|
||||
export function materialChange(num1, num2, num3, num4, person) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
UserID: state.state.user.id,
|
||||
ModularID: router.currentRoute.path,
|
||||
type: '2',
|
||||
name: '采购管理_采购物料修改_零件数量维护_修改数据',
|
||||
param: `组件零件流水号=${num1}&标准件和外购件流水号=${num2}&原物料流水号=${num3}&新物料流水号=${num4}&申请人=${person}`
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
@@ -16,6 +16,18 @@ export function initMachineProject() {
|
||||
}
|
||||
})
|
||||
}
|
||||
export function initMachine() {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
UserID: state.state.user.id,
|
||||
ModularID: router.currentRoute.path,
|
||||
type: '1',
|
||||
name: 'PDM_项目名称_查询数据'
|
||||
}
|
||||
})
|
||||
}
|
||||
// 分组查询
|
||||
export function searchGroup(num) {
|
||||
return request({
|
||||
@@ -73,3 +85,16 @@ export function submitMaterialReturn(materialNumber, basicNumber, number, name,
|
||||
}
|
||||
})
|
||||
}
|
||||
export function editsubmit(num, num1, num2, num3) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
UserID: state.state.user.id,
|
||||
ModularID: router.currentRoute.path,
|
||||
type: '2',
|
||||
name: '库存管理_出库记录_编辑数据',
|
||||
param: '机床流水号=' + num + '&组件流水号=' + num1 + '&领料人=' + num2 + '&离线采购件出库流水号=' + num3
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
@@ -147,24 +147,24 @@
|
||||
stripe
|
||||
size="mini"
|
||||
@row-click="openDialogFormVisible">
|
||||
<el-table-column align="center" label="状态" min-width="80" fixed>
|
||||
<el-table-column align="center" label="状态" min-width="80">
|
||||
<template slot-scope="scope">
|
||||
<span v-if="scope.row.是否发出.toString() === '1'" type="success" size="small">已发出</span>
|
||||
<span v-else type="danger" size="small">未发出</span>
|
||||
<!--{{ scope.row.是否发出.toString() === '1' ? '已发出' : '未发出' }}-->
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="发货单号" min-width="120" fixed>
|
||||
<el-table-column align="center" label="发货单号" min-width="120">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.发货单编号 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="发货单名" min-width="110" fixed>
|
||||
<el-table-column align="center" label="发货单名" min-width="110">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.发货单名称 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="收货单位" min-width="200" fixed>
|
||||
<el-table-column align="center" label="收货单位" min-width="200">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.收货单位 }}
|
||||
</template>
|
||||
|
||||
@@ -29,7 +29,7 @@
|
||||
</el-tooltip>
|
||||
</div>
|
||||
<el-table v-loading="loading" :data="tableData" highlight-current-row border stripe size="mini" style="width: 100%;max-height: 520px" height="320" @selection-change="handleSelectionChange">
|
||||
<el-table-column type="selection" align="center" width="45"/>
|
||||
<el-table-column :selectable="selectable" type="selection" align="center" width="45"/>
|
||||
<el-table-column label="序号" align="center" type="index" width="50"/>
|
||||
<el-table-column label="机床图号" align="center" min-width="150px">
|
||||
<template slot-scope="scope">{{ scope.row.机床图号 }}</template>
|
||||
@@ -82,8 +82,8 @@
|
||||
</el-table-column>
|
||||
<el-table-column label="操作" fixed="right" align="center" width="100">
|
||||
<template slot-scope="scope">
|
||||
<el-tooltip :open-delay="1000" effect="dark" content="编辑零件数量" placement="top">
|
||||
<el-button :disabled="scope.row.考核状态>=6&&scope.row.状态==='已加工'" size="mini" type="text" icon="el-icon-edit" @click="type=1;handleEdit(scope.row)"/>
|
||||
<el-tooltip :open-delay="1000" effect="dark" content="编辑零件" placement="top">
|
||||
<el-button :disabled="scope.row.考核状态>=7" size="mini" type="text" icon="el-icon-edit" @click="type=1;handleEdit(scope.row)"/>
|
||||
</el-tooltip>
|
||||
<el-tooltip :open-delay="1000" effect="dark" content="删除该行" placement="top">
|
||||
<el-button :disabled="scope.row.考核状态>=6&&scope.row.状态==='已加工'" size="mini" type="text" icon="el-icon-delete" @click="handleDelete(scope.row)"/>
|
||||
@@ -119,6 +119,7 @@
|
||||
highlight-current-row
|
||||
border
|
||||
@selection-change="handleSelectionChange1">
|
||||
<el-table-column :selectable="selectable1" type="selection" align="center" width="45"/>
|
||||
<el-table-column
|
||||
label="序号"
|
||||
align="center"
|
||||
@@ -188,6 +189,11 @@
|
||||
type="text"
|
||||
icon="el-icon-delete"
|
||||
@click="handleDelete(scope.row)"/>
|
||||
<el-button
|
||||
:disabled="parseInt(scope.row.询价状态编号)===3"
|
||||
size="mini"
|
||||
type="text"
|
||||
@click="materialChange(scope.row)">物料变更</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
@@ -582,28 +588,100 @@
|
||||
</el-tab-pane>
|
||||
</el-tabs>
|
||||
</el-card>
|
||||
<el-dialog v-el-drag-dialog :visible.sync="dialogFormVisible3" title="更改数量" center style="min-height: 300px" width="400px">
|
||||
<el-form ref="form3" :model="form3" :rules="rules3" label-position="left" label-width="110px" class="demo-ruleForm">
|
||||
<el-dialog v-el-drag-dialog :visible.sync="dialogFormVisible3" title="更改数量" center style="min-height: 300px" width="350px">
|
||||
<el-form ref="form3" :model="form3" :rules="rules3" label-position="right" label-width="80px" class="demo-ruleForm">
|
||||
<el-form-item label="数量" prop="数量">
|
||||
<el-input
|
||||
:readonly="editnumber"
|
||||
v-model="form3.数量"
|
||||
size="small"
|
||||
style="width:200px"/>
|
||||
</el-form-item>
|
||||
<el-form-item v-if="showmessage" label="名称" prop="名称">
|
||||
<el-input
|
||||
v-model="form3.名称"
|
||||
size="small"
|
||||
style="width:200px"/>
|
||||
</el-form-item>
|
||||
<el-form-item v-if="showmessage" label="零件图号" prop="零件图号">
|
||||
<el-input
|
||||
v-model="form3.零件图号"
|
||||
size="small"
|
||||
style="width:200px"/>
|
||||
</el-form-item>
|
||||
<el-form-item v-if="showmessage" label="材料" prop="材料">
|
||||
<el-select v-model="form3.材料" placeholder="请选择材料" style="margin: 0px 20px 0px 0px" filterable clearable size="small">
|
||||
<el-option
|
||||
v-for="item in material"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button type="primary" @click="submitEdit('form3')">确定</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
|
||||
<el-dialog v-el-drag-dialog :visible.sync="dialogVisible3" title="物料变更选择" center style="min-height: 300px;" width="780px">
|
||||
<el-row style="margin-bottom: 10px">
|
||||
<span>物料名称:</span>
|
||||
<el-input v-model="materialName0" placeholder="物料名称" style="width: 200px" size="small" clearable/>
|
||||
<span>物料规格:</span>
|
||||
<el-input v-model="materialSpec0" placeholder="物料规格" style="width: 200px" size="small" clearable/>
|
||||
</el-row>
|
||||
<el-row style="margin-bottom: 10px">
|
||||
<span>物料型号:</span>
|
||||
<el-input v-model="materialModel0" placeholder="物料型号" style="width: 200px" size="small" clearable/>
|
||||
<el-button type="success" size="small" icon="el-icon-search" style="margin-left:10px" @click="pageCurrent02=1;pageSize02=10;total02=0;searchMaterial()">查询</el-button>
|
||||
</el-row>
|
||||
<el-table :data="tableData02" size="mini" style="width: 97%;max-height: 300px;margin-top:15px" height="400px" border highlight-current-row @row-click="selectNewMaterial">
|
||||
<el-table-column align="center" label="物料名称" min-width="150">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.物料名称 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="物料规格" min-width="150">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.物料规格 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="物料型号" min-width="150">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.物料型号 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<div class="block" style="margin: 10px 0;">
|
||||
<el-pagination
|
||||
:current-page="pageCurrent02"
|
||||
:page-sizes="[10, 20, 30, 40]"
|
||||
:page-size="pageSize02"
|
||||
:total="total02"
|
||||
style="display:inline-block;width:50%"
|
||||
layout="total, sizes, prev, pager, next, jumper"
|
||||
@size-change="handleSizeChange02"
|
||||
@current-change="handleCurrentChange02"/>
|
||||
</div>
|
||||
<span style="font-size: large;color: red">将原物料替换为: {{ materialNew }}</span>
|
||||
<!--<el-input v-model="materialNew" size="small" readonly style="margin: 10px 10px 0 10px"></el-input>-->
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button size="small" @click="dialogVisible3=false">取消</el-button>
|
||||
<el-button type="primary" size="small" @click="submitMaterialChange">确定</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { alldeleteWB, alldelete, machineSelect, groupSelect, basicPartsData, deleteBasicParts, deleteBasicParts5, deleteBasicParts6, alldeleteBasicParts5, alldeleteBasicParts6, purchasePartsData, deletePurchaseData, editPurchaseData, editBasicParts, getTable, editProductNum, getTable1, editProduceNum, searchTable1, searchTable2, searchTable5, searchTable6, editGroupBasicPartNum, editGroupPartNum } from '@/api/BasicData/PartsNumberMaintenance'
|
||||
import { mapGetters } from 'vuex'
|
||||
import { materialChange, searchAllMaterial, getmaterial, alldeleteWB, alldelete, machineSelect, groupSelect, basicPartsData, deleteBasicParts, deleteBasicParts5, deleteBasicParts6, alldeleteBasicParts5, alldeleteBasicParts6, purchasePartsData, deletePurchaseData, editPurchaseData, editBasicParts, getTable, editProductNum, getTable1, editProduceNum, searchTable1, searchTable2, searchTable5, searchTable6, editGroupBasicPartNum, editGroupPartNum } from '@/api/BasicData/PartsNumberMaintenance'
|
||||
export default {
|
||||
name: 'Index',
|
||||
data() {
|
||||
return {
|
||||
material: [],
|
||||
activeName: '1',
|
||||
projectName: '',
|
||||
BasicParts: '',
|
||||
@@ -620,7 +698,10 @@ export default {
|
||||
groupValue: '',
|
||||
group: [],
|
||||
form3: {
|
||||
数量: ''
|
||||
数量: '',
|
||||
名称: '',
|
||||
零件图号: '',
|
||||
材料: ''
|
||||
},
|
||||
rules3: {
|
||||
数量: [{ required: true, message: '请输入数量', trigger: 'blur' }]
|
||||
@@ -628,6 +709,7 @@ export default {
|
||||
dialogFormVisible3: false,
|
||||
loading: false,
|
||||
loadingWB: false,
|
||||
editnumber: '',
|
||||
// total: 0,
|
||||
tableData: [],
|
||||
tableData1: [],
|
||||
@@ -663,7 +745,21 @@ export default {
|
||||
pageSize7: 10,
|
||||
total7: 0,
|
||||
gouxuan: 0,
|
||||
totalnumber: 0
|
||||
totalnumber: 0,
|
||||
showmessage: false,
|
||||
dialogVisible3: false,
|
||||
groupPartNumValue: '',
|
||||
standardAndPurchaseValue: '',
|
||||
materialOldValue: '',
|
||||
materialSpec0: '',
|
||||
materialName0: '',
|
||||
materialModel0: '',
|
||||
tableData02: [],
|
||||
pageCurrent02: 1,
|
||||
pageSize02: 20,
|
||||
total02: 0,
|
||||
materialNew: '',
|
||||
materialNewValue: ''
|
||||
|
||||
// pageCurrentWB: 1,
|
||||
// pageSizeWB: 10,
|
||||
@@ -671,6 +767,11 @@ export default {
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
...mapGetters([
|
||||
'name',
|
||||
'token',
|
||||
'id' // 人员编号
|
||||
]),
|
||||
groupName() {
|
||||
for (let i = 0; i < this.group.length; i++) {
|
||||
if (this.group[i].value === this.groupValue) {
|
||||
@@ -725,10 +826,83 @@ export default {
|
||||
}
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.getMaterial()
|
||||
},
|
||||
mounted() {
|
||||
this.fetchData()
|
||||
},
|
||||
methods: {
|
||||
selectable(row) {
|
||||
return row.考核状态 < 6 && row.状态 !== '已加工'
|
||||
},
|
||||
selectable1(row) {
|
||||
return row.询价状态编号 !== 3
|
||||
},
|
||||
submitMaterialChange() {
|
||||
materialChange(this.groupPartNumValue, this.standardAndPurchaseValue, this.materialOldValue, this.materialNewValue, this.id).then(response => {
|
||||
if (response.data[0].result === '1') {
|
||||
this.$message.success('提交变更申请成功')
|
||||
this.dialogVisible3 = false
|
||||
this.searchTable11()
|
||||
} else { this.$message.error('操作失败') }
|
||||
})
|
||||
this.getTableData()
|
||||
},
|
||||
searchMaterial() {
|
||||
if (this.materialName0 || this.materialSpec0 || this.materialModel0) {
|
||||
let check1, check2, check3
|
||||
this.materialName0 ? check1 = 1 : check1 = 0
|
||||
this.materialSpec0 ? check2 = 1 : check2 = 0
|
||||
this.materialModel0 ? check3 = 1 : check3 = 0
|
||||
searchAllMaterial(check1, this.materialName0, check2, this.materialSpec0, check3, this.materialModel0, this.pageCurrent02, this.pageSize02).then(response => {
|
||||
this.tableData02 = response.data.result
|
||||
this.total02 = parseInt(response.data.output[0].ItemCount)
|
||||
})
|
||||
} else {
|
||||
this.$message.warning('请至少输入一种搜索条件')
|
||||
}
|
||||
},
|
||||
selectNewMaterial(row) {
|
||||
this.materialNew = ''
|
||||
this.materialNewValue = row.物料流水号
|
||||
this.materialNew += row.物料名称 + ' ' + row.物料规格 + ' ' + row.物料型号
|
||||
},
|
||||
materialChange(row) { // 物料变更 标准件和外购件
|
||||
console.log(row.组件零件流水号, 12)
|
||||
if (row.组件零件流水号 !== '' && row.组件零件流水号 !== null) {
|
||||
this.$confirm('该物料已分配到采购部,是否继续修改?', '提示', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
this.dialogVisible3 = true
|
||||
this.groupPartNumValue = row.组件零件流水号
|
||||
this.standardAndPurchaseValue = row.标准件和外购件流水号
|
||||
this.materialOldValue = row.物料流水号
|
||||
}).catch(() => {
|
||||
this.$message({
|
||||
type: 'info',
|
||||
message: '已取消修改'
|
||||
})
|
||||
})
|
||||
} else {
|
||||
this.dialogVisible3 = true
|
||||
this.groupPartNumValue = row.组件零件流水号
|
||||
this.standardAndPurchaseValue = row.标准件和外购件流水号
|
||||
this.materialOldValue = row.物料流水号
|
||||
}
|
||||
},
|
||||
getMaterial() {
|
||||
getmaterial().then(response => {
|
||||
for (let i = 0; i < response.data.length; i++) {
|
||||
this.material.push({
|
||||
value: response.data[i].材料流水号,
|
||||
label: response.data[i].材料
|
||||
})
|
||||
}
|
||||
})
|
||||
},
|
||||
fetchData() {
|
||||
this.getSelect(machineSelect, ['机床图号', '机床流水号'], 'machine')
|
||||
console.log(this.machine)
|
||||
@@ -743,7 +917,7 @@ export default {
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
if (this.activeName === '1') {
|
||||
alldeleteBasicParts5(this.projectName, this.machineName, this.groupName).then(res => {
|
||||
alldeleteBasicParts5(this.machineName, this.groupName).then(res => {
|
||||
console.log(res, 1)
|
||||
if (res.data[0].result === '1') {
|
||||
this.$message.success('删除成功')
|
||||
@@ -752,7 +926,7 @@ export default {
|
||||
} else { this.$message.error('删除失败') }
|
||||
})
|
||||
} else if (this.activeName === '2') {
|
||||
alldeleteBasicParts6(this.projectName, this.machineName, this.groupName).then(res => {
|
||||
alldeleteBasicParts6(this.machineName, this.groupName).then(res => {
|
||||
console.log(res, 2)
|
||||
if (res.data[0].result === '1') {
|
||||
this.$message.success('删除成功')
|
||||
@@ -958,23 +1132,67 @@ export default {
|
||||
if (this.$refs['form3'] !== undefined) {
|
||||
this.$refs['form3'].resetFields()
|
||||
}
|
||||
this.dialogFormVisible3 = true
|
||||
if (row.基本件流水号 && this.type === 1) {
|
||||
console.log(row.跟单号, row.考核状态, row.状态)
|
||||
if (row.基本件流水号 && this.type === 1 && row.跟单号 !== null) {
|
||||
this.$confirm('跟单已打出,是否确定修改?', '提示', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
this.showmessage = true
|
||||
this.dialogFormVisible3 = true
|
||||
this.BasicParts = row.基本件流水号
|
||||
this.form3.数量 = row.零件数量
|
||||
this.form3.名称 = row.零件名称
|
||||
this.form3.零件图号 = row.零件图号
|
||||
this.form3.材料 = row.材料流水号
|
||||
if (row.考核状态 >= 6 && row.状态 === '已加工') {
|
||||
this.editnumber = true
|
||||
} else {
|
||||
this.editnumber = false
|
||||
}
|
||||
}).catch(() => {
|
||||
this.$message({
|
||||
type: 'info',
|
||||
message: '已取消修改'
|
||||
})
|
||||
})
|
||||
} else if (row.基本件流水号 && this.type === 1 && row.跟单号 === null) {
|
||||
this.showmessage = true
|
||||
this.dialogFormVisible3 = true
|
||||
this.BasicParts = row.基本件流水号
|
||||
this.form3.数量 = row.零件数量
|
||||
this.form3.名称 = row.零件名称
|
||||
this.form3.零件图号 = row.零件图号
|
||||
this.form3.材料 = row.材料
|
||||
if (row.考核状态 >= 6 && row.状态 === '已加工') {
|
||||
this.editnumber = true
|
||||
} else {
|
||||
this.editnumber = false
|
||||
}
|
||||
} else if (row.标准件和外购件流水号 && this.type === 1) {
|
||||
this.showmessage = false
|
||||
this.dialogFormVisible3 = true
|
||||
this.PurchaseData = row.标准件和外购件流水号
|
||||
this.form3.数量 = row.零件数量
|
||||
} else if (row.组件零件基本件流水号 && this.type === 1) {
|
||||
this.showmessage = false
|
||||
this.dialogFormVisible3 = true
|
||||
this.productNum = row.组件零件基本件流水号
|
||||
this.form3.数量 = row.投产总数量
|
||||
} else if (row.工艺计划流水号) {
|
||||
this.showmessage = false
|
||||
this.dialogFormVisible3 = true
|
||||
this.produceNum = row.工艺计划流水号
|
||||
this.form3.数量 = row.投产数量
|
||||
} else if (row.组件零件流水号 && this.type === 2) {
|
||||
this.showmessage = false
|
||||
this.dialogFormVisible3 = true
|
||||
this.groupPartNum = row.组件零件流水号
|
||||
this.form3.数量 = row.零件数量
|
||||
} else if (row.组件零件基本件流水号 && this.type === 2) {
|
||||
this.showmessage = false
|
||||
this.dialogFormVisible3 = true
|
||||
this.groupBasicPartNum = row.组件零件基本件流水号
|
||||
this.form3.数量 = row.数量
|
||||
}
|
||||
@@ -983,7 +1201,7 @@ export default {
|
||||
this.$refs[formName].validate((valid) => {
|
||||
if (valid) {
|
||||
if (this.BasicParts !== '') {
|
||||
editBasicParts(this.BasicParts, this.form3.数量).then(response => {
|
||||
editBasicParts(this.BasicParts, this.form3.数量, this.form3.名称, this.form3.零件图号, this.form3.材料).then(response => {
|
||||
if (response.data[0].result === '1') {
|
||||
this.$message.success('编辑成功')
|
||||
this.dialogFormVisible3 = false
|
||||
@@ -1063,6 +1281,14 @@ export default {
|
||||
this.searchTable6()
|
||||
})
|
||||
}
|
||||
},
|
||||
handleSizeChange02(val) {
|
||||
this.pageSize02 = val
|
||||
this.searchMaterial()
|
||||
},
|
||||
handleCurrentChange02(val) {
|
||||
this.pageCurrent02 = val
|
||||
this.searchMaterial()
|
||||
}
|
||||
// handleSizeChanges(val) {
|
||||
// this.pageCurrent = 1
|
||||
|
||||
@@ -24,7 +24,7 @@
|
||||
<el-button type="distribution" icon="el-icon-edit" size="small" @click="addMaterial()">新增</el-button>
|
||||
</el-row>
|
||||
</div>
|
||||
<el-table v-loading="loading" :data="tableData1" stripe highlight-current-row border height="550px" style="width: 1040px" size="mini">
|
||||
<el-table v-loading="loading" :data="tableData1" stripe highlight-current-row border height="550px" style="width: 1240px" size="mini">
|
||||
<el-table-column label="名称" prop="物料名称" align="center" width="150" show-overflow-tooltip>
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.物料名称 }}
|
||||
|
||||
@@ -49,6 +49,11 @@
|
||||
</el-card>
|
||||
<el-card style="width: 1220px">
|
||||
<el-table :data="tableData" border stripe size="mini" height="700">
|
||||
<el-table-column label="出库类别" align="center" width="80" show-overflow-tooltip>
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.出库类型 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="名称" align="center" width="160" show-overflow-tooltip>
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.名称 }}
|
||||
@@ -64,6 +69,16 @@
|
||||
{{ scope.row.规格 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="机床图号" align="center" width="120" show-overflow-tooltip>
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.机床图号 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="组号" align="center" width="120" show-overflow-tooltip>
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.组号 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="出库数量" align="center" width="90" show-overflow-tooltip>
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.出库数量 }}
|
||||
@@ -94,9 +109,12 @@
|
||||
{{ scope.row.退料时间 ? scope.row.退料时间.split(' ')[0] : '' }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="操作" align="center" width="100">
|
||||
<el-table-column label="操作" align="center" width="120" fixed="right">
|
||||
<template slot-scope="scope">
|
||||
<el-button :disabled="Number(scope.row.退料数量) >= Number(scope.row.出库数量)" type="text" size="mini" icon="el-icon-right" @click="yesApproval(scope.row)">退货</el-button>
|
||||
<el-tooltip content="编辑" placement="top">
|
||||
<el-button :disabled="scope.row.出库类型 !== '离线出库'" type="text" size="mini" icon="el-icon-edit" style="margin-left: 20px" @click="editmessage(scope.row)"/>
|
||||
</el-tooltip>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
@@ -112,19 +130,19 @@
|
||||
@current-change="handleCurrentChange1"/>
|
||||
</div>
|
||||
</el-card>
|
||||
<el-dialog :visible.sync="dialogFormVisible" title="退料" center width="300px">
|
||||
<el-dialog :visible.sync="dialogFormVisible" title="补投" center width="300px">
|
||||
<el-form ref="form" :model="form" :rules="rules" label-position="left" label-width="80px" class="demo-ruleForm">
|
||||
<div>
|
||||
<el-row style="padding: 10px 0">
|
||||
<ei-row>
|
||||
<span>{{ nameOrNumber }}</span>
|
||||
</el-row>
|
||||
<el-row style="padding: 10px 0">
|
||||
</ei-row>
|
||||
<el-row>
|
||||
<span>出库数量:{{ outNumber }}</span>
|
||||
</el-row>
|
||||
<el-row style="padding: 10px 0">
|
||||
<el-row>
|
||||
<span>领料人:{{ people }}</span>
|
||||
</el-row>
|
||||
<el-row style="padding: 10px 0">
|
||||
<el-row>
|
||||
<span>出库时间:{{ time }}</span>
|
||||
</el-row>
|
||||
</div>
|
||||
@@ -145,16 +163,58 @@
|
||||
<el-button :disabled="handleEdit_disable" size="small" type="primary" @click="submit()">确 定</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
|
||||
<el-dialog :visible.sync="editFormVisible" title="编辑" center width="300px">
|
||||
<el-form ref="form1" :model="form1" :rules="rules1" label-position="left" label-width="80px" class="demo-ruleForm">
|
||||
<el-form-item label="机床" prop="机床">
|
||||
<el-select v-model="form1.machineValue1" style="width: 140px" filterable size="small" placeholder="机床名称" @change="machineChange1">
|
||||
<el-option
|
||||
v-for="item in machine1"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<!--<el-form-item label="组号" prop="组号">-->
|
||||
<!--<el-select v-model="form1.groupValue1" style="width: 140px" filterable size="small" placeholder="组号">-->
|
||||
<!--<el-option-->
|
||||
<!--v-for="item in group1"-->
|
||||
<!--:key="item.value"-->
|
||||
<!--:label="item.label"-->
|
||||
<!--:value="item.value"/>-->
|
||||
<!--</el-select>-->
|
||||
<!--</el-form-item>-->
|
||||
<el-form-item label="领料人" prop="领料人">
|
||||
<el-input v-model="form1.peopleName" style="width: 140px" size="small" />
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button size="small" type="primary" @click="editSubmit()">确 定</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { initMachineProject, searchGroup, searchRecord, initLocateName, submitMaterialReturn } from '@/api/Inventory/MaterialReturn'
|
||||
import { initMachine, editsubmit, initMachineProject, searchGroup, searchRecord, initLocateName, submitMaterialReturn } from '@/api/Inventory/MaterialReturn'
|
||||
import { mapGetters } from 'vuex'
|
||||
export default {
|
||||
name: 'PurchaseOutRecord',
|
||||
data() {
|
||||
return {
|
||||
machine1: [],
|
||||
group1: [],
|
||||
editFormVisible: false,
|
||||
form1: {
|
||||
machineValue1: '',
|
||||
peopleName: '',
|
||||
groupValue1: ''
|
||||
},
|
||||
rules1: {
|
||||
machineValue1: [{ required: true, message: '请选择机床' }],
|
||||
peopleName: [{ required: true, message: '请输入领料人' }],
|
||||
groupValue1: [{ required: true, message: '请选择领料人' }]
|
||||
},
|
||||
handleEdit_disable: false,
|
||||
dialogFormVisible: false,
|
||||
form: {
|
||||
@@ -187,7 +247,8 @@ export default {
|
||||
pageSize1: 100,
|
||||
pageCurrent1: 1,
|
||||
total1: 0,
|
||||
outTime: '' // 出库时间
|
||||
outTime: '', // 出库时间
|
||||
materialOutNumber: '' // 出库流水号
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
@@ -208,6 +269,24 @@ export default {
|
||||
this.searchRecord()
|
||||
},
|
||||
methods: {
|
||||
editSubmit() {
|
||||
editsubmit(this.form1.machineValue1, this.form1.groupValue1, this.form1.peopleName, this.materialOutNumber).then(response => {
|
||||
if (response.data[0].result === '1') {
|
||||
this.$message.success('编辑成功')
|
||||
this.editFormVisible = false
|
||||
this.searchRecord()
|
||||
} else {
|
||||
this.$message.error('编辑失败')
|
||||
this.editFormVisible = false
|
||||
}
|
||||
})
|
||||
},
|
||||
editmessage(row) {
|
||||
this.editFormVisible = true
|
||||
this.form1.peopleName = row.领料人
|
||||
this.form1.machineValue1 = Number(row.机床流水号)
|
||||
this.materialOutNumber = row.零件流水号
|
||||
},
|
||||
fetchData() {
|
||||
initMachineProject().then(response => {
|
||||
for (let i = 0; i < response.data.length; i++) {
|
||||
@@ -218,6 +297,15 @@ export default {
|
||||
})
|
||||
}
|
||||
})
|
||||
initMachine().then(response => {
|
||||
for (let i = 0; i < response.data.length; i++) {
|
||||
this.machine1.push({
|
||||
label: response.data[i].机床图号,
|
||||
name: response.data[i].项目名称,
|
||||
value: response.data[i].机床流水号
|
||||
})
|
||||
}
|
||||
})
|
||||
initLocateName().then(response => {
|
||||
for (let i = 0; i < response.data.length; i++) {
|
||||
this.locateName.push({
|
||||
@@ -242,6 +330,21 @@ export default {
|
||||
}
|
||||
})
|
||||
},
|
||||
machineChange1() {
|
||||
this.group1 = []
|
||||
this.form1.groupValue1 = ''
|
||||
searchGroup(this.form1.machineValue1).then(response => {
|
||||
for (let i = 0; i < response.data.length; i++) {
|
||||
this.group1.push({
|
||||
value: response.data[i].组件流水号,
|
||||
label: response.data[i].组号
|
||||
})
|
||||
}
|
||||
if (response.data.length > 0) {
|
||||
this.form1.groupValue = this.group1[0].value
|
||||
}
|
||||
})
|
||||
},
|
||||
searchRecord() {
|
||||
let check1, check2, check3, check4, check5, check6, check7
|
||||
this.projectValue ? check1 = 1 : check1 = 0
|
||||
|
||||
@@ -42,17 +42,17 @@
|
||||
</el-table-column>
|
||||
<el-table-column label="计划准结(分)" align="center" prop="计划准备工时" width="110">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.计划准备工时 }}
|
||||
{{ scope.row.计划准备工时 ? scope.row.计划准备工时 : 0 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="单件定额(分)" align="center" width="110">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.单件计划工时 }}
|
||||
{{ scope.row.单件计划工时 ? scope.row.单件计划工时 : 0 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="计划工时(分)" align="center" prop="计划工时" width="110">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.计划工时 }}
|
||||
{{ scope.row.计划工时 ? scope.row.计划工时 : 0 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="计划完成" align="center" width="110">
|
||||
@@ -67,27 +67,27 @@
|
||||
</el-table-column>
|
||||
<el-table-column label="单件加工工时(分)" align="center" prop="加工工时" width="140">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.修补单件工时 }}
|
||||
{{ scope.row.修补单件工时 ? scope.row.修补单件工时 : 0 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="加工工时(分)" align="center" prop="完成工时" width="110">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.完成工时 }}
|
||||
{{ scope.row.完成工时 ? scope.row.完成工时 : 0 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="完成工时(分)" align="center" prop="完成工时1" width="110">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.完成工时1 }}
|
||||
{{ scope.row.完成工时1 ? scope.row.完成工时1 : 0 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="准结(分)" align="center" prop="修补工时" width="110">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.修补工时 }}
|
||||
{{ scope.row.修补工时 ? scope.row.修补工时 : 0 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="扫码工时(分)" align="center" prop="扫码工时" width="110">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.扫码工时 }}
|
||||
{{ scope.row.扫码工时 ? scope.row.扫码工时 : 0 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="工时比值" align="center" width="100">
|
||||
@@ -184,7 +184,7 @@ export default {
|
||||
计划准备工时: response.data.result[i].准结定额工时,
|
||||
单件计划工时: response.data.result[i].单件定额工时,
|
||||
计划工时: response.data.result[i].计划工时,
|
||||
计划加工日期: response.data.result[i].计划日期.split(' ')[0],
|
||||
计划加工日期: response.data.result[i].计划日期 ? response.data.result[i].计划日期.split(' ')[0] : '-',
|
||||
加工数量: response.data.result[i].完成数量,
|
||||
加工准备工时: response.data.result[i].修补准结工时,
|
||||
加工工时: response.data.result[i].设备工时,
|
||||
|
||||
@@ -188,7 +188,7 @@
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="采购数量">
|
||||
<template slot-scope="scope">
|
||||
{{ parseInt(scope.row.询价状态编号)===1&&scope.row.人员编号!=='' ? '—' : scope.row.数量 || scope.row.离线采购数量 || '—' }}
|
||||
{{ parseInt(scope.row.询价状态编号)===1&&scope.row.人员编号!=='' ? '—' : scope.row.离线采购数量 || (scope.row.数量==='0' ? '—' : scope.row.数量) || '—' }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="用滞货数">
|
||||
|
||||
@@ -17,8 +17,8 @@
|
||||
</el-card>
|
||||
<el-card>
|
||||
<el-table v-loading="loading" :data="tableData" border stripe size="mini" height="650" style="width: 1480px">
|
||||
<el-table-column label="序号" align="center" type="index" width="50"/>
|
||||
<el-table-column label="外协状态" align="center" width="80px">
|
||||
<el-table-column label="序号" align="center" type="index" width="50" fixed/>
|
||||
<el-table-column label="外协状态" align="center" width="80px" fixed>
|
||||
<template slot-scope="scope">
|
||||
<el-tag v-if="Number(scope.row.外协状态)==1" type="primary" size="mini">未提交</el-tag>
|
||||
<el-tag v-if="Number(scope.row.外协状态)===0" type="success" size="mini">未外协</el-tag>
|
||||
|
||||
@@ -13,13 +13,13 @@
|
||||
<div style="float: right; color: #8492a6; font-size: 13px">{{ item.name }}</div>
|
||||
</el-option>
|
||||
</el-select>
|
||||
<!-- <el-select v-model="groupNumberValue" placeholder="组号" size="small" clearable>-->
|
||||
<!-- <el-option-->
|
||||
<!-- v-for="item in groupNumber"-->
|
||||
<!-- :key="item.value"-->
|
||||
<!-- :label="item.label"-->
|
||||
<!-- :value="item.value"/>-->
|
||||
<!-- </el-select>-->
|
||||
<el-select v-model="groupNumberValue" placeholder="组号" size="small" clearable>
|
||||
<el-option
|
||||
v-for="item in groupNumber"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"/>
|
||||
</el-select>
|
||||
<el-input v-model="Name" placeholder="名称规格型号" size="small" clearable/>
|
||||
<!-- <el-input v-model="spec" placeholder="规格" size="small" clearable/>-->
|
||||
<!-- <el-input v-model="model" placeholder="型号" size="small" clearable/>-->
|
||||
|
||||
@@ -36,7 +36,7 @@
|
||||
<el-col style="width: 60%">
|
||||
<el-card>
|
||||
<el-table
|
||||
v-loading="listLoading"
|
||||
v-loading="listLoading1"
|
||||
:data="tableData"
|
||||
size="mini"
|
||||
border
|
||||
@@ -318,6 +318,7 @@ export default {
|
||||
tableDataAll: [],
|
||||
tableData10: [],
|
||||
listLoading: false,
|
||||
listLoading1: false,
|
||||
unSpecification: [],
|
||||
pageCurrent: 1,
|
||||
pageSize: 10,
|
||||
@@ -366,6 +367,9 @@ export default {
|
||||
if (this.unSpecification.data) {
|
||||
return this.unSpecification.data.length > 0
|
||||
}
|
||||
if (this.listLoading === true) {
|
||||
return true
|
||||
}
|
||||
return true
|
||||
},
|
||||
materialName() {
|
||||
@@ -438,7 +442,7 @@ export default {
|
||||
this.pageCurrent = 1
|
||||
this.tableData10 = []
|
||||
try {
|
||||
this.listLoading = true
|
||||
this.listLoading1 = true
|
||||
this.total = 0
|
||||
this.tableDataAll = []
|
||||
const projectCheck = this.projectName ? 1 : 0
|
||||
@@ -468,7 +472,7 @@ export default {
|
||||
}
|
||||
this.total = this.tableDataAll.length
|
||||
this.pagination(this.pageCurrent, this.pageSize) // 前端分页,数据很多生成DOM节点也多,分页效果很明显。
|
||||
this.listLoading = false
|
||||
this.listLoading1 = false
|
||||
} catch (e) {
|
||||
console.log(`查询零件发生错误:${e}`)
|
||||
}
|
||||
@@ -649,7 +653,9 @@ export default {
|
||||
} else {
|
||||
this.$message.error(`${this.err}个零件传递失败`)
|
||||
}
|
||||
this.listLoading = false
|
||||
setTimeout(() => {
|
||||
this.listLoading = false
|
||||
}, 6000)
|
||||
} else {
|
||||
this.$message.warning(`请选择分组传递`)
|
||||
}
|
||||
|
||||
@@ -232,7 +232,7 @@
|
||||
</div>
|
||||
</el-dialog>
|
||||
<el-dialog v-el-drag-dialog :visible.sync="dialogVisible10" title="添加到货明细" center style="min-height: 200px" width="1600px">
|
||||
<el-form ref="form10" :model="form10" :rules="rules10" label-position="right" label-width="60px">
|
||||
<el-form ref="form10" :model="form10" :rules="rules10" label-position="right" label-width="80px">
|
||||
<el-row style="background-color: white">
|
||||
<el-col :span="5" style="margin-left: 2%">
|
||||
<span>供应商</span>
|
||||
@@ -290,7 +290,7 @@
|
||||
</el-row>
|
||||
</div>
|
||||
<div>
|
||||
<el-button type="primary" size="small" style="margin-left: 40%;margin-top: 10px" @click="submitAddArrivalOrderMX">确定</el-button>
|
||||
<el-button type="primary" style="margin-left: 40%;margin-top: 15px" @click="submitAddArrivalOrderMX">确定</el-button>
|
||||
</div>
|
||||
</div>
|
||||
<div style="width: 79%;float: left;margin-left: 10px">
|
||||
@@ -511,6 +511,11 @@ export default {
|
||||
purchasingOrder: '',
|
||||
ArrivalOrderNumber: '',
|
||||
ArrivalOrderMXNumber: '',
|
||||
ArrivalDetailSerialNumber: '',
|
||||
ArrivalOrderGroup: [],
|
||||
ArrivalOrderMXNumberGroup: [],
|
||||
numberGroup: [],
|
||||
LxnumberGroup: [],
|
||||
supplierName0: '',
|
||||
planType: 0,
|
||||
planTypes: [
|
||||
@@ -525,6 +530,8 @@ export default {
|
||||
],
|
||||
arrest: [],
|
||||
arrest1: [],
|
||||
arrest00: [],
|
||||
arrest10: [],
|
||||
check: 0,
|
||||
Name: '',
|
||||
单价: '',
|
||||
@@ -1032,12 +1039,32 @@ export default {
|
||||
})
|
||||
},
|
||||
deleteArrivalOrder(row) { // 删除采购单
|
||||
this.ArrivalOrderGroup = []
|
||||
this.ArrivalOrderMXNumberGroup = []
|
||||
this.numberGroup = []
|
||||
this.LxnumberGroup = []
|
||||
this.ArrivalDetailSerialNumber = ''
|
||||
searchTable5(row.到货单流水号).then(response => {
|
||||
for (let i = 0; i < response.data.length; i++) {
|
||||
this.ArrivalDetailSerialNumber = response.data[i].到货单明细流水号
|
||||
this.ArrivalOrderGroup.push(response.data[i].到货单明细流水号)
|
||||
console.log(this.ArrivalDetailSerialNumber, 231)
|
||||
searchTable6(this.ArrivalDetailSerialNumber).then(response => {
|
||||
for (let j = 0; j < response.data.length; j++) {
|
||||
this.ArrivalOrderMXNumberGroup.push(response.data[j].到货单明细绑定流水号)
|
||||
this.numberGroup.push(response.data[j].采购计划明细流水号)
|
||||
this.LxnumberGroup.push(response.data[j].离线采购计划明细流水号)
|
||||
}
|
||||
})
|
||||
}
|
||||
console.log(this.ArrivalOrderMXNumberGroup, this.numberGroup, this.LxnumberGroup, 111)
|
||||
})
|
||||
this.$confirm('确定删除该到货单?', '提示', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
deletePurchaseOrder(row.到货单流水号).then(response => {
|
||||
deletePurchaseOrder(row.到货单流水号, this.ArrivalOrderGroup, this.ArrivalOrderMXNumberGroup, this.numberGroup, this.LxnumberGroup).then(response => {
|
||||
if (response.data[0].result === '1') {
|
||||
this.$message.success('删除成功')
|
||||
this.searchTable4()
|
||||
@@ -1090,19 +1117,23 @@ export default {
|
||||
if (this.arrest.length === 0) {
|
||||
this.$message.warning('请勾选要绑定的材料')
|
||||
} else {
|
||||
this.arrest00 = this.arrest
|
||||
this.arrest = []
|
||||
this.工艺计划流水号组 = []
|
||||
this.采购计划明细流水号组 = []
|
||||
this.离线采购计划明细流水号组 = []
|
||||
this.本次到货数量组 = []
|
||||
this.到货重量组 = []
|
||||
this.到货金额组 = []
|
||||
this.arrest.map(v => {
|
||||
this.工艺计划流水号组.push(v.工艺计划流水号)
|
||||
this.采购计划明细流水号组.push(v.采购计划明细流水号)
|
||||
this.离线采购计划明细流水号组.push(v.离线采购计划明细流水号)
|
||||
this.本次到货数量组.push(v.未到货数量)
|
||||
this.到货重量组.push(v.到货重量)
|
||||
this.到货金额组.push(v.到货重量 * this.form10.单价)
|
||||
this.arrest00.map(v => {
|
||||
if (v.到货重量 > 0) {
|
||||
this.工艺计划流水号组.push(v.工艺计划流水号)
|
||||
this.采购计划明细流水号组.push(v.采购计划明细流水号)
|
||||
this.离线采购计划明细流水号组.push(v.离线采购计划明细流水号)
|
||||
this.本次到货数量组.push(v.未到货数量)
|
||||
this.到货重量组.push(v.到货重量)
|
||||
this.到货金额组.push(v.到货重量 * this.form10.单价)
|
||||
}
|
||||
})
|
||||
AddArrivalOrderMX(this.ArrivalOrderNumber, this.form10.CailiaoValue, this.form10.数量, this.form10.单位, this.form10.单价, this.form10.金额, this.工艺计划流水号组, this.采购计划明细流水号组, this.本次到货数量组, this.离线采购计划明细流水号组, this.到货重量组, this.到货金额组, this.userId).then(response => {
|
||||
if (response.data[0].result === '1') {
|
||||
@@ -1172,17 +1203,28 @@ export default {
|
||||
})
|
||||
},
|
||||
deleteArrivalMX(row) {
|
||||
this.ArrivalOrderMXNumberGroup = []
|
||||
this.numberGroup = []
|
||||
this.LxnumberGroup = []
|
||||
searchTable6(this.ArrivalOrderMXNumber).then(response => {
|
||||
for (let i = 0; i < response.data.length; i++) {
|
||||
this.ArrivalOrderMXNumberGroup.push(response.data[i].到货单明细绑定流水号)
|
||||
this.numberGroup.push(response.data[i].采购计划明细流水号)
|
||||
this.LxnumberGroup.push(response.data[i].离线采购计划明细流水号)
|
||||
}
|
||||
})
|
||||
this.$confirm('确定取消该物料的到货信息?', '提示', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
deleteArrivalMX(row.到货单明细流水号).then(response => {
|
||||
deleteArrivalMX(row.到货单明细流水号, this.ArrivalOrderMXNumberGroup, this.numberGroup, this.LxnumberGroup).then(response => {
|
||||
if (response.data[0].result === '1') {
|
||||
this.$message.success('删除成功')
|
||||
searchTable5(this.ArrivalOrderNumber).then(response => {
|
||||
this.tableData5 = response.data
|
||||
})
|
||||
this.tableData6 = []
|
||||
} else { this.$message.error('数据占用,删除失败') }
|
||||
})
|
||||
}).catch(() => {
|
||||
@@ -1238,19 +1280,23 @@ export default {
|
||||
} else if (this.未绑定数量 < this.totalWight2) {
|
||||
this.$message.warning('所选物料总重量超出未绑定重量')
|
||||
} else {
|
||||
this.arrest10 = this.arrest1
|
||||
this.arrest1 = []
|
||||
this.工艺计划流水号组 = []
|
||||
this.采购计划明细流水号组 = []
|
||||
this.离线采购计划明细流水号组 = []
|
||||
this.本次到货数量组 = []
|
||||
this.到货重量组 = []
|
||||
this.到货金额组 = []
|
||||
this.arrest1.map(v => {
|
||||
this.工艺计划流水号组.push(v.工艺计划流水号)
|
||||
this.采购计划明细流水号组.push(v.采购计划明细流水号)
|
||||
this.离线采购计划明细流水号组.push(v.离线采购计划明细流水号)
|
||||
this.本次到货数量组.push(v.未到货数量)
|
||||
this.到货重量组.push(v.到货重量)
|
||||
this.到货金额组.push(v.到货重量 * this.单价)
|
||||
this.arrest10.map(v => {
|
||||
if (v.到货重量 > 0) {
|
||||
this.工艺计划流水号组.push(v.工艺计划流水号)
|
||||
this.采购计划明细流水号组.push(v.采购计划明细流水号)
|
||||
this.离线采购计划明细流水号组.push(v.离线采购计划明细流水号)
|
||||
this.本次到货数量组.push(v.未到货数量)
|
||||
this.到货重量组.push(v.到货重量)
|
||||
this.到货金额组.push(v.到货重量 * this.form10.单价)
|
||||
}
|
||||
})
|
||||
addMateriel(this.ArrivalOrderMXNumber, this.工艺计划流水号组, this.采购计划明细流水号组, this.本次到货数量组, this.离线采购计划明细流水号组, this.到货重量组, this.到货金额组, this.userId).then(response => {
|
||||
if (response.data[0].result === '1') {
|
||||
@@ -1280,6 +1326,8 @@ export default {
|
||||
this.tableData6 = response.data
|
||||
if (response.data.length !== 0) {
|
||||
this.未绑定数量 = response.data[0].未绑定数量
|
||||
} else {
|
||||
this.totalWight1 = 0.00
|
||||
}
|
||||
})
|
||||
} else { this.$message.error('取消失败') }
|
||||
|
||||
Reference in New Issue
Block a user