Merge branch 'master' of http://gitea.xxhhcty.xyz:8080/zcdsj/factory_web
This commit is contained in:
commit
35d105baf8
|
|
@ -640,6 +640,7 @@
|
||||||
style="width: 100%"
|
style="width: 100%"
|
||||||
placeholder="不合格数量"
|
placeholder="不合格数量"
|
||||||
controls-position="right"
|
controls-position="right"
|
||||||
|
@change="count_notok_change"
|
||||||
></el-input-number>
|
></el-input-number>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
|
|
@ -1210,6 +1211,7 @@ export default {
|
||||||
if(this.form.count_notok>count_notok){
|
if(this.form.count_notok>count_notok){
|
||||||
this.form.count_n_qt = this.form.count_notok-count_notok;
|
this.form.count_n_qt = this.form.count_notok-count_notok;
|
||||||
}
|
}
|
||||||
|
this.form.count_ok = this.form.count - this.form.count_notok;
|
||||||
},
|
},
|
||||||
getMaterialItem(){
|
getMaterialItem(){
|
||||||
let that = this;
|
let that = this;
|
||||||
|
|
|
||||||
|
|
@ -49,6 +49,26 @@
|
||||||
@click="handleQuery"
|
@click="handleQuery"
|
||||||
></el-button>
|
></el-button>
|
||||||
</div>
|
</div>
|
||||||
|
<div class="right-panel" v-if="activeName=='gongxu'">
|
||||||
|
<el-select
|
||||||
|
v-model="query2.process_name"
|
||||||
|
placeholder="选择工序"
|
||||||
|
clearable
|
||||||
|
filterable
|
||||||
|
>
|
||||||
|
<el-option
|
||||||
|
v-for="item in processList"
|
||||||
|
:key="item"
|
||||||
|
:label="item"
|
||||||
|
:value="item">
|
||||||
|
</el-option>
|
||||||
|
</el-select>
|
||||||
|
<el-button
|
||||||
|
type="primary"
|
||||||
|
icon="el-icon-search"
|
||||||
|
@click="handleQuery"
|
||||||
|
></el-button>
|
||||||
|
</div>
|
||||||
</el-header>
|
</el-header>
|
||||||
<el-main class="nopadding">
|
<el-main class="nopadding">
|
||||||
<el-tabs type="border-card" v-model="activeName" @tab-click="handleClick" style="height: 100%;" lazy>
|
<el-tabs type="border-card" v-model="activeName" @tab-click="handleClick" style="height: 100%;" lazy>
|
||||||
|
|
@ -402,6 +422,96 @@
|
||||||
</el-main>
|
</el-main>
|
||||||
</el-container>
|
</el-container>
|
||||||
</el-tab-pane>
|
</el-tab-pane>
|
||||||
|
<el-tab-pane name="gongxu" label="工序统计" style="height: 100%;">
|
||||||
|
<el-container v-if="activeName=='gongxu'">
|
||||||
|
<el-main>
|
||||||
|
<scTable
|
||||||
|
v-if="showTable"
|
||||||
|
ref="table5"
|
||||||
|
:data="tableData"
|
||||||
|
row-key="id"
|
||||||
|
hidePagination
|
||||||
|
hideDo
|
||||||
|
stripe
|
||||||
|
>
|
||||||
|
<el-table-column type="index" width="50" fixed="left"/>
|
||||||
|
<el-table-column label="操作人" prop="员工">
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="总数" prop="总切片数">
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="长点">
|
||||||
|
<template #default="scope">
|
||||||
|
<span v-if="scope.row.暗点不合格">{{scope.row.暗点不合格.含}}</span>
|
||||||
|
<span v-else>0</span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="长点率">
|
||||||
|
<template #default="scope">
|
||||||
|
<span v-if="scope.row.暗点不合格">{{((scope.row.暗点不合格.含/scope.row.总切片数)*100).toFixed(2) }}%</span>
|
||||||
|
<span v-else>0%</span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="放大率不合格">
|
||||||
|
<template #default="scope">
|
||||||
|
<span v-if="scope.row['放大率¢16mm不合格']">{{scope.row['放大率¢16mm不合格'].含}}</span>
|
||||||
|
<span v-else>0</span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="放大率不合格占比">
|
||||||
|
<template #default="scope">
|
||||||
|
<span v-if="scope.row['放大率¢16mm不合格']">{{((scope.row['放大率¢16mm不合格'].含/scope.row.总切片数)*100).toFixed(2) }}%</span>
|
||||||
|
<span v-else>0%</span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
</scTable>
|
||||||
|
</el-main>
|
||||||
|
</el-container>
|
||||||
|
</el-tab-pane>
|
||||||
|
<el-tab-pane name="total" label="总统计" style="height: 100%;">
|
||||||
|
<el-container v-if="activeName=='total'">
|
||||||
|
<el-main>
|
||||||
|
<scTable
|
||||||
|
v-if="showTable"
|
||||||
|
ref="table4"
|
||||||
|
:data="tableData"
|
||||||
|
row-key="id"
|
||||||
|
hidePagination
|
||||||
|
hideDo
|
||||||
|
stripe
|
||||||
|
>
|
||||||
|
<el-table-column type="index" width="50" fixed="left"/>
|
||||||
|
<el-table-column label="丝高" prop="丝高">
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="总数" prop="总切片数">
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="长点">
|
||||||
|
<template #default="scope">
|
||||||
|
<span v-if="scope.row.暗点不合格">{{scope.row.暗点不合格.含}}</span>
|
||||||
|
<span v-else>0</span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="长点率">
|
||||||
|
<template #default="scope">
|
||||||
|
<span v-if="scope.row.暗点不合格">{{((scope.row.暗点不合格.含/scope.row.总切片数)*100).toFixed(2) }}%</span>
|
||||||
|
<span v-else>0%</span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="放大率不合格">
|
||||||
|
<template #default="scope">
|
||||||
|
<span v-if="scope.row['放大率¢16mm不合格']">{{scope.row['放大率¢16mm不合格'].含}}</span>
|
||||||
|
<span v-else>0</span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="放大率不合格占比">
|
||||||
|
<template #default="scope">
|
||||||
|
<span v-if="scope.row['放大率¢16mm不合格']">{{((scope.row['放大率¢16mm不合格'].含/scope.row.总切片数)*100).toFixed(2) }}%</span>
|
||||||
|
<span v-else>0%</span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
</scTable>
|
||||||
|
</el-main>
|
||||||
|
</el-container>
|
||||||
|
</el-tab-pane>
|
||||||
</el-tabs>
|
</el-tabs>
|
||||||
</el-main>
|
</el-main>
|
||||||
<el-drawer v-model="visible" :title="userName+'板段列表'" size="50%" direction="rtl" append-to-body destroy-on-close>
|
<el-drawer v-model="visible" :title="userName+'板段列表'" size="50%" direction="rtl" append-to-body destroy-on-close>
|
||||||
|
|
@ -432,6 +542,9 @@ export default {
|
||||||
time_gte:'',
|
time_gte:'',
|
||||||
time_lte:'',
|
time_lte:'',
|
||||||
},
|
},
|
||||||
|
query2:{
|
||||||
|
process_name:'压板出炉',
|
||||||
|
},
|
||||||
query:{
|
query:{
|
||||||
end_date:'',
|
end_date:'',
|
||||||
start_date:'',
|
start_date:'',
|
||||||
|
|
@ -440,6 +553,7 @@ export default {
|
||||||
mgruops:[],
|
mgruops:[],
|
||||||
tableData:[],
|
tableData:[],
|
||||||
detailRow:[],
|
detailRow:[],
|
||||||
|
processList:['装模','装炉','压板出炉','脱膜测量'],
|
||||||
params:{cate:'热压'},
|
params:{cate:'热压'},
|
||||||
apiObj1: this.$API.wpm.wpr.query,
|
apiObj1: this.$API.wpm.wpr.query,
|
||||||
apiObj: this.$API.mtm.process.list,
|
apiObj: this.$API.mtm.process.list,
|
||||||
|
|
@ -455,15 +569,22 @@ export default {
|
||||||
getData(){
|
getData(){
|
||||||
let that = this;
|
let that = this;
|
||||||
let params = {};
|
let params = {};
|
||||||
params.query = that.query;
|
|
||||||
let biStr = '';
|
let biStr = '';
|
||||||
if(that.activeName=='luhao'){
|
if(that.activeName=='luhao'){
|
||||||
|
params.query = that.query;
|
||||||
biStr = 'product_defect_equip_bdgy';
|
biStr = 'product_defect_equip_bdgy';
|
||||||
params.query.select_cols = ",ls.板段编号列表,ls.切片编号列表";
|
params.query.select_cols = ",ls.板段编号列表,ls.切片编号列表";
|
||||||
}else if(that.activeName=='muju'){
|
}else if(that.activeName=='muju'){
|
||||||
|
params.query = that.query;
|
||||||
biStr = 'product_defect_model';
|
biStr = 'product_defect_model';
|
||||||
params.query.select_cols = "";
|
params.query.select_cols = "";
|
||||||
|
}else if(that.activeName=='gongxu'){
|
||||||
|
params.query = that.query2;
|
||||||
|
biStr = 'product_defect_reya';
|
||||||
|
}else if(that.activeName=='total'){
|
||||||
|
biStr = 'product_defect_sg';
|
||||||
}
|
}
|
||||||
|
console.log('params',params);
|
||||||
that.$API.bi.dataset.exec.req(biStr, params).then((res) => {
|
that.$API.bi.dataset.exec.req(biStr, params).then((res) => {
|
||||||
let data = res.data2.ds0;
|
let data = res.data2.ds0;
|
||||||
data.forEach(item=>{
|
data.forEach(item=>{
|
||||||
|
|
@ -528,7 +649,7 @@ export default {
|
||||||
console.log('e.props.name',e.props.name);
|
console.log('e.props.name',e.props.name);
|
||||||
this.activeName = e.props.name;
|
this.activeName = e.props.name;
|
||||||
this.showTable=false;
|
this.showTable=false;
|
||||||
if(e.props.name=='luhao'||e.props.name=='muju'){
|
if(e.props.name=='luhao'||e.props.name=='muju'||e.props.name=='gongxu'||e.props.name=='total'){
|
||||||
this.getData();
|
this.getData();
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
|
||||||
|
|
@ -160,16 +160,16 @@
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="开台人" align="center" class-name="colorheader6">
|
<el-table-column label="开台人" align="center" class-name="colorheader6">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<span>{{ scope.row.data.一体刀_操作人?scope.row.data.一体刀_操作人:'' }}</span>
|
<span>{{ scope.row.data.喷码_一体刀_操作人?scope.row.data.喷码_一体刀_操作人:'' }}</span>
|
||||||
<span>{{ scope.row.data.磨床开台_操作人?scope.row.data.磨床开台_操作人:'' }}</span>
|
<span>{{ scope.row.data.喷码_磨床开台_操作人?scope.row.data.喷码_磨床开台_操作人:'' }}</span>
|
||||||
<span>{{ scope.row.data.光锥一体刀_操作人?scope.row.data.光锥一体刀_操作人:'' }}</span>
|
<span>{{ scope.row.data.光锥一体刀_操作人?scope.row.data.光锥一体刀_操作人:'' }}</span>
|
||||||
<span>{{ scope.row.data.小批量一体刀_操作人?scope.row.data.小批量一体刀_操作人:'' }}</span>
|
<span>{{ scope.row.data.喷码_小批量一体刀_操作人?scope.row.data.喷码_小批量一体刀_操作人:'' }}</span>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="拆头人" align="center" class-name="colorheader7">
|
<el-table-column label="拆头人" align="center" class-name="colorheader7">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<span>{{ scope.row.data.拆头_操作人?scope.row.data.拆头_操作人:'' }}</span>
|
<span>{{ scope.row.data.喷码_拆头_操作人?scope.row.data.喷码_拆头_操作人:'' }}</span>
|
||||||
<span>{{ scope.row.data.光锥拆头_操作人?scope.row.data.光锥拆头_操作人:'' }}</span>
|
<span>{{ scope.row.data.喷码_光锥拆头_操作人?scope.row.data.喷码_光锥拆头_操作人:'' }}</span>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="喷码人" align="center" class-name="colorheader1">
|
<el-table-column label="喷码人" align="center" class-name="colorheader1">
|
||||||
|
|
|
||||||
|
|
@ -565,7 +565,7 @@ export default {
|
||||||
obj.compare = "lte";
|
obj.compare = "lte";
|
||||||
obj.field = "data__外观检验_返修_日期";
|
obj.field = "data__外观检验_返修_日期";
|
||||||
}
|
}
|
||||||
if(that.query.batch.indexOf(' ')>-1){
|
if(that.query.batch != "" && that.query.batch != null && that.query.batch != undefined&&that.query.batch.indexOf(' ')){
|
||||||
let arrs = that.query.batch.split(' ');
|
let arrs = that.query.batch.split(' ');
|
||||||
arrs.forEach((item,index)=>{
|
arrs.forEach((item,index)=>{
|
||||||
let newArrayName1 = 'arr1' + index;
|
let newArrayName1 = 'arr1' + index;
|
||||||
|
|
|
||||||
|
|
@ -7,7 +7,32 @@
|
||||||
destroy-on-close
|
destroy-on-close
|
||||||
@closed="$emit('closed')"
|
@closed="$emit('closed')"
|
||||||
>
|
>
|
||||||
<div id="tableWap" style="height: 100%;">
|
<div id="tableWap" style="height: 100%;" v-if="route_code=='zlybcl'">
|
||||||
|
<el-tabs v-model="activeName" @tab-change="handleClick1">
|
||||||
|
<el-tab-pane v-for="item in mpointList" :label="item.nickname" :name="item.nickname" :key="item.id" lazy>
|
||||||
|
<scTable
|
||||||
|
v-if="item.name !== '折线图'"
|
||||||
|
ref="table"
|
||||||
|
:apiObj="apiObj"
|
||||||
|
row-key="id"
|
||||||
|
stripe
|
||||||
|
:height="tableHeight1"
|
||||||
|
:params="{'mpoint':item.id, 'timex__gte':startTime, 'timex__lte':endTime}"
|
||||||
|
hideDo
|
||||||
|
>
|
||||||
|
<el-table-column label="时间" prop="timex">
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="数值" prop="val_float">
|
||||||
|
<template #default="scope">
|
||||||
|
{{ scope.row.val_float.toFixed(3) }}
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
</scTable>
|
||||||
|
<scEcharts v-if="item.name == '折线图'" :height="chartHeight" :option="option"></scEcharts>
|
||||||
|
</el-tab-pane>
|
||||||
|
</el-tabs>
|
||||||
|
</div>
|
||||||
|
<div id="tableWap" style="height: 100%;" v-else>
|
||||||
<el-tabs v-model="activeName" @tab-change="handleClick">
|
<el-tabs v-model="activeName" @tab-change="handleClick">
|
||||||
<el-tab-pane v-for="item in mpointList" :label="item.nickname" :name="item.nickname" :key="item.id" lazy>
|
<el-tab-pane v-for="item in mpointList" :label="item.nickname" :name="item.nickname" :key="item.id" lazy>
|
||||||
<scTable
|
<scTable
|
||||||
|
|
@ -61,6 +86,8 @@ export default {
|
||||||
mpointList:[],
|
mpointList:[],
|
||||||
activeName: "",
|
activeName: "",
|
||||||
tableHeight:300,
|
tableHeight:300,
|
||||||
|
tableHeight1:300,
|
||||||
|
chartHeight:'280px',
|
||||||
option: {
|
option: {
|
||||||
title: {
|
title: {
|
||||||
text: "",
|
text: "",
|
||||||
|
|
@ -84,14 +111,19 @@ export default {
|
||||||
min: 0,
|
min: 0,
|
||||||
max: 100
|
max: 100
|
||||||
},
|
},
|
||||||
series:{
|
series:[
|
||||||
name: "数据检测",
|
{
|
||||||
type: "line",
|
name: "数据检测",
|
||||||
data: [],
|
type: "line",
|
||||||
}
|
data: [],
|
||||||
|
}
|
||||||
|
]
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
|
mounted() {
|
||||||
|
this.route_code = this.$route.path.split("/")[2];
|
||||||
|
},
|
||||||
methods: {
|
methods: {
|
||||||
open() {
|
open() {
|
||||||
let that = this;
|
let that = this;
|
||||||
|
|
@ -100,6 +132,8 @@ export default {
|
||||||
that.$nextTick(() => {
|
that.$nextTick(() => {
|
||||||
let height = document.getElementById("tableWap").clientHeight;
|
let height = document.getElementById("tableWap").clientHeight;
|
||||||
that.tableHeight = height - 345;
|
that.tableHeight = height - 345;
|
||||||
|
that.tableHeight1 = height - 40;
|
||||||
|
that.chartHeight =(height - 40)+'px';
|
||||||
})
|
})
|
||||||
that.params.timex__gte = that.startTime;
|
that.params.timex__gte = that.startTime;
|
||||||
that.params.timex__lte = that.endTime;
|
that.params.timex__lte = that.endTime;
|
||||||
|
|
@ -109,7 +143,14 @@ export default {
|
||||||
that.activeName = res[0].nickname;
|
that.activeName = res[0].nickname;
|
||||||
that.params.mpoint = res[0].id;
|
that.params.mpoint = res[0].id;
|
||||||
that.apiObj = that.$API.enm.mplogx;
|
that.apiObj = that.$API.enm.mplogx;
|
||||||
that.handleClick();
|
if(this.route_code =='zlybcl'){
|
||||||
|
let obj = {name:'折线图',nickname:'折线图',id:'666'};
|
||||||
|
that.mpointList.push(obj);
|
||||||
|
that.chartData();
|
||||||
|
that.handleClick1();
|
||||||
|
}else{
|
||||||
|
that.handleClick();
|
||||||
|
}
|
||||||
}else{
|
}else{
|
||||||
that.$message.error("该设备没有监测点");
|
that.$message.error("该设备没有监测点");
|
||||||
}
|
}
|
||||||
|
|
@ -118,7 +159,7 @@ export default {
|
||||||
handleClick(val){
|
handleClick(val){
|
||||||
let that = this;
|
let that = this;
|
||||||
that.option.xAxis.data = [];
|
that.option.xAxis.data = [];
|
||||||
that.option.series.data = [];
|
that.option.series[0].data = [];
|
||||||
that.mpointList.forEach(item=>{
|
that.mpointList.forEach(item=>{
|
||||||
if(item.nickname == that.activeName){
|
if(item.nickname == that.activeName){
|
||||||
that.query.mpoint = item.id;
|
that.query.mpoint = item.id;
|
||||||
|
|
@ -141,11 +182,64 @@ export default {
|
||||||
that.option.yAxis.min = minNum;
|
that.option.yAxis.min = minNum;
|
||||||
that.option.yAxis.max = maxNum;
|
that.option.yAxis.max = maxNum;
|
||||||
that.option.xAxis.data = xAxisData;
|
that.option.xAxis.data = xAxisData;
|
||||||
that.option.series.data = seriesData;
|
that.option.series[0].data = seriesData;
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
handleClick1(val){
|
||||||
|
let that = this;
|
||||||
|
that.mpointList.forEach(item=>{
|
||||||
|
if(item.nickname == that.activeName){
|
||||||
|
that.query.mpoint = item.id;
|
||||||
|
that.query.page = 1;
|
||||||
|
}
|
||||||
|
})
|
||||||
|
},
|
||||||
|
chartData(){
|
||||||
|
let that = this;
|
||||||
|
const promises = that.mpointList.map(item => {
|
||||||
|
if (item.name !== '折线图') {
|
||||||
|
let params = {
|
||||||
|
mpoint: item.id,
|
||||||
|
timex__gte: that.startTime,
|
||||||
|
timex__lte: that.endTime,
|
||||||
|
page: 0
|
||||||
|
};
|
||||||
|
return that.$API.enm.mplogx.req(params);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
Promise.all(promises).then(responses => {
|
||||||
|
that.option.xAxis.data = [];
|
||||||
|
that.option.series.data = [];
|
||||||
|
let minNum = null,maxNum = 0,series = [];
|
||||||
|
responses.forEach((res,index) => {
|
||||||
|
if(res!==undefined){
|
||||||
|
let minNum0=0,maxNum0=0,seriesData = [],xAxisData = [];
|
||||||
|
res.forEach(item=>{
|
||||||
|
xAxisData.unshift(item.timex);
|
||||||
|
let value = Number(item.val_float);
|
||||||
|
seriesData.unshift(value);
|
||||||
|
})
|
||||||
|
that.option.xAxis.data = xAxisData;
|
||||||
|
minNum0 = seriesData.reduce((a, b) => a < b ? a : b);
|
||||||
|
minNum = minNum === null ? minNum0 : Math.min(minNum,minNum0);
|
||||||
|
maxNum0 = Math.max(...seriesData);
|
||||||
|
maxNum = Math.max(maxNum,maxNum0);
|
||||||
|
series.push({
|
||||||
|
name: that.mpointList[index].nickname,
|
||||||
|
type: "line",
|
||||||
|
data: seriesData,
|
||||||
|
})
|
||||||
|
}
|
||||||
|
});
|
||||||
|
that.option.yAxis.min = minNum;
|
||||||
|
that.option.yAxis.max = maxNum;
|
||||||
|
that.option.series = series;
|
||||||
|
}).catch(error => {
|
||||||
|
console.error('Error:', error);
|
||||||
|
});
|
||||||
|
},
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|
|
||||||
|
|
@ -40,25 +40,20 @@
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col>
|
<el-col>
|
||||||
<el-form-item label="批次号" prop="wm_in">
|
<el-form-item label="批次号" prop="wm_in">
|
||||||
<el-select
|
<xtSelect
|
||||||
|
:apiObj="apiObj"
|
||||||
|
:params="params"
|
||||||
v-model="form.wm_in"
|
v-model="form.wm_in"
|
||||||
placeholder="交接物料批次号"
|
:labelField="'batch'"
|
||||||
class="width100"
|
v-model:obj="materialrow"
|
||||||
filterable
|
v-model:label="form.batch"
|
||||||
@change="changeMaterial"
|
style="width:100%"
|
||||||
|
@change="materialChange"
|
||||||
>
|
>
|
||||||
<el-option
|
<el-table-column label="批次号" prop="batch"></el-table-column>
|
||||||
v-for="item in materialOptions"
|
<el-table-column label="名称" prop="material_name"></el-table-column>
|
||||||
:key="item.id"
|
<el-table-column label="数量" prop="count"></el-table-column>
|
||||||
:label="item.batch"
|
</xtSelect>
|
||||||
:value="item.id"
|
|
||||||
>
|
|
||||||
<div style="position:relative;width:100%">
|
|
||||||
<span style="margin-right:15px!important;">{{ item.batch }}({{ item.material_name }})</span>
|
|
||||||
<span style="position:absolute;right:0">{{ item.count }}</span>
|
|
||||||
</div>
|
|
||||||
</el-option>
|
|
||||||
</el-select>
|
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :md="12" :sm="24">
|
<el-col :md="12" :sm="24">
|
||||||
|
|
@ -407,6 +402,9 @@ export default {
|
||||||
show: "查看日志",
|
show: "查看日志",
|
||||||
},
|
},
|
||||||
//表单数据
|
//表单数据
|
||||||
|
apiObj:this.$API.wpm.wmaterial.list,
|
||||||
|
params:{},
|
||||||
|
materialrow:{},
|
||||||
form: Object.assign({}, defaultForm),
|
form: Object.assign({}, defaultForm),
|
||||||
//验证规则
|
//验证规则
|
||||||
rules: {
|
rules: {
|
||||||
|
|
@ -532,7 +530,7 @@ export default {
|
||||||
})
|
})
|
||||||
}else{
|
}else{
|
||||||
if(route!==null){
|
if(route!==null){
|
||||||
that.$API.qm.qct.getQct.req({material:material_in,tag:'process'}).then((res) => {
|
that.$API.qm.qct.getQct.req({material:material_in,tag:'process',type:'in'}).then((res) => {
|
||||||
res.qct_defects.forEach((item) => {
|
res.qct_defects.forEach((item) => {
|
||||||
that.defectinform[item.defect_name] = 0;
|
that.defectinform[item.defect_name] = 0;
|
||||||
})
|
})
|
||||||
|
|
@ -548,7 +546,7 @@ export default {
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
//material_out
|
//material_out
|
||||||
that.$API.qm.qct.getQct.req({material:material_out,tag:'process'}).then((res) => {
|
that.$API.qm.qct.getQct.req({material:material_out,tag:'process',type:'out'}).then((res) => {
|
||||||
res.qct_defects.forEach((item) => {
|
res.qct_defects.forEach((item) => {
|
||||||
that.defectform[item.defect_name] = 0;
|
that.defectform[item.defect_name] = 0;
|
||||||
})
|
})
|
||||||
|
|
@ -638,20 +636,19 @@ export default {
|
||||||
params.state = 10;//合格
|
params.state = 10;//合格
|
||||||
params.material = that.material_in!==''?that.material_in:'';
|
params.material = that.material_in!==''?that.material_in:'';
|
||||||
}
|
}
|
||||||
console.log('that.material_in:',that.material_in);
|
that.params = params;
|
||||||
that.$API.wpm.wmaterial.list.req(params).then((res) => {
|
},
|
||||||
that.materialOptions = res;
|
materialChange(){
|
||||||
if(that.codeText!==''){
|
let that = this;
|
||||||
res.forEach(item=>{
|
that.qct_defects.forEach((item) => {
|
||||||
if(item.batch == that.codeBatch){
|
that.defectform[item.defect_name] = 0;
|
||||||
that.form.wm_in = item.id;
|
that.defectinform[item.defect_name] = 0;
|
||||||
that.form.batch = item.batch;
|
})
|
||||||
that.materialCount = that.form.count_use = that.form.count_ok = item.count_cando;
|
that.materialFix = that.materialrow.material;
|
||||||
that.form.count_real = item.count-that.form.count_pn_jgqbl;
|
that.form.batch = that.materialrow.batch;
|
||||||
}
|
that.materialCount = that.form.count_use = that.form.count_real = that.form.count_ok = Number(that.materialrow.count);
|
||||||
})
|
that.form.count_real = Number(that.materialrow.count)-that.form.count_pn_jgqbl;
|
||||||
}
|
that.getdefects(that.route,that.material_in,that.material_out);
|
||||||
});
|
|
||||||
},
|
},
|
||||||
changeMaterial(val){
|
changeMaterial(val){
|
||||||
let that = this;
|
let that = this;
|
||||||
|
|
|
||||||
|
|
@ -136,21 +136,12 @@
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="交接类别" prop="type" width="80">
|
<el-table-column label="交接类别" prop="type" width="80">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<el-tag v-if="scope.row.type == 10" type="success"
|
<el-tag v-if="scope.row.type == 10" type="success">正常</el-tag>
|
||||||
>正常</el-tag
|
<el-tag v-if="scope.row.type == 20" type="warning">返工</el-tag>
|
||||||
>
|
<el-tag v-if="scope.row.type == 30" type="primary">检验</el-tag>
|
||||||
<el-tag v-if="scope.row.type == 20" type="warning"
|
<el-tag v-if="scope.row.type == 40" type="danger">报废</el-tag>
|
||||||
>返工</el-tag
|
<el-tag v-if="scope.row.type == 50" type="warning">改版</el-tag>
|
||||||
>
|
<el-tag v-if="scope.row.type == 60" type="warning">退料</el-tag>
|
||||||
<el-tag v-if="scope.row.type == 30" type="primary"
|
|
||||||
>检验</el-tag
|
|
||||||
>
|
|
||||||
<el-tag v-if="scope.row.type == 40" type="danger"
|
|
||||||
>报废</el-tag
|
|
||||||
>
|
|
||||||
<el-tag v-if="scope.row.type == 60" type="warning"
|
|
||||||
>退料</el-tag
|
|
||||||
>
|
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
|
|
|
||||||
|
|
@ -343,7 +343,7 @@ export default {
|
||||||
},
|
},
|
||||||
initForm:{},
|
initForm:{},
|
||||||
selectObjIds:[],
|
selectObjIds:[],
|
||||||
apiObj:this.$API.wpm.wmaterial.list,
|
apiObj:this.$API.mtm.material.list,
|
||||||
apiObjM:null,
|
apiObjM:null,
|
||||||
params:{},
|
params:{},
|
||||||
paramsM:{},
|
paramsM:{},
|
||||||
|
|
@ -680,7 +680,8 @@ export default {
|
||||||
that.form.material_changed = item.material;
|
that.form.material_changed = item.material;
|
||||||
that.form.material_changed_fname = item.material_name;
|
that.form.material_changed_fname = item.material_name;
|
||||||
that.form.recive_mgroup = that.mgroupId;
|
that.form.recive_mgroup = that.mgroupId;
|
||||||
that.form.new_batch = item.batch;
|
// that.form.new_batch = item.batch;
|
||||||
|
// that.form.mtype = 30;
|
||||||
}
|
}
|
||||||
|
|
||||||
that.form.handoverb.push(obj);
|
that.form.handoverb.push(obj);
|
||||||
|
|
|
||||||
|
|
@ -130,14 +130,14 @@
|
||||||
@click="table_Check(scope.row)"
|
@click="table_Check(scope.row)"
|
||||||
v-auth="'ftestwork.create'"
|
v-auth="'ftestwork.create'"
|
||||||
type="primary"
|
type="primary"
|
||||||
v-if="(scope.row.state == 10||scope.row.state == 34)&&scope.row.mgroup_name !== '退火'"
|
v-if="scope.row.state == 10||scope.row.state == 34"
|
||||||
>检验</el-button>
|
>检验</el-button>
|
||||||
<!-- v-if="(scope.row.mgroup_name == '黑化'||scope.row.mgroup_name == '退火'||scope.row.mgroup_name == '外观检验')&&(scope.row.state == 10||scope.row.state == 20||scope.row.state == 34)" -->
|
<!-- v-if="(scope.row.mgroup_name == '黑化'||scope.row.mgroup_name == '退火'||scope.row.mgroup_name == '外观检验')&&(scope.row.state == 10||scope.row.state == 20||scope.row.state == 34)" -->
|
||||||
<el-button
|
<el-button
|
||||||
link size="small"
|
link size="small"
|
||||||
type="warning"
|
type="warning"
|
||||||
@click="tableCheckList(scope.row)"
|
@click="tableCheckList(scope.row)"
|
||||||
v-if="(scope.row.state == 10||scope.row.state == 34)&&scope.row.mgroup_name !== '退火'"
|
v-if="scope.row.state == 10||scope.row.state == 34"
|
||||||
>检验记录</el-button>
|
>检验记录</el-button>
|
||||||
<el-button @click="printMaterial(scope.row)" type="text">打签</el-button>
|
<el-button @click="printMaterial(scope.row)" type="text">打签</el-button>
|
||||||
</template>
|
</template>
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue