外协查询V2

This commit is contained in:
liulujia1
2020-04-14 15:53:20 +08:00
23 changed files with 1269 additions and 427 deletions

View File

@@ -0,0 +1,48 @@
import request from '@/utils/request'
import state from '@/store'
import router from '@/router'
// 初始化机床项目
export function initMachineProject() {
return request({
url: '',
method: 'post',
data: {
UserID: state.state.user.id,
ModularID: router.currentRoute.path,
type: '1',
// name: 'PDM_项目名称_查询数据'
name: '采购管理_仓库采购_出库记录_机床图号_查询'
}
})
}
// 分组查询
export function searchGroup(num) {
return request({
url: '',
method: 'post',
data: {
UserID: state.state.user.id,
ModularID: router.currentRoute.path,
type: '1',
// name: 'PDM_组件名称_查询数据',
name: '采购管理_仓库采购_出库记录_组件名称_查询',
param: '机床流水号=' + num
}
})
}
// 查询记录
export function searchRecord(check1, project, check2, machine, check3, group, check4, name, check5, spec, check6, model, check7, time1, time2, pageCurrent, pageSize) {
return request({
url: '',
method: 'post',
data: {
UserID: state.state.user.id,
ModularID: router.currentRoute.path,
type: '1',
name: `库存管理_出库记录_查询数据`,
param: `项目流水号_check=${check1}&项目流水号=${project}&机床流水号_check=${check2}&机床流水号=${machine}&组件流水号_check=${check3}&组件流水号=${group}&名称_check=${check4}&名称=${name}&规格_check=${check5}&规格=${spec}&图号或型号_check=${check6}&图号或型号=${model}&出库时间_check=${check7}&出库开始时间=${time1}&出库结束时间=${time2}`,
Pagination: pageCurrent + '&' + pageSize
}
})
}

View File

@@ -115,7 +115,7 @@ export function editData1(Number, manufacturers, freight, Explain) {
})
}
// 新建外协加工任务单
export function addTable(contractNumber, personNum, manufacturers, time, freight) {
export function addTable(contractNumber, personNum, manufacturers, time, time2, freight) {
return request({
url: '',
method: 'post',
@@ -124,12 +124,12 @@ export function addTable(contractNumber, personNum, manufacturers, time, freight
ModularID: router.currentRoute.path,
type: '2',
name: '车间生产管理_外协加工任务单_增加数据',
param: '表单号=' + contractNumber + '=string&外协计划员编号=' + personNum + '&外协厂家=' + manufacturers + '=int&任务下达日期=' + time + '=string&运费=' + freight + '=int'
param: '表单号=' + contractNumber + '&外协计划员编号=' + personNum + '&外协厂家=' + manufacturers + '&任务下达日期=' + time + '&到货日期=' + time2 + '&运费=' + freight
}
})
}
// 外协加工任务单修改
export function editData(Number, manufacturers, freight, Explain) {
export function editData(Number, manufacturers, freight, Explain, time2) {
return request({
url: '',
method: 'post',
@@ -138,7 +138,7 @@ export function editData(Number, manufacturers, freight, Explain) {
ModularID: router.currentRoute.path,
type: '2',
name: '车间生产管理_外协加工任务单_修改数据',
param: '外协加工任务单流水号=' + Number + '&外协厂家=' + manufacturers + '&运费=' + freight + '&扣款说明=' + Explain
param: '外协加工任务单流水号=' + Number + '&外协厂家=' + manufacturers + '&运费=' + freight + '&扣款说明=' + Explain + '&到货日期=' + time2
}
})
}
@@ -152,7 +152,7 @@ export function deleteData(Number) {
ModularID: router.currentRoute.path,
type: '2',
name: '车间生产管理_外协加工任务单_删除数据',
param: '外协加工任务单流水号=' + Number + '=int'
param: '外协加工任务单流水号=' + Number
}
})
}
@@ -166,7 +166,7 @@ export function deleteData1(Number) {
ModularID: router.currentRoute.path,
type: '2',
name: '车间生产管理_外协加工任务单明细_删除数据',
param: '外协加工任务单明细流水号=' + Number + '=int'
param: '外协加工任务单明细流水号=' + Number
}
})
}
@@ -181,7 +181,7 @@ export function getNumber(time) {
ModularID: router.currentRoute.path,
type: '1',
name: '车间生产管理_外协加工任务单_查询数据_单据编号',
param: '任务下达日期=' + time + '=string&表单号=1=string=output'
param: '任务下达日期=' + time + '&表单号=1=string=output'
}
})
}

View File

@@ -423,7 +423,6 @@ export function transferMX(num1, name, num2, remark, mark, num3, num4, num5, num
// 传递零件
export function transferMX1(num1, name, num2, remark, mark, num3, num4, num5, num7, type, transmit, num6, num8, num9, id, oldId, oldNum, peopleid) {
console.log(peopleid, 9090909090)
return request({
url: '',
method: 'post',

View File

@@ -0,0 +1,44 @@
import request from '@/utils/request'
import state from '@/store'
import router from '@/router'
// 获取机床
export function searchMachine() {
return request({
url: '',
method: 'post',
data: {
UserID: state.state.user.id,
ModularID: router.currentRoute.path,
type: '1',
name: 'PDM_项目名称_查询数据'
}
})
}
// 查询报废零件
export function searchtable(check1, value1, check3, value3, check5, value5, value6, pageCurrent, pageSize) {
return request({
url: '',
method: 'post',
data: {
UserID: state.state.user.id,
ModularID: router.currentRoute.path,
type: '1',
name: '车间生产管理工艺_传递后_零件报废补投_查询数据_新',
param: '机床流水号_check=' + check1 + '&机床流水号=' + value1 + '&零件图号_check=' + check3 + '&零件图号=' + value3 + '&时间段_check=' + check5 + '&开始时间=' + value5 + '&结束时间=' + value6 + `&PageCurrent=${pageCurrent}&PageSize=${pageSize}&PageCount=1111=int=output&ItemCount=1111=int=output`
}
})
}
export function editA(CutCodebefore, Number, id) {
return request({
url: '',
method: 'post',
data: {
UserID: state.state.user.id,
ModularID: router.currentRoute.path,
type: '2',
name: '车间生产管理工艺_零件工艺计划_报废零件_补投',
param: '工艺计划流水号=' + CutCodebefore + '&补投数量=' + Number + '&补投人=' + id
}
})
}

View File

@@ -16,8 +16,9 @@ export function getInfo(token) {
url: '',
method: 'post',
data: {
type: '3',
name: `select * from 基础表_角色模块信息 inner join 基础表_模块信息 on 基础表_角色模块信息.id = 基础表_模块信息.id where 角色编号=${token} order by 模块顺序`
type: '1',
name: `菜单系统模块_获取角色模块_查询数据`,
param: `角色编号=${token}`
}
})
}

View File

@@ -44,6 +44,7 @@ const user = {
Cookies.set('id', data[0].人员编号, { expires: 1 })
Cookies.set('name', data[0].姓名, { expires: 1 })
Cookies.set('userId', data[0].考勤编号, { expires: 1 })
Cookies.set('session_id', data[0].session_id)
commit('SET_TOKEN', data[0].角色编号)
commit('SET_NAME', data[0].姓名)
commit('SET_ID', data[0].人员编号)

View File

@@ -1,4 +1,6 @@
import axios from 'axios'
// import Cookies from 'js-cookie'
// import store from '@/store'
export const wsuri = `ws://123.56.95.229:61101//WebMoudule//websocket`
export const name = `OP8888`
@@ -26,7 +28,44 @@ export const MESUploadFile = `http://123.56.95.229:8010/submit/MESUploadFile.ash
export const MESDownloadFile = `http://123.56.95.229:8010/submit/MESDownloadFile.ashx`
const service = axios.create({
baseURL: `http://123.56.95.229:8010/submit/MESCommonBase.ashx`,
// baseURL: `http://192.168.1.192:8045/submit/MESCommonBase.ashx`,
timeout: 1500000 // 请求超时时间
})
// && config.data.name !== '菜单系统模块_通知信息_查询数据' && config.data.name !== '菜单系统模块_首页信息_查询数据1' && config.data.name !== '菜单系统模块_首页信息_查询数据2'
service.interceptors.request.use(config => {
// if (config.data.name !== '菜单系统模块_用户名密码_查询数据_new2' && config.data.name !== '菜单系统模块_获取角色模块_查询数据') {
// getSession_id().then(res => {
// if (res === 0) {
// store.dispatch('FedLogOut').then(() => {
// location.reload() // 为了重新实例化vue-router对象 避免bug
// alert('此账号已异地登录,请查重新登录')
// })
// }
// })
// }
return config
}, error => {
Promise.reject(error)
})
export default service
// async function getSession_id() {
// const id = Cookies.get('id')
// const session_id = Cookies.get('session_id')
// const param = {
// url: url,
// method: 'post',
// data: {
// type: '1',
// name: '菜单系统模块_用户sessionID_查询数据',
// param: '人员编号=' + id
// }
// }
// const res = await axios(param)
// if (session_id !== res.data[0].session_id) {
// return 0
// } else {
// return 1
// }
// }

View File

@@ -0,0 +1,228 @@
<template>
<div class="app-container">
<el-card style="width: 1000px;margin: 0px 0px 5px 0px">
<el-row style="margin-bottom:10px;margin-top: 10px">
<el-select v-model="machineValue" filterable placeholder="机床图号" size="small" clearable style="width: 180px" @change="machineChange">
<el-option
v-for="item in machine"
:key="item.value"
:label="item.label"
:value="item.value">
<div style="float: left">{{ item.label }}</div>
<div style="float: right; color: #8492a6; font-size: 13px">{{ item.name }}</div>
</el-option>
</el-select>
<el-select v-model="groupValue" placeholder="组号" size="small" style="width: 90px;margin-left: 10px" clearable filterable>
<el-option
v-for="item in group"
:key="item.value"
:label="item.label"
:value="item.value"/>
</el-select>
<el-input v-model="name" placeholder="名称图号规格领料人" clearable size="small" style="width:165px;margin-left: 10px" @keyup.enter.native="pageCurrent1=1;pageSize1=100;searchRecord()"/>
<!--<el-input v-model="model" placeholder="图号或型号" clearable size="small" style="width:150px;margin-left: 10px" />-->
<!--<el-input v-model="spec" placeholder="规格" clearable size="small" style="width:150px;margin: 0px 10px" />-->
<el-date-picker
v-model="outTime"
type="daterange"
size="small"
format="yyyy-MM-dd"
value-format="yyyy-MM-dd"
range-separator="~"
style="width:240px;margin-left: 10px"
start-placeholder="开始日期"
end-placeholder="结束日期"/>
<el-button type="primary" icon="el-icon-search" size="small" style="margin-left: 20px" plain @click="pageCurrent1=1;pageSize1=100;searchRecord()">查询</el-button>
<el-button :loading="loading_export" type="success" icon="el-icon-bottom" plain size="small" style="margin-left: 15px" @click="exportExcel()">导出</el-button>
</el-row>
<el-row v-show="false" style="margin-bottom:10px">
<el-date-picker
v-model="outTime"
type="daterange"
size="small"
format="yyyy-MM-dd"
value-format="yyyy-MM-dd"
range-separator="~"
style="width:250px;margin-left: 0px"
start-placeholder="开始时间"
end-placeholder="结束时间"/>
</el-row>
</el-card>
<el-card style="width: 1000px">
<el-table :data="tableData" border stripe size="mini" height="700">
<el-table-column label="名称" align="center" width="180" show-overflow-tooltip>
<template slot-scope="scope">
{{ scope.row.名称 }}
</template>
</el-table-column>
<el-table-column label="图号或型号" align="center" width="180" show-overflow-tooltip>
<template slot-scope="scope">
{{ scope.row.图号或型号 }}
</template>
</el-table-column>
<el-table-column label="规格" align="center" width="270" 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.出库数量 }}
</template>
</el-table-column>
<el-table-column label="领料人" align="center" width="100" show-overflow-tooltip>
<template slot-scope="scope">
{{ scope.row.领料人 }}
</template>
</el-table-column>
<el-table-column label="出库时间" align="center" min-width="90">
<template slot-scope="scope">
{{ scope.row.出库时间 ? scope.row.出库时间.split(' ')[0] : '-' }}
</template>
</el-table-column>
</el-table>
<div class="block" style="margin-top: 10px;">
<el-pagination
:current-page="pageCurrent1"
:page-sizes="[10, 20, 30, 40, 100]"
:page-size="pageSize1"
:total="total1"
style="display:inline-block;width:50%"
layout="total, sizes, prev, pager, next, jumper"
@size-change="handleSizeChange1"
@current-change="handleCurrentChange1"/>
</div>
</el-card>
</div>
</template>
<script>
import { initMachineProject, searchGroup, searchRecord } from '@/api/Inventory/PurchaseOutRecord'
export default {
name: 'PurchaseOutRecord',
data() {
return {
loading_export: false,
projectValue: '', // 项目名称
project: [],
machineValue: '',
machine: [],
groupValue: '',
group: [],
name: '',
spec: '',
model: '',
tableData: [],
pageSize1: 100,
pageCurrent1: 1,
total1: 0,
outTime: '' // 出库时间
}
},
watch: {
groupValue() {
this.searchRecord()
}
},
created() {
this.fetchData()
},
mounted() {
this.searchRecord()
},
methods: {
// EXCEL 导出
// 姜福壮
async exportExcel() {
this.loading_export = true
let check1, check2, check3, check4, check5, check6, check7
this.projectValue ? check1 = 1 : check1 = 0
this.machineValue ? check2 = 1 : check2 = 0
this.groupValue ? check3 = 1 : check3 = 0
this.name ? check4 = 1 : check4 = 0
this.spec ? check5 = 1 : check5 = 0
this.model ? check6 = 1 : check6 = 0
this.outTime ? check7 = 1 : (check7 = 0, this.outTime = '')
var param = []
param[0] = ['项目流水号_check', check1]
param[1] = ['项目流水号', this.projectValue]
param[2] = ['机床流水号_check', check2]
param[3] = ['机床流水号', this.machineValue]
param[4] = ['组件流水号_check', check3]
param[5] = ['组件流水号', this.groupValue]
param[6] = ['名称_check', check4]
param[7] = ['名称', this.name]
param[8] = ['规格_check', check5]
param[9] = ['规格', this.spec]
param[10] = ['图号或型号_check', check6]
param[11] = ['图号或型号', this.model]
param[12] = ['出库时间_check', check7]
param[13] = ['出库开始时间', this.outTime[0]]
param[14] = ['出库结束时间', this.outTime[1]]
var Data = this.CreateData('2001', '报表_采购部仓库_出库记录_查询', param)
await this.exportExcel_NPOI(Data)
setTimeout(() => {
this.loading_export = false
}, 5000)
},
fetchData() {
initMachineProject().then(response => {
for (let i = 0; i < response.data.length; i++) {
this.machine.push({
label: response.data[i].机床图号,
name: response.data[i].项目名称,
value: response.data[i].机床流水号
})
}
})
},
machineChange() {
this.group = []
this.groupValue = ''
searchGroup(this.machineValue).then(response => {
for (let i = 0; i < response.data.length; i++) {
this.group.push({
value: response.data[i].组件流水号,
label: response.data[i].组号
})
}
if (response.data.length > 0) {
this.groupValue = this.group[0].value
}
})
},
searchRecord() {
let check1, check2, check3, check4, check5, check6, check7
this.projectValue ? check1 = 1 : check1 = 0
this.machineValue ? check2 = 1 : check2 = 0
this.groupValue ? check3 = 1 : check3 = 0
this.name ? check4 = 1 : check4 = 0
this.spec ? check5 = 1 : check5 = 0
this.model ? check6 = 1 : check6 = 0
this.outTime ? check7 = 1 : (check7 = 0, this.outTime = '')
searchRecord(check1, this.projectValue, check2, this.machineValue, check3, this.groupValue, check4, this.name, check5, this.spec, check6, this.model, check7, this.outTime[0], this.outTime[1], this.pageCurrent1, this.pageSize1).then(res => {
this.tableData = res.data.rows
this.total1 = res.data.total
})
},
handleSizeChange1(val) {
this.pageSize1 = val
this.pageCurrent1 = 1
this.searchRecord()
},
handleCurrentChange1(val) {
this.pageCurrent1 = val
this.searchRecord()
}
}
}
</script>
<style scoped>
.el-card{
margin-bottom: 15px;
}
span{
margin: 10px 0 10px 10px;
}
</style>

View File

@@ -29,7 +29,7 @@
</el-row>
</el-card>
<el-card>
<el-table :data="tableData" style="width: 1120px" height="580" stripe size="mini" border @selection-change="handleSelectionChange">
<el-table :data="tableData" style="width: 1020px" height="580" stripe size="mini" border @selection-change="handleSelectionChange">
<el-table-column
type="selection"
width="45"/>
@@ -54,11 +54,6 @@
{{ scope.row.零件名称 }}
</template>
</el-table-column>
<el-table-column align="center" label="入库时间" width="100px">
<template slot-scope="scope">
{{ scope.row.入库时间 }}
</template>
</el-table-column>
<el-table-column align="center" label="库存数量" width="90px">
<template slot-scope="scope">
{{ scope.row.出库数量1 }}
@@ -97,7 +92,7 @@
</div>
</el-card>
<el-dialog v-el-drag-dialog :visible.sync="dialogFormVisible" title="出库信息" center width="380px">
<el-form ref="form" :model="form" :rules="rules" label-position="left">
<el-form ref="form" :model="form" :rules="rules" label-position="right">
<el-form-item label="部门" prop="部门" label-width="100px" size="small">
<!-- <el-input v-model="form.department" size="small" placeholder="请输入人员编号" style="width: 200px"/>-->
<el-select v-model="form.department" placeholder="请选择部门" size="small" clearable style="width: 200px;" @change="selectLeaders">
@@ -185,7 +180,6 @@ export default {
组号: response.data.rows[i].组号,
零件图号: response.data.rows[i].零件图号,
零件名称: response.data.rows[i].零件名称,
入库时间: response.data.rows[i].入库时间,
已出库数量: Number(response.data.rows[i].出库数量),
入库数量: Number(response.data.rows[i].入库数量),
工艺计划流水号: response.data.rows[i].工艺计划流水号,

View File

@@ -29,57 +29,77 @@
</el-card>
<el-card style="margin-top: 5px">
<el-table v-loading="loading1" :data="tableData1" size="mini" border stripe style="width: 100%" height="600px" highlight-current-row>
<el-table-column label="采购合同编号" align="center" min-width="130">
<el-table-column label="采购合同编号" align="center" width="110">
<template slot-scope="scope">
{{ scope.row.采购合同编号 }}
</template>
</el-table-column>
<el-table-column label="供应商" align="center" min-width="150">
<el-table-column label="供应商" align="center" min-width="150" show-overflow-tooltip>
<template slot-scope="scope">
{{ scope.row.供应商名称 }}
</template>
</el-table-column>
<el-table-column label="采购员" align="center" min-width="60">
<el-table-column label="采购员" align="center" width="70">
<template slot-scope="scope">
{{ scope.row.姓名 }}
</template>
</el-table-column>
<el-table-column label="合同金额(元)" align="center" min-width="60">
<el-table-column label="合同金额(元)" align="center" min-width="90">
<template slot-scope="scope">
{{ scope.row.合同总额 }}
</template>
</el-table-column>
<el-table-column label="交货日期" align="center" min-width="60">
<el-table-column label="交货日期" align="center" width="90">
<template slot-scope="scope">
{{ scope.row.交货日期 }}
</template>
</el-table-column>
<el-table-column label="提交时间" align="center" min-width="60">
<el-table-column label="提交时间" align="center" width="90">
<template slot-scope="scope">
{{ scope.row.操作时间 ? scope.row.操作时间.split(' ')[0] : '' }}
</template>
</el-table-column>
<el-table-column label="审核人" align="center" min-width="60">
<el-table-column label="审核人" align="center" width="90">
<template slot-scope="scope">
{{ scope.row.审核人姓名 }}
</template>
</el-table-column>
<el-table-column label="审核时间" align="center" min-width="60">
<el-table-column label="审核时间" align="center" width="90">
<template slot-scope="scope">
{{ scope.row.审核时间 ? scope.row.审核时间.split(' ')[0] : '' }}
</template>
</el-table-column>
<el-table-column label="审核结果" align="center" min-width="60">
<el-table-column label="审核结果" align="center" min-width="90">
<template slot-scope="scope">
{{ scope.row.审核情况内容 }}
</template>
</el-table-column>
<el-table-column label="未过原因" align="center" min-width="60">
<el-table-column label="审核未过原因" align="center" width="80">
<template slot-scope="scope">
{{ scope.row.未通过审核原因 }}
</template>
</el-table-column>
<el-table-column label="操作" align="center" width="90px" fixed="right">
<el-table-column label="审批人" align="center" width="90">
<template slot-scope="scope">
{{ scope.row.审批人姓名 }}
</template>
</el-table-column>
<el-table-column label="审批时间" align="center" min-width="90">
<template slot-scope="scope">
{{ scope.row.审批时间 ? scope.row.审批时间.split(' ')[0] : '' }}
</template>
</el-table-column>
<el-table-column label="审批结果" align="center" min-width="90">
<template slot-scope="scope">
{{ scope.row.审批情况内容 }}
</template>
</el-table-column>
<el-table-column label="审批未过原因" align="center" width="80">
<template slot-scope="scope">
{{ scope.row.未通过审批原因 }}
</template>
</el-table-column>
<el-table-column label="操作" align="center" width="50px" fixed="right">
<template slot-scope="scope">
<el-tooltip :open-delay="1000" effect="dark" content="查看详情" placement="top">
<div style="display: inline-block">

View File

@@ -621,6 +621,8 @@ export default {
this.$refs['form10'].resetFields()
}
this.openUrgentItem_disable = false
this.form10.规格 = ''
this.form10.机床号 = ''
this.dialogFormVisible10 = true
},
typeChange() {

View File

@@ -1,95 +1,39 @@
<template>
<div class="app-container">
<el-card>
<!-- <el-input v-model="billNames" clearable filterable size="small" placeholder="供应商或合同编号" style="width: 200px;margin: 5px"/>-->
<el-select v-model="supplierValue" placeholder="供应商" filterable size="small" style="margin-left: 5px" clearable @change="totalSum=0;totalPay=0;totalDebt=0;">
<el-option
v-for="item in supplier"
:key="item.value"
:label="item.label"
:value="item.value"/>
</el-select>
<el-select v-model="personValue" placeholder="采购员" size="small" style="width: 120px" clearable>
<el-option
v-for="item in person"
:key="item.value"
:label="item.label"
:value="item.value"/>
</el-select>
<span style="margin-left: 0">审核时间:</span>
<el-date-picker
v-model="dateRange"
size="small"
type="daterange"
align="center"
style="width: 300px"
value-format="yyyy-MM-dd"
format="yyyy-MM-dd"
range-separator=""
start-placeholder="开始日期"
end-placeholder="结束日期"/>
<el-button type="primary" plain size="small" icon="el-icon-search" style="margin-left: 10px" @click="total1=0;pageCurrent1=1;pageSize1=50;searchTable1()">查询</el-button>
<el-radio v-model="radio" label="1" style="margin: 0 0 0 10px">全部</el-radio>
<el-radio v-model="radio" label="2" style="margin: 0 0 0 10px">通过</el-radio>
<el-radio v-model="radio" label="3" style="margin: 0 0 0 10px">未过</el-radio>
<el-button type="success" size="small" icon="el-icon-download" style="margin-left:10px;margin-top: 3px;margin-right: 20px;float: right" plain @click="exportTable('')">导出</el-button>
</el-card>
<el-card style="margin-top: 5px">
<el-table v-loading="loading1" :data="tableData1" size="mini" border stripe style="width: 100%" height="600px" highlight-current-row>
<el-table-column label="供应商" align="center" min-width="150">
<!-- <h3 style="margin-top: 0">采购合同</h3>-->
<el-table v-loading="" :data="tableData1" border stripe style="width: 100%;max-height: 300px;" height="200px" size="mini" highlight-current-row @row-click="searchTable01">
<el-table-column label="供应商" align="center" min-width="170">
<template slot-scope="scope">
{{ scope.row.供应商名称 }}
</template>
</el-table-column>
<el-table-column label="请款" align="center" min-width="60">
<el-table-column label="请款时间" align="center" min-width="140">
<template slot-scope="scope">
{{ scope.row.请款时间.substr(0,10) }}
</template>
</el-table-column>
<el-table-column label="请款人" align="center" min-width="80">
<template slot-scope="scope">
{{ scope.row.姓名 }}
</template>
</el-table-column>
<el-table-column label="请款金额(元)" align="center" min-width="60">
<el-table-column label="请款金额(元)" align="center" min-width="80" prop="请款金额">
<template slot-scope="scope">
{{ scope.row.请款金额 }}
</template>
</el-table-column>
<el-table-column label="提交时间" align="center" min-width="60">
<el-table-column label="审核" align="center" width="200">
<template slot-scope="scope">
{{ scope.row.请款时间 ? scope.row.请款时间.split(' ')[0] : '' }}
</template>
</el-table-column>
<el-table-column label="审核人" align="center" min-width="60">
<template slot-scope="scope">
{{ scope.row.审核人姓名 }}
</template>
</el-table-column>
<el-table-column label="审核时间" align="center" min-width="60">
<template slot-scope="scope">
{{ scope.row.审核时间 ? scope.row.审核时间.split(' ')[0] : '' }}
</template>
</el-table-column>
<el-table-column label="审核结果" align="center" min-width="60">
<template slot-scope="scope">
{{ scope.row.审核情况内容 }}
</template>
</el-table-column>
<el-table-column label="未过原因" align="center" min-width="60">
<template slot-scope="scope">
{{ scope.row.未通过审核原因 }}
</template>
</el-table-column>
<el-table-column label="操作" align="center" width="90px" fixed="right">
<template slot-scope="scope">
<el-tooltip :open-delay="1000" effect="dark" content="查看详情" placement="top">
<div style="display: inline-block">
<el-button type="text" size="mini" @click="searchTable2(scope.row)">详情</el-button>
</div>
</el-tooltip>
<el-button type="text" size="mini" icon="el-icon-check" plain @click="yesApproval(scope.row)">通过</el-button>
<el-button type="text" size="mini" icon="el-icon-close" plain @click="noApproval(scope.row)">不通过</el-button>
</template>
</el-table-column>
</el-table>
<div class="block" style="margin-top: 10px;">
<el-pagination
:current-page="pageCurrent1"
:page-sizes="[50, 100, 150, 200]"
:page-sizes="[10, 20, 30, 40]"
:page-size="pageSize1"
:total="total1"
style="display:inline-block;width:50%"
@@ -98,60 +42,114 @@
@current-change="handleCurrentChange1"/>
</div>
</el-card>
<el-dialog v-el-drag-dialog :visible.sync="dialogFormVisible" title="请款信息明细" center width="800px">
<el-table :data="gridData1" border highlight-current-row size="mini">
<el-table-column min-width="150" align="center" label="合同编号">
<!-- <h3 style="">合同明细</h3>-->
<el-row>
<el-col :span="10">
<el-card>
<el-table :data="gridData1" :summary-method="getSummaries2" border highlight-current-row size="mini" show-summary @row-click="searchContactDetail">
<el-table-column min-width="120" align="center" label="合同编号">
<template slot-scope="scope">
{{ scope.row.采购合同编号 ? scope.row.采购合同编号 : scope.row.离线合同编号 }}
</template>
</el-table-column>
<el-table-column width="120" align="center" label="合同额(元)" prop="到货金额">
<el-table-column width="110" align="center" label="合同额(元)" prop="已付金额">
<template slot-scope="scope">
{{ parseFloat(scope.row.合同总金额).toFixed(2) }}
</template>
</el-table-column>
<el-table-column width="120" align="center" label="到货金额(元)" prop="到货金额">
<el-table-column width="110" align="center" label="到货金额(元)" prop="已付金额">
<template slot-scope="scope">
{{ parseFloat(scope.row.到货金额).toFixed(2) }}
</template>
</el-table-column>
<el-table-column width="120" align="center" label="已付金额(元)" prop="已付金额">
<el-table-column width="105" align="center" label="已付金额(元)" prop="已付金额">
<template slot-scope="scope">
{{ parseFloat(scope.row.已付金额).toFixed(2) }}
</template>
</el-table-column>
<el-table-column width="120" align="center" label="请款金额(元)" prop="请款金额">
<el-table-column width="105" align="center" label="请款金额(元)" prop="请款金额">
<template slot-scope="scope">
{{ parseFloat(scope.row.请款金额).toFixed(2) }}
</template>
</el-table-column>
</el-table>
</el-dialog>
</el-card>
</el-col>
<el-col :span="14">
<el-card>
<el-table :data="contractDetail2" :summary-method="getSummaries" border height="500px" size="mini" stripe show-summary>
<el-table-column label="物料名称" align="center" min-width="150">
<template slot-scope="scope">
{{ scope.row.物料名称 ? scope.row.物料名称 : scope.row.零件名称 }}
</template>
</el-table-column>
<el-table-column label="物料规格" align="center" min-width="260">
<template slot-scope="scope">
{{ scope.row.物料规格 ? scope.row.物料规格 : scope.row.规格 }}
</template>
</el-table-column>
<el-table-column label="物料型号" align="center" width="150">
<template slot-scope="scope">
{{ scope.row.物料型号 ? scope.row.物料型号 : scope.row.零件图号 }}
</template>
</el-table-column>
<el-table-column label="数量" align="center" width="70">
<template slot-scope="scope">
{{ scope.row.数量 }}
</template>
</el-table-column>
<el-table-column label="到货数量" align="center" width="80">
<template slot-scope="scope">
{{ scope.row.合同类型 === 1 ? scope.row.已到货数量 : scope.row.到货数量 }}
</template>
</el-table-column>
<el-table-column label="合计(元)" align="center" min-width="100" prop="合计">
<template slot-scope="scope">
{{ (parseFloat(scope.row.单价||0) * parseInt(scope.row.数量||0)).toFixed(2) }}
</template>
</el-table-column>
<el-table-column label="单价(元)" align="center" min-width="100" prop="单价">
<template slot-scope="scope">
{{ parseFloat(scope.row.单价||0).toFixed(2) }}
</template>
</el-table-column>
<el-table-column label="交货期要求" align="center" min-width="100" prop="交货期要求">
<template slot-scope="scope">
{{ scope.row.合同类型 === 1 ? scope.row.交货期.split(' ')[0] === '1900-01-01' ? '-' : scope.row.交货期.split(' ')[0] : scope.row.交货期要求 }}
</template>
</el-table-column>
<el-table-column label="备注" align="center" min-width="150" prop="备注">
<template slot-scope="scope">
{{ scope.row.备注 }}
</template>
</el-table-column>
</el-table>
</el-card>
</el-col>
</el-row>
</div>
</template>
<script>
import { initBuyer, searchTable1, searchTable2, searchSupplier } from '@/api/ManufacturingCenter/RequestApprovalQuery'
import { initApproval, execApproval, initApprovalOffline, searchRequsetFundDetail1, searchRequsetFundDetail2, execApprovalOffline, searchContactDetail, searchMateriel } from '@/api/PurchasingCenter/FundApproval'
import { mapGetters } from 'vuex'
export default {
name: '', // 出纳付款
data() {
return {
radio: '1',
billNames: '',
supplier: [],
supplierValue: '',
person: [],
personValue: '',
dateRange: '',
total1: 0,
pageCurrent1: 1,
pageSize1: 50,
contractDetail1: '',
contractDetail2: [],
tableData1: [],
loading1: false,
dialogFormVisible: false,
gridData1: []
pageSize1: 10,
pageCurrent1: 1,
total1: 0,
tableData2: [],
pageSize2: 10,
pageCurrent2: 1,
total2: 0,
gridData1: [],
gridData2: []
}
},
computed: {
@@ -164,82 +162,230 @@ export default {
},
created() {
this.fetchData()
this.searchTable1()
this.searchSupplier()
},
methods: {
searchSupplier() {
this.supplier = []
searchSupplier().then(response => {
for (let i = 0; i < response.data.length; i++) {
this.supplier.push({
label: response.data[i].供应商名称,
value: response.data[i].供应商流水号
})
getSummaries2(param) { // 合计
const { columns, data } = param
const sums = []
columns.forEach((column, index) => {
if (index === 0) {
sums[index] = '总价'
return
} else if (index === 2 || index === 3) {
const values = data.map(item => Number(item[column.property]))
if (!values.every(value => isNaN(value))) {
sums[index] = values.reduce((prev, curr) => {
const value = Number(curr)
if (!isNaN(value)) {
return prev + curr
} else {
return prev
}
}, 0)
sums[index] = sums[index].toFixed(2) + ' 元'
} else {
sums[index] = 'N/A'
}
}
})
return sums
},
searchContactDetail(row) {
var check
row.采购合同流水号 ? check = 1 : check = 2
searchContactDetail(check, row.采购合同流水号, row.离线合同流水号).then(response => {
this.contractDetail2 = response.data
})
},
searchOfflineContactDetail(row) { // 查询离线合同明细
searchMateriel(row.离线合同流水号).then(response => {
this.contractDetail2 = response.data
})
},
getSummaries(param) { // 合计
const { columns, data } = param
const sums = []
columns.forEach((column, index) => {
if (index === 0) {
sums[index] = '总价'
} else if (index === 3) {
const values = data.map(item => Number(parseFloat(item['数量'])))
if (!values.every(value => isNaN(value))) {
sums[index] = values.reduce((prev, curr) => {
const value = Number(curr)
if (!isNaN(value)) {
return prev + curr
} else {
return prev
}
}, 0)
sums[index] = sums[index] + ' 件'
} else {
sums[index] = '0'
}
} else if (index === 4) {
for (let i = 0; i < data.length; i++) {
if (!data[i].到货数量) {
data[i].到货数量 = 0
}
if (!data[i].已到货数量) {
data[i].已到货数量 = 0
}
}
const values = data.map(item => Number(parseInt(item['到货数量'])) + Number(parseInt(item['已到货数量'])))
if (!values.every(value => isNaN(value))) {
sums[index] = values.reduce((prev, curr) => {
const value = Number(curr)
if (!isNaN(value)) {
return prev + curr
} else {
return prev
}
}, 0)
sums[index] = sums[index] + ' 件'
} else {
sums[index] = '0'
}
} else if (index === 5) {
const values = data.map(item => Number(parseFloat(item['单价']) * parseInt(item['数量'])))
if (!values.every(value => isNaN(value))) {
sums[index] = values.reduce((prev, curr) => {
const value = Number(curr)
if (!isNaN(value)) {
return prev + curr
} else {
return prev
}
}, 0)
sums[index] = sums[index].toFixed(2) + ' 元'
} else {
sums[index] = 'N/A'
}
}
})
return sums
},
fetchData() {
this.person = []
initBuyer().then(response => {
for (let i = 0; i < response.data.length; i++) {
this.person.push({
label: response.data[i].姓名,
value: response.data[i].人员编号
})
}
})
this.searchTable1()
this.searchTable2()
},
searchTable1() {
this.loading1 = true
var check1, check2, check3
this.supplierValue ? check1 = 1 : check1 = 0
this.dateRange ? check2 = 1 : (check2 = 0, this.dateRange = '')
this.personValue ? check3 = 1 : check3 = 0
searchTable1(this.radio, check1, this.supplierValue, check2, this.dateRange[0], this.dateRange[1], check3, this.personValue, this.pageCurrent1, this.pageSize1).then(response => {
console.log(response.data)
this.loading1 = false
initApproval(this.pageCurrent1, this.pageSize1, 2).then(response => {
this.tableData1 = response.data.rows
this.total1 = response.data.total
})
},
exportTable() {
var check1, check2, check3
this.supplierValue ? check1 = 1 : check1 = 0
this.dateRange ? check2 = 1 : (check2 = 0, this.dateRange = '')
this.personValue ? check3 = 1 : check3 = 0
var param = []
param[0] = ['查询全部', this.radio]
param[1] = ['供应商流水号_check', check1]
param[2] = ['供应商流水号', this.supplierValue]
param[3] = ['时间段_check', check2]
if (check2 === 0) {
param[4] = ['开始时间', '']
param[5] = ['结束时间', '']
} else {
param[4] = ['开始时间', this.dateRange[0]]
param[5] = ['结束时间', this.dateRange[1]]
}
param[6] = ['人员编号_check', check3]
param[7] = ['人员编号', this.personValue]
var Data = this.CreateData('2001', '报表_采购管理_情况审核查询_查询数据', param)
this.exportExcel_NPOI(Data)
},
searchTable2(row) {
this.gridData1 = []
searchTable2(row.采购合同请款流水号).then(response => {
this.gridData1 = response.data
this.dialogFormVisible = true
})
},
handleSizeChange1(val) {
this.pageCurrent1 = 1
this.pageSize1 = val
this.pageCurrent1 = 1
this.searchTable1()
},
handleCurrentChange1(val) {
this.pageCurrent1 = val
this.searchTable1()
},
searchTable2() {
initApprovalOffline(this.pageCurrent2, this.pageSize2, 2).then(response => {
console.log(response.data.rows)
this.tableData2 = response.data.rows
this.total2 = response.data.total
})
},
handleSizeChange2(val) {
this.pageSize2 = val
this.pageCurrent2 = 1
this.searchTable2()
},
handleCurrentChange2(val) {
this.pageCurrent2 = val
this.searchTable2()
},
searchTable01(row) { // 查看详情(请款信息包含的合同)
this.gridData1 = []
this.contractDetail2 = []
searchRequsetFundDetail1(row.采购合同请款流水号).then(response => {
this.gridData1 = response.data
})
},
searchTable02(row) { // 查看详情(请款信息包含的合同)
searchRequsetFundDetail2(row.离线合同请款流水号).then(response => {
this.gridData2 = response.data
})
},
yesApproval(row) { // 通过付款
this.$confirm('确定付款通过?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
execApproval(row.采购合同请款流水号, 1, '通过', this.id, 2).then(response => {
if (response.data[0].result === '1') {
this.$message.success('执行成功')
// 记录付款金额及时间
this.searchTable1()
} else { this.$message.error('执行失败') }
})
}).catch(() => {
this.$message({
type: 'info',
message: '取消操作'
})
})
},
noApproval(row) { // 不通过付款
this.$prompt('请输入不通过原因', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消'
}).then(({ value }) => {
execApproval(row.采购合同请款流水号, 2, value, this.id, 2).then(response => {
if (response.data[0].result === '1') {
this.$message.success('执行成功')
this.searchTable1()
} else { this.$message.error('执行失败') }
})
}).catch(() => {
this.$message({
type: 'info',
message: '取消操作'
})
})
},
yesApprovalOffline(row) { // 通过审核
this.$confirm('确定审核通过?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
execApprovalOffline(row.离线合同请款流水号, 1, '通过', this.id, 2).then(response => {
if (response.data[0].result === '1') {
this.$message.success('执行成功')
this.searchTable2()
} else { this.$message.error('执行失败') }
})
}).catch(() => {
this.$message({
type: 'info',
message: '取消操作'
})
})
},
noApprovalOffline(row) { // 不通过审核
this.$prompt('请输入不通过原因', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消'
}).then(({ value }) => {
execApprovalOffline(row.离线合同请款流水号, 2, value, this.id, 2).then(response => {
if (response.data[0].result === '1') {
this.$message.success('执行成功')
this.searchTable2()
} else { this.$message.error('执行失败') }
})
}).catch(() => {
this.$message({
type: 'info',
message: '取消操作'
})
})
}
}
}

View File

@@ -32,7 +32,7 @@
</el-select>
<el-button type="primary" icon="el-icon-search" size="small" plain style="margin-left: 10px" @click="total=0;pageSize = 20;pageCurrent = 1;searchTable()">查询</el-button>
<!--<el-button type="primary" icon="el-icon-search" size="small" plain style="margin-left: 10px" @click="total=0;pageSize = 20;pageCurrent = 1;loginsession()">session</el-button>-->
<el-button type="distribution" icon="el-icon-top" size="small" plain style="margin-left: 10px" @click="submit()">提交补投</el-button>
<el-button :disabled="handleEdit_disable || procedureGroup.length === 0" type="distribution" icon="el-icon-top" size="small" plain style="margin-left: 10px" @click="submit()">提交补投</el-button>
</el-row>
</el-card>
</div>
@@ -42,7 +42,6 @@
v-loading="loading"
ref="multipleTable"
:data="tableData"
:row-class-name="tableRowClassName"
height="590"
style="width: 1390px; margin: 3px 0"
size="mini"
@@ -50,7 +49,12 @@
highlight-current-row
element-loading-text="拼命加载中"
@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" width="80px">
<template slot-scope="scope">
{{ scope.row.进程 }}
</template>
</el-table-column>
<el-table-column label="机床图号" prop="机床图号" align="center" width="140px" show-overflow-tooltip>
<template slot-scope="scope">
{{ scope.row.机床图号 }}
@@ -84,7 +88,7 @@
</el-table-column>
<el-table-column label="加工数" align="center">
<template slot-scope="scope">
{{ scope.row.批次数量 }}
{{ scope.row.投产数量 }}
</template>
</el-table-column>
<el-table-column label="质检数量" align="center">
@@ -122,6 +126,11 @@
{{ scope.row.报废时间 ? scope.row.报废时间.split(' ')[0] : '' }}
</template>
</el-table-column>
<el-table-column label="补投数" align="center" width="90px">
<template slot-scope="scope">
{{ scope.row.补投数量 }}
</template>
</el-table-column>
<el-table-column label="补投时间" align="center" width="90">
<template slot-scope="scope">
{{ scope.row.补投时间 ? scope.row.补投时间.split(' ')[0] : '' }}
@@ -214,9 +223,6 @@ export default {
}
})
},
machineChange() {
this.searchTable()
},
exportTable() {
let check7, check8
if (this.partName !== '' && this.partName !== null) {
@@ -293,14 +299,11 @@ export default {
})
})
},
tableRowClassName({ row }) {
if (row.是否加急 === '1') {
return 'UrgentItem'
}
selectable(row) {
return row.报废时间 === null
},
handleSelectionChange(val) {
this.procedureGroup = val
console.log(val, 123)
},
// 分页
handleSizeChange(val) {

View File

@@ -38,9 +38,10 @@
{{ scope.row.备注 }}
</template>
</el-table-column>
<el-table-column label="操作" align="center" width="70px" fixed="right">
<el-table-column label="操作" align="center" width="100px" fixed="right">
<template slot-scope="scope">
<el-button size="mini" type="text" plain class="el-icon-edit" @click="handleChange1(scope.$index, scope.row, 'form');param = 1"/>
<el-button size="mini" type="text" plain class="el-icon-delete" @click="handleDelete(scope.$index, scope.row, 'form')"/>
</template>
</el-table-column>
</el-table>

View File

@@ -109,9 +109,9 @@
<el-input v-positive="'float'" v-model="scope.row.加工价格_成交" class="editWorkTime" type="number" style="text-align: right" size="small" @change="saveAct(scope.row)" @blur="filterNuber(scope.row.加工价格_成交, scope.$index, '加工价格_成交')"/>
</template>
</el-table-column>
<el-table-column label="机加工开始时间" align="center" width="150px">
<el-table-column label="到货日期" align="center" width="150px">
<template slot-scope="scope">
{{ scope.row.机加工开始时间 }}
{{ scope.row.到货日期 }}
</template>
</el-table-column>
<el-table-column label="操作" align="center" width="80px">
@@ -139,6 +139,16 @@
placeholder="下达任务日期"
value-format="yyyy-MM-dd"/>
</el-form-item>
<el-form-item label="到货日期" prop="到货日期" style="margin-left: 70px">
<el-date-picker
v-model="form.到货日期"
type="date"
size="small"
style="width:200px"
default-value
placeholder="到货日期"
value-format="yyyy-MM-dd"/>
</el-form-item>
<el-form-item label="外协厂家" prop="外协厂家" style="margin-left: 70px">
<el-select v-model="form.外协厂家" placeholder="选择外协厂家" filterable clearable size="small" style="width:200px">
<el-option
@@ -230,6 +240,7 @@ export default {
form: {
表单号: '',
下达任务日期: '',
到货日期: '',
外协厂家: '',
运费: null
},
@@ -372,7 +383,7 @@ export default {
this.List3.push({
外协加工任务单明细流水号: response.data[i].外协加工任务单明细流水号,
加工价格_成交: response.data[i].加工价格_成交.toFixed(2),
机加工开始时间: response.data[i].机加工开始时间 ? response.data[i].机加工开始时间.split(' ')[0] : '',
到货日期: response.data[i].到货日期,
零件图号: response.data[i].零件图号,
零件名称: response.data[i].零件名称,
批次数量: response.data[i].批次数量,
@@ -455,7 +466,7 @@ export default {
this.$message.error('请输入数字')
} else {
this.handleAdd_disable = true
addTable(this.form.表单号, this.id, this.form.外协厂家, this.form.下达任务日期, this.form.运费).then(response => {
addTable(this.form.表单号, this.id, this.form.外协厂家, this.form.下达任务日期, this.form.到货日期, this.form.运费).then(response => {
if (response.data[0].result === '1') {
this.$notify({
title: '成功',
@@ -476,7 +487,7 @@ export default {
// 提交编辑
submitEdit() {
this.handleAdd_disable = true
editData(this.Number, this.form.外协厂家, this.form.运费, this.Explain).then(response => {
editData(this.Number, this.form.外协厂家, this.form.运费, this.Explain, this.form.到货日期).then(response => {
if (response.data[0].result === '1') {
this.$message.success('编辑成功')
this.dialogFormVisible = false

View File

@@ -35,11 +35,7 @@
<el-card>
<el-button :disabled="loading" type="warning" size="mini" icon="el-icon-arrow-down" style="margin-left:10px" plain @click="getSpareParts">收货</el-button>
<el-table v-loading="loading" :data="List3" border size="mini" height="595" style="width: 100%" @selection-change="handleSelectionChange">
<el-table-column
:selectable="selectable"
type="selection"
align="center"
width="55"/>
<el-table-column :selectable="selectable" type="selection" align="center" width="55"/>
<el-table-column label="收货状态" width="100" align="center">
<template slot-scope="scope">
<el-tag v-if="scope.row.到货状态===1" type="success" size="small" style="margin: 0px">已收货</el-tag>
@@ -61,6 +57,11 @@
{{ scope.row.批次数量 }}
</template>
</el-table-column>
<el-table-column label="计划到货日期" align="center" >
<template slot-scope="scope">
{{ scope.row.到货日期 }}
</template>
</el-table-column>
</el-table>
</el-card>
</el-col>

View File

@@ -2,7 +2,7 @@
<div class="app-container">
<el-card>
<!--<h3 style="margin-top: 0">采购合同</h3>-->
<el-table v-loading="" :data="tableData1" border stripe style="width: 100%;height: 150px;" height="300px" size="mini" highlight-current-row @row-click="searchTable01">
<el-table v-loading="" :data="tableData1" border stripe style="width: 100%;height: 150px;" height="200px" size="mini" highlight-current-row @row-click="searchTable01">
<el-table-column label="供应商" align="center" min-width="170">
<template slot-scope="scope">
{{ scope.row.供应商名称 }}
@@ -45,30 +45,38 @@
<!--<h3 style="">合同明细</h3>-->
<el-row>
<el-col :span="10">
<el-card>
<el-table :data="gridData1" :summary-method="getSummaries2" border stripe highlight-current-row size="mini" show-summary @row-click="searchContactDetail">
<el-table-column min-width="150" align="center" label="合同编号">
<el-table-column width="120" align="center" label="合同编号">
<template slot-scope="scope">
{{ scope.row.采购合同编号 ? scope.row.采购合同编号 : scope.row.离线合同编号 }}
</template>
</el-table-column>
<el-table-column width="120" align="center" label="到货金额(元)" prop="到货金额">
<el-table-column width="110" align="center" label="合同总额(元)" prop="到货金额">
<template slot-scope="scope">
{{ parseFloat(scope.row.合同总金额).toFixed(2) }}
</template>
</el-table-column>
<el-table-column width="110" align="center" label="到货金额(元)" prop="到货金额">
<template slot-scope="scope">
{{ parseFloat(scope.row.到货金额).toFixed(2) }}
</template>
</el-table-column>
<el-table-column width="120" align="center" label="已付金额(元)" prop="已付金额">
<el-table-column width="105" align="center" label="已付金额(元)" prop="已付金额">
<template slot-scope="scope">
{{ parseFloat(scope.row.已付金额).toFixed(2) }}
</template>
</el-table-column>
<el-table-column width="120" align="center" label="请款金额(元)" prop="请款金额">
<el-table-column width="105" align="center" label="请款金额(元)" prop="请款金额">
<template slot-scope="scope">
{{ parseFloat(scope.row.请款金额).toFixed(2) }}
</template>
</el-table-column>
</el-table>
</el-card>
</el-col>
<el-col :span="14">
<el-card>
<el-table :data="contractDetail2" :summary-method="getSummaries" border height="500px" size="mini" stripe show-summary>
<el-table-column label="物料名称" align="center" min-width="150">
<template slot-scope="scope">
@@ -95,7 +103,7 @@
{{ scope.row.合同类型 === 1 ? scope.row.已到货数量 : scope.row.到货数量 }}
</template>
</el-table-column>
<el-table-column label="计(元)" align="center" min-width="100" prop="合计">
<el-table-column label="计(元)" align="center" min-width="100" prop="合计">
<template slot-scope="scope">
{{ (parseFloat(scope.row.单价||0) * parseInt(scope.row.数量||0)).toFixed(2) }}
</template>
@@ -116,6 +124,7 @@
</template>
</el-table-column>
</el-table>
</el-card>
</el-col>
</el-row>
@@ -239,7 +248,7 @@ export default {
const sums = []
columns.forEach((column, index) => {
if (index === 0) {
sums[index] = '总价'
sums[index] = '合计'
} else if (index === 3) {
const values = data.map(item => Number(parseFloat(item['数量'])))
if (!values.every(value => isNaN(value))) {
@@ -278,6 +287,21 @@ export default {
} else {
sums[index] = '0'
}
} else if (index === 5) {
const values = data.map(item => Number(parseFloat(item['数量'])) * Number(parseFloat(item['单价'])))
if (!values.every(value => isNaN(value))) {
sums[index] = values.reduce((prev, curr) => {
const value = Number(curr)
if (!isNaN(value)) {
return prev + curr
} else {
return prev
}
}, 0)
sums[index] = sums[index] + ' 元'
} else {
sums[index] = '0'
}
}
})
return sums
@@ -412,7 +436,7 @@ export default {
<style scoped>
.el-card{
margin-bottom: 15px;
/*margin-bottom: 15px;*/
}
.el-select{
width:200px

View File

@@ -1,73 +1,73 @@
<template>
<div class="app-container">
<el-card>
<span>合同号:</span>
<el-select v-model="contractNumValue" placeholder="合同号" size="small" filterable clearable>
<el-option
v-for="item in contractNum"
:key="item.value"
:label="item.label"
:value="item.value">
<div style="float: left">{{ item.label }}</div>
<div style="float: right; color: #8492a6; font-size: 13px">{{ item.name }}</div>
</el-option>
</el-select>
<span>采购员:</span>
<el-select v-model="personValue" placeholder="采购员" clearable size="small" style="width: 100px">
<el-option
v-for="item in person"
:key="item.value"
:label="item.label"
:value="item.value"/>
</el-select>
<span>供应商:</span>
<el-input v-model="supplierName" placeholder="供应商" size="small" clearable style="width:180px"/>
<el-button type="primary" plain size="small" icon="el-icon-search" style="margin-left:10px" @click="total1=0;pageCurrent1=1;pageSize1=10;searchTable1()">查询</el-button>
</el-card>
<!-- <el-card>-->
<!-- <span>合同号:</span>-->
<!-- <el-select v-model="contractNumValue" placeholder="合同号" size="small" filterable clearable>-->
<!-- <el-option-->
<!-- v-for="item in contractNum"-->
<!-- :key="item.value"-->
<!-- :label="item.label"-->
<!-- :value="item.value">-->
<!-- <div style="float: left">{{ item.label }}</div>-->
<!-- <div style="float: right; color: #8492a6; font-size: 13px">{{ item.name }}</div>-->
<!-- </el-option>-->
<!-- </el-select>-->
<!-- <span>采购员:</span>-->
<!-- <el-select v-model="personValue" placeholder="采购员" clearable size="small" style="width: 100px">-->
<!-- <el-option-->
<!-- v-for="item in person"-->
<!-- :key="item.value"-->
<!-- :label="item.label"-->
<!-- :value="item.value"/>-->
<!-- </el-select>-->
<!-- <span>供应商:</span>-->
<!-- <el-input v-model="supplierName" placeholder="供应商" size="small" clearable style="width:180px"/>-->
<!-- <el-button type="primary" plain size="small" icon="el-icon-search" style="margin-left:10px" @click="total1=0;pageCurrent1=1;pageSize1=10;searchTable1()">查询</el-button>-->
<!-- </el-card>-->
<el-card>
<el-table v-loading="loading1" :data="tableData1" size="mini" stripe border style="width: 100%;max-height: 450px;" height="450px" highlight-current-row @row-click="searchTable2">
<el-table-column label="展开" align="center" type="expand">
<template slot-scope="scope">
<el-form id="table" label-position="left" inline class="demo-table-expand">
<el-row>
<el-form-item label="交货日期">
{{ scope.row.交货日期 }}
</el-form-item>
</el-row>
<el-row>
<el-form-item label="支付日期">
{{ scope.row.支付日期 }}
</el-form-item>
</el-row>
<el-row>
<el-form-item label="支付方式">
{{ scope.row.支付方式 }}
</el-form-item>
</el-row>
<el-row>
<el-form-item label="开票信息">
{{ scope.row.开票信息 }}
</el-form-item>
</el-row>
<el-row>
<el-form-item label="其他说明">
{{ scope.row.其他说明 }}
</el-form-item>
</el-row>
</el-form>
</template>
</el-table-column>
<el-table v-loading="loading1" :data="tableData1" size="mini" stripe border style="width: 60%" height="210px" highlight-current-row @row-click="searchTable2">
<!-- <el-table-column label="展开" align="center" type="expand">-->
<!-- <template slot-scope="scope">-->
<!-- <el-form id="table" label-position="left" inline class="demo-table-expand">-->
<!-- <el-row>-->
<!-- <el-form-item label="交货日期">-->
<!-- {{ scope.row.交货日期 }}-->
<!-- </el-form-item>-->
<!-- </el-row>-->
<!-- <el-row>-->
<!-- <el-form-item label="支付日期">-->
<!-- {{ scope.row.支付日期 }}-->
<!-- </el-form-item>-->
<!-- </el-row>-->
<!-- <el-row>-->
<!-- <el-form-item label="支付方式">-->
<!-- {{ scope.row.支付方式 }}-->
<!-- </el-form-item>-->
<!-- </el-row>-->
<!-- <el-row>-->
<!-- <el-form-item label="开票信息">-->
<!-- {{ scope.row.开票信息 }}-->
<!-- </el-form-item>-->
<!-- </el-row>-->
<!-- <el-row>-->
<!-- <el-form-item label="其他说明">-->
<!-- {{ scope.row.其他说明 }}-->
<!-- </el-form-item>-->
<!-- </el-row>-->
<!-- </el-form>-->
<!-- </template>-->
<!-- </el-table-column>-->
<el-table-column label="采购合同号" align="center" min-width="130">
<template slot-scope="scope">
{{ scope.row.采购合同编号 }}
</template>
</el-table-column>
<el-table-column label="采购合同名称" align="center" min-width="130">
<template slot-scope="scope">
{{ scope.row.采购合同名称 }}
</template>
</el-table-column>
<!-- <el-table-column label="采购合同名称" align="center" min-width="130">-->
<!-- <template slot-scope="scope">-->
<!-- {{ scope.row.采购合同名称 }}-->
<!-- </template>-->
<!-- </el-table-column>-->
<el-table-column label="供应商" align="center" min-width="150">
<template slot-scope="scope">
{{ scope.row.供应商名称 }}
@@ -83,6 +83,11 @@
{{ scope.row.合同总额 }}
</template>
</el-table-column>
<el-table-column label="提交时间" align="center" min-width="60">
<template slot-scope="scope">
{{ scope.row.操作时间 ? scope.row.操作时间.split(' ')[0] : '-' }}
</template>
</el-table-column>
<el-table-column label="操作" align="center" min-width="100" fixed="right">
<template slot-scope="scope">
<el-button type="text" size="mini" icon="el-icon-edit-outline" @click="Open(scope.row)">审批</el-button>
@@ -115,7 +120,7 @@
:value="item.value"/>
</el-select>
</el-form-item>
<el-form-item v-show="form2.审批是否通过!==2" label="未通过原因" prop="未通过原因">
<el-form-item v-show="form2.审批是否通过===2" label="未通过原因" prop="未通过原因">
<el-input v-model="form2.未通过原因" :disabled="form2.审批是否通过!==2" size="small"/>
</el-form-item>
</el-form>

View File

@@ -349,6 +349,7 @@
<script>
import { sleep } from '../../../utils/tool'
import { unSpecificationQuery1, updateNum, specificationQuery1, unSpecificationQueryWB1, specificationQueryWB1, deleteBasicParts, deleteBWParts, getMaterial, getMaterialWB, searchMaterialWB, updateRow, updateRowWB, transferMX1, update, searchOldParts, getMachineNames, transferWG1, allDelete, update1, searchMaterial1 } from '../../../api/TechnologyCenter/ImportParts'
import { mapGetters } from 'vuex'
export default {
name: 'SpecificationData',
props: {
@@ -443,7 +444,13 @@ export default {
return this.materials[i].label
}
}
}
},
...mapGetters([
'sidebar',
'avatar',
'name',
'id' // 人员编号
])
},
watch: {
machineNames(val) {
@@ -482,6 +489,7 @@ export default {
}
},
async fetchData() {
console.log(this.$store.state.user.id, 12232434)
this.pageCurrent = 1
this.tableData10 = []
try {
@@ -728,7 +736,8 @@ export default {
for (let i = 0; i < this.tableDataAll.length; i++) {
const data = this.tableDataAll[i]
const total = parseInt(data.备件数量) + parseInt(data.装机数量) * parseInt(data.部件数量)
const resp = await transferMX1(data.图号或者型号, data.名称, total, data.备注, data.标记, data.设计者编号, data.组件流水号, data.材料流水号, data.规格, 1, data.是否传递, data.序号, data.分类码, data.整改类型, data.id, data.前id, data.前图号或者型号, this.$store.state.user.id)
const resp = await transferMX1(data.图号或者型号, data.名称, total, data.备注, data.标记, data.设计者编号, data.组件流水号, data.材料流水号, data.规格, 1, data.是否传递, data.序号, data.分类码, data.整改类型, data.id, data.前id, data.前图号或者型号, this.id)
await sleep(10)
if (resp.data[0].result === '0') {
this.err++
@@ -745,7 +754,7 @@ export default {
dataType = 1
}
console.log(data)
const resp = await transferWG1(data.组件流水号, data.物料流水号, total, data.备注, data.标记, data.设计者编号, data.是否传递, dataType, data.序号, data.id, data.备件数量, data.分类码, data.整改类型, this.$store.state.user.id)
const resp = await transferWG1(data.组件流水号, data.物料流水号, total, data.备注, data.标记, data.设计者编号, data.是否传递, dataType, data.序号, data.id, data.备件数量, data.分类码, data.整改类型, this.id)
await sleep(10)
if (resp.data[0].result === '0') {
this.err++

View File

@@ -565,11 +565,6 @@ export default {
purchasingOrder: '',
ArrivalOrderNumber: '',
ArrivalOrderMXNumber: '',
ArrivalDetailSerialNumber: '',
ArrivalOrderGroup: [],
ArrivalOrderMXNumberGroup: [],
numberGroup: [],
LxnumberGroup: [],
supplierName0: '',
planType: 0,
planTypes: [
@@ -897,12 +892,9 @@ export default {
sums[index] = 'N/A'
}
} else if (index === 7) {
sums[index] = '总金额:'
return
} else if (index === 8) {
const values = data.map(item => Number(item['金额']))
if (!values.every(value => isNaN(value))) {
sums[index] = values.reduce((prev, curr) => {
sums[index] = '总金额:' + values.reduce((prev, curr) => {
const value = Number(curr)
if (!isNaN(value)) {
return (parseInt((Number(prev) + Number(curr)) * 100) / 100).toFixed(2)
@@ -1041,34 +1033,12 @@ 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(() => {
console.log(row.到货单流水号, this.ArrivalOrderGroup, this.ArrivalOrderMXNumberGroup, this.numberGroup, this.LxnumberGroup, 2222)
deletePurchaseOrder(row.到货单流水号, this.ArrivalOrderGroup, this.ArrivalOrderMXNumberGroup, this.numberGroup, this.LxnumberGroup).then(response => {
console.log(response, 123)
deletePurchaseOrder(row.到货单流水号).then(response => {
if (response.data[0].result === '1') {
this.$message.success('删除成功')
this.searchTable4()
@@ -1128,14 +1098,12 @@ export default {
this.到货重量组 = []
this.到货金额组 = []
this.arrest.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') {
@@ -1205,28 +1173,17 @@ 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.到货单明细流水号, this.ArrivalOrderMXNumberGroup, this.numberGroup, this.LxnumberGroup).then(response => {
deleteArrivalMX(row.到货单明细流水号).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(() => {
@@ -1245,6 +1202,7 @@ export default {
if (response.data.length !== 0) {
this.中间变量 = response.data[0].单件重量
this.未绑定数量 = response.data[0].未绑定数量
console.log(this.未绑定数量, 111)
} else {
this.未绑定数量 = row.数量
}
@@ -1287,14 +1245,12 @@ export default {
this.到货重量组 = []
this.到货金额组 = []
this.arrest1.map(v => {
if (v.到货数量 > 0) {
this.工艺计划流水号组.push(v.工艺计划流水号)
this.采购计划明细流水号组.push(v.采购计划明细流水号)
this.离线采购计划明细流水号组.push(v.离线采购计划明细流水号)
this.本次到货数量组.push(v.未到货数量)
this.到货重量组.push(v.到货重量)
this.到货金额组.push(v.到货重量 * this.单价)
}
})
addMateriel(this.ArrivalOrderMXNumber, this.工艺计划流水号组, this.采购计划明细流水号组, this.本次到货数量组, this.离线采购计划明细流水号组, this.到货重量组, this.到货金额组, this.userId).then(response => {
if (response.data[0].result === '1') {

View File

@@ -505,6 +505,16 @@ export default {
if (response.data[0].result === '1') {
this.$message.success('增加成功')
this.dialogVisible1 = false
this.gongyingshangValue = ''
this.gongyingshang = []
getGongyingshang().then(response => {
for (let i = 0; i < response.data.length; i++) {
this.gongyingshang.push({
label: response.data[i].供应商名称,
value: response.data[i].供应商
})
}
})
this.searchTable1()
} else {
this.addTable1_disable = false

View File

@@ -0,0 +1,297 @@
<template>
<div>
<div style="width: 1900px;overflow:auto">
<div style="white-space: nowrap">
<el-card>
<el-row>
<el-select v-model="machineNameValue" placeholder="机床图号" style="width: 150px" size="small" filterable clearable>
<el-option
v-for="item in machineName"
:key="item.value"
:label="item.label"
:value="item.value"/>
</el-select>
<el-input v-model="partName" placeholder="零件图号名称" size="small" clearable style="width:150px"/>
<el-date-picker
v-model="outTime"
type="daterange"
size="small"
format="yyyy-MM-dd"
value-format="yyyy-MM-dd"
range-separator="~"
style="width:240px;margin-left: 10px"
start-placeholder="开始日期"
end-placeholder="结束日期"/>
<el-button type="primary" icon="el-icon-search" size="small" plain style="margin-left: 10px" @click="total=0;pageSize = 20;pageCurrent = 1;searchTable()">查询</el-button>
<!--<el-button type="primary" icon="el-icon-search" size="small" plain style="margin-left: 10px" @click="total=0;pageSize = 20;pageCurrent = 1;loginsession()">session</el-button>-->
</el-row>
</el-card>
</div>
</div>
<el-card>
<el-table
v-loading="loading"
:data="tableData"
:row-class-name="tableRowClassName"
height="590"
style="width: 1390px; margin: 3px 0"
size="mini"
border
highlight-current-row
element-loading-text="拼命加载中">
<el-table-column label="机床图号" prop="机床图号" align="center" width="140px" show-overflow-tooltip>
<template slot-scope="scope">
{{ scope.row.机床图号 }}
</template>
</el-table-column>
<el-table-column label="机床名称" prop="机床名称" align="center" width="200px" show-overflow-tooltip>
<template slot-scope="scope">
{{ scope.row.机床名称 }}
</template>
</el-table-column>
<el-table-column label="组号" prop="组号" align="center" width="100px" show-overflow-tooltip>
<template slot-scope="scope">
{{ scope.row.组号 }}
</template>
</el-table-column>
<el-table-column label="零件图号" prop="零件图号" align="center" width="173px" show-overflow-tooltip>
<!--<el-table-column label="零件图号" prop="零件图号" align="center" width="180" show-overflow-tooltip>-->
<template slot-scope="scope">
{{ scope.row.零件图号 }}
</template>
</el-table-column>
<el-table-column label="零件名称" align="center" width="129" show-overflow-tooltip>
<template slot-scope="scope">
{{ scope.row.零件名称 }}
</template>
</el-table-column>
<el-table-column label="投产数" align="center" width="70px">
<template slot-scope="scope">
{{ scope.row.投产数量 }}
</template>
</el-table-column>
<el-table-column label="报废数" align="center" width="70px">
<template slot-scope="scope">
{{ scope.row.报废数量 }}
</template>
</el-table-column>
<el-table-column label="补投数" align="center" width="70px">
<template slot-scope="scope">
{{ scope.row.补投数量 }}
</template>
</el-table-column>
<el-table-column label="报废日期" align="center" width="100">
<template slot-scope="scope">
{{ scope.row.报废时间 ? scope.row.报废时间.split(' ')[0] : '' }}
</template>
</el-table-column>
<el-table-column label="报废人" align="center" width="100">
<template slot-scope="scope">
{{ scope.row.姓名 }}
</template>
</el-table-column>
<el-table-column label="补投日期" align="center" width="100">
<template slot-scope="scope">
{{ scope.row.补投时间 ? scope.row.补投时间.split(' ')[0] : '' }}
</template>
</el-table-column>
<el-table-column label="操作" align="center" width="90px" fixed="right">
<template slot-scope="scope">
<el-tooltip :open-delay="1000" effect="dark" content="补投报废零件" placement="top">
<div style="display: inline-block">
<el-button :disabled="scope.row.报废数量-scope.row.补投数量===0" type="text" size="mini" @click="Supplementation(scope.row)">补投</el-button>
</div>
</el-tooltip>
</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>
<el-dialog :visible.sync="dialogFormVisible" title="补投" center width="300px">
<el-form ref="form" :model="form" label-position="left" label-width="80px" class="demo-ruleForm">
<el-form-item label="补投数量" prop="补投数量">
<el-input-number v-model="form.补投数量" :min="1" :max="scrapNumber-supplementationNumber" :step="1" size="small" />
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button size="small" @click="dialogFormVisible=false">取消</el-button>
<el-button :disabled="handleEdit_disable" size="small" type="primary" @click="submit()"> </el-button>
</div>
</el-dialog>
</div>
</template>
<script>
import { searchMachine, searchtable, editA } from '@/api/WorkshopProcurement/ScrappedSupplementaryInvestment1'
import { mapGetters } from 'vuex'
export default {
data() {
return {
machineNameValue: '', // 机床图号
machineName: [],
partName: '',
all: false,
loading: false,
handleEdit_disable: false,
dialogFormVisible: false,
form: {
补投数量: ''
},
scrapNumber: '',
supplementationNumber: '',
Data: [],
CutCodeBefore: '', // 工艺计划流水号
tableData: [], // 表格数据
total: 0, // 总条数
pageSize: 30, // 每页显示条数
pageCurrent: 1, // 后台获取页
outTime: '',
order: ''
}
},
computed: {
...mapGetters([
'id',
'token'
])
},
created() {
this.projectChange()
},
methods: {
projectChange() {
this.machineName = []
this.machineNameValue = ''
searchMachine().then(response => {
for (let i = 0; i < response.data.length; i++) {
this.machineName.push({
label: response.data[i].机床图号,
value: response.data[i].机床流水号
})
}
})
},
exportTable() {
let check7, check8
if (this.partName !== '' && this.partName !== null) {
this.partNamecheck = true
} else {
this.partNamecheck = false
}
this.outTime ? check7 = 1 : (check7 = 0, this.outTime = '')
this.all === false ? check8 = 0 : check8 = 1
var param = []
param[0] = ['机床流水号', this.machineNameValue]
param[1] = ['零件图号_check', this.partNamecheck]
param[2] = ['零件图号', this.partName]
param[3] = ['投产时间_check', check7]
if (check7 === 0) {
param[4] = ['开始时间', '']
param[5] = ['结束时间', '']
} else {
param[4] = ['开始时间', this.outTime[0]]
param[5] = ['结束时间', this.outTime[1]]
}
param[6] = ['加急_check', check8]
var Data = this.CreateData('2001', '报表_生产计划查询', param)
this.exportExcel_NPOI(Data)
},
// 查询表格数据
searchTable() {
this.loading = true
let check, check1, check7
this.machineNameValue ? check = 1 : check = 0
this.partName ? check1 = 1 : check1 = 0
this.outTime ? check7 = 1 : (check7 = 0, this.outTime = '')
searchtable(check, this.machineNameValue, check1, this.partName, check7, this.outTime[0], this.outTime[1], this.pageCurrent, this.pageSize).then(response => {
console.log(response.data, 123)
this.tableData = response.data.result
this.loading = false
this.total = parseInt(response.data.output[0].ItemCount)
this.loading = false
})
},
Supplementation(row) {
this.form.补投数量 = Number(row.报废数量) - Number(row.补投数量)
this.scrapNumber = row.报废数量
this.supplementationNumber = row.补投数量
this.CutCodeBefore = row.工艺计划流水号
this.dialogFormVisible = true
},
submit() {
if (this.form.补投数量 > 0) {
if (!this.editB_disable) {
this.handleEdit_disable = true
editA(this.CutCodeBefore, this.form.补投数量, this.id).then(response => {
if (response.data[0].result === '1') {
this.$message.success('补投成功')
this.dialogFormVisible = false
this.searchTable()
this.handleEdit_disable = false
} else {
this.handleEdit_disable = false
this.$message.error('补投失败')
}
})
}
} else {
this.$message.warning('补投数量不能为零')
}
},
tableRowClassName({ row }) {
if (row.是否加急 === '1') {
return 'UrgentItem'
}
},
// 分页
handleSizeChange(val) {
this.pageCurrent = 1
this.pageSize = val
this.searchTable()
},
handleCurrentChange(val) {
this.pageCurrent = val
this.searchTable()
}
}
}
</script>
<style scoped>
.el-form--label-left >>> .el-form-item__label {
text-align: right;
}
>>>.el-dialog--center .el-dialog__body {
text-align: initial;
padding: 20px 30px 20px
}
>>>.el-dialog__header {
padding: 20px 20px 0px;
}
>>>.el-dialog__footer {
padding: 0px 20px 20px;
/*text-align: right;*/
-webkit-box-sizing: border-box;
box-sizing: border-box;
}
>>>.el-form-item {
margin-bottom: 13px;
}
</style>
<style>
.el-table .UrgentItem{
background: #FF9797;
}
</style>

View File

@@ -69,8 +69,9 @@ export default {
url: '',
method: 'post',
data: {
type: '3',
name: `select * from 基础表_角色模块信息 inner join 基础表_模块信息 on 基础表_角色模块信息.id = 基础表_模块信息.id where 角色编号= ${this.token} and [path] = '/'`
type: '1',
name: `菜单系统模块_首页信息_查询数据1`,
param: '角色编号=' + this.token
}
}).then(data => {
this.fathers = []
@@ -92,8 +93,9 @@ export default {
url: '',
method: 'post',
data: {
type: '3',
name: `select * from 基础表_角色模块信息 inner join 基础表_模块信息 on 基础表_角色模块信息.id = 基础表_模块信息.id where 角色编号= ${this.token} and [path] <> '/'`
type: '1',
name: `菜单系统模块_首页信息_查询数据2`,
param: '角色编号=' + this.token
}
}).then(data => {
this.sons = []
@@ -113,8 +115,9 @@ export default {
url: '',
method: 'post',
data: {
type: '3',
name: `select * from 基础表_角色模块信息 inner join 基础表_模块信息 on 基础表_角色模块信息.id = 基础表_模块信息.id where 角色编号=${this.token} and 是否通知 = 1`
type: '1',
name: `菜单系统模块_通知信息_查询数据`,
param: '角色编号=' + this.token
}
}).then(data => {
this.sudokus = []