From a9b7dfa18432bdaca6ac66cedbbeef9b02c2d077 Mon Sep 17 00:00:00 2001
From: loulijun2021 <1694218219@qq.com>
Date: 星期四, 18 五月 2023 14:05:53 +0800
Subject: [PATCH] 1.质检方案修改优化
---
src/views/qualityManager/qualityPlaning.vue | 73 +++++++++++++++++++++++++++++++-----
1 files changed, 63 insertions(+), 10 deletions(-)
diff --git a/src/views/qualityManager/qualityPlaning.vue b/src/views/qualityManager/qualityPlaning.vue
index fd9ece9..5c21948 100644
--- a/src/views/qualityManager/qualityPlaning.vue
+++ b/src/views/qualityManager/qualityPlaning.vue
@@ -197,10 +197,10 @@
<template slot-scope="{row}">
<div v-if="!row[item.prop]">/</div>
<div v-else-if="item.prop==='checktype'">
- {{ checktypeArr.find(i=>i.code===row[item.prop]).name }}
+ {{ checktypeArr.find(i => i.code === row[item.prop]).name }}
</div>
<div v-else-if="item.prop==='sampmethod'">
- {{ sampltypeArr.find(i=>i.code===row[item.prop]).name }}
+ {{ sampltypeArr.find(i => i.code === row[item.prop]).name }}
</div>
<!-- 閫傜敤瀵硅薄-->
<div v-else-if="item.prop==='suitobject'">
@@ -358,6 +358,27 @@
</el-select>
</el-form-item>
<br>
+ <el-form-item
+ v-if="dialogForm.checktype==='FirstCheck'||dialogForm.checktype==='PatroCheck'||dialogForm.checktype==='EndCheck'"
+ label="宸ュ簭鍚嶇О"
+ prop="stepcode"
+ >
+ <el-select
+ v-model="dialogForm.stepcode"
+ style="width: 200px"
+ filterable
+ placeholder="璇烽�夋嫨"
+ :popper-append-to-body="false"
+ >
+ <el-option
+ v-for="item in StepSelectArr"
+ :key="item.stepcode"
+ :label="item.stepname"
+ :value="item.stepcode"
+ />
+ </el-select>
+ </el-form-item>
+
<el-form-item label="妫�楠屾柟妗堟弿杩�">
<el-input v-model="dialogForm.descr" type="textarea" :autosize="{ minRows: 2 }" />
</el-form-item>
@@ -683,7 +704,7 @@
import { validateCode } from '@/utils/global'
import elDragDialog from '@/directive/el-drag-dialog'
import waves from '@/directive/waves'
-import { PartSelect, StockTypeSelect, UomSelect } from '@/api/makeModel'
+import { PartSelect, StepSelect, StockTypeSelect, UomSelect } from '@/api/makeModel'
import {
QualityInspectionAddEditSave,
QualityInspectionDelete,
@@ -796,21 +817,40 @@
sortable: true
},
{
+ minWidth: false,
+ width: 110,
+ prop: 'stepcode',
+ label: '宸ュ簭缂栫爜',
+ id: 9,
+ show: false,
+ fixed: false,
+ sortable: true
+ }, {
minWidth: 110,
width: false,
- prop: 'lm_user',
- label: '鍒涘缓浜哄憳',
- id: 9,
+ prop: 'stepname',
+ label: '宸ュ簭鍚嶇О',
+ id: 10,
show: true,
fixed: false,
sortable: true
},
{
- minWidth: 160,
- width: false,
+ minWidth: false,
+ width: 110,
+ prop: 'username',
+ label: '鍒涘缓浜哄憳',
+ id: 11,
+ show: true,
+ fixed: false,
+ sortable: true
+ },
+ {
+ minWidth: false,
+ width: 160,
prop: 'lm_date',
label: '鍒涘缓鏃堕棿',
- id: 10,
+ id: 12,
show: true,
fixed: false,
sortable: true
@@ -828,6 +868,7 @@
sampscale: '', // 鎶芥姣斾緥
suitobject: 'P', // 閫傜敤瀵硅薄
suitpart: [], // 閫傜敤鐗╂枡
+ stepcode: '', // 宸ュ簭
descr: '' // /鎻忚堪
},
operation: '',
@@ -858,6 +899,9 @@
],
suitpart: [
{ required: true, message: '璇烽�夋嫨鐗╂枡鎴栫墿鏂欑被鍒�', trigger: ['blur', 'change'] }
+ ],
+ stepcode: [
+ { required: true, message: '璇烽�夋嫨宸ュ簭鍚嶇О', trigger: ['blur', 'change'] }
]
},
checkitem: [],
@@ -872,6 +916,7 @@
UomSelectArr: [], // 鍗曚綅涓嬫媺鏁扮粍
CheckItemSelectAllArr: [], // 妫�楠岄」鐩�(鎵�鏈�)
CheckItemSelectArr: [], // 妫�楠岄」鐩�
+ StepSelectArr: [], // 宸ュ簭鍚嶇О涓嬫媺鎵�鏈�
isCancel: true// 鏄惁鍙彇娑�
@@ -900,8 +945,13 @@
this.getStepCheckItemSelect()
this.getPartSelect()
this.getStockTypeSelect()
+ this.getStepSelect()
}
})
+ },
+ async getStepSelect() {
+ const { data: res } = await StepSelect()
+ this.StepSelectArr = res
},
async getQualityInspectionSearch() {
const res = await QualityInspectionSearch(this.form)
@@ -955,6 +1005,7 @@
this.dialogForm.qualityinsptcode = row.code
this.dialogForm.qualityinsptname = row.name
this.dialogForm.status = row.status
+ this.dialogForm.stepcode = row.stepcode
this.dialogForm.checktype = row.checktype
this.dialogForm.sampmethod = row.sampmethod
// this.dialogForm.sampscare = row.sampscare
@@ -998,6 +1049,7 @@
this.dialogForm.qualityinsptcode = row.code
this.dialogForm.qualityinsptname = row.name
this.dialogForm.status = row.status
+ this.dialogForm.stepcode = row.stepcode
this.dialogForm.checktype = row.checktype
this.dialogForm.sampmethod = row.sampmethod
if (this.dialogForm.sampmethod === 'FIXED') {
@@ -1154,6 +1206,7 @@
checktype: '',
sampmethod: 'FIXED',
sampnum: '',
+ stepcode: '',
sampscale: '',
suitobject: 'P',
suitpart: [],
@@ -1165,7 +1218,6 @@
this.CheckItemSelectArr = JSON.parse(JSON.stringify(this.CheckItemSelectAllArr))
this.$refs.dialogForm.clearValidate()
},
-
// 瀵硅瘽妗嗗彇娑�
dialogVisibleCancel() {
this.dialogVisible = false
@@ -1197,6 +1249,7 @@
qualityinsptcode: this.dialogForm.qualityinsptcode,
qualityinsptname: this.dialogForm.qualityinsptname,
status: this.dialogForm.status,
+ stepcode: this.dialogForm.checktype === 'InCheck' || this.dialogForm.checktype === 'OutCheck' ? '' : this.dialogForm.stepcode,
checktype: this.dialogForm.checktype,
sampmethod: this.dialogForm.sampmethod,
sampscare: this.dialogForm.sampnum ? this.dialogForm.sampnum : this.dialogForm.sampscale,
--
Gitblit v1.9.3