diff --git a/jero-web/src/views/projectManagement/components/certificationList/index.vue b/jero-web/src/views/projectManagement/components/certificationList/index.vue index f9b9692ff..91c1a32d1 100644 --- a/jero-web/src/views/projectManagement/components/certificationList/index.vue +++ b/jero-web/src/views/projectManagement/components/certificationList/index.vue @@ -1528,7 +1528,12 @@ let notConditions = [] for (let i = 0; i < this.selectedRowKeysList.length; i++) { if (this.selectedRowKeysList[i].flowStatus == 'List to be checked') { - ids.push(this.selectedRowKeysList[i].id) + if (this.selectedRowKeysList[i].projectCertificationInventoryEOS && (this.selectedRowKeysList[i].projectCertificationInventoryEOS.length > 0 || this.selectedRowKeysList[i].projectCertificationInventoryEOS !== null)) { + this.failedMessage(this.selectedRowKeysList[i].serialNumber + this.$t('platformitemhasbeenassociated') ) + return + }else{ + ids.push(this.selectedRowKeysList[i].id) + } } else { notConditions.push(this.selectedRowKeysList[i].inspectionItem) } @@ -1587,7 +1592,12 @@ this.selectedRowKeysList[i].flowStatus == 'Engineer return' || this.selectedRowKeysList[i].flowStatus == 'Results to be reviewed' || this.selectedRowKeysList[i].flowStatus == 'Review and return') { - ids.push(this.selectedRowKeysList[i].id) + if (this.selectedRowKeysList[i].projectCertificationInventoryEOS && (this.selectedRowKeysList[i].projectCertificationInventoryEOS.length > 0 || this.selectedRowKeysList[i].projectCertificationInventoryEOS !== null)) { + this.failedMessage(this.selectedRowKeysList[i].serialNumber + this.$t('platformitemhasbeenassociated') ) + return + }else{ + ids.push(this.selectedRowKeysList[i].id) + } } else { notConditions.push(this.selectedRowKeysList[i].inspectionItem) } @@ -1605,7 +1615,12 @@ if (this.selectedRowKeysList[i].flowStatus == 'Task to be confirmed' || this.selectedRowKeysList[i].flowStatus == 'Results to be submitted' || this.selectedRowKeysList[i].flowStatus == 'Review and return') { - ids.push(this.selectedRowKeysList[i].id) + if (this.selectedRowKeysList[i].projectCertificationInventoryEOS && (this.selectedRowKeysList[i].projectCertificationInventoryEOS.length > 0 || this.selectedRowKeysList[i].projectCertificationInventoryEOS !== null)) { + this.failedMessage(this.selectedRowKeysList[i].serialNumber + this.$t('platformitemhasbeenassociated') ) + return + }else{ + ids.push(this.selectedRowKeysList[i].id) + } } else { notConditions.push(this.selectedRowKeysList[i].inspectionItem) } @@ -1623,7 +1638,12 @@ if (this.selectedRowKeysList[i].flowStatus == 'Task to be confirmed' || this.selectedRowKeysList[i].flowStatus == 'Results to be submitted' || this.selectedRowKeysList[i].flowStatus == 'Review and return') { - ids.push(this.selectedRowKeysList[i].id) + if (this.selectedRowKeysList[i].projectCertificationInventoryEOS && (this.selectedRowKeysList[i].projectCertificationInventoryEOS.length > 0 || this.selectedRowKeysList[i].projectCertificationInventoryEOS !== null)) { + this.failedMessage(this.selectedRowKeysList[i].serialNumber + this.$t('platformitemhasbeenassociated') ) + return + }else{ + ids.push(this.selectedRowKeysList[i].id) + } } else { notConditions.push(this.selectedRowKeysList[i].inspectionItem) } @@ -1818,7 +1838,12 @@ for (let i = 0; i < this.selectedRowKeysList.length; i++) { if (this.selectedRowKeysList[i].dutyPersonName == this.userInfo().username) { if (this.selectedRowKeysList[i].flowStatus == 'Results to be submitted') { - ids.push(this.selectedRowKeysList[i].id) + if (this.selectedRowKeysList[i].projectCertificationInventoryEOS && (this.selectedRowKeysList[i].projectCertificationInventoryEOS.length > 0 || this.selectedRowKeysList[i].projectCertificationInventoryEOS !== null)) { + this.failedMessage(this.selectedRowKeysList[i].serialNumber + this.$t('platformitemhasbeenassociated') ) + return + }else{ + ids.push(this.selectedRowKeysList[i].id) + } } else { notConditions.push(this.selectedRowKeysList[i].inspectionItem) } @@ -1829,7 +1854,12 @@ } else { for (let i = 0; i < this.selectedRowKeysList.length; i++) { if (this.selectedRowKeysList[i].flowStatus == 'Results to be submitted') { - ids.push(this.selectedRowKeysList[i].id) + if (this.selectedRowKeysList[i].projectCertificationInventoryEOS && (this.selectedRowKeysList[i].projectCertificationInventoryEOS.length > 0 || this.selectedRowKeysList[i].projectCertificationInventoryEOS !== null)) { + this.failedMessage(this.selectedRowKeysList[i].serialNumber + this.$t('platformitemhasbeenassociated') ) + return + }else{ + ids.push(this.selectedRowKeysList[i].id) + } } else { notConditions.push(this.selectedRowKeysList[i].inspectionItem) } @@ -1865,7 +1895,12 @@ if (this.selectedRowKeysList[i].flowStatus == 'Task to be confirmed' || this.selectedRowKeysList[i].flowStatus == 'Results to be submitted' || this.selectedRowKeysList[i].flowStatus == 'Review and return') { - this.toDoIds.push(this.selectedRowKeysList[i].id) + if (this.selectedRowKeysList[i].projectCertificationInventoryEOS && (this.selectedRowKeysList[i].projectCertificationInventoryEOS.length > 0 || this.selectedRowKeysList[i].projectCertificationInventoryEOS !== null)) { + this.failedMessage(this.selectedRowKeysList[i].serialNumber + this.$t('platformitemhasbeenassociated') ) + return + }else{ + this.toDoIds.push(this.selectedRowKeysList[i].id) + } } else { this.toDoNotConditions.push(this.selectedRowKeysList[i].inspectionItem) } @@ -1982,10 +2017,20 @@ if (this.selectedRowKeysList[i].flowStatus == 'List to be checked' || this.selectedRowKeysList[i].flowStatus == 'Refusal of responsible person') { if (this.selectedRowKeysList[i].deliverableType == '1635545748968783874') { - NAId.push(this.selectedRowKeysList[i].id) + if (this.selectedRowKeysList[i].projectCertificationInventoryEOS && (this.selectedRowKeysList[i].projectCertificationInventoryEOS.length > 0 || this.selectedRowKeysList[i].projectCertificationInventoryEOS !== null)) { + this.failedMessage(this.selectedRowKeysList[i].serialNumber + this.$t('platformitemhasbeenassociated') ) + return + }else{ + NAId.push(this.selectedRowKeysList[i].id) + } } else if (this.selectedRowKeysList[i].dutyPerson && this.selectedRowKeysList[i].deliverableType && this.selectedRowKeysList[i].sdt && this.selectedRowKeysList[i].endTime) { - ids.push(this.selectedRowKeysList[i].id) + if (this.selectedRowKeysList[i].projectCertificationInventoryEOS && (this.selectedRowKeysList[i].projectCertificationInventoryEOS.length > 0 || this.selectedRowKeysList[i].projectCertificationInventoryEOS !== null)) { + this.failedMessage(this.selectedRowKeysList[i].serialNumber + this.$t('platformitemhasbeenassociated') ) + return + }else{ + ids.push(this.selectedRowKeysList[i].id) + } } else { notConditions.push(this.selectedRowKeysList[i].inspectionItem) } @@ -2025,7 +2070,12 @@ for (let i = 0; i < this.selectedRowKeysList.length; i++) { if (this.selectedRowKeysList[i].flowStatus == 'List to be checked' || this.selectedRowKeysList[i].flowStatus == 'Refusal of responsible person') { - ids.push(this.selectedRowKeysList[i].id) + if (this.selectedRowKeysList[i].projectCertificationInventoryEOS && (this.selectedRowKeysList[i].projectCertificationInventoryEOS.length > 0 || this.selectedRowKeysList[i].projectCertificationInventoryEOS !== null)) { + this.failedMessage(this.selectedRowKeysList[i].serialNumber + this.$t('platformitemhasbeenassociated') ) + return + }else{ + ids.push(this.selectedRowKeysList[i].id) + } } else { notConditions.push(this.selectedRowKeysList[i].inspectionItem) } @@ -2055,7 +2105,12 @@ let notConditions = [] for (let i = 0; i < this.selectedRowKeysList.length; i++) { if (this.selectedRowKeysList[i].flowStatus == 'Task to be confirmed') { - ids.push(this.selectedRowKeysList[i].id) + if (this.selectedRowKeysList[i].projectCertificationInventoryEOS && (this.selectedRowKeysList[i].projectCertificationInventoryEOS.length > 0 || this.selectedRowKeysList[i].projectCertificationInventoryEOS !== null)) { + this.failedMessage(this.selectedRowKeysList[i].serialNumber + this.$t('platformitemhasbeenassociated') ) + return + }else{ + ids.push(this.selectedRowKeysList[i].id) + } } else { notConditions.push(this.selectedRowKeysList[i].inspectionItem) } @@ -2084,7 +2139,12 @@ for (let i = 0; i < this.selectedRowKeysList.length; i++) { if (this.selectedRowKeysList[i].flowStatus == 'Task to be confirmed' && this.selectedRowKeysList[i].dutyPersonName == this.userInfo().username) { - ids.push(this.selectedRowKeysList[i].id) + if (this.selectedRowKeysList[i].projectCertificationInventoryEOS && (this.selectedRowKeysList[i].projectCertificationInventoryEOS.length > 0 || this.selectedRowKeysList[i].projectCertificationInventoryEOS !== null)) { + this.failedMessage(this.selectedRowKeysList[i].serialNumber + this.$t('platformitemhasbeenassociated') ) + return + }else{ + ids.push(this.selectedRowKeysList[i].id) + } } else { notConditions.push(this.selectedRowKeysList[i].inspectionItem) } @@ -2126,7 +2186,12 @@ for (let i = 0; i < this.selectedRowKeysList.length; i++) { if (this.selectedRowKeysList[i].flowStatus == 'Results to be submitted' || this.selectedRowKeysList[i].flowStatus == 'Review and return') { - ids.push(this.selectedRowKeysList[i].id) + if (this.selectedRowKeysList[i].projectCertificationInventoryEOS && (this.selectedRowKeysList[i].projectCertificationInventoryEOS.length > 0 || this.selectedRowKeysList[i].projectCertificationInventoryEOS !== null)) { + this.failedMessage(this.selectedRowKeysList[i].serialNumber + this.$t('platformitemhasbeenassociated') ) + return + }else{ + ids.push(this.selectedRowKeysList[i].id) + } } else { notConditions.push(this.selectedRowKeysList[i].inspectionItem) } @@ -2153,7 +2218,12 @@ if ((this.selectedRowKeysList[i].flowStatus == 'Results to be submitted' || this.selectedRowKeysList[i].flowStatus == 'Review and return') && this.selectedRowKeysList[i].dutyPersonName == this.userInfo().username) { - ids.push(this.selectedRowKeysList[i].id) + if (this.selectedRowKeysList[i].projectCertificationInventoryEOS && (this.selectedRowKeysList[i].projectCertificationInventoryEOS.length > 0 || this.selectedRowKeysList[i].projectCertificationInventoryEOS !== null)) { + this.failedMessage(this.selectedRowKeysList[i].serialNumber + this.$t('platformitemhasbeenassociated') ) + return + }else{ + ids.push(this.selectedRowKeysList[i].id) + } } else { notConditions.push(this.selectedRowKeysList[i].inspectionItem) } @@ -2179,10 +2249,20 @@ let _this = this for (let i = 0; i < this.selectedRowKeysList.length; i++) { if (this.selectedRowKeysList[i].flowStatus == 'Results to be reviewed') { - ids.push(this.selectedRowKeysList[i].id) + if (this.selectedRowKeysList[i].projectCertificationInventoryEOS && (this.selectedRowKeysList[i].projectCertificationInventoryEOS.length > 0 || this.selectedRowKeysList[i].projectCertificationInventoryEOS !== null)) { + this.failedMessage(this.selectedRowKeysList[i].serialNumber + this.$t('platformitemhasbeenassociated') ) + return + }else{ + ids.push(this.selectedRowKeysList[i].id) + } } else if (this.selectedRowKeysList[i].flowStatus == 'Review and pass' && value == 'rzgcssc_th') { - ids.push(this.selectedRowKeysList[i].id) - isTrue = true + if (this.selectedRowKeysList[i].projectCertificationInventoryEOS && (this.selectedRowKeysList[i].projectCertificationInventoryEOS.length > 0 || this.selectedRowKeysList[i].projectCertificationInventoryEOS !== null)) { + this.failedMessage(this.selectedRowKeysList[i].serialNumber + this.$t('platformitemhasbeenassociated') ) + return + }else{ + ids.push(this.selectedRowKeysList[i].id) + isTrue = true + } } else { notConditions.push(this.selectedRowKeysList[i].inspectionItem) } @@ -2346,9 +2426,19 @@ for (let i = 0; i < this.selectedRowKeysList.length; i++) { if (this.selectedRowKeysList[i].flowStatus == 'Review and pass') { if (this.roleSwitchingCode == 20 && this.selectedRowKeysList[i].dutyPersonName == this.userInfo().username) { - ids.push(this.selectedRowKeysList[i].id) + if (this.selectedRowKeysList[i].projectCertificationInventoryEOS && (this.selectedRowKeysList[i].projectCertificationInventoryEOS.length > 0 || this.selectedRowKeysList[i].projectCertificationInventoryEOS !== null)) { + this.failedMessage(this.selectedRowKeysList[i].serialNumber + this.$t('platformitemhasbeenassociated') ) + return + }else{ + ids.push(this.selectedRowKeysList[i].id) + } } else if (this.roleSwitchingCode == 21) { - ids.push(this.selectedRowKeysList[i].id) + if (this.selectedRowKeysList[i].projectCertificationInventoryEOS && (this.selectedRowKeysList[i].projectCertificationInventoryEOS.length > 0 || this.selectedRowKeysList[i].projectCertificationInventoryEOS !== null)) { + this.failedMessage(this.selectedRowKeysList[i].serialNumber + this.$t('platformitemhasbeenassociated') ) + return + }else{ + ids.push(this.selectedRowKeysList[i].id) + } } else { notConditions.push(this.selectedRowKeysList[i].inspectionItem) } diff --git a/jero-web/src/views/projectManagement/components/listOfRegulations.vue b/jero-web/src/views/projectManagement/components/listOfRegulations.vue index 822b1ad18..2392a3867 100644 --- a/jero-web/src/views/projectManagement/components/listOfRegulations.vue +++ b/jero-web/src/views/projectManagement/components/listOfRegulations.vue @@ -2149,7 +2149,12 @@ contentList[i].designFlowStatus == 'List to be checked' || contentList[i].verifyFlowStatus == 'Duty Person Rejected' || contentList[i].designFlowStatus == 'Duty Person Rejected') { - idList.push(contentList[i].id) + if (contentList[i].projectLawsInventoryEOS && (contentList[i].projectLawsInventoryEOS.length > 0 || contentList[i].projectLawsInventoryEOS !== null)) { + detailedWarningList.push( + < div > { contentList[i].serialNumber + this.$t('platformitemhasbeenassociated') } < /div>) + }else{ + idList.push(contentList[i].id) + } } else if (contentList[i].designFlowStatus == 'NA' || contentList[i].verifyFlowStatus == 'NA') { detailedWarningList.push( < div > { contentList[i].serialNumber + this.$t('pleaseSelectTheDataverificationVerified') } < /div>) @@ -2268,7 +2273,12 @@ content[i].designFlowStatus == 'Results to be submitted' || content[i].verifyFlowStatus == 'Results to be reviewed' || content[i].designFlowStatus == 'Results to be reviewed') { - this.questionIdList.push(content[i].id) + if (content[i].projectLawsInventoryEOS && (content[i].projectLawsInventoryEOS.length > 0 || content[i].projectLawsInventoryEOS !== null)) { + this.questionWarning.push( + < div > { content[i].serialNumber + this.$t('platformitemhasbeenassociated') } < /div>) + }else{ + this.questionIdList.push(content[i].id) + } } else { detailedWarningList.push(content[i].serialNumber) } @@ -3459,7 +3469,11 @@ isVerify = true } if (isDesign || isVerify) { - this.$refs.toResubmitFormRef.getData(dataSource[0], isDesign, isVerify) + if (dataSource[0].projectLawsInventoryEOS && (dataSource[0].projectLawsInventoryEOS.length > 0 || dataSource[0].projectLawsInventoryEOS !== null)) { + this.$message.warning(dataSource[0].serialNumber + this.$t('platformitemhasbeenassociated')) + }else{ + this.$refs.toResubmitFormRef.getData(dataSource[0], isDesign, isVerify) + } } else { this.$message.warning(this.$t('selectDesignConformanceAsConformance')) }