yangwl
zhaoxiaolin 10 months ago
parent 56744d1afd
commit 6320a45734

@ -1,6 +1,6 @@
<template>
<div>
<el-col :span="4" :xs="24">
<el-col :span="6" :xs="24">
<!-- 新增按钮 -->
<el-button class="groupAdd" type="primary" @click="handleAdd"
>新增物料组</el-button>
@ -27,7 +27,7 @@
@node-click="handleNodeClick"
>
<span class="custom-tree-node" slot-scope="{ node, data }">
<span style="width:110px; display:block; word-break:keep-all; white-space:nowrap; overflow:hidden; text-overflow:ellipsis"
<span style="width:220px; display:block; word-break:keep-all; white-space:nowrap; overflow:hidden; text-overflow:ellipsis"
v-bind:title="node.label"
>{{node.label}}</span>
<span>
@ -178,7 +178,7 @@ export default {
this.materialOptions = response.data;
this.treeInit();
});
},
//
@ -190,7 +190,7 @@ export default {
treeInit() {
const firstTreeNode = this.materialOptions[0];
firstTreeNode.level = 1;
this.$emit('child-event', firstTreeNode); //
this.$emit('child-event', firstTreeNode); //
},
//
handleNodeClick(data,node) {
@ -208,7 +208,7 @@ export default {
}else{
this.$emit('onNodeClick', this.nodeData);
}
},
/** 新增按钮操作 */
handleAdd() {
@ -327,7 +327,7 @@ export default {
.groupAdd {
margin: 10px auto;
width: 100%;
}
.custom-tree-node {
flex: 1;

@ -2,7 +2,7 @@
<div class="app-container">
<el-row :gutter="20">
<MaterialGroupAdd ref="MaterialGroupAdd" @onNodeClick="onNodeClick" @child-event="getCheckTypeList"></MaterialGroupAdd>
<el-col :span="20" :xs="24">
<el-col :span="18" :xs="24">
<el-row :gutter="10" class="mb8">
<el-col :span="23" :xs="24">
<el-tabs v-model="editableTabsValue" type="card" @tab-click="handleClick">
@ -176,14 +176,9 @@
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
<el-form ref="form" :model="form" :rules="rules" label-width="100px">
<el-form-item label="规则名称" prop="projectId">
<el-select filterable v-model="form.projectId" @change="handleChange" placeholder="请选择检验规则属性" >
<el-option
v-for="item in checkRuleList"
:key="item.id"
:label="item.ruleName"
:value="item.id"
></el-option>
</el-select>
<el-input v-model="form.projectId" v-if="false"/>
<el-input v-model="form.id" v-if="false"/>
<el-input v-model="form.ruleName" disabled/>
</el-form-item>
<el-form-item label="抽样比例" prop="sample">
<el-input v-model="form.sample" placeholder="请输入抽样比例" />

@ -65,7 +65,7 @@
</template>
</el-table-column>
<el-table-column label="测量单位" align="left" prop="unitCode" width="90"/>
<el-table-column label="抽样方案" align="left" prop="samplePlan" width="100"/>
<el-table-column label="抽样方案" align="left" prop="samplePlan" width="100" :show-overflow-tooltip="true"/>
<el-table-column label="合格判定" align="left" prop="judge"/ width="100">
<el-table-column label="缺陷等级" align="left" prop="defectLevel" width="90"/>
<el-table-column label="检验方式" align="left" prop="checkMode" width="90" :show-overflow-tooltip="true"/>

@ -1,13 +1,25 @@
<template>
<div class="app-container">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="100px">
<el-form-item label="任务编码" prop="checkNo">
<el-input
v-model="queryParams.checkNo"
placeholder="请输入所属任务编码"
clearable
@keyup.enter.native="handleQuery"
/>
<el-form-item label="检验类型" prop="typeCode">
<el-select v-model="queryParams.typeCode" clearable placeholder="请选择检验类型" @change="getCheckTypeList">
<el-option
v-for="dict in dict.type.check_type"
:key="dict.value"
:label="dict.label"
:value="dict.value"
></el-option>
</el-select>
</el-form-item>
<el-form-item label="检验节点" prop="checkType">
<el-select v-model="queryParams.checkType" clearable placeholder="请选择检验节点">
<el-option
v-for="dict in checkTypeList"
:key="dict.checkType"
:label="dict.checkName"
:value="dict.checkType"
></el-option>
</el-select>
</el-form-item>
<el-form-item label="订单编码" prop="orderNo">
<el-input
@ -25,14 +37,7 @@
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="物料名称" prop="materialName">
<el-input
v-model="queryParams.materialName"
placeholder="请输入物料名称"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<!--
<el-form-item label="检测地点" prop="checkLoc">
<el-input
v-model="queryParams.checkLoc"
@ -48,7 +53,7 @@
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
</el-form-item>-->
<el-form-item label="检验时间" prop="checkTime">
<el-date-picker
v-model="queryParams.checkTimeArray"
@ -107,15 +112,14 @@
<el-table v-loading="loading" :data="unqualifiedList" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="id" align="center" prop="id" v-if="false"/>
<el-table-column label="检查任务编码" align="center" prop="checkNo" width="150"/>
<el-table-column label="订单编码" align="center" prop="orderNo" width="150"/>
<el-table-column label="批次号" align="center" prop="incomeBatchNo" width="100"/>
<el-table-column label="检查任务编码" align="center" prop="checkNo" width="130"/>
<el-table-column label="订单编码" align="center" prop="orderNo" width="130"/>
<el-table-column label="批次号" align="center" prop="incomeBatchNo" width="150" :show-overflow-tooltip="true"/>
<el-table-column label="质检项目" align="center" prop="checkName" width="80"/>
<el-table-column label="物料编码" align="center" prop="materialCode" width="150"/>
<el-table-column label="物料名称" align="center" prop="materialName" width="150"/>
<el-table-column label="物料编码" align="center" prop="materialCode" width="150" :formatter="productCodeFormate"/>
<el-table-column label="物料名称" align="center" prop="materialName" width="150" :show-overflow-tooltip="true"/>
<el-table-column label="订单数量" align="center" prop="quality" />
<el-table-column label="单位" align="center" prop="unit" />
<el-table-column label="异常时间" align="center" prop="checkTime" width="120"/>
<el-table-column label="状态" align="center" prop="status" >
<template slot-scope="scope">
<dict-tag
@ -126,7 +130,11 @@
</el-table-column>
<el-table-column label="下一节点编码" align="center" prop="nextNodeCode" width="120"/>
<el-table-column label="下一节点名称" align="center" prop="nextNodeName" width="120"/>
<el-table-column label="提报时间" align="center" prop="createTime" width="120"/>
<el-table-column label="流程发起时间" align="center" prop="createTime" width="150">
<template slot-scope="scope">
<span>{{ parseTime(scope.row.createTime, '{y}-{m}-{d} {h}:{i}:{s}') }}</span>
</template>
</el-table-column>
<el-table-column label="不合格描述" align="center" prop="remark" width="120"/>
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<template slot-scope="scope">
@ -140,7 +148,7 @@
</template>
</el-table-column>
</el-table>
<pagination
v-show="total>0"
:total="total"
@ -158,7 +166,7 @@
<el-input v-model="form.checkNo" placeholder="请输入检验任务编号" disabled/>
</el-form-item>
</el-col>
<el-col :span="8">
<el-col :span="8">
<el-form-item label="来料批次号" prop="incomeBatchNo">
<el-input v-model="form.incomeBatchNo" placeholder="请输入来料批次号" />
</el-form-item>
@ -183,7 +191,7 @@
<el-input v-model="form.materialCode" placeholder="请输入物料号" disabled/>
</el-form-item>
</el-col>
</el-row>
</el-row>
<el-row>
<el-col :span="8">
<el-form-item label="检验类型" prop="checkType" >
@ -197,7 +205,7 @@
</el-select>
</el-form-item>
</el-col>
<el-col :span="8">
<el-col :span="8">
<el-form-item label="收货数量" prop="quality">
<el-input type="number" v-model="form.quality" placeholder="请输入收货数量" />
</el-form-item>
@ -223,11 +231,11 @@
</el-input>
</el-form-item>
</el-col>
<el-col :span="8">
<el-col :span="8">
<el-form-item label="供应商编码" prop="supplierCode">
<el-input v-model="form.supplierCode" placeholder="请输入供应商编码" disabled/>
</el-form-item>
</el-col>
</el-col>
<el-col :span="8">
<el-form-item label="来料时间" prop="incomeTime">
<el-date-picker clearable
@ -238,7 +246,7 @@
</el-date-picker>
</el-form-item>
</el-col>
</el-row>
</el-row>
<el-row>
<el-col :span="8">
<el-form-item label="检测人姓名" prop="checkManName">
@ -252,7 +260,7 @@
<el-input v-model="form.checkManCode" placeholder="请输入检测人工号" disabled/>
</el-form-item>
</el-col>
<el-col :span="8">
<el-col :span="8">
<el-form-item label="检测地点" prop="checkLoc">
<el-input v-model="form.checkLoc" placeholder="请输入检测地点" />
</el-form-item>
@ -264,7 +272,7 @@
<el-input type="textarea" autosize placeholder="请输入内容" v-model="form.remark"></el-input>
</el-form-item>
</el-col>
</el-row>
</el-row>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button type="primary" @click="submitForm"> </el-button>
@ -276,10 +284,11 @@
<script>
import { listUnqualified, getUnqualified, delUnqualified, addUnqualified, updateUnqualified } from "@/api/quality/unqualified";
import { getCheckTypeList} from "@/api/quality/qcTable";
import moment from 'moment';
export default {
name: "Unqualified",
dicts: ["do_result"],
dicts: ["do_result","check_type"],
data() {
return {
//
@ -314,12 +323,16 @@ export default {
attr3: null,
attr4: null,
factoryCode: null,
typeCode:null,
checkType:null,
},
//
form: {},
//
rules: {
}
},
checkTypeList:[],
checkTypes:[]
};
},
created() {
@ -330,7 +343,7 @@ export default {
methods: {
/****/
getCheckTypes() {
getCheckTypes('material').then(response => {
getCheckTypes('').then(response => {
this.checkTypes = response;
});
},
@ -443,15 +456,15 @@ export default {
}
});
},
/** 删除按钮操作 */
handleDelete(row) {
const ids = row.id || this.ids;
this.$modal.confirm('是否确认删除不合格处理编号为"' + ids + '"的数据项?').then(function() {
return delUnqualified(ids);
}).then(() => {
this.getList();
this.$modal.msgSuccess("删除成功");
}).catch(() => {});
getCheckTypeList(val){
//
getCheckTypeList(val).then(response => {
this.checkTypeList = response
});
},
//
productCodeFormate(row, column, cellValue){
return cellValue.slice(7,18); //
},
/** 导出按钮操作 */
handleExport() {

Loading…
Cancel
Save