生产过程检验ABC不良品的动态获取,抽样规则优化,物料组成员优化

master
shaoyong 11 months ago
parent 519a6b377e
commit 024ff7533b

@ -42,3 +42,9 @@ export function delDefectType(faultId) {
method: 'delete'
});
}
export function getDefectTypeListByDefectType(defectType) {
return request({
url: '/quality/defectType/getDefectTypeListByDefectType/' + defectType,
method: 'get',
});
}

@ -313,7 +313,12 @@ export default {
console.log(this.form.groupId);
if(this.form.materialCode != null) {
addMaterialGroupDetail(this.form).then((response) => {
this.$modal.msgSuccess("新增成功");
let message = response.code
if(message == 200) {
this.$modal.msgSuccess("新增成功");
}else {
this.$modal.msgError("新增失败");
}
this.open = false;
this.getMaterialTree();
});

@ -196,7 +196,7 @@
</template>
</el-table-column>
<el-table-column label="检验节点" align="center" prop="checkName" />
<el-table-column label="创建时间" align="center" prop="createTime" width="180">
<el-table-column label="创建时间" align="center" prop="createTime" width="180">
<template slot-scope="scope">
<span>{{ parseTime(scope.row.createTime, '{y}-{m}-{d} {h}:{i}:{s}') }}</span>
</template>
@ -332,19 +332,9 @@
<el-input type="number" v-model="form.sampleQuality" placeholder="请输入抽样数量" />
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="A类不良数量" prop="aNoOkquality">
<el-input type="number" v-model="form.aNoOkquality" placeholder="请输入不良数量" />
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="B类不良数量" prop="bNoOkquality">
<el-input type="number" v-model="form.bNoOkquality" placeholder="请输入不良数量" />
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="C类不良数量" prop="cNoOkquality">
<el-input type="number" v-model="form.cNoOkquality" placeholder="请输入不良数量" />
<el-col :span="6" v-for="(item,index) in form.defects" :key="index">
<el-form-item :label="item.defectSubclass" prop="">
<el-input type="number" v-model="item.noOkQuality" placeholder="请输入不合格数量" />
</el-form-item>
</el-col>
</el-row>
@ -424,6 +414,7 @@ import ItemSelectWorkOrder from "./selectWorkOrder.vue";
import ItemSelectWorkCenter from "./selectWorkCenter.vue";
import ItemSelectUser from "../qcIncome/selectUser.vue";
import ItemSelectProject from "../qcIncome/checkProjectType.vue";
import { getDefectTypeListByDefectType } from "@/api/quality/defectType.js";
export default {
name: "QcProduce",
components: { ItemSelectWorkCenter,ItemSelectUser,ItemSelectProject,ItemSelectWorkOrder},
@ -445,6 +436,7 @@ export default {
//
qcProduceList: [],
checkTypeList:[],
defectTypeList: [],
//
title: "",
//
@ -522,6 +514,7 @@ export default {
this.getDate();
this.getList();
this.getCheckTypes();
this.handleDefectType();
},
methods: {
/****/
@ -602,7 +595,8 @@ export default {
updateBy: null,
updateTime: null,
factoryCode: null,
delFlag: null
delFlag: null,
defects: []
};
this.resetForm("form");
},
@ -625,8 +619,10 @@ export default {
/** 新增按钮操作 */
handleAdd() {
this.reset();
this.form.defects = this.defectTypeList;
this.open = true;
this.title = "添加生产过程检验任务";
},
/** 修改按钮操作 */
handleUpdate(row) {
@ -735,6 +731,12 @@ export default {
//
saveCheck(){
this.getList();
},
handleDefectType() {
const defectType = "produce"
getDefectTypeListByDefectType(defectType).then(response => {
this.defectTypeList = response.rows;
});
}
}
};

@ -133,13 +133,13 @@
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
<el-form ref="form" :model="form" :rules="rules" label-width="80px">
<el-form-item label="开始值" prop="startValue">
<el-input v-model="form.startValue" placeholder="请输入数字" />
<el-input type="number" v-model="form.startValue" placeholder="请输入数字" />
</el-form-item>
<el-form-item label="结束值" prop="endValue">
<el-input v-model="form.endValue" placeholder="请输入数字" />
<el-input type="number" v-model="form.endValue" placeholder="请输入数字" />
</el-form-item>
<el-form-item label="抽样数量" prop="sampleQuality">
<el-input v-model="form.sampleQuality" placeholder="请输入抽样数量" />
<el-input type="number" v-model="form.sampleQuality" placeholder="请输入抽样数量" />
</el-form-item>
<el-form-item label="检验类型" prop="typeCode">
<el-select v-model="form.typeCode" placeholder="请选择检验类型"
@ -217,15 +217,12 @@ export default {
rules: {
startValue: [
{ required: true, message: "开始值不能为空", trigger: "blur" },
{ pattern: /^[1-9]\d*$/, message: "请输入正整数,且开头不能为0", trigger: "blur"}
],
endValue: [
{ required: true, message: "结束值不能为空", trigger: "blur" },
{ pattern: /^[1-9]\d*$/, message: "请输入正整数,且开头不能为0", trigger: "blur"}
],
sampleQuality: [
{ required: true, message: "抽样数量不能为空", trigger: "blur" },
{ pattern: /^[1-9]\d*$/, message: "请输入正整数,且开头不能为0", trigger: "blur"}
],
typeCode: [
{ required: true, message: "检验类型不能为空", trigger: "blur" }

Loading…
Cancel
Save