中航光电PDA端
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

742 lines
44 KiB

<template>
<view class="contentBox">
<!-- 后续生产追溯维护 -->
<uni-forms ref="wrForm" class="formBox" style="width:100%">
<uni-forms-item name="allegation"><input type="text" v-model="twoInput" @input="twoInputBlur"
class="uni-input-border" placeholder="流程卡" /></uni-forms-item>
</uni-forms>
<view class="tableBox">
<t-table style="margin-top:10rpx;width:100%">
<t-tr>
<t-td>
<uni-data-checkbox v-model="line" :localdata="lineList" />
</t-td>
</t-tr>
</t-table>
<view class="cusTableBox" style="margin-bottom: 50rpx;">
<table class="cusTable" cellspacing="0">
<tr>
<td colspan="4" style="min-width:100px">槽位/工步</td>
<td colspan="3" style="min-width:180px">实际参数</td>
<td colspan="4" style="min-width:170px">工艺要求</td>
</tr>
<template v-for="(itemSlot,indexSlot) in preserveSlotList">
<!-- 模板一 -->
<template v-if="itemSlot.rfpsType == 1">
<tr :key="itemSlot.slotName+indexSlot">
<td :rowspan="3" colspan="4">{{ itemSlot.slotName }} </td>
</tr>
<template v-for="(itemChild,indexChild) in itemSlot.childrenList">
<tr :key="itemSlot.slotName+indexSlot+indexChild">
<td v-if="indexChild ==0">{{ itemChild.paramName }}</td>
<td v-if="indexChild ==0" colspan="2">
<uni-datetime-picker type="datetime" v-model="itemChild.rfpdTime" />
</td>
<td v-if="indexChild ==1">{{ itemChild.paramName }} </td>
<td v-if="indexChild ==1" colspan="2">
<uni-datetime-picker type="datetime" v-model="itemChild.rfpdTime" />
</td>
<td colspan="2"> {{ itemChild.detailName }} </td>
<td colspan="2">{{ itemChild.ask }} </td>
</tr>
</template>
</template>
<!-- 模板二 -->
<template v-else-if="itemSlot.rfpsType == 2">
<tr :key="itemSlot.slotName+indexSlot">
<td :rowspan="4" colspan="4"> {{ itemSlot.slotName }}</td>
</tr>
<template v-for="(itemChild,indexChild) in itemSlot.childrenList">
<tr :key="itemSlot.slotName+indexSlot+indexChild">
<td v-if="indexChild ==0">{{ itemChild.paramName }}</td>
<td v-if="indexChild ==0" colspan="2">
<uni-datetime-picker type="datetime" v-model="itemChild.rfpdTime" />
</td>
<td v-if="indexChild ==1">{{ itemChild.paramName }} </td>
<td v-if="indexChild ==1" colspan="2">
<uni-datetime-picker type="datetime" v-model="itemChild.rfpdTime" />
</td>
<td v-if="indexChild ==0" :rowspan="2" colspan="2">{{ itemChild.detailName }}
</td>
<td v-if="indexChild ==0" :rowspan="2" colspan="2">{{ itemChild.ask }}</td>
<td v-if="indexChild > 1" colspan="3">
<input v-model="itemChild.paramValue" placeholder="请输入内容" />
</td>
<td v-if="indexChild > 1" colspan="2"> {{ itemChild.detailName }}</td>
<td v-if="indexChild > 1" colspan="2">{{ itemChild.ask }}</td>
</tr>
</template>
</template>
<!-- 模板三 -->
<template v-else-if="itemSlot.rfpsType == 3">
<tr :key="itemSlot.slotName+indexSlot">
<td :rowspan="5" colspan="4">{{ itemSlot.slotName }} </td>
</tr>
<template v-for="(itemChild,indexChild) in itemSlot.childrenList">
<tr :key="itemSlot.slotName+indexSlot+indexChild">
<td v-if="indexChild == 0">{{ itemChild.paramName }}</td>
<td v-if="indexChild == 0" colspan="2">
<uni-datetime-picker type="datetime" v-model="itemChild.rfpdTime" />
</td>
<td v-if="indexChild == 1">{{ itemChild.paramName }} </td>
<td v-if="indexChild == 1" colspan="2">
<uni-datetime-picker type="datetime" v-model="itemChild.rfpdTime" />
</td>
<td v-if="indexChild == 0" :rowspan="2" colspan="2">{{ itemChild.detailName }}
</td>
<td v-if="indexChild == 0" :rowspan="2" colspan="2">{{ itemChild.ask }} </td>
<td v-if="indexChild > 1" colspan="3">
<input v-model="itemChild.paramValue" placeholder="请输入内容" />
</td>
<td v-if="indexChild > 1" colspan="2">{{ itemChild.detailName }}</td>
<td v-if="indexChild > 1" colspan="2">{{ itemChild.ask }}</td>
</tr>
</template>
</template>
<!-- 模板四 -->
<template v-else-if="itemSlot.rfpsType == 4">
<tr :key="itemSlot.slotName+indexSlot">
<td :rowspan="4" colspan="4">{{ itemSlot.slotName }} </td>
</tr>
<template v-for="(itemChild,indexChild) in itemSlot.childrenList">
<tr :key="itemSlot.slotName+indexSlot+indexChild">
<td colspan="3">
<input v-model="itemChild.paramValue" placeholder="请输入内容" />
</td>
<td colspan="2">{{ itemChild.detailName }}</td>
<td colspan="2">{{ itemChild.ask }} </td>
</tr>
</template>
</template>
<!-- 模板五 -->
<template v-else-if="itemSlot.rfpsType == 5">
<tr :key="itemSlot.slotName+indexSlot">
<td :rowspan="6" colspan="4">{{ itemSlot.slotName }} </td>
</tr>
<template v-for="(itemChild,indexChild) in itemSlot.childrenList">
<tr v-if="indexChild == 0" :key="itemSlot.slotName+indexSlot+indexChild">
<td colspan="3">
<input v-model="itemChild.paramValue" placeholder="请输入内容" />
</td>
<td colspan="2">{{ itemChild.detailName }}</td>
<td colspan="2">{{ itemChild.ask }}</td>
</tr>
<tr v-else :key="itemSlot.slotName+indexSlot+indexChild">
<td colspan="5" v-if="indexChild == 1" style="min-width: 180px;">
<input v-model="itemChild.paramValue"
@input="oneInputBlur($event,itemChild,itemSlot)" placeholder="请扫描物料条码" />
</td>
<td colspan="5" v-if="indexChild != 1" style="min-width: 180px;">
<input v-model="itemChild.paramValue" />
</td>
<td colspan="2">{{ itemChild.detailName }}</td>
</tr>
</template>
</template>
<!-- 模板六 -->
<template v-else-if="itemSlot.rfpsType == 6">
<tr :key="itemSlot.slotName+indexSlot">
<td :rowspan="7" colspan="4"> {{ itemSlot.slotName }} </td>
</tr>
<template v-for="(itemChild,indexChild) in itemSlot.childrenList">
<tr v-if="indexChild <= 1" :key="itemSlot.slotName+indexSlot+indexChild">
<td colspan="3">
<input v-model="itemChild.paramValue" placeholder="请输入内容" />
</td>
<td colspan="2">{{ itemChild.detailName }}</td>
<td colspan="2">{{ itemChild.ask }}</td>
</tr>
<tr v-else :key="itemSlot.slotName+indexSlot+indexChild">
<td colspan="5" v-if="indexChild == 2">
<input v-model="itemChild.paramValue"
@input="oneInputBlur($event,itemChild,itemSlot)" placeholder="请扫描物料条码" />
</td>
<td colspan="5" v-else>{{itemChild.paramValue}}</td>
<td colspan="2">{{ itemChild.detailName }}</td>
</tr>
</template>
</template>
<!-- 模板七 -->
<template v-else-if="itemSlot.rfpsType == 7">
<tr :key="itemSlot.slotName+indexSlot">
<td colspan="4"> {{ itemSlot.slotName }} </td>
<td colspan="3">
<input v-model="itemSlot.childrenList[0].paramValue" placeholder="请输入内容" />
</td>
<td colspan="2">{{ itemSlot.childrenList[0].detailName }}</td>
<td colspan="2">{{ itemSlot.childrenList[0].ask }}</td>
</tr>
</template>
<!-- 模板八 -->
<template v-else-if="itemSlot.rfpsType == 8">
<tr :key="itemSlot.slotName+indexSlot">
<td :rowspan="3" colspan="4">{{ itemSlot.slotName }}</td>
</tr>
<template v-for="(itemChild,indexChild) in itemSlot.childrenList">
<tr :key="itemSlot.slotName+indexSlot+indexChild">
<td colspan="3">
<input v-model="itemChild.paramValue" placeholder="请输入内容" />
</td>
<td colspan="2">{{ itemChild.detailName }}</td>
<td colspan="2">{{ itemChild.ask }}</td>
</tr>
</template>
</template>
<!-- 模板九 -->
<template v-else-if="itemSlot.rfpsType == 9">
<tr :key="itemSlot.slotName+indexSlot">
<td :rowspan="6" colspan="4">{{ itemSlot.slotName }}</td>
</tr>
<template v-for="(itemChild,indexChild) in itemSlot.childrenList">
<tr v-if="indexChild <=1" :key="itemSlot.slotName+indexSlot+indexChild">
<td v-if="indexChild ==0">{{ itemChild.paramName }}</td>
<td v-if="indexChild ==0" colspan="2">
<uni-datetime-picker type="datetime" v-model="itemChild.rfpdTime" />
</td>
<td v-if="indexChild ==1">{{ itemChild.paramName }}</td>
<td v-if="indexChild ==1" colspan="2">
<uni-datetime-picker type="datetime" v-model="itemChild.rfpdTime" />
</td>
<td v-if="indexChild ==0" :rowspan="2" colspan="2">{{ itemChild.detailName }}
</td>
<td v-if="indexChild ==0" :rowspan="2" colspan="2">{{ itemChild.ask }}</td>
</tr>
<tr v-else :key="itemSlot.slotName+indexSlot+indexChild">
<td colspan="3">
<input v-model="itemChild.paramValue" placeholder="请输入内容" />
</td>
<td colspan="2">{{ itemChild.detailName }}</td>
<td colspan="2">{{ itemChild.ask }}</td>
</tr>
</template>
</template>
<!-- 模板十 -->
<template v-else-if="itemSlot.rfpsType == 10">
<template v-for="(itemChild,indexChild) in itemSlot.childrenList">
<tr :key="itemSlot.slotName+indexSlot+indexChild">
<td colspan="4">{{ itemSlot.slotName }}</td>
<td colspan="3">
<switch checked style="transform:scale(0.7)"
@change="slotSwitchChange($event,itemChild)" />
</td>
<td colspan="2">{{ itemChild.detailName }}</td>
<td colspan="2">{{ itemChild.ask }}</td>
</tr>
</template>
</template>
<!-- 模板十一 -->
<template v-else-if="itemSlot.rfpsType == 11">
<tr :key="itemSlot.slotName+indexSlot">
<td :rowspan="5" colspan="4">{{ itemSlot.slotName }}</td>
</tr>
<template v-for="(itemChild,indexChild) in itemSlot.childrenList">
<tr v-if="indexChild <=1" :key="itemSlot.slotName+indexSlot+indexChild">
<td v-if="indexChild ==0">{{ itemChild.paramName }}</td>
<td v-if="indexChild ==0" colspan="2">
<uni-datetime-picker type="datetime" v-model="itemChild.rfpdTime" />
</td>
<td v-if="indexChild ==1">{{ itemChild.paramName }}</td>
<td v-if="indexChild ==1" colspan="2">
<uni-datetime-picker type="datetime" v-model="itemChild.rfpdTime" />
</td>
<td v-if="indexChild ==0" :rowspan="2" colspan="2">{{ itemChild.detailName }}
</td>
<td v-if="indexChild ==0" :rowspan="2" colspan="2">{{ itemChild.ask }}</td>
</tr>
<tr v-else-if="indexChild==2" :key="itemSlot.slotName+indexSlot+indexChild">
<td colspan="3">
<input v-model="itemChild.paramValue" placeholder="请输入内容" />
</td>
<td colspan="2">{{ itemChild.detailName }}</td>
<td colspan="2">{{ itemChild.ask }}</td>
</tr>
<tr v-else-if="indexChild==3" :key="itemSlot.slotName+indexSlot+indexChild">
<td colspan="3">
<input v-model="itemChild.paramValue" placeholder="请输入内容" />
</td>
<td colspan="4">{{ itemChild.detailName }}</td>
</tr>
</template>
</template>
<!-- 模板十二 -->
<template v-else-if="itemSlot.rfpsType == 12">
<tr :key="itemSlot.slotName+indexSlot">
<td :rowspan="4" colspan="4">{{ itemSlot.slotName }}</td>
</tr>
<template v-for="(itemChild,indexChild) in itemSlot.childrenList">
<tr :key="itemSlot.slotName+indexSlot+indexChild">
<td>{{ itemChild.paramName }}</td>
<td colspan="2">
<uni-datetime-picker type="datetime" v-model="itemChild.rfpdTime" />
</td>
<td v-if="indexChild ==0" :rowspan="3" colspan="2">{{ itemChild.detailName }}
</td>
<td v-if="indexChild ==0" :rowspan="3" colspan="2">{{ itemChild.ask }}</td>
</tr>
</template>
</template>
<!-- 模板十三 -->
<template v-else-if="itemSlot.rfpsType == 13">
<tr :key="itemSlot.slotName+indexSlot">
<td :rowspan="11" colspan="4">{{ itemSlot.slotName }}</td>
</tr>
<template v-for="(itemChild,indexChild) in itemSlot.childrenList">
<tr :key="itemSlot.slotName+indexSlot+indexChild">
<td colspan="5" v-if="indexChild == 0">
<input v-model="itemChild.paramValue"
@input="oneInputBlur($event,itemChild,itemSlot)" placeholder="请扫描物料条码" />
</td>
<td colspan="5" v-else-if="0<indexChild && indexChild<4">
{{itemChild.paramValue}}
</td>
<td colspan="5" v-else-if="indexChild >= 4">
<input v-model="itemChild.paramValue" placeholder="请输入内容" />
</td>
<td colspan="2">{{ itemChild.detailName }}</td>
</tr>
</template>
</template>
<!-- 模板十四 -->
<template v-else-if="itemSlot.rfpsType == 14">
<tr :key="itemSlot.slotName+indexSlot">
<td :rowspan="13" colspan="4">{{ itemSlot.slotName }}</td>
</tr>
<template v-for="(itemChild,indexChild) in itemSlot.childrenList">
<tr v-if="indexChild <=1" :key="itemSlot.slotName+indexSlot+indexChild">
<td v-if="indexChild ==0">{{ itemChild.paramName }}</td>
<td v-if="indexChild ==0" colspan="2">
<uni-datetime-picker type="datetime" v-model="itemChild.rfpdTime" />
</td>
<td v-if="indexChild ==1">{{ itemChild.paramName }}</td>
<td v-if="indexChild ==1" colspan="2">
<uni-datetime-picker type="datetime" v-model="itemChild.rfpdTime" />
</td>
<td v-if="indexChild ==0" :rowspan="2" colspan="2">{{ itemChild.detailName }}
</td>
<td v-if="indexChild ==0" :rowspan="2" colspan="2">{{ itemChild.ask }}</td>
</tr>
<tr v-else-if="indexChild == 2" :key="itemSlot.slotName+indexSlot+indexChild">
<td colspan="3">
<input v-model="itemChild.paramValue" placeholder="请输入内容" />
</td>
<td colspan="2">{{ itemChild.detailName }}</td>
<td colspan="2">{{ itemChild.ask }}</td>
</tr>
<tr v-else-if="indexChild == 3" :key="itemSlot.slotName+indexSlot+indexChild">
<td>{{ itemChild.paramName }}</td>
<td colspan="2">
<uni-datetime-picker type="datetime" v-model="itemChild.rfpdTime" />
</td>
<td colspan="2">{{ itemChild.detailName }}</td>
<td colspan="2">{{ itemChild.ask }}</td>
</tr>
<tr v-else :key="itemSlot.slotName+indexSlot+indexChild">
<td colspan="5" v-if="indexChild == 4 || indexChild == 8">
<input v-model="itemChild.paramValue"
@input="oneInputBlur($event,itemChild,itemSlot)" placeholder="请扫描物料条码" />
</td>
<td colspan="5" v-else>{{itemChild.paramValue}}</td>
<td colspan="2">{{ itemChild.detailName }}</td>
</tr>
</template>
</template>
<!-- 模板十五 -->
<template v-else-if="itemSlot.rfpsType == 15">
<tr :key="itemSlot.slotName+indexSlot">
<td :rowspan="15" colspan="4">{{ itemSlot.slotName }}</td>
</tr>
<template v-for="(itemChild,indexChild) in itemSlot.childrenList">
<tr v-if="indexChild <=1" :key="itemSlot.slotName+indexSlot+indexChild">
<td v-if="indexChild ==0">{{ itemChild.paramName }}</td>
<td v-if="indexChild ==0" colspan="2">
<uni-datetime-picker type="datetime" v-model="itemChild.rfpdTime" />
</td>
<td v-if="indexChild ==1">{{ itemChild.paramName }}</td>
<td v-if="indexChild ==1" colspan="2">
<uni-datetime-picker type="datetime" v-model="itemChild.rfpdTime" />
</td>
<td v-if="indexChild ==0" :rowspan="2" colspan="2">{{ itemChild.detailName }}
</td>
<td v-if="indexChild ==0" :rowspan="2" colspan="2">{{ itemChild.ask }}</td>
</tr>
<tr v-else-if="indexChild == 2" :key="itemSlot.slotName+indexSlot+indexChild">
<td colspan="3">
<input v-model="itemChild.paramValue" placeholder="请输入内容" />
</td>
<td colspan="2">{{ itemChild.detailName }}</td>
<td colspan="2">{{ itemChild.ask }}</td>
</tr>
<tr v-else-if="indexChild == 3 || indexChild == 4"
:key="itemSlot.slotName+indexSlot+indexChild">
<td :colspan="3">
<input v-model="itemChild.paramValue" placeholder="请输入内容" />
</td>
<td v-if="indexChild == 3" :rowspan="2" colspan="2">{{ itemChild.detailName }}
</td>
<td v-if="indexChild == 3" :rowspan="2" colspan="2">{{ itemChild.ask }}</td>
</tr>
<tr v-else-if="indexChild == 5" :key="itemSlot.slotName+indexSlot+indexChild">
<td>{{ itemChild.paramName }}</td>
<td colspan="2">
<uni-datetime-picker type="datetime" v-model="itemChild.rfpdTime" />
</td>
<td colspan="2">{{ itemChild.detailName }}</td>
<td colspan="2">{{ itemChild.ask }}</td>
</tr>
<tr v-else :key="itemSlot.slotName+indexSlot+indexChild">
<td colspan="5" v-if="indexChild == 6 || indexChild == 10">
<input v-model="itemChild.paramValue"
@input="oneInputBlur($event,itemChild,itemSlot)" placeholder="请扫描物料条码" />
</td>
<td colspan="5" v-else>{{itemChild.paramValue}}</td>
<td colspan="2">{{ itemChild.detailName }}</td>
</tr>
</template>
</template>
<!-- 模板十六 -->
<template v-else-if="itemSlot.rfpsType == 16">
<tr :key="itemSlot.slotName+indexSlot">
<td :rowspan="17" colspan="4">{{ itemSlot.slotName }}</td>
</tr>
<template v-for="(itemChild,indexChild) in itemSlot.childrenList">
<tr v-if="indexChild <=1" :key="itemSlot.slotName+indexSlot+indexChild">
<td v-if="indexChild ==0">{{ itemChild.paramName }}</td>
<td v-if="indexChild ==0" colspan="2">
<uni-datetime-picker type="datetime" v-model="itemChild.rfpdTime" />
</td>
<td v-if="indexChild ==1">{{ itemChild.paramName }}</td>
<td v-if="indexChild ==1" colspan="2">
<uni-datetime-picker type="datetime" v-model="itemChild.rfpdTime" />
</td>
<td v-if="indexChild ==0" :rowspan="2" colspan="2">{{ itemChild.detailName }}
</td>
<td v-if="indexChild ==0" :rowspan="2" colspan="2">{{ itemChild.ask }}</td>
</tr>
<tr v-else-if="indexChild == 2" :key="itemSlot.slotName+indexSlot+indexChild">
<td colspan="3">
<input v-model="itemChild.paramValue" placeholder="请输入内容" />
</td>
<td colspan="2">{{ itemChild.detailName }}</td>
<td colspan="2">{{ itemChild.ask }}</td>
</tr>
<tr v-else-if="indexChild == 3" :key="itemSlot.slotName+indexSlot+indexChild">
<td>{{ itemChild.paramName }}</td>
<td colspan="2">
<uni-datetime-picker type="datetime" v-model="itemChild.rfpdTime" />
</td>
<td colspan="2">{{ itemChild.detailName }}</td>
<td colspan="2">{{ itemChild.ask }}</td>
</tr>
<tr v-else :key="itemSlot.slotName+indexSlot+indexChild">
<td colspan="5" v-if="indexChild == 4 || indexChild == 8|| indexChild == 12">
<input v-model="itemChild.paramValue"
@input="oneInputBlur($event,itemChild,itemSlot)" placeholder="请扫描物料条码" />
</td>
<td colspan="5" v-else>{{itemChild.paramValue}}</td>
<td colspan="2">{{ itemChild.detailName }}</td>
</tr>
</template>
</template>
<!-- 模板十七 -->
<template v-else-if="itemSlot.rfpsType == 17">
<tr :key="itemSlot.slotName+indexSlot">
<td :rowspan="9" colspan="4">{{ itemSlot.slotName }}</td>
</tr>
<template v-for="(itemChild,indexChild) in itemSlot.childrenList">
<tr v-if="indexChild <=1" :key="itemSlot.slotName+indexSlot+indexChild">
<td v-if="indexChild ==0">{{ itemChild.paramName }}</td>
<td v-if="indexChild ==0" colspan="2">
<uni-datetime-picker type="datetime" v-model="itemChild.rfpdTime" />
</td>
<td v-if="indexChild ==1">{{ itemChild.paramName }}</td>
<td v-if="indexChild ==1" colspan="2">
<uni-datetime-picker type="datetime" v-model="itemChild.rfpdTime" />
</td>
<td v-if="indexChild ==0" :rowspan="2" colspan="2">{{ itemChild.detailName }}
</td>
<td v-if="indexChild ==0" :rowspan="2" colspan="2">{{ itemChild.ask }}</td>
</tr>
<tr v-else-if="indexChild == 2" :key="itemSlot.slotName+indexSlot+indexChild">
<td colspan="3">
<input v-model="itemChild.paramValue" placeholder="请输入内容" />
</td>
<td colspan="2">{{ itemChild.detailName }}</td>
<td colspan="2">{{ itemChild.ask }}</td>
</tr>
<tr v-else-if="indexChild == 3" :key="itemSlot.slotName+indexSlot+indexChild">
<td>{{ itemChild.paramName }}</td>
<td colspan="2">
<uni-datetime-picker type="datetime" v-model="itemChild.rfpdTime" />
</td>
<td colspan="2">{{ itemChild.detailName }}</td>
<td colspan="2">{{ itemChild.ask }}</td>
</tr>
<tr v-else :key="itemSlot.slotName+indexSlot+indexChild">
<td colspan="5" v-if="indexChild == 4">
<input v-model="itemChild.paramValue"
@input="oneInputBlur($event,itemChild,itemSlot)" placeholder="请扫描物料条码" />
</td>
<td colspan="5" v-else>{{itemChild.paramValue}}</td>
<td colspan="2">{{ itemChild.detailName }}</td>
</tr>
</template>
</template>
<!-- 模板十八 -->
<template v-else-if="itemSlot.rfpsType == 18">
<template v-for="(itemChild,indexChild) in itemSlot.childrenList">
<tr :key="itemSlot.slotName+indexSlot+indexChild">
<td colspan="4">{{ itemSlot.slotName }} </td>
<td colspan="5">
<input v-model="itemChild.paramValue" placeholder="请输入内容" />
</td>
<td colspan="2">{{ itemChild.detailName }}</td>
</tr>
</template>
</template>
</template>
</table>
</view>
</view>
<view class="buttonBox"><button class="button" type="primary" :disabled="!(preserveSlotList.length>0)"
@click="submitClick">保存</button></view>
</view>
</template>
<script>
import tTable from '@/components/t-table/t-table.vue';
import tTh from '@/components/t-table/t-th.vue';
import tTr from '@/components/t-table/t-tr.vue';
import tTd from '@/components/t-table/t-td.vue';
import inputBlur from '@/mixin/inputBlur.js';
export default {
mixins: [inputBlur],
components: {
tTable,
tTh,
tTr,
tTd
},
data() {
return {
line: 1,
preserveSlotList: [],
lineList: [{
text: '上线前',
value: 1
}, {
text: '下线后',
value: 0
}],
obj: {}
};
},
onShow() {},
methods: {
oneInputBlur(e, itemChild, itemSlot) {
clearTimeout(this.time)
if (e.detail.value.length == 0) {
return
}
this.time = setTimeout(() => {
this.oneInputData(e.detail.value, itemChild, itemSlot)
}, 1800);
},
oneInputData(code, itemChild, itemSlot) {
this.mterialMessData(code, itemChild, itemSlot)
},
twoInputData(code) {
this.getData(code)
},
mterialMessData(code, itemChild, itemSlot) {
if (!code) return;
this.$ajax.request({
url: 'prMakeRec/getMaterialMess',
method: 'POST',
data: {
goodsCode: code
},
success: data => {
console.log(data);
if (coGoods) {
const {
goodsName,
checkoutCode,
releasenoTime
} = data.coGoods;
if (itemSlot.rfpsType == 5) { // 模板六
itemSlot.childrenList[1].paramValue = code;
itemSlot.childrenList[2].paramValue = goodsName;
itemSlot.childrenList[3].paramValue = checkoutCode;
itemSlot.childrenList[4].paramValue = releasenoTime;
} else if (itemSlot.rfpsType == 6) { // 模板六
itemSlot.childrenList[2].paramValue = code;
itemSlot.childrenList[3].paramValue = goodsName;
itemSlot.childrenList[4].paramValue = checkoutCode;
itemSlot.childrenList[5].paramValue = releasenoTime;
} else if (itemSlot.rfpsType == 13) { // 模板十三
itemSlot.childrenList[0].paramValue = code;
itemSlot.childrenList[1].paramValue = goodsName;
itemSlot.childrenList[2].paramValue = checkoutCode;
itemSlot.childrenList[3].paramValue = releasenoTime;
} else if (itemSlot.rfpsType == 14) { // 模板十四
if (itemChild.detailIndex == 5) {
itemSlot.childrenList[4].paramValue = code;
itemSlot.childrenList[5].paramValue = goodsName;
itemSlot.childrenList[6].paramValue = checkoutCode;
itemSlot.childrenList[7].paramValue = releasenoTime;
} else if (itemChild.detailIndex == 9) {
itemSlot.childrenList[8].paramValue = code;
itemSlot.childrenList[9].paramValue = goodsName;
itemSlot.childrenList[10].paramValue = checkoutCode;
itemSlot.childrenList[11].paramValue = releasenoTime;
}
} else if (itemSlot.rfpsType == 15) { // 模板十五
if (itemChild.detailIndex == 7) {
itemSlot.childrenList[6].paramValue = code;
itemSlot.childrenList[7].paramValue = goodsName;
itemSlot.childrenList[8].paramValue = checkoutCode;
itemSlot.childrenList[9].paramValue = releasenoTime;
} else if (itemChild.detailIndex == 11) {
itemSlot.childrenList[10].paramValue = code;
itemSlot.childrenList[11].paramValue = goodsName;
itemSlot.childrenList[12].paramValue = checkoutCode;
itemSlot.childrenList[13].paramValue = releasenoTime;
}
} else if (itemSlot.rfpsType == 16) { // 模板十六
if (itemChild.detailIndex == 5) {
itemSlot.childrenList[4].paramValue = code;
itemSlot.childrenList[5].paramValue = goodsName;
itemSlot.childrenList[6].paramValue = checkoutCode;
itemSlot.childrenList[7].paramValue = releasenoTime;
} else if (itemChild.detailIndex == 9) {
itemSlot.childrenList[8].paramValue = code;
itemSlot.childrenList[9].paramValue = goodsName;
itemSlot.childrenList[10].paramValue = checkoutCode;
itemSlot.childrenList[11].paramValue = releasenoTime;
} else if (itemChild.detailIndex == 13) {
itemSlot.childrenList[12].paramValue = code;
itemSlot.childrenList[13].paramValue = goodsName;
itemSlot.childrenList[14].paramValue = checkoutCode;
itemSlot.childrenList[15].paramValue = releasenoTime;
}
} else if (itemSlot.rfpsType == 17) { // 模板十七
itemSlot.childrenList[4].paramValue = code;
itemSlot.childrenList[5].paramValue = goodsName;
itemSlot.childrenList[6].paramValue = checkoutCode;
itemSlot.childrenList[7].paramValue = releasenoTime;
}
}
uni.showToast({
title: '数据获取成功'
});
}
});
},
getData(code) {
if (!code) return;
this.twoInput = code;
this.$ajax.request({
url: 'pdaLoad/remarryRedeemRetrospectDefend',
method: 'POST',
data: {
cardNo: this.twoInput,
line: this.line
},
success: data => {
this.twoInput = '';
this.preserveSlotList = data.dsRbFilePreserveSlotList;
this.obj = data;
}
});
},
submitClick() {
let line = this.line == 1 ? true : false
this.$ajax.request({
url: 'prMakeRec/remarryRedeemSaveRetrospectDefend',
data: {
line,
mtuId: this.obj.mtuId,
preserveSlotList: this.preserveSlotList,
},
method: 'POST',
success: data => {
this.line = 1
this.preserveSlotList = []
uni.showToast({
title: '维护成功'
});
this.twoInput = '';
}
});
},
switchChange: function(e) {
this.line = e.detail.value
},
slotSwitchChange(e, itemChild) {
itemChild.qualified = e.detail.value
},
}
};
</script>
<style scoped lang="scss">
.contentBox {
position: relative;
height: 88vh;
.formBox {
position: absolute;
height: 10vh;
}
.tableBox {
position: absolute;
top: 10vh;
height: 76vh;
width: 100%;
overflow: auto;
.cusTableBox {
width: 100%;
overflow-x: auto;
.cusTable {
tr {
page-break-inside: avoid;
}
td {
height: 30px;
border: 1px solid #000;
background: transparent;
color: #000;
font-size: 14px;
text-align: center;
padding: 0;
margin: 0;
// ::v-deep .input__inner {
// text-align: center;
// height: 26px !important;
// width: 80% !important;
// }
}
}
}
}
.buttonBox {
position: fixed;
bottom: 0.5vh;
left: 50%;
transform: translate(-50%);
}
}
</style>