认证清单添加补充提交按钮
This commit is contained in:
@@ -227,6 +227,14 @@
|
||||
{{ $t('reviewAndReturn') }}
|
||||
</div>
|
||||
|
||||
<!-- 补充提交-->
|
||||
<div @click="supplementarySubmissionClick()"
|
||||
v-if="roleSwitchingCode == 20 || roleSwitchingCode == 21"
|
||||
class="operator-text">
|
||||
<a-icon type="rollback"/>
|
||||
{{ $t('supplementarySubmission') }}
|
||||
</div>
|
||||
|
||||
<!-- 任务接受-->
|
||||
<div @click="missionAcceptedClick('zrrjsrw',$t('confirmToAcceptTheTask'))"
|
||||
v-if="roleSwitchingCode == 20 || roleSwitchingCode == 21"
|
||||
@@ -599,7 +607,7 @@
|
||||
type: 'date',
|
||||
value: 'endTime',
|
||||
text: this.$t('closingDate')
|
||||
},
|
||||
}
|
||||
],
|
||||
disabled: false,
|
||||
queryParamQuery: {},
|
||||
@@ -2106,6 +2114,62 @@
|
||||
}
|
||||
})
|
||||
window.open(newUrl.href, '_blank')
|
||||
},
|
||||
supplementarySubmissionClick() {
|
||||
if (this.selectedRowKeys && this.selectedRowKeys.length > 0) {
|
||||
let ids = []
|
||||
let notConditions = []
|
||||
let _this = this
|
||||
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)
|
||||
} else if (this.roleSwitchingCode == 21) {
|
||||
ids.push(this.selectedRowKeysList[i].id)
|
||||
} else {
|
||||
notConditions.push(this.selectedRowKeysList[i].inspectionItem)
|
||||
}
|
||||
} else {
|
||||
notConditions.push(this.selectedRowKeysList[i].inspectionItem)
|
||||
}
|
||||
}
|
||||
let data = ''
|
||||
if (notConditions && notConditions.length > 0) {
|
||||
if (this.roleSwitchingCode == 20) {
|
||||
data = this.$t('inspectionItems') + '"' + notConditions.join('、') + '"' + this.$t('conditionsNotMet') + ',' + this.$t('onlyProcessStatusOfApprovedCanBeSelected') + this.$t('andTheOperatorCurrentData')
|
||||
} else {
|
||||
data = this.$t('inspectionItems') + '"' + notConditions.join('、') + '"' + this.$t('conditionsNotMet') + ',' + this.$t('onlyProcessStatusOfApprovedCanBeSelected')
|
||||
}
|
||||
}
|
||||
if (ids && ids.length > 0) {
|
||||
this.$confirm({
|
||||
content: _this.$t('confirmSupplementarySubmission'),
|
||||
onOk() {
|
||||
let query = {
|
||||
ids: ids.join(','),
|
||||
'flowStatus': 'Results to be submitted'
|
||||
}
|
||||
postAction('/project/projectCertificationInventoryEO/updateStatusBatch', query).then((res) => {
|
||||
if (res.success) {
|
||||
_this.$message.success(_this.$t('OperationSuccessful'))
|
||||
_this.getList()
|
||||
_this.selectedRowKeys = []
|
||||
_this.selectedRowKeysList = []
|
||||
if (notConditions && notConditions.length > 0) {
|
||||
_this.failedMessage(data)
|
||||
}
|
||||
} else {
|
||||
_this.$message.warning(_this.$t('operationFailed'))
|
||||
}
|
||||
})
|
||||
}
|
||||
})
|
||||
} else {
|
||||
this.failedMessage(data)
|
||||
}
|
||||
} else {
|
||||
this.$message.warning(this.$t('selectLeastOne'))
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user