Merge remote-tracking branch 'origin/master'
This commit is contained in:
@@ -77,6 +77,7 @@
|
||||
import { ACCESS_TOKEN } from '@/store/mutation-types'
|
||||
import ImportFile from '@/components/ImportFile/index'
|
||||
import Vue from 'vue'
|
||||
import moment from 'moment'
|
||||
|
||||
export default {
|
||||
name: 'docLibrary',
|
||||
@@ -141,7 +142,8 @@
|
||||
...this.$refs.searchRef.queryParam,
|
||||
id: this.idList.join(',')
|
||||
}
|
||||
downloadFile('document/bussDocumentLibraryEO/exportExcel', this.$t('DocumentLibrary')+'.xls', query, this.Deselect)
|
||||
let handlingTime = moment(new Date()).format('YYYY-MM-DD')
|
||||
downloadFile('document/bussDocumentLibraryEO/exportExcel', this.$t('DocumentLibrary')+handlingTime+'.xls', query, this.Deselect)
|
||||
},
|
||||
Deselect() {
|
||||
this.$refs.tableDataRef.selectedRowKeys = []
|
||||
@@ -154,7 +156,8 @@
|
||||
id: this.idList.join(','),
|
||||
flag: 'file'
|
||||
}
|
||||
downloadFile('document/bussDocumentLibraryEO/exportZip', '文档库.zip', query, this.Deselect)
|
||||
let handlingTime = moment(new Date()).format('YYYY-MM-DD')
|
||||
downloadFile('document/bussDocumentLibraryEO/exportZip', this.$t('DocumentLibrary')+handlingTime+'.zip', query, this.Deselect)
|
||||
},
|
||||
//新增
|
||||
handleAdd() {
|
||||
@@ -162,7 +165,8 @@
|
||||
},
|
||||
//下载模板
|
||||
handleModule() {
|
||||
downloadFile('document/bussDocumentLibraryEO/exportTemplate', '文档库导入模板.xls', {})
|
||||
|
||||
downloadFile('document/bussDocumentLibraryEO/exportTemplate', this.$t('importTemplate')+this.$t('importTemplate')+'.xls', {})
|
||||
},
|
||||
//批量删除
|
||||
handleDel() {
|
||||
|
||||
@@ -126,7 +126,7 @@
|
||||
name: this.$t('experimentFailed'),
|
||||
status: res.certificationProgress
|
||||
})
|
||||
color.push('#FF8543')
|
||||
color.push('#E83030')
|
||||
this.dataSource[0].experimentFailed = res.certificationProgressCount
|
||||
} else if (res.certificationProgress == 'Test passed') {
|
||||
data.push({
|
||||
|
||||
@@ -1077,9 +1077,11 @@
|
||||
}
|
||||
})
|
||||
} else {
|
||||
let index = 0
|
||||
for (let i = 0; i < this.dataSource.length; i++) {
|
||||
for (let j = 0; j < selectedRowKeys.length; j++) {
|
||||
if (this.dataSource[i].id == selectedRowKeys[j]) {
|
||||
index++
|
||||
this.dataSource[i].taskAffirmDueDate = this.formInline.taskAffirmDueDate
|
||||
Object.keys(this.dataSource[i]).forEach(res => {
|
||||
if (this.dataSource[i][res] && this.dataSource[i][res] instanceof String) {
|
||||
@@ -1089,7 +1091,7 @@
|
||||
})
|
||||
setTimeout(() => {
|
||||
this.confirmLoading = true
|
||||
this.startProcess(this.dataSource[i])
|
||||
this.startProcess(this.dataSource[i],index)
|
||||
}, 500)
|
||||
}
|
||||
}
|
||||
@@ -1099,7 +1101,7 @@
|
||||
})
|
||||
},
|
||||
|
||||
startProcess(value) {
|
||||
startProcess(value,index) {
|
||||
let query = {
|
||||
type: 1,
|
||||
msg: JSON.stringify(value).replace(/\"/g, '\''),
|
||||
@@ -1110,12 +1112,12 @@
|
||||
}
|
||||
postAction('/workFlow/startProcess', query).then((res) => {
|
||||
if (res.success) {
|
||||
this.completeTask(value, res.result)
|
||||
this.completeTask(value, res.result,index)
|
||||
}
|
||||
})
|
||||
},
|
||||
|
||||
completeTask(value, taskId) {
|
||||
completeTask(value, taskId,index) {
|
||||
let handlingTime = moment(new Date()).format('YYYY-MM-DD HH:mm:ss')
|
||||
value.handlingTime = handlingTime
|
||||
let query = {
|
||||
@@ -1125,11 +1127,13 @@
|
||||
}
|
||||
postAction('/workFlow/completeTask', query).then((res) => {
|
||||
if (res.success) {
|
||||
this.visible = false
|
||||
this.selectedRowKeys = []
|
||||
this.$message.success(this.$t('OperationSuccessful'))
|
||||
this.confirmLoading = false
|
||||
this.getList()
|
||||
if (index == this.selectedRowKeys.length){
|
||||
this.visible = false
|
||||
this.selectedRowKeys = []
|
||||
this.$message.success(this.$t('OperationSuccessful'))
|
||||
this.confirmLoading = false
|
||||
this.getList()
|
||||
}
|
||||
} else {
|
||||
this.$message.warning(this.$t('operationFailed'))
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user