Merge branch 'master' of http://192.168.0.149:10010/r/高精2.0
This commit is contained in:
@@ -353,3 +353,37 @@ export function searchMerge(num) {
|
||||
}
|
||||
})
|
||||
}
|
||||
export function getPerson(num) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '3',
|
||||
name: 'select * from dbo.人事档案管理_人员名单 inner join dbo.菜单系统模块_人员与角色 ' +
|
||||
'on 人事档案管理_人员名单.人员编号=菜单系统模块_人员与角色.人员编号 ' +
|
||||
'where 角色编号=3 or 角色编号=2'
|
||||
}
|
||||
})
|
||||
}
|
||||
export function tiaozheng1(num1, num2) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '2',
|
||||
name: '采购件入库_创建询价单_调整采购任务_循环执行',
|
||||
param: '人员编号=' + num1 + '&标准件和外购件流水号组=' + num2
|
||||
}
|
||||
})
|
||||
}
|
||||
export function tiaozheng2(num1, num2) {
|
||||
return request({
|
||||
url: '',
|
||||
method: 'post',
|
||||
data: {
|
||||
type: '2',
|
||||
name: '采购件入库_创建询价单_调整采购任务_基本件_循环执行',
|
||||
param: '人员编号=' + num1 + '&基本件流水号组=' + num2
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
@@ -77,18 +77,21 @@
|
||||
<el-input v-model="materialSpec" placeholder="物料规格" size="small" clearable/>
|
||||
<span>物料型号:</span>
|
||||
<el-input v-model="materialModel" placeholder="物料型号" size="small" clearable/>
|
||||
<el-button
|
||||
type="success"
|
||||
size="small"
|
||||
icon="el-icon-search"
|
||||
style="margin-left: 10px"
|
||||
@click="pageCurrent11=1;pageSize11=100;total11=0;searchTable11()">查询</el-button>
|
||||
<el-button
|
||||
type="warning"
|
||||
size="small"
|
||||
icon="el-icon-download"
|
||||
style="margin-left: 10px"
|
||||
@click="exportUninquirySheet">导出未询价物料清单</el-button>
|
||||
<el-button type="success" size="small" icon="el-icon-search" style="margin-left: 10px" @click="pageCurrent11=1;pageSize11=100;total11=0;searchTable11()">查询</el-button>
|
||||
<el-button type="warning" size="small" icon="el-icon-download" style="margin-left: 10px" @click="exportUninquirySheet">导出未询价物料清单</el-button>
|
||||
<el-popover v-model="visible" title="调整采购任务" placement="top" width="180">
|
||||
<div style="text-align: right; margin: 0">
|
||||
<el-select v-model="PersonValue" style="width:150px" placeholder="人员" size="small" filterable clearable>
|
||||
<el-option
|
||||
v-for="item in Person"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"/>
|
||||
</el-select>
|
||||
<el-button type="primary" size="mini" @click="visible = false;tiaozheng1()">确定</el-button>
|
||||
</div>
|
||||
<el-button slot="reference" type="warning" size="small" plain style="margin-left: 2px">调整采购任务</el-button>
|
||||
</el-popover>
|
||||
</el-row>
|
||||
<el-row style="margin-bottom: 10px">
|
||||
<el-table
|
||||
@@ -275,18 +278,21 @@
|
||||
<el-input v-model="partName" placeholder="零件名称" size="small" clearable/>
|
||||
<span>零件规格:</span>
|
||||
<el-input v-model="partSpec" placeholder="零件规格" size="small" clearable/>
|
||||
<el-button
|
||||
type="success"
|
||||
size="small"
|
||||
icon="el-icon-search"
|
||||
style="margin-left: 10px"
|
||||
@click="pageCurrent12=1;pageSize12=100;total12=0;searchTable12()">查询</el-button>
|
||||
<el-button
|
||||
type="warning"
|
||||
size="small"
|
||||
icon="el-icon-download"
|
||||
style="margin-left: 10px"
|
||||
@click="exportUninquirySheet">导出未询价物料清单</el-button>
|
||||
<el-button type="success" size="small" icon="el-icon-search" style="margin-left: 10px" @click="pageCurrent12=1;pageSize12=100;total12=0;searchTable12()">查询</el-button>
|
||||
<el-button type="warning" size="small" icon="el-icon-download" style="margin-left: 10px" @click="exportUninquirySheet">导出未询价物料清单</el-button>
|
||||
<el-popover v-model="visible2" title="调整采购任务" placement="top" width="180">
|
||||
<div style="text-align: right; margin: 0">
|
||||
<el-select v-model="PersonValue" style="width:150px" placeholder="人员" size="small" filterable clearable>
|
||||
<el-option
|
||||
v-for="item in Person"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"/>
|
||||
</el-select>
|
||||
<el-button type="primary" size="mini" @click="visible2 = false;tiaozheng2()">确定</el-button>
|
||||
</div>
|
||||
<el-button slot="reference" type="warning" size="small" plain style="margin-left: 2px">调整采购任务</el-button>
|
||||
</el-popover>
|
||||
</el-row>
|
||||
<el-row style="margin-bottom: 10px">
|
||||
<el-table
|
||||
@@ -298,7 +304,7 @@
|
||||
height="500px"
|
||||
size="mini"
|
||||
@selection-change="handleSelectionChange2">
|
||||
<el-table-column :selectable="selectable" align="center" width="35" type="selection"/>
|
||||
<el-table-column :selectable="selectable" align="center" width="50" type="selection"/>
|
||||
<!--<el-table-column label="操作" align="center" width="100" fixed="left">-->
|
||||
<!--<template slot-scope="scope">-->
|
||||
<!--<el-button :disabled="parseInt(scope.row.询价状态编号)!==1||parseInt(scope.row.是否确认)!==1" type="primary" size="mini" @click="partChange(scope.row)">零件变更</el-button>-->
|
||||
@@ -877,7 +883,7 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { getBillNum, searchMaterial, searchPart, searchSupplier, searchCreateInquirySheet, searchCreateInquirySheet2, searchSheetDetail, editInquirySheet,
|
||||
import { tiaozheng2, tiaozheng1, getPerson, getBillNum, searchMaterial, searchPart, searchSupplier, searchCreateInquirySheet, searchCreateInquirySheet2, searchSheetDetail, editInquirySheet,
|
||||
createInquirySheet, deleteInquirySheet, addInquirySheet1, addInquirySheet2, outInquirySheet, searchAllMaterial, materialChange, saveOrder,
|
||||
submitUseInventory, initProject, searchMachine, searchGroup, searchBaseInfo, editBaseInfo, getExport1, getExport2, searchMerge } from '@/api/PurchasingCenter/CreateInquirySheet'
|
||||
import { mapGetters } from 'vuex'
|
||||
@@ -889,6 +895,12 @@ export default {
|
||||
name: '', // 创建询价单
|
||||
data() {
|
||||
return {
|
||||
标准件和外购件流水号: [],
|
||||
基本件流水号: [],
|
||||
visible: false,
|
||||
visible2: false,
|
||||
Person: [],
|
||||
PersonValue: '',
|
||||
supplierNames: [], // 供应商下拉框
|
||||
switchValue: false, // 物料变更列显示开关
|
||||
source: [
|
||||
@@ -1052,10 +1064,12 @@ export default {
|
||||
computed: {
|
||||
...mapGetters([
|
||||
'name',
|
||||
'token',
|
||||
'id' // 人员编号
|
||||
])
|
||||
},
|
||||
created() {
|
||||
this.getPerson()
|
||||
this.fetchData()
|
||||
this.searchTable11() // 查表1
|
||||
this.searchTable2() // 查表2
|
||||
@@ -1064,10 +1078,55 @@ export default {
|
||||
this.initDirection()
|
||||
},
|
||||
methods: {
|
||||
tiaozheng1() {
|
||||
if (this.标准件和外购件流水号.length !== 0) {
|
||||
if (this.PersonValue) {
|
||||
tiaozheng1(this.PersonValue, this.标准件和外购件流水号).then(response => {
|
||||
if (response.data[0].result === '1') {
|
||||
this.$message.success('调整成功')
|
||||
this.searchTable11()
|
||||
} else {
|
||||
this.$message.warning('调整失败')
|
||||
}
|
||||
})
|
||||
} else {
|
||||
this.$message.warning('请选择人员')
|
||||
}
|
||||
} else {
|
||||
this.$message.warning('请选择物料')
|
||||
}
|
||||
},
|
||||
tiaozheng2() {
|
||||
if (this.基本件流水号.length !== 0) {
|
||||
if (this.PersonValue) {
|
||||
tiaozheng2(this.PersonValue, this.基本件流水号).then(response => {
|
||||
if (response.data[0].result === '1') {
|
||||
this.$message.success('调整成功')
|
||||
this.searchTable12()
|
||||
} else {
|
||||
this.$message.warning('调整失败')
|
||||
}
|
||||
})
|
||||
} else {
|
||||
this.$message.warning('请选择人员')
|
||||
}
|
||||
} else {
|
||||
this.$message.warning('请选择物料')
|
||||
}
|
||||
},
|
||||
getPerson() {
|
||||
getPerson().then(response => {
|
||||
for (let i = 0; i < response.data.length; i++) {
|
||||
this.Person.push({
|
||||
value: response.data[i].人员编号,
|
||||
label: response.data[i].姓名
|
||||
})
|
||||
}
|
||||
})
|
||||
},
|
||||
initDirection() {
|
||||
const direction = this.$getDirection()
|
||||
direction.on('keyup', function(e, val) {
|
||||
console.log(val)
|
||||
if (e.keyCode === 39) {
|
||||
direction.next()
|
||||
}
|
||||
@@ -1162,7 +1221,6 @@ export default {
|
||||
}
|
||||
}).then(res => {
|
||||
this.machines1 = res.data
|
||||
console.log(this.machines1)
|
||||
})
|
||||
},
|
||||
async searchUnBuyPartNumber() {
|
||||
@@ -1364,7 +1422,6 @@ export default {
|
||||
this.dialogVisible4 = true
|
||||
},
|
||||
// cancelUseInventory(row) { // 取消使用滞货
|
||||
// console.log(row)
|
||||
// this.backlogMaterialNum = row.物料流水号
|
||||
// this.backlogGroupPartNum = row.组件零件流水号
|
||||
// this.cancelNum = row.使用滞货数量
|
||||
@@ -1373,7 +1430,6 @@ export default {
|
||||
// cancelButtonText: '取消',
|
||||
// type: 'warning'
|
||||
// }).then(() => {
|
||||
// console.log(this.backlogMaterialNum, this.cancelNum, this.backlogGroupPartNum)
|
||||
// cancelUseInventory(this.backlogMaterialNum, this.cancelNum, this.backlogGroupPartNum).then(response => {
|
||||
// if (response.data[0].result === '1') {
|
||||
// this.searchTable11()
|
||||
@@ -1675,7 +1731,6 @@ export default {
|
||||
printNode.remove()
|
||||
})
|
||||
}).catch(res => {
|
||||
console.log(res)
|
||||
this.$message({
|
||||
type: 'info',
|
||||
message: '已取消操作'
|
||||
@@ -1724,7 +1779,6 @@ export default {
|
||||
}
|
||||
})
|
||||
}).catch(res => {
|
||||
console.log(res)
|
||||
this.$message({
|
||||
type: 'info',
|
||||
message: '已取消操作'
|
||||
@@ -1734,17 +1788,21 @@ export default {
|
||||
handleSelectionChange1(val) { // 标准件和外购件多选
|
||||
this.groupPartNum = []
|
||||
this.allNum = []
|
||||
this.标准件和外购件流水号 = []
|
||||
for (let i = 0; i < val.length; i++) {
|
||||
this.groupPartNum[i] = val[i].组件零件流水号
|
||||
this.allNum[i] = val[i].待询价数量
|
||||
this.标准件和外购件流水号[i] = val[i].标准件和外购件流水号
|
||||
}
|
||||
},
|
||||
handleSelectionChange2(val) { // 基本件多选
|
||||
this.groupPartBasicNum = []
|
||||
this.allNum = []
|
||||
this.基本件流水号 = []
|
||||
for (let i = 0; i < val.length; i++) {
|
||||
this.groupPartBasicNum[i] = val[i].组件零件基本件流水号
|
||||
this.allNum[i] = val[i].零件数量
|
||||
this.基本件流水号[i] = val[i].基本件流水号
|
||||
}
|
||||
},
|
||||
addInquirySheet() { // 追加物料
|
||||
@@ -1894,7 +1952,6 @@ export default {
|
||||
},
|
||||
partChange(row) { // 零件变更 基本件
|
||||
this.$message('没有基本件的标准库')
|
||||
console.log(row)
|
||||
},
|
||||
searchMaterial() {
|
||||
if (this.materialName0 || this.materialSpec0 || this.materialModel0) {
|
||||
|
||||
Reference in New Issue
Block a user