Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
phsl
/
admin
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
4e0e8dd2
authored
Jan 17, 2025
by
Lesan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat: bpmn跳过表达式
parent
8e5271a6
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
42 additions
and
1 deletions
+42
-1
src/components/bpmnProcessDesigner/package/designer/plugins/descriptor/flowableDescriptor.json
+11
-0
src/components/bpmnProcessDesigner/package/penal/task/task-components/UserTask.vue
+31
-1
No files found.
src/components/bpmnProcessDesigner/package/designer/plugins/descriptor/flowableDescriptor.json
View file @
4e0e8dd2
...
...
@@ -1438,6 +1438,17 @@
"isBody"
:
true
}
]
},
{
"name"
:
"SkipExpression"
,
"extends"
:
[
"bpmn:UserTask"
],
"properties"
:
[
{
"name"
:
"skipExpression"
,
"isAttr"
:
true
,
"type"
:
"String"
}
]
}
],
"emumerations"
:
[]
...
...
src/components/bpmnProcessDesigner/package/penal/task/task-components/UserTask.vue
View file @
4e0e8dd2
...
...
@@ -192,6 +192,16 @@
<!-- 选择弹窗 -->
<ProcessExpressionDialog
ref=
"processExpressionDialogRef"
@
select=
"selectProcessExpression"
/>
</el-form-item>
<el-form-item
label=
"跳过表达式"
prop=
"skipExpression"
>
<el-input
type=
"textarea"
v-model=
"userTaskForm.skipExpression"
clearable
style=
"width: 100%"
@
change=
"updateSkipExpression"
/>
</el-form-item>
</el-form>
</
template
>
...
...
@@ -220,7 +230,8 @@ const props = defineProps({
const
prefix
=
inject
(
'prefix'
)
const
userTaskForm
=
ref
({
candidateStrategy
:
undefined
,
// 分配规则
candidateParam
:
[]
// 分配选项
candidateParam
:
[],
// 分配选项
skipExpression
:
''
// 跳过表达式
})
const
bpmnElement
=
ref
()
const
bpmnInstances
=
()
=>
(
window
as
any
)?.
bpmnInstances
...
...
@@ -311,6 +322,13 @@ const resetTaskForm = () => {
(
ex
)
=>
ex
.
$type
!==
`
${
prefix
}
:CandidateStrategy`
&&
ex
.
$type
!==
`
${
prefix
}
:CandidateParam`
)
??
[]
// 跳过表达式
if
(
businessObject
.
skipExpression
!=
undefined
)
{
userTaskForm
.
value
.
skipExpression
=
businessObject
.
skipExpression
}
else
{
userTaskForm
.
value
.
skipExpression
=
''
}
// 改用通过extensionElements来存储数据
return
if
(
businessObject
.
candidateStrategy
!=
undefined
)
{
...
...
@@ -390,6 +408,18 @@ const updateElementTask = () => {
})
}
const
updateSkipExpression
=
()
=>
{
if
(
userTaskForm
.
value
.
skipExpression
&&
userTaskForm
.
value
.
skipExpression
!==
''
)
{
bpmnInstances
().
modeling
.
updateProperties
(
toRaw
(
bpmnElement
.
value
),
{
skipExpression
:
userTaskForm
.
value
.
skipExpression
})
}
else
{
bpmnInstances
().
modeling
.
updateProperties
(
toRaw
(
bpmnElement
.
value
),
{
skipExpression
:
null
})
}
}
// 打开监听器弹窗
const
processExpressionDialogRef
=
ref
()
const
openProcessExpressionDialog
=
async
()
=>
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment