|
|
|
@ -121,18 +121,6 @@
|
|
|
|
|
></el-switch>
|
|
|
|
|
</template>
|
|
|
|
|
</el-table-column>
|
|
|
|
|
<el-table-column label="更新" align="center" class-name="small-padding fixed-width" >
|
|
|
|
|
<template slot-scope="scope">
|
|
|
|
|
<el-button
|
|
|
|
|
v-if="scope.row.weight === '1'"
|
|
|
|
|
size="mini"
|
|
|
|
|
type="text"
|
|
|
|
|
icon="el-icon-refresh"
|
|
|
|
|
@click="getList"
|
|
|
|
|
v-hasPermi="['quality:qcIncome:edit']"
|
|
|
|
|
>更新</el-button>
|
|
|
|
|
</template>
|
|
|
|
|
</el-table-column>
|
|
|
|
|
</el-table>
|
|
|
|
|
|
|
|
|
|
<pagination
|
|
|
|
@ -167,6 +155,7 @@
|
|
|
|
|
<el-form-item>
|
|
|
|
|
<el-button type="primary" @click="submitForm('dynamicValidateForm')">提交</el-button>
|
|
|
|
|
<el-button @click="addDomain">新增测量值</el-button>
|
|
|
|
|
<el-button v-if="this.weight === '1'" type="primary" icon="el-icon-refresh" @click="handleWeightValue">自动获取</el-button>
|
|
|
|
|
<el-button @click="resetForm('dynamicValidateForm')">重置</el-button>
|
|
|
|
|
</el-form-item>
|
|
|
|
|
</el-form>
|
|
|
|
@ -195,7 +184,7 @@
|
|
|
|
|
</template>
|
|
|
|
|
<script>
|
|
|
|
|
|
|
|
|
|
import { getCkeckProjectList,changeCheckDetailStatus,commitActualValue,commitCheckResult,getDefectList} from "@/api/quality/income";
|
|
|
|
|
import { getCkeckProjectList,changeCheckDetailStatus,commitActualValue,commitCheckResult,getDefectList,getWeightValue} from "@/api/quality/income";
|
|
|
|
|
import { getDefectValue, commitDefectValue, updateDefectValue} from "@/api/quality/checkTaskDefect";
|
|
|
|
|
export default {
|
|
|
|
|
name: "itemSelectUser",
|
|
|
|
@ -245,6 +234,7 @@ export default {
|
|
|
|
|
valueOpen: false,
|
|
|
|
|
//检测详情的id
|
|
|
|
|
recordId:'',
|
|
|
|
|
weight: null,
|
|
|
|
|
//检测详情的belongTo
|
|
|
|
|
belongTo:'',
|
|
|
|
|
//检测类型
|
|
|
|
@ -417,7 +407,19 @@ export default {
|
|
|
|
|
handleShowValue(row) {
|
|
|
|
|
this.valueOpen = true;
|
|
|
|
|
this.recordId = row.recordId;
|
|
|
|
|
},
|
|
|
|
|
this.weight = row.weight;
|
|
|
|
|
const actualValue = row.actualValue;
|
|
|
|
|
if(actualValue !== null || actualValue !== ''){
|
|
|
|
|
this.dynamicValidateForm.domains = [];
|
|
|
|
|
let values = actualValue.split(",");
|
|
|
|
|
values.forEach((item,index) => {
|
|
|
|
|
this.dynamicValidateForm.domains.push({
|
|
|
|
|
value: item,
|
|
|
|
|
key: Date.now() + index
|
|
|
|
|
});
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
/** 不良类型弹窗 */
|
|
|
|
|
handleDefectType(row) {
|
|
|
|
|
this.defectForm.defectItems.forEach(item => {
|
|
|
|
@ -520,6 +522,29 @@ export default {
|
|
|
|
|
// 重置 defectForm.defectItems 为初始状态或清空 noOkQuality
|
|
|
|
|
this.defectForm.defectItems.forEach(item => (item.noOkQuality = 0));
|
|
|
|
|
},
|
|
|
|
|
handleWeightValue() {
|
|
|
|
|
const recordId = this.recordId;
|
|
|
|
|
getWeightValue(recordId).then(response => {
|
|
|
|
|
if(response.code === 200) {
|
|
|
|
|
let value = response.msg;
|
|
|
|
|
if(value !== null || value !== ''){
|
|
|
|
|
let arr = value.split(",");
|
|
|
|
|
console.log(arr);
|
|
|
|
|
arr.forEach((item,index)=> {
|
|
|
|
|
this.dynamicValidateForm.domains.push({
|
|
|
|
|
value: item,
|
|
|
|
|
key: Date.now() + index
|
|
|
|
|
});
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
console.log(this.dynamicValidateForm.domains);
|
|
|
|
|
}else {
|
|
|
|
|
this.$modal.msgError(response.msg);
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
};
|
|
|
|
|