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
d9019c12
authored
Feb 24, 2025
by
YunaiV
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
【代码评审】BPM:触发器 HTTP 异步
parent
32f2d406
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
11 additions
and
7 deletions
+11
-7
src/components/SimpleProcessDesignerV2/src/consts.ts
+8
-6
src/components/SimpleProcessDesignerV2/src/nodes-config/TriggerNodeConfig.vue
+3
-1
No files found.
src/components/SimpleProcessDesignerV2/src/consts.ts
View file @
d9019c12
...
@@ -756,6 +756,7 @@ export enum TriggerTypeEnum {
...
@@ -756,6 +756,7 @@ export enum TriggerTypeEnum {
* 发送 HTTP 请求触发器
* 发送 HTTP 请求触发器
*/
*/
HTTP_REQUEST
=
1
,
HTTP_REQUEST
=
1
,
// TODO @jason:要不把 FORM_UPDATE、FORM_DELETE 调整从 10、11 这样?
/**
/**
* 表单数据更新触发器
* 表单数据更新触发器
*/
*/
...
@@ -764,6 +765,7 @@ export enum TriggerTypeEnum {
...
@@ -764,6 +765,7 @@ export enum TriggerTypeEnum {
* 表单数据删除触发器
* 表单数据删除触发器
*/
*/
FORM_DELETE
=
3
,
FORM_DELETE
=
3
,
// TODO @jason:1)HTTP_REQUEST_ASYNC 这个枚举值?;2)枚举值改成 2?;3)【有点纠结,微信讨论】异步是里面加个属性 async 属性,还是作为单独的枚举值。
/**
/**
* 发起异步 HTTP 请求
* 发起异步 HTTP 请求
*/
*/
...
@@ -795,7 +797,7 @@ export type FormTriggerSetting = {
...
@@ -795,7 +797,7 @@ export type FormTriggerSetting = {
// 条件组
// 条件组
conditionGroups
?:
ConditionGroup
conditionGroups
?:
ConditionGroup
// 更新表单字段配置
// 更新表单字段配置
updateFormFields
?:
Record
<
string
,
any
>
,
updateFormFields
?:
Record
<
string
,
any
>
// 删除表单字段配置
// 删除表单字段配置
deleteFields
?:
string
[]
deleteFields
?:
string
[]
}
}
...
@@ -813,11 +815,11 @@ export const TRIGGER_TYPES: DictDataVO[] = [
...
@@ -813,11 +815,11 @@ export const TRIGGER_TYPES: DictDataVO[] = [
export
type
ChildProcessSetting
=
{
export
type
ChildProcessSetting
=
{
calledProcessDefinitionKey
:
string
calledProcessDefinitionKey
:
string
calledProcessDefinitionName
:
string
calledProcessDefinitionName
:
string
async
:
boolean
,
async
:
boolean
inVariables
?:
IOParameter
[]
,
inVariables
?:
IOParameter
[]
outVariables
?:
IOParameter
[]
,
outVariables
?:
IOParameter
[]
skipStartUserNode
:
boolean
,
skipStartUserNode
:
boolean
startUserSetting
:
StartUserSetting
,
startUserSetting
:
StartUserSetting
}
}
export
type
IOParameter
=
{
export
type
IOParameter
=
{
...
...
src/components/SimpleProcessDesignerV2/src/nodes-config/TriggerNodeConfig.vue
View file @
d9019c12
...
@@ -36,6 +36,7 @@
...
@@ -36,6 +36,7 @@
</el-select>
</el-select>
</el-form-item>
</el-form-item>
<!-- HTTP 请求触发器 -->
<!-- HTTP 请求触发器 -->
<!-- TODO @jason:可以考虑用 [].include 更简洁 -->
<div
<div
v-if=
"
v-if=
"
(configForm.type === TriggerTypeEnum.HTTP_REQUEST ||
(configForm.type === TriggerTypeEnum.HTTP_REQUEST ||
...
@@ -408,7 +409,8 @@ const changeTriggerType = () => {
...
@@ -408,7 +409,8 @@ const changeTriggerType = () => {
if
(
configForm
.
value
.
type
===
TriggerTypeEnum
.
ASYNC_HTTP_REQUEST
)
{
if
(
configForm
.
value
.
type
===
TriggerTypeEnum
.
ASYNC_HTTP_REQUEST
)
{
configForm
.
value
.
httpRequestSetting
=
configForm
.
value
.
httpRequestSetting
=
originalSetting
?.
type
===
TriggerTypeEnum
.
ASYNC_HTTP_REQUEST
&&
originalSetting
.
httpRequestSetting
originalSetting
?.
type
===
TriggerTypeEnum
.
ASYNC_HTTP_REQUEST
&&
originalSetting
.
httpRequestSetting
?
originalSetting
.
httpRequestSetting
?
originalSetting
.
httpRequestSetting
:
{
:
{
url
:
''
,
url
:
''
,
...
...
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