<template>
|
<view>
|
<view>
|
<div class="fr">
|
<u-input v-model="ipt" fontSize="28" placeholder="请输入内容" style="height: 60px;"></u-input>
|
<u-button text="搜索" type="primary" style="height: 72px;width: 110px;margin-left: 10px;" @click="select()"></u-button>
|
</div>
|
|
</view>
|
|
<uni-card v-for="item in inspections" @click="gotoInfo(item)" class="card-box" >
|
<view>
|
<u-row customStyle="margin-bottom: 10px">
|
<u-col span="2">
|
<label>检验单号:</label>
|
</u-col>
|
<u-col span="4">
|
<label>{{item.RELEASE_NO}}</label>
|
</u-col>
|
</u-row>
|
<u-row customStyle="margin-bottom: 10px">
|
<u-col span="2">
|
<label>工单批次:</label>
|
</u-col>
|
<u-col span="4">
|
<label>{{item.LOT_NO}}</label>
|
</u-col>
|
</u-row>
|
<u-row customStyle="margin-bottom: 10px">
|
<u-col span="2">
|
<label>工单数量:</label>
|
</u-col>
|
<u-col span="4">
|
<label>{{item.FBATCH_QTY}}</label>
|
</u-col>
|
</u-row>
|
<u-row customStyle="margin-bottom: 10px">
|
<u-col span="2">
|
<label>送检时间:</label>
|
</u-col>
|
<u-col span="4">
|
<label>{{item.CREATE_DATE}}</label>
|
</u-col>
|
</u-row>
|
<u-row customStyle="margin-bottom: 10px">
|
<u-col span="2">
|
<label>产品名称:</label>
|
</u-col>
|
<u-col>
|
<label>{{item.ITEM_NO}} | {{item.ITEM_NAME}}</label>
|
</u-col>
|
</u-row>
|
<u-row customStyle="margin-bottom: 10px">
|
<u-col span="2">
|
<label>图号颜色:</label>
|
</u-col>
|
<u-col>
|
<label>{{item.ENGINEERING_NO}} / {{item.COLOR_NAME}}</label>
|
</u-col>
|
</u-row>
|
<u-row customStyle="margin-bottom: 10px">
|
<u-col span="2">
|
<label>规格材质:</label>
|
</u-col>
|
<u-col>
|
<label>{{item.ITEM_MODEL}} / {{item.MATERIAL}}</label>
|
</u-col>
|
</u-row>
|
<u-row customStyle="margin-bottom: 10px" v-if="item.OPERATE_MAN">
|
<u-col span="2">
|
<label>操作员 / 检验类型:</label>
|
</u-col>
|
<u-col span="4">
|
<label>{{item.OPERATE_MAN}} / {{item.FTYPE}}</label>
|
</u-col>
|
</u-row>
|
</view>
|
|
</uni-card>
|
<u-toast ref="uToast" />
|
</view>
|
</template>
|
|
<script>
|
import { getFqcCheckList,getFqcByCode,getFqcCheckListByNo } from '../../api/fqc'
|
export default {
|
data() {
|
return {
|
inspections: [],
|
jyd:{},
|
moduleKey:0,
|
ipt:''
|
}
|
},
|
onLoad() {
|
this.getFqcInfos()
|
},
|
onPullDownRefresh() {
|
this.getFqcInfos()
|
setTimeout(function () {
|
uni.stopPullDownRefresh();
|
}, 1000);
|
},
|
onNavigationBarButtonTap(e) {
|
let that = this
|
uni.scanCode({
|
scanType: ['qrCode'],
|
success: function (res) {
|
getFqcByCode(res.result).then( res => {
|
if(!res.result) {
|
uni.showToast({
|
title: res.msg,
|
icon: 'none',
|
duration:3000
|
})
|
return
|
}else{
|
uni.showToast({
|
title: " 扫 码 成 功 ",
|
icon: 'none',
|
duration:3000
|
}),
|
uni.navigateTo({
|
url:'/pages/fqc/fqcInspectionDetail?item='+ encodeURIComponent(JSON.stringify(res.data[0]).replace(/\%/g, '%25').replace(/\ /g,'%20').replace(/\?/g,'%3F').replace(/\+/g,'%2B').replace(/\&/g,'%26')) ,
|
})
|
}
|
})
|
}
|
});
|
},
|
methods: {
|
getFqcInfos() {
|
getFqcCheckList().then(res => {
|
if(!res.result) {
|
this.$refs.uToast.show({
|
message: res.msg,
|
type: 'error'
|
})
|
return
|
}
|
this.inspections = res.data
|
})
|
},
|
gotoInfo(e) {
|
uni.navigateTo({
|
url:'/pages/fqc/fqcInspectionDetail?item='+ encodeURIComponent(JSON.stringify(e).replace(/\%/g, '%25').replace(/\ /g,'%20').replace(/\?/g,'%3F').replace(/\+/g,'%2B').replace(/\&/g,'%26')) ,
|
})
|
},
|
reload(){
|
this.$nextTick(()=>{
|
this.$refs.uToast.show({
|
message: "提交成功",
|
type: 'success'
|
})
|
this.getFqcInfos()
|
})
|
},
|
select(){
|
getFqcCheckListByNo(this.ipt).then(res => {
|
if(!res.result) {
|
this.$refs.uToast.show({
|
message: res.msg,
|
type: 'error'
|
})
|
return
|
}
|
this.inspections = res.data
|
})
|
}
|
}
|
}
|
</script>
|
|
<style>
|
.fr{
|
display: flex;
|
margin: 15px;
|
flex-direction: row;
|
margin-top: 10px;
|
}
|
.red{
|
color: red;
|
}
|
.card-box{
|
position: relative;
|
}
|
.f_type{
|
position: absolute;
|
right: 13%;
|
top:12%;
|
width: 20px;
|
line-height: 100px;
|
font-size: 8vh;
|
margin: 0 auto;
|
}
|
</style>
|