对接认证清单

This commit is contained in:
范强强
2023-03-08 15:16:51 +08:00
parent 73d551bc6d
commit 74b39431a5
5 changed files with 114 additions and 23 deletions
+6
View File
@@ -1406,4 +1406,10 @@ module.exports = {
missionRejection:'Mission Rejection',
turnToDo:'Turn To Do',
initiateTask:'Initiate a Task',
areYouReturnToStudio:'Are you sure to return to studio?',
confirmLaunchTask:'Confirm launch task ?',
conditionsNotMet:'Conditions not met',
onlyProcessStatusReturned:'Only the data whose process status is list to be checked and rejected by the responsible person can be returned',
onlyProcessReturned:'Only data with process status of list to be checked and rejected by responsible person can be initiated',
}
+5
View File
@@ -1507,4 +1507,9 @@ module.exports = {
missionRejection:'任务拒绝',
turnToDo:'转办',
initiateTask:'发起任务',
areYouReturnToStudio:'确认退回至studio吗?',
confirmLaunchTask:'确认发起任务?',
conditionsNotMet:'不满足条件',
onlyProcessStatusReturned:'只能退回流程状态为清单待校核和责任人拒绝的数据',
onlyProcessReturned:'只能发起流程状态为清单待校核和责任人拒绝的数据',
}
@@ -241,6 +241,9 @@
} else if (this.$route.query.type == '105') {
this.textColor(this.$t('TaskParameterCollection'))
this.textTitle = this.$t('TaskParameterCollection')
}else if (this.$route.query.type == '106') {
this.textColor(this.$t('certificationList'))
this.textTitle = this.$t('certificationList')
}
} else {
if (this.userInfo().userRoleList && this.userInfo().userRoleList.length > 0) {
@@ -186,13 +186,15 @@
</div>
<!-- 发起任务-->
<div @click="initiatingProcessClick" v-if="roleSwitchingCode == 2" class="operator-text">
<div @click="initiatingProcessClick('rzgcsjsrw',$t('confirmLaunchTask'))"
v-if="roleSwitchingCode == 2" class="operator-text">
<a-icon type="check-circle"/>
{{ $t('initiateTask') }}
</div>
<!-- 退回至Studio-->
<div @click="returnToStudioClick" v-if="roleSwitchingCode == 2" class="operator-text">
<div @click="returnToStudioClick('rzgcsthrw',$t('areYouReturnToStudio'))"
v-if="roleSwitchingCode == 2" class="operator-text">
<a-icon type="close-circle"/>
{{ $t('returnToStudio') }}
</div>
@@ -1032,14 +1034,6 @@
} else {
this.$message.warning(this.$t('selectLeastOne'))
}
},
//发起流程
initiatingProcessClick() {
},
//退回至Studio
returnToStudioClick() {
},
//审批通过
ApprovedClick() {
@@ -1095,24 +1089,90 @@
item.roleCode = this.roleSwitchingCode
this.$refs.TaskListModelRef.getData(item, this.$t('CertificationProgress'))
},
submitTask(value) {
//发起流程
initiatingProcessClick(value, prompt) {
if (this.selectedRowKeys && this.selectedRowKeys.length > 0) {
let selectedRowKeys = JSON.parse(JSON.stringify(this.selectedRowKeys))
let query = {
'nodeKey': value,
'projectLibraryId': this.$route.query.id,
'ids': selectedRowKeys.join(',')
}
postAction('/project/projectCertificationInventoryEO/submitTask', query).then((res) => {
if (res.success) {
let ids = []
let notConditions = []
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)
} else {
notConditions.push(this.selectedRowKeysList[i].serialNumber)
}
})
}
let data = ''
if (notConditions && notConditions.length > 0) {
data = this.$t('standardNo') + '"' + notConditions.join('、') + '"' + this.$t('conditionsNotMet') + ',' + this.$t('onlyProcessReturned')
}
if (ids && ids.length > 0) {
this.submitTask(value, prompt, ids, notConditions, data)
} else {
this.failedMessage(data)
}
} else {
this.$message.warning(this.$t('selectLeastOne'))
}
},
//退回至Studio
returnToStudioClick(value, prompt) {
if (this.selectedRowKeys && this.selectedRowKeys.length > 0) {
let ids = []
let notConditions = []
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)
} else {
notConditions.push(this.selectedRowKeysList[i].serialNumber)
}
}
let data = ''
if (notConditions && notConditions.length > 0) {
data = this.$t('standardNo') + '"' + notConditions.join('、') + '"' + this.$t('conditionsNotMet') + ',' + this.$t('onlyProcessStatusReturned')
}
if (ids && ids.length > 0) {
this.submitTask(value, prompt, ids, notConditions, data)
} else {
this.failedMessage(data)
}
} else {
this.$message.warning(this.$t('selectLeastOne'))
}
},
failedMessage(data) {
let detailedWarningList = []
detailedWarningList.push(data)
this.$warning({
content: ( < div > { detailedWarningList } < /div>)
})
},
submitTask(value, prompt, ids, notConditions, data) {
let _this = this
this.$confirm({
content: prompt,
onOk() {
let query = {
'nodeKey': value,
'projectLibraryId': _this.$route.query.id,
'ids': ids.join(',')
}
postAction('/project/projectCertificationInventoryEO/submitTask', 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'))
}
})
}
})
}
}
}
@@ -28,6 +28,9 @@
</a>
<span v-else>--</span>
</span>
<span slot="taskStatus" slot-scope="text,record">
<span>{{text ? text : '--'}}</span>
</span>
</a-table>
<div class="page" v-if="dataSource && dataSource.length > 0">
<a-pagination
@@ -99,7 +102,8 @@
align: 'left',
dataIndex: 'statusShow',
ellipsis: true,
width: 170
width: 170,
scopedSlots: { customRender: 'taskStatus' }
},
{
title: this.$t('operation'),
@@ -174,6 +178,19 @@
}
})
window.open(newUrl.href, '_blank')
}else if (row.flowType == '21') {
let newUrl = this.$router.resolve({
path: '/ProjectDetails',
query: {
id: row.projectLibraryId,
projectName: row.projectName,
projectNameId: row.projectNameId,
targetMarket: row.targetMarket,
studioEngineer: row.studioEngineer,
type: '106'
}
})
window.open(newUrl.href, '_blank')
} else if (row.flowType == '2') {
row.taskId = row.taskId + ''
if (row.taskId.length > 30) {