更新
This commit is contained in:
@@ -33,7 +33,7 @@ export function edit(num1) {
|
|||||||
data: {
|
data: {
|
||||||
type: '2',
|
type: '2',
|
||||||
name: '车间生产管理工艺_备料单导出_状态更改',
|
name: '车间生产管理工艺_备料单导出_状态更改',
|
||||||
param: '工艺计划流水号=' + num1
|
param: `工艺计划流水号=${num1}&备料打印=1`
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
@@ -45,7 +45,7 @@ export function edit2(num1) {
|
|||||||
data: {
|
data: {
|
||||||
type: '2',
|
type: '2',
|
||||||
name: '车间生产管理工艺_备料单导出_外购备料',
|
name: '车间生产管理工艺_备料单导出_外购备料',
|
||||||
param: '工艺计划流水号=' + num1
|
param: `工艺计划流水号组=${num1}&是否外购备料=1`
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|||||||
47
src/api/ManufacturingCenter/EquipmentConditionAnalysis.js
Normal file
47
src/api/ManufacturingCenter/EquipmentConditionAnalysis.js
Normal file
@@ -0,0 +1,47 @@
|
|||||||
|
import request from '@/utils/request'
|
||||||
|
|
||||||
|
export function getData(num, num1, pageCurrent, pageSize) {
|
||||||
|
return request({
|
||||||
|
url: '',
|
||||||
|
method: 'post',
|
||||||
|
data: {
|
||||||
|
type: '1',
|
||||||
|
name: '车间生产管理_设备运行情况_查询数据',
|
||||||
|
param: '工位号=' + num + '&日期=' + num1,
|
||||||
|
pagination: pageCurrent + '&' + pageSize
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
export function getData1(num) {
|
||||||
|
return request({
|
||||||
|
url: '',
|
||||||
|
method: 'post',
|
||||||
|
data: {
|
||||||
|
type: '1',
|
||||||
|
name: '车间生产管理_设备运行情况_查询数据_全员',
|
||||||
|
param: '日期=' + num
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
export function getData2(num, num1, num2) {
|
||||||
|
return request({
|
||||||
|
url: '',
|
||||||
|
method: 'post',
|
||||||
|
data: {
|
||||||
|
type: '1',
|
||||||
|
name: '车间生产管理_设备运行情况_查询数据_折线图',
|
||||||
|
param: '工位号=' + num + '&开始时间=' + num1 + '&结束时间=' + num2
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
// 初始化 人员和工位
|
||||||
|
export function getMachine() {
|
||||||
|
return request({
|
||||||
|
url: '',
|
||||||
|
method: 'post',
|
||||||
|
data: {
|
||||||
|
type: '1',
|
||||||
|
name: '车间生产管理工艺_加工顺序调整_查询工位及人员'
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
@@ -122,4 +122,15 @@ export function dele(num, a, b) {
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
// 打回
|
||||||
|
export function edit(num) {
|
||||||
|
return request({
|
||||||
|
url: '',
|
||||||
|
method: 'post',
|
||||||
|
data: {
|
||||||
|
type: '2',
|
||||||
|
name: 'MRP_计划订单_组件零件清单_基本件_打回数据',
|
||||||
|
param: '组件零件基本件流水号=' + num
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|||||||
@@ -98,3 +98,15 @@ export function handlechange2(Number, code) {
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 打回
|
||||||
|
export function edit(num1) {
|
||||||
|
return request({
|
||||||
|
url: '',
|
||||||
|
method: 'post',
|
||||||
|
data: {
|
||||||
|
type: '2',
|
||||||
|
name: '车间生产管理工艺_备料单导出_状态更改',
|
||||||
|
param: `工艺计划流水号=${num1}&备料打印=0`
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|||||||
@@ -85,7 +85,7 @@ export function importBasics(establishment, proofread, review, date, projectName
|
|||||||
data: {
|
data: {
|
||||||
type: '2',
|
type: '2',
|
||||||
name: '组件明细表_基本件_导入数据gj',
|
name: '组件明细表_基本件_导入数据gj',
|
||||||
param: `编制=${establishment}&校对=${proofread}&审核=${review}&日期=${date}&项目=${projectName}&机床=${machineNum}&设备名称=${machineName}&部件名称=${componentName}&部件数量=${componentNum}&组号=${groupNum}&合同编号=${contractNum}&合计页码=${totalNum}&页码=${pageNum}&图号=${drawingNum}&名称=${name}&规格\\=${type}&材料=${material}&备件数量=${spareNum}&装机数量=${useNum}&制造商=${manufacturer}&备注\\=${remarks}&分类码=${classificationCode}`
|
param: `编制=${establishment}&校对=${proofread}&审核=${review}&日期=${date}&项目=${projectName}&机床=${machineNum}&设备名称=${machineName}&部件名称=${componentName}&部件数量=${componentNum}&组号=${groupNum}&合同编号=${contractNum}&合计页码=${totalNum}&页码=${pageNum}&图号=${drawingNum}&名称=${name}&规格\\=${type}&材料=${material}&备件数量=${spareNum}&装机数量=${useNum}&制造商=${manufacturer}&备注\\=${remarks}&分类码=${classificationCode}&导入类型=0=int=output`
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
@@ -96,7 +96,7 @@ export function importTotal(establishment, projectName, machineNum, machineName,
|
|||||||
data: {
|
data: {
|
||||||
type: '2',
|
type: '2',
|
||||||
name: '组件明细表_总图_导入数据gj',
|
name: '组件明细表_总图_导入数据gj',
|
||||||
param: `编制=${establishment}&项目=${projectName}&机床=${machineNum}&设备名称=${machineName}&部件数量=${componentNum}&图号=${drawingNum}&名称=${name}&规格\\=${type}&材料=${material}&装机数量=${useNum}&制造商=${manufacturer}&备注\\=${remarks}`
|
param: `编制=${establishment}&项目=${projectName}&机床=${machineNum}&设备名称=${machineName}&部件数量=${componentNum}&图号=${drawingNum}&名称=${name}&规格\\=${type}&材料=${material}&装机数量=${useNum}&制造商=${manufacturer}&备注\\=${remarks}&导入类型=0=int=output`
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -173,3 +173,15 @@ export function searchSupplier(check1, value1, check2, value2, check3, value3, c
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
// 打回备料
|
||||||
|
export function edit2(num1) {
|
||||||
|
return request({
|
||||||
|
url: '',
|
||||||
|
method: 'post',
|
||||||
|
data: {
|
||||||
|
type: '2',
|
||||||
|
name: '车间生产管理工艺_备料单导出_外购备料',
|
||||||
|
param: `工艺计划流水号组=${num1}&是否外购备料=0`
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|||||||
@@ -19,7 +19,7 @@ export const ServerIP = `http://192.168.1.231:8411/webpage/file/`
|
|||||||
export const uploadFileMachine = `http://192.168.1.231:8411/submit/uploadFileMachine.ashx` // 机床总图 发布时改成0.231
|
export const uploadFileMachine = `http://192.168.1.231:8411/submit/uploadFileMachine.ashx` // 机床总图 发布时改成0.231
|
||||||
export const downloadFileMachine = `http://192.168.1.231:8411/submit/downloadFileMachine.ashx` // 机床总图 发布时改成0.231
|
export const downloadFileMachine = `http://192.168.1.231:8411/submit/downloadFileMachine.ashx` // 机床总图 发布时改成0.231
|
||||||
const service = axios.create({
|
const service = axios.create({
|
||||||
baseURL: `http://localhost:8411/submit/MESCommonBase.ashx`,
|
baseURL: `http://192.168.1.231:8411/submit/MESCommonBase.ashx`,
|
||||||
timeout: 1500000 // 请求超时时间
|
timeout: 1500000 // 请求超时时间
|
||||||
})
|
})
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,350 @@
|
|||||||
|
<template>
|
||||||
|
<div class="app-container">
|
||||||
|
<el-card>
|
||||||
|
<span>工位号:</span>
|
||||||
|
<el-select v-model="MachineValue" filterable size="small" style="width:160px;margin-bottom:10px" placeholder="工位号">
|
||||||
|
<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.value2 }}</div>
|
||||||
|
</el-option>
|
||||||
|
</el-select>
|
||||||
|
<span>日期:</span>
|
||||||
|
<el-date-picker
|
||||||
|
v-model="Time"
|
||||||
|
value-format="yyyy-MM-dd"
|
||||||
|
size="small"
|
||||||
|
style="width: 160px"
|
||||||
|
type="date"
|
||||||
|
placeholder="选择日期"/>
|
||||||
|
<el-button type="success" size="small" icon="el-icon-search" style="margin-left: 15px" @click="pageSize=10; pageCurrent= 1;searchData()">查询</el-button>
|
||||||
|
</el-card>
|
||||||
|
<el-card>
|
||||||
|
<el-table
|
||||||
|
:data="tableDataA"
|
||||||
|
border
|
||||||
|
style="width: 100%;max-height: 450px;margin-top: 10px"
|
||||||
|
height="450px"
|
||||||
|
highlight-current-row
|
||||||
|
size="small">
|
||||||
|
<el-table-column
|
||||||
|
type="index"
|
||||||
|
label="序号"
|
||||||
|
align="center"
|
||||||
|
width="50"/>
|
||||||
|
<el-table-column label="工位号" align="center">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
{{ scope.row.工位号 }}
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="状态" align="center">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
{{ scope.row.状态 }}
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="电流" align="center">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
{{ scope.row.电流 }}
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="开始时间" align="center">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
{{ scope.row.开始时间 }}
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="结束时间" align="center">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
{{ scope.row.结束时间 }}
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="持续时间" align="center">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
{{ scope.row.持续时间 }}
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="日期" align="center">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
{{ scope.row.日期.split(' ')[0] }}
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
</el-table>
|
||||||
|
<div class="block">
|
||||||
|
<el-pagination
|
||||||
|
:current-page="pageCurrent"
|
||||||
|
:page-sizes="[10, 20, 30, 40]"
|
||||||
|
:page-size="pageSize"
|
||||||
|
:total="total"
|
||||||
|
layout="total, sizes, prev, pager, next, jumper"
|
||||||
|
@size-change="handleSizeChange"
|
||||||
|
@current-change="handleCurrentChange"/>
|
||||||
|
</div>
|
||||||
|
</el-card>
|
||||||
|
<el-card style="width: 49.8%; float: left;margin-right: 5px">
|
||||||
|
<div id="myChart1" style="width: 1000px; height: 570px; margin: auto"/>
|
||||||
|
</el-card>
|
||||||
|
<el-card style="width: 49.8%">
|
||||||
|
<div id="myChart2" style="width: 1000px; height: 570px; margin: auto"/>
|
||||||
|
</el-card>
|
||||||
|
<el-card>
|
||||||
|
<span>工位号:</span>
|
||||||
|
<el-select v-model="MachineValue1" filterable size="small" style="width:160px;margin-bottom:10px" placeholder="工位号">
|
||||||
|
<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.value2 }}</div>
|
||||||
|
</el-option>
|
||||||
|
</el-select>
|
||||||
|
<span style="margin-left: 10px">时间段:</span>
|
||||||
|
<el-date-picker
|
||||||
|
v-model="date1"
|
||||||
|
style="width:160px;margin:10px;"
|
||||||
|
size="small"
|
||||||
|
type="date"
|
||||||
|
value-format="yyyy-MM-dd"
|
||||||
|
format="yyyy-MM-dd"
|
||||||
|
placeholder="选择日期"/>
|
||||||
|
<span>~</span>
|
||||||
|
<el-date-picker
|
||||||
|
v-model="date2"
|
||||||
|
style="width:160px;margin:10px;"
|
||||||
|
size="small"
|
||||||
|
type="date"
|
||||||
|
value-format="yyyy-MM-dd"
|
||||||
|
format="yyyy-MM-dd"
|
||||||
|
placeholder="选择日期"/>
|
||||||
|
<el-button type="success" size="small" icon="el-icon-search" style="margin-left: 15px" @click="searchData1()">查询</el-button>
|
||||||
|
</el-card>
|
||||||
|
<el-card>
|
||||||
|
<div id="myChart" style="width: 1000px; height: 570px; margin: auto"/>
|
||||||
|
</el-card>
|
||||||
|
<el-card>
|
||||||
|
<div id="myChart3" style="width: 100%; height: 520px; margin: auto"/>
|
||||||
|
</el-card>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>import { getData, getData1, getData2, getMachine } from '@/api/ManufacturingCenter/EquipmentConditionAnalysis'
|
||||||
|
export default {
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
tableDataA: [],
|
||||||
|
MachineValue: '',
|
||||||
|
MachineValue1: '',
|
||||||
|
Machine: [],
|
||||||
|
Time: '',
|
||||||
|
date1: '',
|
||||||
|
date2: '',
|
||||||
|
time1: '',
|
||||||
|
time2: '',
|
||||||
|
time3: '',
|
||||||
|
time11: '',
|
||||||
|
time22: '',
|
||||||
|
time33: '',
|
||||||
|
pageCurrent: 1,
|
||||||
|
pageSize: 10,
|
||||||
|
total: 0,
|
||||||
|
table: []
|
||||||
|
}
|
||||||
|
},
|
||||||
|
mounted() {
|
||||||
|
this.drawLine()
|
||||||
|
},
|
||||||
|
created() {
|
||||||
|
this.fetchData()
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
fetchData() {
|
||||||
|
this.MachineValue = ''
|
||||||
|
this.Machine = []
|
||||||
|
getMachine().then(response => {
|
||||||
|
for (let i = 0; i < response.data.length; i++) {
|
||||||
|
this.Machine.push({
|
||||||
|
label: response.data[i].终端编号,
|
||||||
|
value: response.data[i].终端编号,
|
||||||
|
value2: response.data[i].姓名
|
||||||
|
})
|
||||||
|
}
|
||||||
|
})
|
||||||
|
},
|
||||||
|
searchData() {
|
||||||
|
getData(this.MachineValue, this.Time, this.pageCurrent, this.pageSize).then(response => {
|
||||||
|
this.tableDataA = response.data.rows
|
||||||
|
this.total = response.data.total
|
||||||
|
this.time1 = response.data.rows[0].运行持续时间
|
||||||
|
this.time2 = response.data.rows[0].等待持续时间
|
||||||
|
this.time3 = response.data.rows[0].停机持续时间
|
||||||
|
}).then(() => {
|
||||||
|
this.drawLine1()
|
||||||
|
})
|
||||||
|
getData1(this.Time).then(response => {
|
||||||
|
this.time11 = response.data[0].运行持续时间
|
||||||
|
this.time22 = response.data[0].等待持续时间
|
||||||
|
this.time33 = response.data[0].停机持续时间
|
||||||
|
}).then(() => {
|
||||||
|
this.drawLine2()
|
||||||
|
})
|
||||||
|
},
|
||||||
|
searchData1() {
|
||||||
|
getData2(this.MachineValue1, this.date1, this.date2).then(response => {
|
||||||
|
this.table = response.data
|
||||||
|
console.log(this.table)
|
||||||
|
}).then(() => {
|
||||||
|
this.drawLine()
|
||||||
|
})
|
||||||
|
},
|
||||||
|
// 绘制图形
|
||||||
|
drawLine() {
|
||||||
|
const myChart = this.$echarts.init(document.getElementById('myChart'))
|
||||||
|
const xData = []
|
||||||
|
const lineData = []
|
||||||
|
for (let i = 0; i < this.table.length; i++) {
|
||||||
|
xData.push(this.table[i].日期.split(' ')[0])
|
||||||
|
lineData.push(this.table[i].利用率.toFixed(2))
|
||||||
|
}
|
||||||
|
myChart.clear()
|
||||||
|
myChart.setOption({
|
||||||
|
tooltip: {
|
||||||
|
trigger: 'axis',
|
||||||
|
axisPointer: {
|
||||||
|
type: 'cross',
|
||||||
|
crossStyle: {
|
||||||
|
color: '#999'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
legend: {
|
||||||
|
data: ['利用率']
|
||||||
|
},
|
||||||
|
xAxis: [
|
||||||
|
{
|
||||||
|
type: 'category',
|
||||||
|
name: '日期',
|
||||||
|
data: xData,
|
||||||
|
axisPointer: {
|
||||||
|
type: 'shadow'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
],
|
||||||
|
yAxis: [
|
||||||
|
{
|
||||||
|
type: 'value',
|
||||||
|
name: '利用率'
|
||||||
|
}
|
||||||
|
],
|
||||||
|
series: [
|
||||||
|
{
|
||||||
|
name: '利用率',
|
||||||
|
type: 'line',
|
||||||
|
label: {
|
||||||
|
normal: {
|
||||||
|
show: true,
|
||||||
|
position: 'top'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
data: lineData
|
||||||
|
}
|
||||||
|
]
|
||||||
|
})
|
||||||
|
},
|
||||||
|
drawLine1() {
|
||||||
|
const myChart = this.$echarts.init(document.getElementById('myChart1'))
|
||||||
|
const xData = ['运行', '等待', '停机']
|
||||||
|
const lineData = [{ name: '运行', value: this.time1 }, { name: '等待', value: this.time2 }, { name: '停机', value: this.time3 }]
|
||||||
|
myChart.clear()
|
||||||
|
myChart.setOption({
|
||||||
|
title: {
|
||||||
|
text: '单台设备状态',
|
||||||
|
x: 350
|
||||||
|
},
|
||||||
|
tooltip: {
|
||||||
|
trigger: 'item',
|
||||||
|
formatter: '{a} <br/>{b} : {c} ({d}%)'
|
||||||
|
},
|
||||||
|
legend: {
|
||||||
|
type: 'scroll',
|
||||||
|
orient: 'vertical',
|
||||||
|
left: 10,
|
||||||
|
top: 20,
|
||||||
|
bottom: 20,
|
||||||
|
data: xData
|
||||||
|
},
|
||||||
|
series: [
|
||||||
|
{
|
||||||
|
name: '状态',
|
||||||
|
type: 'pie',
|
||||||
|
radius: '55%',
|
||||||
|
center: ['40%', '50%'],
|
||||||
|
data: lineData,
|
||||||
|
itemStyle: {
|
||||||
|
emphasis: {
|
||||||
|
shadowBlur: 10,
|
||||||
|
shadowOffsetX: 0,
|
||||||
|
shadowColor: 'rgba(0, 0, 0, 0.5)'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
]
|
||||||
|
})
|
||||||
|
},
|
||||||
|
drawLine2() {
|
||||||
|
const myChart = this.$echarts.init(document.getElementById('myChart2'))
|
||||||
|
const xData = ['运行', '等待', '停机']
|
||||||
|
const lineData = [{ name: '运行', value: this.time11 }, { name: '等待', value: this.time22 }, { name: '停机', value: this.time33 }]
|
||||||
|
myChart.clear()
|
||||||
|
myChart.setOption({
|
||||||
|
title: {
|
||||||
|
text: '全员设备状态',
|
||||||
|
x: 350
|
||||||
|
},
|
||||||
|
tooltip: {
|
||||||
|
trigger: 'item',
|
||||||
|
formatter: '{a} <br/>{b} : {c} ({d}%)'
|
||||||
|
},
|
||||||
|
legend: {
|
||||||
|
type: 'scroll',
|
||||||
|
orient: 'vertical',
|
||||||
|
left: 10,
|
||||||
|
top: 20,
|
||||||
|
bottom: 20,
|
||||||
|
data: xData
|
||||||
|
},
|
||||||
|
series: [
|
||||||
|
{
|
||||||
|
name: '状态',
|
||||||
|
type: 'pie',
|
||||||
|
radius: '55%',
|
||||||
|
center: ['40%', '50%'],
|
||||||
|
data: lineData,
|
||||||
|
itemStyle: {
|
||||||
|
emphasis: {
|
||||||
|
shadowBlur: 10,
|
||||||
|
shadowOffsetX: 0,
|
||||||
|
shadowColor: 'rgba(0, 0, 0, 0.5)'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
]
|
||||||
|
})
|
||||||
|
},
|
||||||
|
handleSizeChange(val) {
|
||||||
|
this.pageCurrent = 1
|
||||||
|
this.pageSize = val
|
||||||
|
this.searchData()
|
||||||
|
},
|
||||||
|
handleCurrentChange(val) {
|
||||||
|
this.pageCurrent = val
|
||||||
|
this.searchData()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style scoped>
|
||||||
|
|
||||||
|
</style>
|
||||||
@@ -186,6 +186,7 @@
|
|||||||
@size-change="handleSizeChange"
|
@size-change="handleSizeChange"
|
||||||
@current-change="handleCurrentChange"/>
|
@current-change="handleCurrentChange"/>
|
||||||
<!--<el-checkbox v-model="checked_baitu" style="margin-top:0px">是否白图</el-checkbox>-->
|
<!--<el-checkbox v-model="checked_baitu" style="margin-top:0px">是否白图</el-checkbox>-->
|
||||||
|
<el-button :loading="listLoading3" type="primary" size="small" style="float:right;margin-left: 10px" @click="back">打回</el-button>
|
||||||
<el-button :loading="listLoading3" type="primary" size="small" style="float:right;" @click="production">投产</el-button>
|
<el-button :loading="listLoading3" type="primary" size="small" style="float:right;" @click="production">投产</el-button>
|
||||||
<el-checkbox v-model="checked_hebing" style="float:right;margin-top:10px;margin-right:10px">合并生产</el-checkbox>
|
<el-checkbox v-model="checked_hebing" style="float:right;margin-top:10px;margin-right:10px">合并生产</el-checkbox>
|
||||||
</div>
|
</div>
|
||||||
@@ -332,7 +333,7 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import { getEntryNameValue, getToolNum, getNum, getTable, production, getTable1, revisionBatch, editList, dele, production2 } from '@/api/ManufacturingCenter/InitialProduction'
|
import { getEntryNameValue, getToolNum, getNum, getTable, production, getTable1, revisionBatch, editList, dele, production2, edit } from '@/api/ManufacturingCenter/InitialProduction'
|
||||||
import { mapGetters } from 'vuex'
|
import { mapGetters } from 'vuex'
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
@@ -574,6 +575,7 @@ export default {
|
|||||||
},
|
},
|
||||||
handleSelectionChange(val) {
|
handleSelectionChange(val) {
|
||||||
this.multipleSelection = val
|
this.multipleSelection = val
|
||||||
|
console.log(this.multipleSelection, 1111)
|
||||||
},
|
},
|
||||||
// 打开分批投产
|
// 打开分批投产
|
||||||
handleEdit(index, row, formName) {
|
handleEdit(index, row, formName) {
|
||||||
@@ -904,6 +906,30 @@ export default {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
back() {
|
||||||
|
if (this.multipleSelection.length === 0) {
|
||||||
|
this.$message.error('请至少选择一个零件')
|
||||||
|
} else {
|
||||||
|
this.a = 0
|
||||||
|
for (let i = 0; i < this.multipleSelection.length; i++) {
|
||||||
|
edit(this.multipleSelection[i].组件零件基本件流水号).then(response => {
|
||||||
|
this.a += parseInt(response.data[0].result)
|
||||||
|
if (this.a === this.multipleSelection.length) {
|
||||||
|
this.$message.success('打回成功')
|
||||||
|
this.total = 0
|
||||||
|
this.pageList = 1
|
||||||
|
this.getTable()
|
||||||
|
this.checked_baitu = false
|
||||||
|
this.checked_gaonandu = false
|
||||||
|
this.tableData1 = []
|
||||||
|
this.listLoading3 = false
|
||||||
|
} else {
|
||||||
|
this.$message.error('打回失败')
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
// 打回档案
|
// 打回档案
|
||||||
handleDele(index, row, formName) {
|
handleDele(index, row, formName) {
|
||||||
this.count2 = this.count2 + 1
|
this.count2 = this.count2 + 1
|
||||||
|
|||||||
@@ -5,6 +5,7 @@
|
|||||||
<el-input v-model="partName" placeholder="零件图号" size="small" clearable style="width:200px"/>
|
<el-input v-model="partName" placeholder="零件图号" size="small" clearable style="width:200px"/>
|
||||||
<el-button size="small" icon="el-icon-search" type="success" style="margin-left: 10px" @click="pageSize=10; pageCurrent=1;searchTable()">查询</el-button>
|
<el-button size="small" icon="el-icon-search" type="success" style="margin-left: 10px" @click="pageSize=10; pageCurrent=1;searchTable()">查询</el-button>
|
||||||
<el-button size="small" icon="el-icon-success" type="primary" style="margin-left: 10px" @click="edit2()">自家备料确认</el-button>
|
<el-button size="small" icon="el-icon-success" type="primary" style="margin-left: 10px" @click="edit2()">自家备料确认</el-button>
|
||||||
|
<el-button size="small" icon="el-icon-success" type="primary" style="margin-left: 10px" @click="back()">打回</el-button>
|
||||||
</el-card>
|
</el-card>
|
||||||
<el-card>
|
<el-card>
|
||||||
<el-table v-loading="loading" :data="tableData" height="580" style="width: 100%;" border element-loading-text="拼命加载中" @selection-change="handleSelectionChange2">
|
<el-table v-loading="loading" :data="tableData" height="580" style="width: 100%;" border element-loading-text="拼命加载中" @selection-change="handleSelectionChange2">
|
||||||
@@ -90,7 +91,7 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import { searchtable, searchtable2, searchtable3, change2, change3 } from '@/api/ManufacturingCenter/MaterialArrivalManagement'
|
import { searchtable, searchtable2, searchtable3, change2, change3, edit } from '@/api/ManufacturingCenter/MaterialArrivalManagement'
|
||||||
import { mapGetters } from 'vuex'
|
import { mapGetters } from 'vuex'
|
||||||
export default {
|
export default {
|
||||||
data() {
|
data() {
|
||||||
@@ -99,6 +100,7 @@ export default {
|
|||||||
editTime: '',
|
editTime: '',
|
||||||
bianliang1: [],
|
bianliang1: [],
|
||||||
bianliang2: [],
|
bianliang2: [],
|
||||||
|
bianliang3: [],
|
||||||
num: 0,
|
num: 0,
|
||||||
arrest: [],
|
arrest: [],
|
||||||
all: false,
|
all: false,
|
||||||
@@ -183,6 +185,24 @@ export default {
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
back() {
|
||||||
|
if (this.arrest2.length === 0) {
|
||||||
|
this.$message.warning('请选择零件')
|
||||||
|
} else {
|
||||||
|
this.a = 0
|
||||||
|
for (let i = 0; i < this.arrest2.length; i++) {
|
||||||
|
edit(this.arrest2[i].工艺计划流水号).then(response => {
|
||||||
|
this.a += parseInt(response.data[0].result)
|
||||||
|
if (this.a === this.arrest2.length) {
|
||||||
|
this.$message.success('打回成功')
|
||||||
|
this.searchTable()
|
||||||
|
} else {
|
||||||
|
this.$message.error('打回失败')
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
zeroFill(i) {
|
zeroFill(i) {
|
||||||
if (i >= 0 && i <= 9) {
|
if (i >= 0 && i <= 9) {
|
||||||
return '0' + i
|
return '0' + i
|
||||||
|
|||||||
@@ -589,7 +589,7 @@ export default {
|
|||||||
RequisitionList: '',
|
RequisitionList: '',
|
||||||
form: {
|
form: {
|
||||||
请购单编号: '',
|
请购单编号: '',
|
||||||
请购车间: '',
|
请购车间: '制造部',
|
||||||
请购时间: ''
|
请购时间: ''
|
||||||
},
|
},
|
||||||
rules: {
|
rules: {
|
||||||
|
|||||||
@@ -413,7 +413,7 @@ export default {
|
|||||||
if (groupNum.indexOf('MX') > -1) {
|
if (groupNum.indexOf('MX') > -1) {
|
||||||
const response = await importBasics(establishment, proofread, review, date, this.projectName, machineNum, machineName, componentName, componentNum, this.group, contractNum, totalNum, pageNum, drawingNum, name, type, material, spareNum, useNum, manufacturer, remarks, classificationCode)
|
const response = await importBasics(establishment, proofread, review, date, this.projectName, machineNum, machineName, componentName, componentNum, this.group, contractNum, totalNum, pageNum, drawingNum, name, type, material, spareNum, useNum, manufacturer, remarks, classificationCode)
|
||||||
const res = response.data
|
const res = response.data
|
||||||
console.log(res)
|
console.log(res, 11111111)
|
||||||
if (res.result[0].result === '0') {
|
if (res.result[0].result === '0') {
|
||||||
this.$notify.error(`${drawingNum}导入失败`)
|
this.$notify.error(`${drawingNum}导入失败`)
|
||||||
}
|
}
|
||||||
@@ -433,6 +433,7 @@ export default {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
|
console.log('哈哈哈哈')
|
||||||
this.err++
|
this.err++
|
||||||
this.$message.error(`导入数据错误`)
|
this.$message.error(`导入数据错误`)
|
||||||
console.log(`导入数据错误${e}`)
|
console.log(`导入数据错误${e}`)
|
||||||
|
|||||||
@@ -30,6 +30,7 @@
|
|||||||
<el-input v-model="partDrawingNumber" placeholder="零件图号" size="mini" clearable style="width: 120px"/>
|
<el-input v-model="partDrawingNumber" placeholder="零件图号" size="mini" clearable style="width: 120px"/>
|
||||||
<el-button type="success" size="mini" icon="el-icon-search" style="margin-left: 10px" @click="pageCurrent1=1;pageSize1=10;total1=0;searchTable1()">查询</el-button>
|
<el-button type="success" size="mini" icon="el-icon-search" style="margin-left: 10px" @click="pageCurrent1=1;pageSize1=10;total1=0;searchTable1()">查询</el-button>
|
||||||
<el-button type="primary" size="mini" icon="el-icon-download" style="margin-left: 10px" @click="addMateriel">选入物料</el-button>
|
<el-button type="primary" size="mini" icon="el-icon-download" style="margin-left: 10px" @click="addMateriel">选入物料</el-button>
|
||||||
|
<el-button type="primary" size="mini" icon="el-icon-download" style="margin-left: 10px" @click="back">打回</el-button>
|
||||||
<el-table v-loading="loading1" :data="tableData1" border style="width: 100%;height: 460px;margin-top: 15px;" height="330" size="mini" @selection-change="handleSelectionChange">
|
<el-table v-loading="loading1" :data="tableData1" border style="width: 100%;height: 460px;margin-top: 15px;" height="330" size="mini" @selection-change="handleSelectionChange">
|
||||||
<el-table-column type="selection" align="center" width="55"/>
|
<el-table-column type="selection" align="center" width="55"/>
|
||||||
<el-table-column label="零件图号" min-width="100" align="center">
|
<el-table-column label="零件图号" min-width="100" align="center">
|
||||||
@@ -350,7 +351,7 @@
|
|||||||
<th colspan="14"><h3>江苏高精机电装备有限公司</h3></th>
|
<th colspan="14"><h3>江苏高精机电装备有限公司</h3></th>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<th colspan="14"><h4>锻件采购计划表</h4></th>
|
<th colspan="14"><h4>{{ 采购单名称 }}</h4></th>
|
||||||
</tr>
|
</tr>
|
||||||
<tr style="height: 40px">
|
<tr style="height: 40px">
|
||||||
<td colspan="2" style="text-align: center;width: 15%">下单单位</td>
|
<td colspan="2" style="text-align: center;width: 15%">下单单位</td>
|
||||||
@@ -378,7 +379,7 @@
|
|||||||
</tr>
|
</tr>
|
||||||
<tr v-for="(list, index) in tableData3" :key="index" style="height: 35px">
|
<tr v-for="(list, index) in tableData3" :key="index" style="height: 35px">
|
||||||
<td style="text-align: center;width: 7%">{{ index + 1 }}</td>
|
<td style="text-align: center;width: 7%">{{ index + 1 }}</td>
|
||||||
<td colspan="2" style="text-align: center;width: 20%">{{ list.零件图号 }}</td>
|
<td colspan="2" style="text-align: center;width: 20%">{{ list.物料零件编码 }}</td>
|
||||||
<td colspan="2" style="text-align: center;width: 10%">{{ list.零件名称 }}</td>
|
<td colspan="2" style="text-align: center;width: 10%">{{ list.零件名称 }}</td>
|
||||||
<td colspan="2" style="text-align: center;width: 10%">{{ list.材料 }}</td>
|
<td colspan="2" style="text-align: center;width: 10%">{{ list.材料 }}</td>
|
||||||
<td colspan="2" style="text-align: center;width: 8%">{{ list.单位 }}</td>
|
<td colspan="2" style="text-align: center;width: 8%">{{ list.单位 }}</td>
|
||||||
@@ -387,6 +388,7 @@
|
|||||||
<td style="text-align: center;width: 17%">{{ list.备注1 }}</td>
|
<td style="text-align: center;width: 17%">{{ list.备注1 }}</td>
|
||||||
</tr>
|
</tr>
|
||||||
</table>
|
</table>
|
||||||
|
<div style="margin-top: 20px">联系人:___________ 联系电话:___________ </div>
|
||||||
</div>
|
</div>
|
||||||
</el-card>
|
</el-card>
|
||||||
</div>
|
</div>
|
||||||
@@ -394,7 +396,7 @@
|
|||||||
|
|
||||||
<script>
|
<script>
|
||||||
import { initPartDrawing, searchPurchasedMaterials, searchPurchaseOrder, searchSupplier, addPurchaseOrder, editPurchaseOrder, deletePurchaseOrder, searchMateriel,
|
import { initPartDrawing, searchPurchasedMaterials, searchPurchaseOrder, searchSupplier, addPurchaseOrder, editPurchaseOrder, deletePurchaseOrder, searchMateriel,
|
||||||
addMateriel, deleteMateriel, saveMateriel, searchRawMaterial, addMateriel2, saveWeight } from '@/api/WorkshopProcurement/CreatingPurchasingMaterials'
|
addMateriel, deleteMateriel, saveMateriel, searchRawMaterial, addMateriel2, saveWeight, edit2 } from '@/api/WorkshopProcurement/CreatingPurchasingMaterials'
|
||||||
import QRCode from 'qrcode'
|
import QRCode from 'qrcode'
|
||||||
import $ from 'jquery'
|
import $ from 'jquery'
|
||||||
import { mapGetters } from 'vuex'
|
import { mapGetters } from 'vuex'
|
||||||
@@ -460,6 +462,7 @@ export default {
|
|||||||
下单日期: '',
|
下单日期: '',
|
||||||
单号: '',
|
单号: '',
|
||||||
计划完成日期: '',
|
计划完成日期: '',
|
||||||
|
采购单名称: '',
|
||||||
form2: {
|
form2: {
|
||||||
采购计划流水号: '',
|
采购计划流水号: '',
|
||||||
采购单名称: '',
|
采购单名称: '',
|
||||||
@@ -744,6 +747,7 @@ export default {
|
|||||||
},
|
},
|
||||||
searchTable3(row) { // 查询采购计划明细
|
searchTable3(row) { // 查询采购计划明细
|
||||||
this.purchasingOrderNumber = row.采购计划流水号
|
this.purchasingOrderNumber = row.采购计划流水号
|
||||||
|
this.采购单名称 = row.采购单名称
|
||||||
this.采购计划状态 = row.采购计划状态
|
this.采购计划状态 = row.采购计划状态
|
||||||
this.下单单位 = row.供应商名称
|
this.下单单位 = row.供应商名称
|
||||||
this.单号 = row.采购单号
|
this.单号 = row.采购单号
|
||||||
@@ -771,6 +775,14 @@ export default {
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
back() {
|
||||||
|
edit2(this.materielGroup).then(response => {
|
||||||
|
if (response.data[0].result === '1') {
|
||||||
|
this.$message.success('打回成功')
|
||||||
|
this.searchTable1()
|
||||||
|
} else { this.$message.error('打回失败') }
|
||||||
|
})
|
||||||
|
},
|
||||||
saveMateriel() { // 保存数据
|
saveMateriel() { // 保存数据
|
||||||
this.partGroup = []
|
this.partGroup = []
|
||||||
this.unit = []
|
this.unit = []
|
||||||
|
|||||||
Reference in New Issue
Block a user