From 9dd05b6679688390ebd4e528dbd02409214d3f3d Mon Sep 17 00:00:00 2001 From: fengyuan_yang <1976974459@qq.com> Date: Wed, 3 Dec 2025 14:40:03 +0800 Subject: [PATCH] =?UTF-8?q?2025-12-03=20=E6=9C=BA=E5=8F=B0=E5=B7=A5?= =?UTF-8?q?=E4=BD=9C=E5=8F=B0=E8=BF=87=E7=A8=8B=E6=A3=80=E9=AA=8C=E6=A3=80?= =?UTF-8?q?=E9=AA=8C=E5=8D=95=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../yieldReport/com_process_inspection.vue | 1788 ++++++++++++++++- 1 file changed, 1695 insertions(+), 93 deletions(-) diff --git a/src/views/modules/yieldReport/com_process_inspection.vue b/src/views/modules/yieldReport/com_process_inspection.vue index 894cf1d..4e7d21f 100644 --- a/src/views/modules/yieldReport/com_process_inspection.vue +++ b/src/views/modules/yieldReport/com_process_inspection.vue @@ -312,72 +312,220 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
+ + + +
+
+
+ + 检验单信息 +
+ + + +
+ + +
+
+ +
+ + +
+
+ +
+ + +
+
+ +
+ + +
+
+ +
+ + +
+
+ +
+ + +
+
+ +
+ + +
+
+
+ + + +
+ + +
+
+ +
+ + +
+
+ +
+ + + +
+
+ +
+ + +
+
+ +
+ + + +
+
+ +
+ + +
+
+
+
+ +
+
+ + 检验结论 +
+ + +
+ + + + + + + + + +
+
+ +
+ + + +
+
+ +
+ + + + + + + + + +
+
+ +
+ + + +
+
+
+
+ + +
+
+ + 数据采集 + + + 文件清单 + +
+
+ + 项目导入 + + + 模板导入 + +
+
+
+ + +
+
+ + + 检验项目明细 + +
+ stripe + style="width: 100%;" + class="inspection-table"> + + + @@ -483,6 +943,17 @@ import { saveIPQCDetailedRecord, // 保存检验明细记录 getSpecialOperationList, // 获取特殊工序列表 inspectionTypeSearch, // 搜索所有检验类型 + disposalMeasuresSearch, // 获取处置措施列表 + getUserRoleList, // 获取用户角色列表 + getOperatorList, // 获取协同人员列表 + getResponsibleOperatorList, // 获取责任人列表 + dataAcquisition, // 数据采集 + dataAcquisitionByItem, // 按项目数据采集 + getIPQCItemList, // 获取IPQC检验项目列表 + addIPQCItemDetails, // 添加检验项目 + deleteIPQCItemDetails, // 删除检验项目 + getIPQCTemplateList, // 获取IPQC模板列表 + importIPQCTemplateItems, // 导入模板项目 } from "@/api/qc/qc.js" import {getTableDefaultListLanguage, getTableUserListLanguage} from "@/api/table.js" import { getInspectionFile } from '@/api/eam/eam_object_list.js' @@ -790,6 +1261,7 @@ export default { inspectionNo: '', partNo: '', partDesc: '', + spec: '', rollQty: '', samplingQty: '', unqualifiedQty: '', @@ -813,8 +1285,86 @@ export default { state: '', passQty: '', notPassQty: '', - batchQualifiedQty: '' + batchQualifiedQty: '', + orderNo: '', + templateId: '' + }, + // 处置措施选项 + disposalMeasuresOptions: [], + // 协同人员/责任人相关 + roleList: [], + operatorModelFlag: false, + operatorData: { + flag: '', + site: '', + bu: '', + adminID: '', + adminName: '', + roleName: '', + roleId: '', + userName: '' + }, + operatorList: [], + operatorDetailList: [ + { + columnProp: 'adminID', + headerAlign: "center", + align: "center", + columnLabel: '用户编码', + columnHidden: false, + columnImage: false, + columnSortable: false, + fixed: '', + columnWidth: 100, + showOverflowTooltip: true + }, + { + columnProp: 'adminName', + headerAlign: "center", + align: "center", + columnLabel: '用户姓名', + columnHidden: false, + columnImage: false, + columnSortable: false, + fixed: '', + columnWidth: 100, + showOverflowTooltip: true + }, + { + columnProp: 'roleName', + headerAlign: "center", + align: "center", + columnLabel: '角色', + columnHidden: false, + columnImage: false, + columnSortable: false, + fixed: '', + columnWidth: 150, + showOverflowTooltip: true + } + ], + dataListSelections2: [], + // 数据采集loading + loadFlag: false, + // 项目导入相关 + itemOperationDialogFlag: false, + itemOperationQuery: { + itemNo: '', + itemDesc: '' + }, + availableItemList: [], + selectedItemList: [], + availableItemSelections: [], + selectedItemSelections: [], + // 模板导入相关 + templateImportDialogFlag: false, + templateQuery: { + templateId: '', + templateDesc: '' }, + templateImportList: [], + templateSelections: [], + importLoading: false, detailList: [], transferLoadFlag: false, saveInformationData: { @@ -1049,6 +1599,10 @@ export default { // 查看 质量任务生成规则控制 动控是否开启 this.queryController() this.inspectionTypeSearch() + // 获取处置措施列表 + this.getDisposalMeasuresOptions() + // 获取用户角色列表 + this.getUserRoleListData() }, // 查询检验类型 @@ -1586,13 +2140,14 @@ export default { this.detailData.inspectionNo = row.inspectionNo this.detailData.partNo = row.partNo this.detailData.partDesc = row.partDesc + this.detailData.spec = row.spec || '' this.detailData.rollQty = row.rollQty this.detailData.samplingQty = row.samplingQty this.detailData.unqualifiedQty = row.unqualifiedQty this.detailData.unqualifiedQuantity = row.unqualifiedQuantity this.detailData.submitFlag = row.submitFlag - this.detailData.disposalMeasures = row.disposalMeasures - this.detailData.disposalRemark = row.disposalRemark + this.detailData.disposalMeasures = row.disposalMeasures || '' + this.detailData.disposalRemark = row.disposalRemark || '' this.detailData.inspectionResult = row.inspectionResult this.detailData.inspectorNo = row.inspectorNo this.detailData.inspectorName = row.inspectorName @@ -1602,11 +2157,13 @@ export default { this.detailData.invdefinetype = row.invdefinetype this.detailData.umId = row.umId this.detailData.umName = row.umName - this.detailData.operator = row.operator - this.detailData.operatorName = row.operatorName - this.detailData.responsiblePerson = row.responsiblePerson - this.detailData.responsiblePersonName = row.responsiblePersonName + this.detailData.operator = row.operator || '' + this.detailData.operatorName = row.operatorName || '' + this.detailData.responsiblePerson = row.responsiblePerson || '' + this.detailData.responsiblePersonName = row.responsiblePersonName || '' this.detailData.state = row.state + this.detailData.orderNo = row.orderNo || '' + this.detailData.templateId = row.templateId || '' if (row.state === '待检验') { this.detailData.passQty = row.samplingQty } else { @@ -1654,12 +2211,54 @@ export default { // 保存检验明细(应用/保存) Transfer(type) { - this.transferLoadFlag = true + // 保存时校验 + if (type === '2') { + if (this.detailData.inspectionResult === '' || this.detailData.inspectionResult == null) { + this.$message.warning('请选择检验结论!') + return + } + if (this.detailData.inspectionResult === '不合格' && (this.detailData.disposalMeasures == null || this.detailData.disposalMeasures === '')) { + this.$message.warning('请选择处置措施!') + return + } + if (this.detailList.length > 0 && this.detailData.inspectionResult === '不合格') { + const flag = this.detailList.some(item => item.itemResult === 'N') + if (!flag) { + this.$message.warning('请选择不合格项目!') + return + } + } + if (this.detailData.inspectionResult !== '不合格') { + this.detailData.disposalMeasures = '' + this.detailData.disposalRemark = '' + } + } + this.saveDetailInformation(type) + }, + + // 保存检验明细信息 + saveDetailInformation(type) { this.saveInformationData.site = this.detailData.site this.saveInformationData.buNo = this.detailData.buNo this.saveInformationData.inspectionNo = this.detailData.inspectionNo - this.saveInformationData.detailList = this.detailList + this.saveInformationData.disposalMeasures = this.detailData.disposalMeasures + this.saveInformationData.disposalRemark = this.detailData.disposalRemark + this.saveInformationData.inspectorNo = this.$store.state.user.name + this.saveInformationData.inspectionResult = this.detailData.inspectionResult + this.saveInformationData.inspectionRemark = this.detailData.inspectionRemark + this.saveInformationData.rollQty = this.detailData.rollQty + this.saveInformationData.samplingQty = this.detailData.samplingQty + this.saveInformationData.unqualifiedQty = this.detailData.unqualifiedQty + this.saveInformationData.partNo = this.detailData.partNo + this.saveInformationData.partDesc = this.detailData.partDesc + this.saveInformationData.operator = this.detailData.operator + this.saveInformationData.responsiblePerson = this.detailData.responsiblePerson + this.saveInformationData.itemList = JSON.parse(JSON.stringify(this.detailList)) + this.saveInformationData.passQty = this.detailData.passQty == null ? 0 : this.detailData.passQty + this.saveInformationData.notPassQty = this.detailData.notPassQty == null ? 0 : this.detailData.notPassQty + this.saveInformationData.batchQualifiedQty = this.detailData.batchQualifiedQty == null ? 0 : this.detailData.batchQualifiedQty this.saveInformationData.type = type + this.transferLoadFlag = true saveIPQCDetailedRecord(this.saveInformationData).then(({data}) => { if (data && data.code === 0) { this.getDataList() @@ -1674,20 +2273,1023 @@ export default { }) }, - // 关闭弹窗 - handleClose() { - this.$emit('update:visible', false) - } - } -} - + // 检验结论变化事件 + resultChange() { + if (this.detailData.inspectionResult !== '不合格') { + this.detailData.disposalMeasures = '' + this.detailData.disposalRemark = '' + } + }, -