diff --git a/src/api/qc/qc.js b/src/api/qc/qc.js index 04fd0bd..24fd2bc 100644 --- a/src/api/qc/qc.js +++ b/src/api/qc/qc.js @@ -42,7 +42,6 @@ export const checkCompleted = data => createAPI(`/pms/qc/checkCompleted`,'post', export const selectModelByPartNo = data => createAPI(`/pms/qc/selectModelByPartNo`,'post',data) export const workOrderSearch = data => createAPI(`/pms/qc/workOrderSearch`,'post',data) export const selectInformationByWorkOrderNo = data => createAPI(`/pms/qc/selectInformationByWorkOrderNo`,'post',data) -export const checkSubDetailValue = data => createAPI(`/pms/qc/checkSubDetailValue`,'post',data) // ===================================== 质检员信息 ===================================== export const inspectorSearch = data => createAPI(`/pms/qc/inspectorSearch`,'post',data) @@ -123,6 +122,7 @@ export const saveFAISubmitResult = data => createAPI(`/pms/qc/saveFAISubmitResul export const saveFAISubDetailed = data => createAPI(`/pms/qc/saveFAISubDetailed`,'post',data) export const selectFAISubDetailedRecord = data => createAPI(`/pms/qc/selectFAISubDetailedRecord`,'post',data) export const checkFAIIsSubmit = data => createAPI(`/pms/qc/checkFAIIsSubmit`,'post',data) +export const checkFAISubDetailValue = data => createAPI(`/pms/qc/checkFAISubDetailValue`,'post',data) // ===================================== IPQC检验 ===================================== export const qcIPQCInspectionSearch = data => createAPI(`/pms/qc/qcIPQCInspectionSearch`,'post',data) @@ -132,6 +132,12 @@ export const saveIPQCDetailedRecord = data => createAPI(`/pms/qc/saveIPQCDetaile export const saveIPQCSubmitResult = data => createAPI(`/pms/qc/saveIPQCSubmitResult`,'post',data) export const saveIPQCSubDetailed = data => createAPI(`/pms/qc/saveIPQCSubDetailed`,'post',data) export const selectIPQCSubDetailedRecord = data => createAPI(`/pms/qc/selectIPQCSubDetailedRecord`,'post',data) +export const checkIPQCIsSubmit = data => createAPI(`/pms/qc/checkIPQCIsSubmit`,'post',data) +export const checkIPQCSubDetailValue = data => createAPI(`/pms/qc/checkIPQCSubDetailValue`,'post',data) +export const getOperationList = data => createAPI(`/pms/qc/getOperationList`,'post',data) +export const getResourceList = data => createAPI(`/pms/qc/getResourceList`,'post',data) +export const getPartList = data => createAPI(`/pms/qc/getPartList`,'post',data) +export const saveOsInspection = data => createAPI(`/pms/qc/saveOsInspection`,'post',data) diff --git a/src/views/modules/qc/FAIResultEntry.vue b/src/views/modules/qc/FAIResultEntry.vue index 71368a7..5c112ad 100644 --- a/src/views/modules/qc/FAIResultEntry.vue +++ b/src/views/modules/qc/FAIResultEntry.vue @@ -345,9 +345,8 @@ saveFAISubmitResult, // 审核 saveFAISubDetailed, // 新增子明细信息 selectFAISubDetailedRecord, // 子明细记录信息查询 - checkFAIIsSubmit, // 检查是否已提交 - checkSubDetailValue // 检查子明细中的实测值是否在规定范围 + checkFAISubDetailValue // 检查子明细中的实测值是否在规定范围 } from "@/api/qc/qc.js"; import Chooselist from '@/views/modules/common/Chooselist_eam'; import {getFileContentList} from '@/api/eam/eam_object_list.js'; @@ -1053,7 +1052,7 @@ return false } if(this.detailList[i].valueTypeDb == 'N') { - checkSubDetailValue(this.detailList[i]).then(({data}) => { + checkFAISubDetailValue(this.detailList[i]).then(({data}) => { if (data.flag == 2 && this.detailList[i].itemResult == 'Y') { this.$confirm(this.detailList[i].itemDesc + ' 中实测值不在合格范围!是否保存为合格?', '提示', { confirmButtonText: '确定', diff --git a/src/views/modules/qc/IPQCResultEntry.vue b/src/views/modules/qc/IPQCResultEntry.vue index a08a39e..014d7a0 100644 --- a/src/views/modules/qc/IPQCResultEntry.vue +++ b/src/views/modules/qc/IPQCResultEntry.vue @@ -26,6 +26,13 @@ + + + + + + + @@ -44,6 +51,7 @@ 清空 查询 + 新增 + + + + + 工单号 + + + + + + + + + + + + + + + + + + + + + + + + + + 保存 + 关闭 + + + @@ -345,9 +400,12 @@ saveIPQCSubmitResult, // 审核 saveIPQCSubDetailed, // 新增子明细信息 selectIPQCSubDetailedRecord, // 子明细记录信息查询 - - checkOutIsSubmit, // 检查是否已提交 - checkSubDetailValue // 检查子明细中的实测值是否在规定范围 + checkIPQCIsSubmit, // 检查是否已提交 + checkIPQCSubDetailValue, // 检查子明细中的实测值是否在规定范围 + getOperationList, // 查询工序列表 + getResourceList, // 查询机台列表 + getPartList, // 查询物料列表 + saveOsInspection, // 新增巡检记录 } from "@/api/qc/qc.js"; import Chooselist from '@/views/modules/common/Chooselist_eam'; import {getFileContentList} from '@/api/eam/eam_object_list.js'; @@ -373,8 +431,8 @@ favorite: false, // 导出 start exportData: [], - exportName: "FAI检验录入" + this.dayjs().format('YYYYMMDDHHmmss'), - exportHeader: ["FAI检验录入"], + exportName: "IPQC检验录入" + this.dayjs().format('YYYYMMDDHHmmss'), + exportHeader: ["IPQC检验录入"], exportFooter: [], exportList:[], // 导出 end @@ -397,6 +455,7 @@ operationDesc: '', startDate: '', endDate: '', + checkType: '', page: 1, limit: 10, }, @@ -414,11 +473,17 @@ inspectionNo:'', partNo: '', partDesc: '', - inspectionTypeNo:'102', - inspectionTypeName:'FAI', + inspectionTypeNo:'101', + inspectionTypeName:'IPQC', inspectorNo:'', inspectorName:'', submit_flag:'', + orderNo: '', + operationDesc: '', + operationNo: '', + resourceId: '', + resourceDesc: '', + rollQty: '', }, // 展示列集 columnList: [ @@ -458,6 +523,18 @@ status: true, fixed: '', }, + { + columnProp: 'checkType', + headerAlign: "center", + align: "left", + columnLabel: '检验类型', + columnHidden: false, + columnImage: false, + columnSortable: false, + sortLv: 0, + status: true, + fixed: '', + }, { columnProp: 'taskDate', headerAlign: "center", @@ -854,6 +931,11 @@ subDetailValues:[] }, options: [], + modalDisableFlag: false, + modalFlag: false, + operationList: [], + resourceList: [], + partList: [], } }, mounted () { @@ -967,10 +1049,141 @@ operationDesc: '', startDate: '', endDate: '', + checkType: '', page: 1, limit: 10, } }, + // 获取基础数据列表S + getBaseList (val,type) { + this.tagNo = val + this.$nextTick(() => { + let strVal = '' + if (val === 1052) { + strVal = this.modalData.orderNo + this.$refs.baseList.init(val, strVal) + } + }) + }, + /* 列表方法的回调 */ + getBaseData (val) { + if (this.tagNo === 1052) { + this.modalData.orderNo = val.orderno + this.getOperationList() + this.getPartList() + } + }, + // 获取工序列表 + getOperationList(){ + getOperationList(this.modalData).then(({data}) => { + if (data && data.code === 0) { + this.operationList = data.rows + } else { + this.$alert(data.msg, '错误', { + confirmButtonText: '确定' + }) + } + }) + }, + // 获取机台列表 + getResourceList(){ + getResourceList(this.modalData).then(({data}) => { + if (data && data.code === 0) { + this.resourceList = data.rows + } else { + this.$alert(data.msg, '错误', { + confirmButtonText: '确定' + }) + } + }) + }, + // 获取物料列表 + getPartList(){ + getPartList(this.modalData).then(({data}) => { + if (data && data.code === 0) { + this.partList = data.rows + } else { + this.$alert(data.msg, '错误', { + confirmButtonText: '确定' + }) + } + }) + }, + addModal(){ + this.modalData={ + flag: '1', + site: this.$store.state.user.site, + inspectionNo:'', + partNo: '', + partDesc: '', + inspectionTypeNo:'101', + inspectionTypeName:'IPQC', + inspectorNo:'', + inspectorName:'', + submit_flag:'', + orderNo: '', + operationDesc: '', + operationNo: '', + resourceId: '', + resourceDesc: '', + rollQty: '', + }; + this.modalDisableFlag = false; + this.modalFlag = true; + }, + // 新增IPQC巡检记录 + saveData(){ + if (this.modalData.orderNo == '' || this.modalData.orderNo == null) { + this.$alert('请选择工单!', '错误', { + confirmButtonText: '确定' + }) + return false + } + if (this.modalData.partNo == '' || this.modalData.partNo == null) { + this.$alert('请选择物料!', '错误', { + confirmButtonText: '确定' + }) + return false + } + if (this.modalData.operationDesc == '' || this.modalData.operationDesc == null) { + this.$alert('请选择工序!', '错误', { + confirmButtonText: '确定' + }) + return false + } + if (this.modalData.resourceId == '' || this.modalData.resourceId == null) { + this.$alert('请选择机台!', '错误', { + confirmButtonText: '确定' + }) + return false + } + if (this.modalData.rollQty == '' || this.modalData.rollQty == null) { + this.$alert('请填写送检数量!', '错误', { + confirmButtonText: '确定' + }) + return false + } + if(this.modalData.flag=='1'){ + saveOsInspection(this.modalData).then(({data}) => { + if (data && data.code === 0) { + this.getDataList() + this.modalFlag = false + this.$message({ + message: '操作成功', + type: 'success', + duration: 1500, + onClose: () => { + } + }) + } else { + this.$alert(data.msg, '错误', { + confirmButtonText: '确定' + }) + } + }) + } + }, + // 获取主信息数据列表 getDataList () { this.searchData.limit = this.pageSize @@ -1000,6 +1213,7 @@ selectionChangeHandle (val) { this.dataListSelections = val }, + // 删除检验记录 deleteModal (row) { this.$confirm(`是否删除这条检验记录?`, '提示', { @@ -1053,7 +1267,7 @@ return false } if(this.detailList[i].valueTypeDb == 'N') { - checkSubDetailValue(this.detailList[i]).then(({data}) => { + checkIPQCSubDetailValue(this.detailList[i]).then(({data}) => { if (data.flag == 2 && this.detailList[i].itemResult == 'Y') { this.$confirm(this.detailList[i].itemDesc + ' 中实测值不在合格范围!是否保存为合格?', '提示', { confirmButtonText: '确定', @@ -1186,7 +1400,7 @@ }, //点击新增更多 handleAddBtn(td) { - checkOutIsSubmit(td).then(({data}) => { + checkIPQCIsSubmit(td).then(({data}) => { if (data.flag != 1) { let obj = {}; obj.subDetailValue = ""; @@ -1201,7 +1415,7 @@ }, //删除 handleDeleteBtn(td) { - checkOutIsSubmit(td).then(({data}) => { + checkIPQCIsSubmit(td).then(({data}) => { if (data.flag != 1) { if (this.checkedDetail.length == 0) { this.$alert("请先选择要删除的数据", "提示", { diff --git a/src/views/modules/qc/IQCResultEntry.vue b/src/views/modules/qc/IQCResultEntry.vue index fb45e4f..e1234d0 100644 --- a/src/views/modules/qc/IQCResultEntry.vue +++ b/src/views/modules/qc/IQCResultEntry.vue @@ -907,7 +907,7 @@ cancelButtonText: '取消', type: 'warning' }).then(() => { - qcInspectionInformationDelete(row).then(({data}) => { + faiRecordDelete(row).then(({data}) => { if (data && data.code ==0) { this.getDataList() this.$message({ diff --git a/src/views/modules/qc/qcFamilyAttribute.vue b/src/views/modules/qc/qcFamilyAttribute.vue index c2cb328..0ec119a 100644 --- a/src/views/modules/qc/qcFamilyAttribute.vue +++ b/src/views/modules/qc/qcFamilyAttribute.vue @@ -677,6 +677,7 @@ } if (this.tagNo === 1049) { this.tempPlanRow.samplingPlanNo = val.sampling_plan_no + this.tempPlanRow.samplingPlanDesc = val.sampling_plan_desc } }, // 获取数据列表 diff --git a/src/views/modules/qc/qcSamplingInspectionProgramme.vue b/src/views/modules/qc/qcSamplingInspectionProgramme.vue index e217e49..5a4272d 100644 --- a/src/views/modules/qc/qcSamplingInspectionProgramme.vue +++ b/src/views/modules/qc/qcSamplingInspectionProgramme.vue @@ -243,7 +243,6 @@ getPlanLists, // 获取矩阵列表 saveSamplingProgrammeDetails, // 新增抽样方案中的矩阵 deleteSamplingProgrammeDetails, // 删除抽样方案中的矩阵 - } from "@/api/qc/qc.js" import Chooselist from '@/views/modules/common/Chooselist_eam' import {userFavoriteList, saveUserFavorite, removeUserFavorite} from '@/api/userFavorite.js' diff --git a/src/views/modules/qc/qcTemplate.vue b/src/views/modules/qc/qcTemplate.vue index e52e092..a356ef6 100644 --- a/src/views/modules/qc/qcTemplate.vue +++ b/src/views/modules/qc/qcTemplate.vue @@ -98,14 +98,11 @@ - + - - - + 抽样方案编码 @@ -125,6 +123,9 @@ + + + 检验水平编码 @@ -133,6 +134,19 @@ + + + + + + + + + + + + + @@ -417,6 +431,8 @@ aql: '', ac: '', re: '', + defaultSamplingQuantity: '', + defaultSamplingProportion: '', }, detailData:{ site: this.$store.state.user.site, @@ -912,6 +928,8 @@ aql: row.aql, ac: row.ac, re: row.re, + defaultSamplingQuantity: row.defaultSamplingQuantity, + defaultSamplingProportion: row.defaultSamplingProportion }; this.modalDisableFlag = true; this.modalFlag = true; @@ -967,20 +985,14 @@ }) return false } - // if (this.modalData.aql == '' || this.modalData.aql == null) { - // this.$alert('请输入AQL!', '错误', { - // confirmButtonText: '确定' - // }) - // return false - // } - // if (this.modalData.ac == '' || this.modalData.ac == null) { - // this.$alert('请输入AC!', '错误', { + // if (this.modalData.defaultSamplingQuantity == '' || this.modalData.defaultSamplingQuantity == null) { + // this.$alert('请输入默认抽样数量!', '错误', { // confirmButtonText: '确定' // }) // return false // } - // if (this.modalData.re == '' || this.modalData.re == null) { - // this.$alert('请输入RE!', '错误', { + // if (this.modalData.defaultSamplingProportion == '' || this.modalData.defaultSamplingProportion == null) { + // this.$alert('请输入默认抽样比例!', '错误', { // confirmButtonText: '确定' // }) // return false