diff --git a/src/views/modules/qc/FAIResultEntry.vue b/src/views/modules/qc/FAIResultEntry.vue index aa148fb..8083c75 100644 --- a/src/views/modules/qc/FAIResultEntry.vue +++ b/src/views/modules/qc/FAIResultEntry.vue @@ -135,12 +135,12 @@ - - 工单号 - + + 派工单号 + - - + + @@ -177,6 +177,14 @@ + + + + + + + + 保存 关闭 @@ -496,6 +504,8 @@ inspectorNo: '', inspectorName: '', submit_flag: '', + seqNo: '', + batchRollNo: '' }, // 展示列集 columnList: [ @@ -571,6 +581,18 @@ status: true, fixed: '', }, + { + columnProp: 'seqNo', + headerAlign: "center", + align: "center", + columnLabel: '派工单号', + columnHidden: false, + columnImage: false, + columnSortable: false, + sortLv: 0, + status: true, + fixed: '', + }, { columnProp: 'operationDesc', headerAlign: "center", @@ -982,6 +1004,13 @@ message: ' ', trigger: 'change' } + ], + seqNoType: [ + { + required: true, + message: ' ', + trigger: 'change' + } ] }, resourceList: [], @@ -1005,7 +1034,7 @@ this.$nextTick(() => { let strVal = '' if (val === 1052) { - strVal = this.modalData.orderNo + strVal = this.modalData.seqNo this.$refs.baseList.init(val, strVal) } }) @@ -1014,7 +1043,10 @@ /* 列表方法的回调 */ getBaseData (val) { if (this.tagNo === 1052) { + this.modalData.seqNo = val.seqno this.modalData.orderNo = val.orderno + this.modalData.operationDesc = '' + this.modalData.resourceId = '' this.getOperationList() this.getPartList() } @@ -1063,6 +1095,10 @@ // 新增FAI巡检记录 saveData(){ + if (this.modalData.seqNo === '' || this.modalData.seqNo == null) { + this.$message.warning('请选择派工单!') + return + } if (this.modalData.orderNo === '' || this.modalData.orderNo == null) { this.$message.warning('请选择工单!') return @@ -1126,6 +1162,8 @@ resourceId: '', resourceDesc: '', rollQty: '', + seqNo: '', + batchRollNo: '' }; this.operationList = []; this.resourceList = []; @@ -1373,7 +1411,7 @@ this.saveInformationData.inspectionRemark = this.detailData.inspectionRemark this.saveInformationData.itemList = JSON.parse(JSON.stringify(this.detailList)) saveFAIDetailedRecord(this.saveInformationData).then(({data}) => { - if (data && data.code == '0') { + if (data && data.code === 0) { this.getDataList() this.detailInformationFlag = false } else { @@ -1462,7 +1500,7 @@ }).then(() => { this.submitData.submitList = this.FAISelections saveFAISubmitResult(this.submitData).then(({data}) => { - if (data && data.code ==0) { + if (data && data.code === 0) { this.getDataList() this.FAISelections = [] this.$message({ @@ -1485,12 +1523,12 @@ // 子明细方法 //表格的新增 rowClassName({ row, rowIndex }) { - row.xh = rowIndex + 1; + row.xh = rowIndex + 1 }, //单选框选中数据 handleDetailSelectionChange(selection) { - this.checkedDetail = selection; + this.checkedDetail = selection }, //点击新增更多 @@ -1498,10 +1536,9 @@ checkFAIIsSubmit(td).then(({data}) => { if (data.flag != 1) { let obj = {}; - obj.subDetailValue = ""; - obj.samplingLocation = ""; - this.tableData.push(obj); - console.log(this.tableData) + obj.subDetailValue = "" + obj.samplingLocation = "" + this.tableData.push(obj) } else { this.$alert("记录已提交!", '错误', { confirmButtonText: '确定' @@ -1517,7 +1554,7 @@ if (this.checkedDetail.length == 0) { this.$alert("请先选择要删除的数据", "提示", { confirmButtonText: "确定", - }); + }) } else { this.$confirm("请是否确认删除该子明细记录?", "提示", { confirmButtonText: "确定", @@ -1525,29 +1562,28 @@ type: "warning", callback: (action) => { if (action === "confirm") { - let val = this.checkedDetail; + let val = this.checkedDetail val.forEach((val, index) => { this.tableData.forEach((v, i) => { if (val.xh === v.xh) { - this.tableData.splice(i, 1); + this.tableData.splice(i, 1) } - }); - }); + }) + }) this.$message({ message: "删除成功,记得保存修改喔!", type: "success", - }); - //this.$refs.tb.clearSelection(); - return; + }) + return } else { this.$message({ message: "已取消删除操作", type: "warning", - }); - return; + }) + return } }, - }); + }) } } else { this.$alert("记录已提交!", '错误', { @@ -1555,7 +1591,6 @@ }) } }) - }, // 新增子明细记录 diff --git a/src/views/modules/qc/FQCResultEntry.vue b/src/views/modules/qc/FQCResultEntry.vue index 066bd17..267344e 100644 --- a/src/views/modules/qc/FQCResultEntry.vue +++ b/src/views/modules/qc/FQCResultEntry.vue @@ -133,12 +133,12 @@ - - 工单号 - + + 派工单号 + - - + + @@ -175,6 +175,14 @@ + + + + + + + + 保存 关闭 @@ -492,6 +500,8 @@ inspectorNo: '', inspectorName: '', submit_flag: '', + seqNo: '', + batchRollNo: '' }, // 展示列集 columnList: [ @@ -567,6 +577,18 @@ status: true, fixed: '', }, + { + columnProp: 'seqNo', + headerAlign: "center", + align: "center", + columnLabel: '派工单号', + columnHidden: false, + columnImage: false, + columnSortable: false, + sortLv: 0, + status: true, + fixed: '', + }, { columnProp: 'operationDesc', headerAlign: "center", @@ -978,6 +1000,13 @@ message: ' ', trigger: 'change' } + ], + seqNoType: [ + { + required: true, + message: ' ', + trigger: 'change' + } ] }, resourceList: [], @@ -1001,7 +1030,7 @@ this.$nextTick(() => { let strVal = '' if (val === 1052) { - strVal = this.modalData.orderNo + strVal = this.modalData.seqNo this.$refs.baseList.init(val, strVal) } }) @@ -1010,7 +1039,10 @@ /* 列表方法的回调 */ getBaseData (val) { if (this.tagNo === 1052) { + this.modalData.seqNo = val.seqno this.modalData.orderNo = val.orderno + this.modalData.operationDesc = '' + this.modalData.resourceId = '' this.getOperationList() this.getPartList() } @@ -1059,6 +1091,10 @@ // 新增FAI巡检记录 saveData(){ + if (this.modalData.seqNo === '' || this.modalData.seqNo == null) { + this.$message.warning('请选择派工单!') + return + } if (this.modalData.orderNo === '' || this.modalData.orderNo == null) { this.$message.warning('请选择工单!') return @@ -1122,6 +1158,8 @@ resourceId: '', resourceDesc: '', rollQty: '', + seqNo: '', + batchRollNo: '' }; this.operationList = []; this.resourceList = []; @@ -1359,7 +1397,7 @@ this.saveInformationData.inspectionRemark = this.detailData.inspectionRemark this.saveInformationData.itemList = JSON.parse(JSON.stringify(this.detailList)) saveFQCDetailedRecord(this.saveInformationData).then(({data}) => { - if (data && data.code == '0') { + if (data && data.code === 0) { this.getDataList() this.detailInformationFlag = false } else { diff --git a/src/views/modules/qc/IPQCResultEntry.vue b/src/views/modules/qc/IPQCResultEntry.vue index 6197137..4e508d1 100644 --- a/src/views/modules/qc/IPQCResultEntry.vue +++ b/src/views/modules/qc/IPQCResultEntry.vue @@ -143,21 +143,12 @@ - - 工单号 - + + 派工单号 + - - - - - - - - - - - + + @@ -184,7 +175,7 @@ - + - - + + + + + + + + + + + + + + + + + @@ -575,6 +581,8 @@ resourceId: '', resourceDesc: '', rollQty: '', + seqNo: '', + batchRollNo: '' }, // 展示列集 columnList: [ @@ -662,6 +670,18 @@ status: true, fixed: '', }, + { + columnProp: 'seqNo', + headerAlign: "center", + align: "center", + columnLabel: '派工单号', + columnHidden: false, + columnImage: false, + columnSortable: false, + sortLv: 0, + status: true, + fixed: '', + }, { columnProp: 'operationDesc', headerAlign: "center", @@ -1043,35 +1063,42 @@ partList: [], IPQCSelections: [], rules:{ - orderNoType:[ + seqNoType: [ + { + required: true, + message: ' ', + trigger: 'change' + } + ], + orderNoType: [ { required: true, message: ' ', trigger: 'change' } ], - operationDescType:[ + operationDescType: [ { required: true, message: ' ', trigger: 'change' } ], - resourceIdType:[ + resourceIdType: [ { required: true, message: ' ', trigger: 'change' } ], - partNoType:[ + partNoType: [ { required: true, message: ' ', trigger: 'change' } ], - rollQtyType:[ + rollQtyType: [ { required: true, message: ' ', @@ -1084,7 +1111,7 @@ message: ' ', trigger: 'change' } - ] + ], }, // orderNoData:{ // limit: 10, @@ -1223,7 +1250,7 @@ this.$nextTick(() => { let strVal = '' if (val === 1052) { - strVal = this.modalData.orderNo + strVal = this.modalData.seqNo this.$refs.baseList.init(val, strVal) } }) @@ -1232,7 +1259,10 @@ /* 列表方法的回调 */ getBaseData (val) { if (this.tagNo === 1052) { + this.modalData.seqNo = val.seqno this.modalData.orderNo = val.orderno + this.modalData.operationDesc = '' + this.modalData.resourceId = '' this.getOperationList() this.getPartList() } @@ -1358,6 +1388,8 @@ resourceId: '', resourceDesc: '', rollQty: '', + seqNo: '', + batchRollNo: '' }; this.operationList = []; this.resourceList = []; @@ -1368,6 +1400,10 @@ // 新增IPQC巡检记录 saveData(){ + if (this.modalData.seqNo === '' || this.modalData.seqNo == null) { + this.$message.warning('请选择派工单!') + return + } if (this.modalData.orderNo === '' || this.modalData.orderNo == null) { this.$message.warning('请选择工单!') return @@ -1463,7 +1499,7 @@ // 删除检验记录 deleteModal () { - if(this.IPQCSelections.length == 0){ + if(this.IPQCSelections.length === 0){ this.$alert('请勾选要删除的检验单!', '提示', { confirmButtonText: '确定' }) @@ -1500,35 +1536,25 @@ }, Transfer(){ - if (this.detailData.inspectionResult == '' || this.detailData.inspectionResult == null) { + if (this.detailData.inspectionResult === '' || this.detailData.inspectionResult == null) { this.$alert('请选择检验结论!', '错误', { confirmButtonText: '确定' }) return false } - if (this.detailData.inspectorNo == '' || this.detailData.inspectorNo == null) { + if (this.detailData.inspectorNo === '' || this.detailData.inspectorNo == null) { this.$alert('请选择检验员!', '错误', { confirmButtonText: '确定' }) return false } - // if (this.detailData.inspectionResult == 'Y' && (this.detailData.disposalMeasures == '特采' || this.detailData.disposalMeasures == '拒收')) { - // this.$alert('合格不予处置措施,请查看!', '错误', { - // confirmButtonText: '确定' - // }) - // return false - // } for (let i = 0; i < this.detailList.length; i++) { - if(this.detailList[i].itemResult == '' || this.detailList[i].itemResult == null){ - // this.$alert(this.detailList[i].itemDesc+'是否合格未确认!', '错误', { - // confirmButtonText: '确定' - // }) - // return false + if(this.detailList[i].itemResult === '' || this.detailList[i].itemResult == null){ this.detailList[i].itemResult = 'Y' } - if(this.detailList[i].valueTypeDb == 'N') { + if(this.detailList[i].valueTypeDb === 'N') { checkIPQCSubDetailValue(this.detailList[i]).then(({data}) => { - if (data.flag == 2 && this.detailList[i].itemResult == 'Y') { + if (data.flag === 2 && this.detailList[i].itemResult ==='Y') { this.$confirm(this.detailList[i].itemDesc + ' 中实测值不在合格范围!是否保存为合格?', '提示', { confirmButtonText: '确定', cancelButtonText: '取消', @@ -1557,7 +1583,7 @@ this.saveInformationData.inspectionRemark = this.detailData.inspectionRemark this.saveInformationData.itemList = JSON.parse(JSON.stringify(this.detailList)) saveIPQCDetailedRecord(this.saveInformationData).then(({data}) => { - if (data && data.code == '0') { + if (data && data.code === 0) { this.getDataList() this.detailInformationFlag = false } else { @@ -1685,7 +1711,6 @@ obj.subDetailValue = ""; obj.samplingLocation = ""; this.tableData.push(obj); - console.log(this.tableData) } else { this.$alert("记录已提交!", '错误', { confirmButtonText: '确定' @@ -1780,13 +1805,10 @@ console.log(this.$route.meta.menuId) userFavoriteList(userFavorite).then(({data}) => { for (let i = 0; i < data.list.length; i++) { - // let flag=false; if(this.$route.meta.menuId==data.list[i].menuId){ this.favorite = true - // flag=true; } } - }) }, @@ -1797,17 +1819,10 @@ functionId: this.$route.meta.menuId, } if (this.favorite) { - // 取消收藏 - // this.$confirm(`确定取消收藏`, '提示', { - // confirmButtonText: '确定', - // cancelButtonText: '取消', - // type: 'warning' - // }).then(() => { - removeUserFavorite(userFavorite).then(({data}) => { - this.$message.success(data.msg) - this.favorite = false - }) - // }) + removeUserFavorite(userFavorite).then(({data}) => { + this.$message.success(data.msg) + this.favorite = false + }) } else { // 收藏 saveUserFavorite(userFavorite).then(({data}) => { @@ -1824,7 +1839,6 @@ await qcIPQCInspectionSearch(this.searchData).then(({data}) => { this.exportList= data.page.list; }) - return this.exportList; }, @@ -1847,7 +1861,6 @@ }) json += "}" let s = eval("(" + json + ")") - return s }, } diff --git a/src/views/modules/qc/qcPartAttribute.vue b/src/views/modules/qc/qcPartAttribute.vue index ed53cb6..362efc4 100644 --- a/src/views/modules/qc/qcPartAttribute.vue +++ b/src/views/modules/qc/qcPartAttribute.vue @@ -1148,6 +1148,9 @@ this.dataListOperationSelections = [] this.operation = '' this.resourceId = '' + this.operationData.operationDesc = '' + this.resourceData.resourceId = '' + this.resourceData.resourceDesc = '' this.operationCurrent = -1 this.resourceCurrent = -1 this.selectionManufacturer = [] diff --git a/src/views/modules/qc/qcTemplate.vue b/src/views/modules/qc/qcTemplate.vue index 815c74b..63b0273 100644 --- a/src/views/modules/qc/qcTemplate.vue +++ b/src/views/modules/qc/qcTemplate.vue @@ -1177,6 +1177,7 @@ return } let inData = { + site: this.$store.state.user.site, templateId: this.detailData.templateId, templateName: this.detailData.templateName, // itemNo: this.itemListRow1.itemNo,