@lambo-design/workflow-approve 1.0.0-beta.89 → 1.0.0-beta.90
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +3 -3
- package/src/components/assignee-box.vue +9 -2
- package/src/portrait.vue +40 -4
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@lambo-design/workflow-approve",
|
|
3
|
-
"version": "1.0.0-beta.
|
|
3
|
+
"version": "1.0.0-beta.90",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"author": "lambo",
|
|
@@ -12,8 +12,8 @@
|
|
|
12
12
|
"devDependencies": {
|
|
13
13
|
"axios": "^0.24.0",
|
|
14
14
|
"axios-cache-plugin": "^0.1.0",
|
|
15
|
-
"@lambo-design/
|
|
16
|
-
"@lambo-design/
|
|
15
|
+
"@lambo-design/shared": "^1.0.0-beta.293",
|
|
16
|
+
"@lambo-design/core": "^4.7.1-beta.168"
|
|
17
17
|
},
|
|
18
18
|
"dependencies": {
|
|
19
19
|
"bpmn-js": "^7.3.1",
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<div>
|
|
3
|
-
<Modal v-model="modalBoxShow" width="1217" title="
|
|
3
|
+
<Modal v-model="modalBoxShow" width="1217" :title="title" @on-ok="onOk" @on-cancel="onCancel" loading>
|
|
4
4
|
<div class="org-info">
|
|
5
5
|
<div class="org-tree" v-if="!useTransferRangeUsers">
|
|
6
6
|
<div class="tree-content">
|
|
@@ -89,6 +89,7 @@ export default {
|
|
|
89
89
|
data() {
|
|
90
90
|
return {
|
|
91
91
|
id: '',
|
|
92
|
+
title: '选择办理人',
|
|
92
93
|
helpBoxType: 'auditTo82',
|
|
93
94
|
ucAdapterType: 'x1',
|
|
94
95
|
useTransferRangeUsers: false,
|
|
@@ -219,6 +220,9 @@ export default {
|
|
|
219
220
|
this.id = id
|
|
220
221
|
this.helpBoxType = helpBoxType
|
|
221
222
|
this.organTreeType = organTreeType
|
|
223
|
+
if (helpBoxType === 'appointHandlerWithCandGroups'){
|
|
224
|
+
this.title = '选择候选人'
|
|
225
|
+
}
|
|
222
226
|
if (data && (data.orgList || data.userList)){
|
|
223
227
|
const {orgList, userList} = data
|
|
224
228
|
if (orgList && orgList.length > 0){
|
|
@@ -287,6 +291,9 @@ export default {
|
|
|
287
291
|
idSelectedArr = [...new Set(idSelectedArr)]
|
|
288
292
|
const assingeeList = idSelectedArr.map(item => item.split(',')[0])
|
|
289
293
|
self.$emit('add-multitask-instance', assingeeList);
|
|
294
|
+
}else if (self.helpBoxType ==='appointHandlerWithCandGroups'){
|
|
295
|
+
idSelectedArr = [...new Set(idSelectedArr)]
|
|
296
|
+
self.$emit('appoint-handler-with-candGroups', idSelectedArr, self.id);
|
|
290
297
|
} else {
|
|
291
298
|
if (idSelectedArr.length > 1) {
|
|
292
299
|
self.loading = false
|
|
@@ -334,7 +341,7 @@ export default {
|
|
|
334
341
|
onSelectionChange: function (selection) {
|
|
335
342
|
let self = this
|
|
336
343
|
// self.idSelectedArr = []
|
|
337
|
-
if (self.helpBoxType !== 'addMultitaskInstance' && selection.length > 1) {
|
|
344
|
+
if (self.helpBoxType !== 'addMultitaskInstance' && self.helpBoxType !== 'appointHandlerWithCandGroups' && selection.length > 1) {
|
|
338
345
|
self.$Message.info('只能选择一条记录!')
|
|
339
346
|
this.$refs.selection.selectAll(false);
|
|
340
347
|
}
|
package/src/portrait.vue
CHANGED
|
@@ -143,6 +143,7 @@
|
|
|
143
143
|
<assigneeBox ref="assigneeHelpBox" :execution-completed="executionCompleted"
|
|
144
144
|
@update-selected="handleSelectedUser" @update-next-node-assignee="updateNextNodeAssignee"
|
|
145
145
|
@add-multitask-instance="addMultitaskInstance" @delegate-task-assignee="delegateTask"
|
|
146
|
+
@appoint-handler-with-candGroups="updateNextNodeCandGroups"
|
|
146
147
|
:data="assigneeBoxData" :smart-flow-server-context="smartFlowServerContext"
|
|
147
148
|
:upms-server-context="upmsServerContext"/>
|
|
148
149
|
<!-- 流程跟踪图弹框 -->
|
|
@@ -1933,14 +1934,14 @@ export default {
|
|
|
1933
1934
|
const oldStr = oldIdList.join(',')
|
|
1934
1935
|
const newStr = newIds.join(',')
|
|
1935
1936
|
return oldStr !== newStr
|
|
1936
|
-
}else {
|
|
1937
|
+
} else {
|
|
1937
1938
|
const allInString = oldIdList.every(item => newIds.includes(item));
|
|
1938
1939
|
const hasExtra = newIds.some(item => !oldIdList.includes(item));
|
|
1939
1940
|
return !allInString || hasExtra
|
|
1940
1941
|
}
|
|
1941
1942
|
|
|
1942
1943
|
}
|
|
1943
|
-
return
|
|
1944
|
+
return !oldSetting !== !newSetting
|
|
1944
1945
|
},
|
|
1945
1946
|
checkTimeLimitUpdate(oldSetting, newSetting) {
|
|
1946
1947
|
if (oldSetting && newSetting) {
|
|
@@ -1959,7 +1960,31 @@ export default {
|
|
|
1959
1960
|
candidateGroupsReadingRangeClick(item) {
|
|
1960
1961
|
let permScope = item.orgTreeType === this.defaultOrganTreeType ? this.permScope : 'all'
|
|
1961
1962
|
let orgTreeType = item.orgTreeType ? item.orgTreeType : this.defaultOrganTreeType
|
|
1962
|
-
|
|
1963
|
+
const self = this
|
|
1964
|
+
const params = {
|
|
1965
|
+
procType: self.procType,
|
|
1966
|
+
procId: self.procId,
|
|
1967
|
+
taskNode: self.taskNode,
|
|
1968
|
+
applyId: self.applyId,
|
|
1969
|
+
taskId: self.curTaskId,
|
|
1970
|
+
processInstanceId: self.instanceId,
|
|
1971
|
+
auditGroup: self.auditGroup,
|
|
1972
|
+
actionType: 'appointHandlerWithCandGroups',
|
|
1973
|
+
}
|
|
1974
|
+
const url = self.smartFlowServerContext + '/manage/nodeConfig/getTransferRange';
|
|
1975
|
+
ajax.post(url, params).then(resp => {
|
|
1976
|
+
if (resp.data.code === '200'){
|
|
1977
|
+
const data = resp.data.data
|
|
1978
|
+
if (data && (data.orgList || data.userList)){
|
|
1979
|
+
self.$refs.assigneeHelpBox.toggleShowHelpBox(orgTreeType, permScope, 'appointHandlerWithCandGroups', item.id, data)
|
|
1980
|
+
} else {
|
|
1981
|
+
this.$refs.candidateGroupsHelpBox.toggleShowHelpBox(permScope, item.candidates, orgTreeType, item.id)
|
|
1982
|
+
}
|
|
1983
|
+
}
|
|
1984
|
+
}).catch(error => {
|
|
1985
|
+
self.$Message.error('获取人员范围失败');
|
|
1986
|
+
console.log(error)
|
|
1987
|
+
})
|
|
1963
1988
|
},
|
|
1964
1989
|
updateCandGroups(newCandGroups, nameStr, detail, nodeId) {
|
|
1965
1990
|
let oldSettings = this.nextNodesOldSettings.filter(item => item.id === nodeId)[0]
|
|
@@ -1972,6 +1997,17 @@ export default {
|
|
|
1972
1997
|
this.$forceUpdate()
|
|
1973
1998
|
}
|
|
1974
1999
|
},
|
|
2000
|
+
updateNextNodeCandGroups(idSelectedArr, nodeId) {
|
|
2001
|
+
const userStr = idSelectedArr.map(item => item.split(',')[0]).join(';')
|
|
2002
|
+
const nameStr = idSelectedArr.map(item => item.split(',')[1]).join(',')
|
|
2003
|
+
const detail = { users: idSelectedArr }
|
|
2004
|
+
let node = this.nextNodesFormList.filter(item => item.id === nodeId)[0]
|
|
2005
|
+
node.candidateGroups = `O:,U:${userStr},P:,R:,RP:,T:`
|
|
2006
|
+
node.candidateNames = nameStr
|
|
2007
|
+
node.candidates = detail
|
|
2008
|
+
node.needUpdate = true
|
|
2009
|
+
this.$forceUpdate()
|
|
2010
|
+
},
|
|
1975
2011
|
updateNextNodeAssignee(selectedAssigneeId, selectedAssigneeName, nodeId) {
|
|
1976
2012
|
let oldSettings = this.nextNodesOldSettings.filter(item => item.id === nodeId)[0]
|
|
1977
2013
|
if (oldSettings.assignee != selectedAssigneeId) {
|
|
@@ -2087,7 +2123,7 @@ export default {
|
|
|
2087
2123
|
self.$refs.assigneeHelpBox.toggleShowHelpBox(organTreeType, permScope, actionType, id, data)
|
|
2088
2124
|
}
|
|
2089
2125
|
}).catch(error => {
|
|
2090
|
-
self.$Message.error('
|
|
2126
|
+
self.$Message.error('获取人员范围失败');
|
|
2091
2127
|
console.log(error)
|
|
2092
2128
|
})
|
|
2093
2129
|
},
|