|
|
@@ -59,11 +59,11 @@
|
|
|
<el-table-column label="重量单位" prop="weightUnit" align="center" width="80" fixed="right" :show-overflow-tooltip="true"></el-table-column>
|
|
|
<el-table-column label="处置状态" prop="disposalStatus" align="center" width="80" fixed="right" :show-overflow-tooltip="true">
|
|
|
<template slot-scope="scope">
|
|
|
- <span v-if="scope.row.disposalStatus == 1 ">返工</span>
|
|
|
- <span v-if="scope.row.disposalStatus == 2 ">返修</span>
|
|
|
+ <span v-if="scope.row.disposalStatus == 1 && form.qualityType == 2">返工</span>
|
|
|
+ <span v-if="scope.row.disposalStatus == 2 && form.qualityType == 2 ">返修</span>
|
|
|
<span v-if="scope.row.disposalStatus == 3 ">报废</span>
|
|
|
- <span v-if="scope.row.disposalStatus == 4 ">降级使用</span>
|
|
|
- <span v-if="scope.row.disposalStatus == 5 ">让步接收</span>
|
|
|
+ <span v-if="scope.row.disposalStatus == 4 && form.qualityType == 2">降级使用</span>
|
|
|
+ <span v-if="scope.row.disposalStatus == 5 && form.qualityType == 2">让步接收</span>
|
|
|
<span v-if="scope.row.disposalStatus == 6 ">留样</span>
|
|
|
<span v-if="scope.row.disposalStatus == 7 ">消耗</span>
|
|
|
<span v-if="scope.row.disposalStatus == 8 ">回用</span>
|
|
|
@@ -93,7 +93,7 @@
|
|
|
@click="handleDetail(scope.$index, scope.row, 'report')">
|
|
|
质检
|
|
|
</el-link>
|
|
|
- <el-link type='primary' :underline="false"> 处置 </el-link>
|
|
|
+ <el-link type='primary' :underline="false" @click="handleDispose(scope.$index, scope.row, 'dispose')"> 处置 </el-link>
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
</el-table>
|
|
|
@@ -125,6 +125,7 @@
|
|
|
</el-card>
|
|
|
|
|
|
<sampleListDialog ref="detailRef" @handleConfirm="handleConfirm"></sampleListDialog>
|
|
|
+ <sampleDisposeDialog ref="disposeRef" @handleDisposeConfirm="handleDisposeConfirm"></sampleDisposeDialog>
|
|
|
</div>
|
|
|
</template>
|
|
|
|
|
|
@@ -138,13 +139,15 @@ import dictMixins from '@/mixins/dictMixins';
|
|
|
|
|
|
// import term from './term';
|
|
|
import sampleListDialog from './components/sampleListDialog.vue';
|
|
|
+import sampleDisposeDialog from './components/sampleDisposeDialog.vue';
|
|
|
|
|
|
import { finishPageTab } from '@/utils/page-tab-util';
|
|
|
export default {
|
|
|
components: {
|
|
|
baseInfo,
|
|
|
// term
|
|
|
- sampleListDialog
|
|
|
+ sampleListDialog,
|
|
|
+ sampleDisposeDialog
|
|
|
},
|
|
|
mixins: [dictMixins],
|
|
|
|
|
|
@@ -439,7 +442,6 @@ export default {
|
|
|
this.$router.go(-1);
|
|
|
},
|
|
|
handleDetail(index, row, type) {
|
|
|
- debugger
|
|
|
if (!this.sampleList[index] || !this.schemeList) {
|
|
|
return;
|
|
|
}
|
|
|
@@ -448,6 +450,15 @@ export default {
|
|
|
console.log(index, row, type, selectedData, 'index, row, type, mergedData')
|
|
|
this.$refs.detailRef.openDia(index, row, type, selectedData,null);
|
|
|
},
|
|
|
+ handleDispose(index, row, type) {
|
|
|
+ if (!this.sampleList[index] ) {
|
|
|
+ return;
|
|
|
+ }
|
|
|
+ // const selectedData = [];
|
|
|
+ // selectedData.push(this.sampleList[index])
|
|
|
+ // console.log(index, row, type, selectedData, 'index, row, type, mergedData')
|
|
|
+ this.$refs.disposeRef.openDispose(index, row, type, null,this.form.qualityType);
|
|
|
+ },
|
|
|
// 报工
|
|
|
handleReporting(index, row) {
|
|
|
this.$refs.baseInfoRefs.$refs.form1.validate((valid) => {
|
|
|
@@ -474,6 +485,14 @@ export default {
|
|
|
});
|
|
|
})
|
|
|
},
|
|
|
+ // 处理确认事件
|
|
|
+ handleDisposeConfirm(list, index) {
|
|
|
+ if (index != null){
|
|
|
+ this.$set(this.sampleList, index, list[0]);
|
|
|
+ }else{
|
|
|
+ this.$set(this.sampleList, null, list);
|
|
|
+ }
|
|
|
+ },
|
|
|
//确认报工
|
|
|
handleConfirm(list, index) {
|
|
|
console.log(list)
|