This commit is contained in:
liushuai
2019-08-20 13:03:06 +08:00
parent 3d6e2e043c
commit d02ecfcdf9
15 changed files with 852 additions and 45 deletions

View File

@@ -114,6 +114,11 @@
<el-tag v-if="purchased(scope.row)" type="info" size="small">已采购</el-tag>
</template>
</el-table-column>
<el-table-column :filters="supplierFilters" :filter-method="filterHandler" label="供货商" align="center" min-width="100" prop="供货商">
<template slot-scope="scope">
{{ scope.row.供货商 }}
</template>
</el-table-column>
<el-table-column label="任务分配时间" align="center" min-width="100">
<template slot-scope="scope">
{{ scope.row.任务分配时间.split(' ')[0] }}
@@ -202,11 +207,6 @@
{{ scope.row.备注 }}
</template>
</el-table-column>
<el-table-column :filters="supplierFilters" :filter-method="filterHandler" label="供货商" align="center" min-width="100" prop="供货商">
<template slot-scope="scope">
{{ scope.row.供货商 }}
</template>
</el-table-column>
<el-table-column label="询价单编号" align="center" min-width="100">
<template slot-scope="scope">
<b v-if="inquiry(scope.row)">{{ scope.row.询价单编号 }}</b>
@@ -307,6 +307,11 @@
<el-tag v-if="purchased(scope.row)" type="info" size="small">已采购</el-tag>
</template>
</el-table-column>
<el-table-column :filters="supplierFilters" :filter-method="filterHandler" label="供货商" align="center" min-width="100" prop="供货商">
<template slot-scope="scope">
{{ scope.row.供货商 }}
</template>
</el-table-column>
<el-table-column label="任务分配时间" align="center" min-width="100">
<template slot-scope="scope">
{{ scope.row.任务分配时间.split(' ')[0] }}
@@ -362,11 +367,6 @@
{{ scope.row.备注 }}
</template>
</el-table-column>
<el-table-column :filters="supplierFilters" :filter-method="filterHandler" label="供货商" align="center" min-width="100" prop="供货商">
<template slot-scope="scope">
{{ scope.row.供货商 }}
</template>
</el-table-column>
<el-table-column label="询价单编号" align="center" min-width="100">
<template slot-scope="scope">
<b v-if="inquiry(scope.row)">{{ scope.row.询价单编号 }}</b>

View File

@@ -48,7 +48,12 @@
<template slot-scope="scope">
<el-tag v-if="parseInt(scope.row.询价状态编号)===1" type="warning" size="small">未询价</el-tag>
<el-tag v-if="parseInt(scope.row.询价状态编号)===3&&parseInt(scope.row.采购状态编号)!==3" type="success" size="small">已询价</el-tag>
<el-tag v-if="parseInt(scope.row.询价状态编号)!==1&&parseInt(scope.row.采购状态编号)===3" type="info" size="small">已采购</el-tag>
<el-tag v-if="parseInt(scope.row.询价状态编号)!==1&&parseInt(scope.row.采购状态编号)===3" type="info" size="small" @click="unbindPart(scope.row)">已采购</el-tag>
</template>
</el-table-column>
<el-table-column :filters="supplierFilters" :filter-method="filterHandler" label="供货商" align="center" min-width="100" prop="供货商">
<template slot-scope="scope">
{{ scope.row.供货商 }}
</template>
</el-table-column>
<el-table-column label="任务分配时间" align="center" min-width="100">
@@ -111,11 +116,6 @@
{{ scope.row.备注 }}
</template>
</el-table-column>
<el-table-column :filters="supplierFilters" :filter-method="filterHandler" label="供货商" align="center" min-width="100" prop="供货商筛选">
<template slot-scope="scope">
{{ scope.row.供货商 }}
</template>
</el-table-column>
<el-table-column :filters="source" :filter-method="filterSource" align="center" label="数据来源" min-width="90px" prop="零件类型筛选">
<template slot-scope="scope">
{{ Number(scope.row.零件类型) === 1 ? 'BZ' : 'WG' }}
@@ -691,6 +691,7 @@ import { searchInventoryNum, searchOfflineContract, searchOfflineContract2, sear
import QRCode from 'qrcode'
import $ from 'jquery'
import { mapGetters } from 'vuex'
import request from '@/utils/request'
export default {
name: '', // 离线合同
@@ -865,6 +866,34 @@ export default {
this.initDirection()
},
methods: {
unbindPart(row) {
this.$confirm('确定还原状态?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
request({
url: '',
method: 'post',
data: {
type: '4',
name: `update MRP_计划订单_组件零件清单 set 询价状态编号 = 1 , 采购状态编号 = 1 where 标准件和外购件流水号 =${row.标准件和外购件流水号}`
}
}).then(res => {
if (res.data[0].result === '1') {
this.$message.success('操作成功')
this.searchTable00()
} else {
this.$message.error('操作失败')
}
})
}).catch(() => {
this.$message({
type: 'info',
message: '已取消操作'
})
})
},
initDirection() {
const direction = this.$getDirection()
direction.on('keyup', function(e, val) {
@@ -884,10 +913,10 @@ export default {
})
},
filterHandler0(value, row) { // 筛选备注
return row['备注'] === value
return row['备注'].trim() === value
},
filterHandler(value, row) { // 筛选供货商
return row['供货商'] === value
return row['供货商'].trim() === value
},
filterSource(value, row) {
return Number(row['零件类型']) === Number(value)