|
@@ -1,7 +1,7 @@
|
|
|
<template>
|
|
<template>
|
|
|
<div>
|
|
<div>
|
|
|
<div class="title_box rx-bc mt6">
|
|
<div class="title_box rx-bc mt6">
|
|
|
- <div class="name">报工信息({{ list.length || 0 }})个 </div>
|
|
|
|
|
|
|
+ <div class="name">报工信息1111({{ list.length || 0 }})个 </div>
|
|
|
|
|
|
|
|
<div class="rx-bc"> </div>
|
|
<div class="rx-bc"> </div>
|
|
|
</div>
|
|
</div>
|
|
@@ -36,6 +36,8 @@
|
|
|
<div class="item ww30"
|
|
<div class="item ww30"
|
|
|
>报工总重量 /{{ row.extInfo.weightUnit }}
|
|
>报工总重量 /{{ row.extInfo.weightUnit }}
|
|
|
</div>
|
|
</div>
|
|
|
|
|
+ <div class="item ww30">设备</div>
|
|
|
|
|
+ <div class="item ww30">炉次号</div>
|
|
|
<div class="item ww30">处置</div>
|
|
<div class="item ww30">处置</div>
|
|
|
<div class="item ww10">操作</div>
|
|
<div class="item ww10">操作</div>
|
|
|
</div>
|
|
</div>
|
|
@@ -69,7 +71,37 @@
|
|
|
@input="blurWeight(it, $index, yyIdx)"
|
|
@input="blurWeight(it, $index, yyIdx)"
|
|
|
></el-input>
|
|
></el-input>
|
|
|
</div>
|
|
</div>
|
|
|
|
|
+<!-- 1 -->
|
|
|
|
|
+ <div class="item ww30">
|
|
|
|
|
+ <el-select
|
|
|
|
|
+ class="content_num"
|
|
|
|
|
+ v-model="it.deviceId"
|
|
|
|
|
+ filterable
|
|
|
|
|
+ placeholder="请选择"
|
|
|
|
|
+ @change="(e) => selectValBatch(e, row, $index, yyIdx)"
|
|
|
|
|
+ size="mini"
|
|
|
|
|
+ :disabled="isDetails"
|
|
|
|
|
+ >
|
|
|
|
|
+ <el-option
|
|
|
|
|
+ v-for="item in deviceList"
|
|
|
|
|
+ :label="item.name"
|
|
|
|
|
+ :value="item.id || item.instanceId"
|
|
|
|
|
+ :key="item.id || item.instanceId"
|
|
|
|
|
+ >
|
|
|
|
|
+ </el-option>
|
|
|
|
|
+ </el-select>
|
|
|
|
|
+ </div>
|
|
|
|
|
|
|
|
|
|
+ <div class="item ww30">
|
|
|
|
|
+ <el-input
|
|
|
|
|
+ size="mini"
|
|
|
|
|
+ class="content_num"
|
|
|
|
|
+ v-model="it.heatNumber"
|
|
|
|
|
+ placeholder="请输入炉次号"
|
|
|
|
|
+ :disabled="isDetails"
|
|
|
|
|
+ />
|
|
|
|
|
+ </div>
|
|
|
|
|
+<!-- 2 -->
|
|
|
<div class="item ww30">
|
|
<div class="item ww30">
|
|
|
<el-select
|
|
<el-select
|
|
|
size="mini"
|
|
size="mini"
|
|
@@ -120,6 +152,8 @@
|
|
|
<div class="item ww20"
|
|
<div class="item ww20"
|
|
|
>类型
|
|
>类型
|
|
|
</div>
|
|
</div>
|
|
|
|
|
+ <div class="item ww30">设备</div>
|
|
|
|
|
+ <div class="item ww30">炉次号</div>
|
|
|
<div class="item ww30">处置/原因</div>
|
|
<div class="item ww30">处置/原因</div>
|
|
|
<div class="item ww10">操作</div>
|
|
<div class="item ww10">操作</div>
|
|
|
</div>
|
|
</div>
|
|
@@ -176,7 +210,37 @@
|
|
|
</el-select>
|
|
</el-select>
|
|
|
</div>
|
|
</div>
|
|
|
|
|
|
|
|
|
|
+<!-- 1 -->
|
|
|
|
|
+ <div class="item ww30">
|
|
|
|
|
+ <el-select
|
|
|
|
|
+ class="content_num"
|
|
|
|
|
+ v-model="it.deviceId"
|
|
|
|
|
+ filterable
|
|
|
|
|
+ placeholder="请选择"
|
|
|
|
|
+ @change="(e) => selectValNoBatch(e, row, $index, yyIdx)"
|
|
|
|
|
+ size="mini"
|
|
|
|
|
+ :disabled="isDetails"
|
|
|
|
|
+ >
|
|
|
|
|
+ <el-option
|
|
|
|
|
+ v-for="item in deviceList"
|
|
|
|
|
+ :label="item.name"
|
|
|
|
|
+ :value="item.id || item.instanceId"
|
|
|
|
|
+ :key="item.id || item.instanceId"
|
|
|
|
|
+ >
|
|
|
|
|
+ </el-option>
|
|
|
|
|
+ </el-select>
|
|
|
|
|
+ </div>
|
|
|
|
|
|
|
|
|
|
+ <div class="item ww30">
|
|
|
|
|
+ <el-input
|
|
|
|
|
+ size="mini"
|
|
|
|
|
+ class="content_num"
|
|
|
|
|
+ v-model="it.heatNumber"
|
|
|
|
|
+ placeholder="请输入炉次号"
|
|
|
|
|
+ :disabled="isDetails"
|
|
|
|
|
+ />
|
|
|
|
|
+ </div>
|
|
|
|
|
+<!-- 2 -->
|
|
|
<div class="item ww30" v-if="it.notType != 5">
|
|
<div class="item ww30" v-if="it.notType != 5">
|
|
|
<div v-if="isDetails">{{ it.notReason }}</div>
|
|
<div v-if="isDetails">{{ it.notReason }}</div>
|
|
|
<el-input
|
|
<el-input
|
|
@@ -186,6 +250,7 @@
|
|
|
v-model="it.notReason"
|
|
v-model="it.notReason"
|
|
|
></el-input>
|
|
></el-input>
|
|
|
</div>
|
|
</div>
|
|
|
|
|
+
|
|
|
|
|
|
|
|
<div class="item ww30" v-if="it.notType == 5">
|
|
<div class="item ww30" v-if="it.notType == 5">
|
|
|
<el-select
|
|
<el-select
|
|
@@ -290,7 +355,7 @@
|
|
|
</template>
|
|
</template>
|
|
|
</el-table-column>
|
|
</el-table-column>
|
|
|
|
|
|
|
|
- <el-table-column
|
|
|
|
|
|
|
+ <!-- <el-table-column
|
|
|
v-if="deviceList.length > 0"
|
|
v-if="deviceList.length > 0"
|
|
|
width="140"
|
|
width="140"
|
|
|
label="设备"
|
|
label="设备"
|
|
@@ -314,7 +379,7 @@
|
|
|
>
|
|
>
|
|
|
</el-option>
|
|
</el-option>
|
|
|
</el-select>
|
|
</el-select>
|
|
|
- <!-- {{ row.deviceName || row.extInfo.deviceName }} -->
|
|
|
|
|
|
|
+ {{ row.deviceName || row.extInfo.deviceName }}
|
|
|
</template>
|
|
</template>
|
|
|
</el-table-column>
|
|
</el-table-column>
|
|
|
|
|
|
|
@@ -333,7 +398,7 @@
|
|
|
:disabled="isDetails"
|
|
:disabled="isDetails"
|
|
|
/>
|
|
/>
|
|
|
</template>
|
|
</template>
|
|
|
- </el-table-column>
|
|
|
|
|
|
|
+ </el-table-column> -->
|
|
|
|
|
|
|
|
<el-table-column label="投料数量" width="90" prop="feedQuantity">
|
|
<el-table-column label="投料数量" width="90" prop="feedQuantity">
|
|
|
<template slot-scope="{ row, $index }">
|
|
<template slot-scope="{ row, $index }">
|
|
@@ -395,7 +460,12 @@
|
|
|
deep: true,
|
|
deep: true,
|
|
|
handler(newVal) {
|
|
handler(newVal) {
|
|
|
console.log('cccccc',newVal)
|
|
console.log('cccccc',newVal)
|
|
|
- this.deviceList = newVal;
|
|
|
|
|
|
|
+
|
|
|
|
|
+ //设备下拉框数据来源
|
|
|
|
|
+ let newData=JSON.parse(JSON.stringify(newVal))
|
|
|
|
|
+ // this.deviceList = newData;
|
|
|
|
|
+ this.deviceArr(newData)
|
|
|
|
|
+
|
|
|
this.changeHeatNumber();
|
|
this.changeHeatNumber();
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
@@ -453,22 +523,94 @@
|
|
|
obj.extInfo.heatNumber
|
|
obj.extInfo.heatNumber
|
|
|
);
|
|
);
|
|
|
},
|
|
},
|
|
|
|
|
+ selectValBatch(e, item, idx,bidx){
|
|
|
|
|
+ let obj = this.deviceList.find((f) => f.id||f.instanceId == e);
|
|
|
|
|
+ //设备名称
|
|
|
|
|
+ this.$set(this.list[idx].extInfo.batchReportInfo[bidx],'deviceName',obj.name)
|
|
|
|
|
+ //炉次号
|
|
|
|
|
+ this.$set(this.list[idx].extInfo.batchReportInfo[bidx], 'heatNumber',obj.extInfo.heatNumber)
|
|
|
|
|
+ //设备id
|
|
|
|
|
+ this.$set(this.list[idx].extInfo.batchReportInfo[bidx],'deviceId',obj.id||obj.instanceId)
|
|
|
|
|
+ },
|
|
|
|
|
+ selectValNoBatch(e, item, idx,bidx){
|
|
|
|
|
+ let obj = this.deviceList.find((f) => f.id||f.instanceId == e);
|
|
|
|
|
+ //设备名称
|
|
|
|
|
+ this.$set(this.list[idx].extInfo.notBatchReportInfo[bidx],'deviceName',obj.name)
|
|
|
|
|
+ //炉次号
|
|
|
|
|
+ this.$set(this.list[idx].extInfo.notBatchReportInfo[bidx], 'heatNumber',obj.extInfo.heatNumber)
|
|
|
|
|
+ //设备id
|
|
|
|
|
+ this.$set(this.list[idx].extInfo.notBatchReportInfo[bidx],'deviceId',obj.id||obj.instanceId)
|
|
|
|
|
+ },
|
|
|
|
|
+
|
|
|
|
|
+ deviceArr(data){
|
|
|
|
|
+ data.forEach((o,i) => {
|
|
|
|
|
+ o.id=o.id ? o.id.toString()+'/'+i : '';
|
|
|
|
|
+ o.instanceId=o.instanceId ? o.instanceId.toString()+'/'+i : '';
|
|
|
|
|
+ })
|
|
|
|
|
+
|
|
|
|
|
+ this.deviceList = data;
|
|
|
|
|
+ if (this.deviceList.length > 0) {
|
|
|
|
|
+ this.list.forEach((o,index) => {
|
|
|
|
|
+
|
|
|
|
|
+ //合格分批设备炉次号
|
|
|
|
|
+ o.extInfo.batchReportInfo.map((report,ridx)=>{
|
|
|
|
|
+ this.$set(this.list[index].extInfo.batchReportInfo[ridx],'deviceName',this.deviceList[0].name)
|
|
|
|
|
+ this.$set(this.list[index].extInfo.batchReportInfo[ridx],'deviceId',this.deviceList[0].id||this.deviceList[0].instanceId)
|
|
|
|
|
+ })
|
|
|
|
|
+ o.extInfo.notBatchReportInfo.map((noReport,noidx)=>{
|
|
|
|
|
+ this.$set(this.list[index].extInfo.notBatchReportInfo[noidx],'deviceName',this.deviceList[0].name)
|
|
|
|
|
+ this.$set(this.list[index].extInfo.notBatchReportInfo[noidx],'deviceId',this.deviceList[0].id||this.deviceList[0].instanceId)
|
|
|
|
|
+ })
|
|
|
|
|
+ //合格分批设备炉次号
|
|
|
|
|
+ this.$forceUpdate();
|
|
|
|
|
+
|
|
|
|
|
+ })
|
|
|
|
|
+ }
|
|
|
|
|
+ },
|
|
|
|
|
|
|
|
changeHeatNumber() {
|
|
changeHeatNumber() {
|
|
|
this.deviceList.forEach((f) => {
|
|
this.deviceList.forEach((f) => {
|
|
|
this.list.forEach((o,index) => {
|
|
this.list.forEach((o,index) => {
|
|
|
|
|
+ // o.deviceId &&
|
|
|
|
|
+ // f.instanceId == o.deviceId &&
|
|
|
if (
|
|
if (
|
|
|
- o.deviceId &&
|
|
|
|
|
- f.instanceId == o.deviceId &&
|
|
|
|
|
this.deviceList.length > 1
|
|
this.deviceList.length > 1
|
|
|
) {
|
|
) {
|
|
|
// o.extInfo.heatNumber = f.extInfo.heatNumber;
|
|
// o.extInfo.heatNumber = f.extInfo.heatNumber;
|
|
|
this.$set(this.list[index].extInfo,'heatNumber',f.extInfo.heatNumber)
|
|
this.$set(this.list[index].extInfo,'heatNumber',f.extInfo.heatNumber)
|
|
|
|
|
+
|
|
|
|
|
+ //合格分批设备炉次号
|
|
|
|
|
+ o.extInfo.batchReportInfo.map((report,ridx)=>{
|
|
|
|
|
+ if(report.deviceId==f.instanceId){
|
|
|
|
|
+ this.$set(this.list[index].extInfo.batchReportInfo[ridx],'heatNumber',f.extInfo.heatNumber)
|
|
|
|
|
+ }
|
|
|
|
|
+ })
|
|
|
|
|
+ o.extInfo.notBatchReportInfo.map((noReport,noidx)=>{
|
|
|
|
|
+ if(noReport.deviceId==f.instanceId){
|
|
|
|
|
+ this.$set(this.list[index].extInfo.notBatchReportInfo[noidx],'heatNumber',f.extInfo.heatNumber)
|
|
|
|
|
+ }
|
|
|
|
|
+ })
|
|
|
|
|
+ //合格分批设备炉次号
|
|
|
this.$forceUpdate();
|
|
this.$forceUpdate();
|
|
|
|
|
+
|
|
|
} else if (this.deviceList.length == 1) {
|
|
} else if (this.deviceList.length == 1) {
|
|
|
o['deviceId'] = this.deviceList[0].id;
|
|
o['deviceId'] = this.deviceList[0].id;
|
|
|
// o.extInfo.heatNumber = this.deviceList[0].extInfo.heatNumber;
|
|
// o.extInfo.heatNumber = this.deviceList[0].extInfo.heatNumber;
|
|
|
this.$set(this.list[index].extInfo,'heatNumber',this.deviceList[0].extInfo.heatNumber)
|
|
this.$set(this.list[index].extInfo,'heatNumber',this.deviceList[0].extInfo.heatNumber)
|
|
|
|
|
+
|
|
|
|
|
+ //合格分批设备炉次号
|
|
|
|
|
+ o.extInfo.batchReportInfo.map((report,ridx)=>{
|
|
|
|
|
+ this.$set(this.list[index].extInfo.batchReportInfo[ridx],'deviceId',this.deviceList[0].id)
|
|
|
|
|
+ this.$set(this.list[index].extInfo.batchReportInfo[ridx],'heatNumber',this.deviceList[0].extInfo.heatNumber)
|
|
|
|
|
+ this.$set(this.list[index].extInfo.batchReportInfo[ridx],'deviceName',this.deviceList[0].extInfo.name)
|
|
|
|
|
+ })
|
|
|
|
|
+ //合格分批设备炉次号
|
|
|
|
|
+ o.extInfo.notBatchReportInfo.map((noReport,noidx)=>{
|
|
|
|
|
+ this.$set(this.list[index].extInfo.notBatchReportInfo[noidx],'deviceId',this.deviceList[0].id)
|
|
|
|
|
+ this.$set(this.list[index].extInfo.notBatchReportInfo[noidx],'heatNumber',this.deviceList[0].extInfo.heatNumber)
|
|
|
|
|
+ this.$set(this.list[index].extInfo.notBatchReportInfo[noidx],'deviceName',this.deviceList[0].extInfo.name)
|
|
|
|
|
+ })
|
|
|
|
|
+
|
|
|
this.$forceUpdate();
|
|
this.$forceUpdate();
|
|
|
}
|
|
}
|
|
|
});
|
|
});
|
|
@@ -480,11 +622,18 @@
|
|
|
},
|
|
},
|
|
|
|
|
|
|
|
handAddListPL(idx) {
|
|
handAddListPL(idx) {
|
|
|
|
|
+ let deviceid=''
|
|
|
|
|
+ if(this.deviceList.length>0){
|
|
|
|
|
+ deviceid=this.deviceList[0].id||this.deviceList[0].instanceId
|
|
|
|
|
+ }
|
|
|
this.list[idx].extInfo.batchReportInfo.push({
|
|
this.list[idx].extInfo.batchReportInfo.push({
|
|
|
allFeedQuantity: '',
|
|
allFeedQuantity: '',
|
|
|
allReportWeight: '',
|
|
allReportWeight: '',
|
|
|
taskId: '',
|
|
taskId: '',
|
|
|
- taskName: ''
|
|
|
|
|
|
|
+ taskName: '',
|
|
|
|
|
+ deviceId: deviceid?deviceid:'',
|
|
|
|
|
+ deviceName:this.deviceList.length>0?this.deviceList[0].deviceName:'',
|
|
|
|
|
+ heatNumber: this.deviceList.length>0?this.deviceList[0].extInfo.heatNumber:'',
|
|
|
});
|
|
});
|
|
|
},
|
|
},
|
|
|
|
|
|
|
@@ -594,12 +743,19 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
handAddListPL4(idx) {
|
|
handAddListPL4(idx) {
|
|
|
|
|
+ let deviceid=''
|
|
|
|
|
+ if(this.deviceList.length>0){
|
|
|
|
|
+ deviceid=this.deviceList[0].id||this.deviceList[0].instanceId
|
|
|
|
|
+ }
|
|
|
this.list[idx].extInfo.notBatchReportInfo.push({
|
|
this.list[idx].extInfo.notBatchReportInfo.push({
|
|
|
allFeedQuantity: '',
|
|
allFeedQuantity: '',
|
|
|
notType: '',
|
|
notType: '',
|
|
|
taskId: '',
|
|
taskId: '',
|
|
|
taskName: '',
|
|
taskName: '',
|
|
|
- notReason: ''
|
|
|
|
|
|
|
+ notReason: '',
|
|
|
|
|
+ deviceId: deviceid?deviceid:'',
|
|
|
|
|
+ deviceName:this.deviceList.length>0?this.deviceList[0].deviceName:'',
|
|
|
|
|
+ heatNumber: this.deviceList.length>0?this.deviceList[0].extInfo.heatNumber:''
|
|
|
});
|
|
});
|
|
|
this.$forceUpdate();
|
|
this.$forceUpdate();
|
|
|
|
|
|