@steedos-labs/plugin-workflow 3.0.0-beta.22 → 3.0.0-beta.24
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/main/default/objectTranslations/flows.en/flows.en.objectTranslation.yml +19 -0
- package/main/default/objectTranslations/flows.zh-CN/flows.zh-CN.objectTranslation.yml +19 -0
- package/main/default/objects/flows/buttons/del.button.yml +7 -10
- package/main/default/objects/flows/buttons/design_form_layout.button.js +5 -2
- package/main/default/objects/flows/buttons/distributeAdmin.button.yml +5 -5
- package/main/default/objects/forms/forms.object.yml +13 -2
- package/main/default/pages/flowdetail.page.amis.json +9 -9
- package/main/default/routes/flow_form_design.ejs +4 -1
- package/main/default/routes/flow_form_design.router.js +3 -2
- package/main/default/triggers/amis_form_design.trigger.js +2 -0
- package/main/default/utils/designerManager.js +2 -0
- package/package.json +1 -1
- package/src/rests/api_workflow_instance_batch_remove.js +4 -3
|
@@ -288,6 +288,8 @@ actions:
|
|
|
288
288
|
label: Flow Designer
|
|
289
289
|
designForm:
|
|
290
290
|
label: Form Designer
|
|
291
|
+
design_form_layout:
|
|
292
|
+
label: Form Designer(New)
|
|
291
293
|
enableFlow:
|
|
292
294
|
label: Enable Flow
|
|
293
295
|
disableFlow:
|
|
@@ -310,8 +312,25 @@ actions:
|
|
|
310
312
|
label: Delete
|
|
311
313
|
addFormFields:
|
|
312
314
|
label: Add Fields
|
|
315
|
+
del:
|
|
316
|
+
label: Delete
|
|
313
317
|
CustomLabels:
|
|
314
318
|
import_flows_error_title: Import Error
|
|
315
319
|
import_flows_error_not_find_object: 'Not find object [ %s ]'
|
|
316
320
|
import_flows_error_not_allow_enable_workflow: 'object [ %s ] not enable workflow'
|
|
317
321
|
import_flows_error_not_find_fields: 'Missing field [ %s ]'
|
|
322
|
+
flows_action_del_dialog_title: Delete Flow
|
|
323
|
+
flows_action_del_dialog_field_flowName: For security reasons, please enter the name of the flow you want to delete (the relevant application form will also be deleted at the same time).
|
|
324
|
+
flows_action_del_dialog_error_not_same: Please confirm that the entered name is inconsistent with the flow name
|
|
325
|
+
flows_action_del_dialog_message_success: Operation successful
|
|
326
|
+
flows_action_del_dialog_message_failed: Operation failed
|
|
327
|
+
flows_action_distributeAdmin_dialog_error_not_find_step: Please first set the steps that allow distribution in the flow designer's steps
|
|
328
|
+
flows_action_distributeAdmin_dialog_field_distribute_optional_users_id: The selection range of distribution objects when the flow is distributed
|
|
329
|
+
flows_action_distributeAdmin_dialog_field_distribute_to_self: When distributing, you can give it to yourself
|
|
330
|
+
flows_action_distributeAdmin_dialog_field_distribute_end_notification: Remind the initiator after the distribution is completed
|
|
331
|
+
flows_action_distributeAdmin_dialog_field_upload_after_being_distributed: Is it allowed to upload attachments after being distributed
|
|
332
|
+
flows_page_record_field_form_name: Form Name
|
|
333
|
+
flows_page_record_field_form_description: Form Description
|
|
334
|
+
flows_page_record_field_form_name_forumla: Title Formula
|
|
335
|
+
flows_page_record_field_form_script: Form Script
|
|
336
|
+
flows_page_record_action_edit_dialog_title: Edit Form
|
|
@@ -285,6 +285,8 @@ actions:
|
|
|
285
285
|
label: 流程设计器
|
|
286
286
|
designForm:
|
|
287
287
|
label: 表单设计器
|
|
288
|
+
design_form_layout:
|
|
289
|
+
label: 表单设计器(New)
|
|
288
290
|
enableFlow:
|
|
289
291
|
label: 启用
|
|
290
292
|
disableFlow:
|
|
@@ -307,8 +309,25 @@ actions:
|
|
|
307
309
|
label: 删除
|
|
308
310
|
addFormFields:
|
|
309
311
|
label: 添加字段
|
|
312
|
+
del:
|
|
313
|
+
label: 删除
|
|
310
314
|
CustomLabels:
|
|
311
315
|
import_flows_error_title: 导入失败
|
|
312
316
|
import_flows_error_not_find_object: '未找到对象[ %s ]'
|
|
313
317
|
import_flows_error_not_allow_enable_workflow: '对象[ %s ]未启用配置对象流程'
|
|
314
318
|
import_flows_error_not_find_fields: '缺少字段[ %s ]'
|
|
319
|
+
flows_action_del_dialog_title: 删除流程
|
|
320
|
+
flows_action_del_dialog_field_flowName: 为了确保安全,请输入您要删除的流程名(同时会删除相关的申请单)
|
|
321
|
+
flows_action_del_dialog_error_not_same: 请确认, 输入的名称与流程名称不一致
|
|
322
|
+
flows_action_del_dialog_message_success: 操作成功
|
|
323
|
+
flows_action_del_dialog_message_failed: 操作失败
|
|
324
|
+
flows_action_distributeAdmin_dialog_error_not_find_step: 请先在流程设计器的步骤中, 设置允许分发的步骤
|
|
325
|
+
flows_action_distributeAdmin_dialog_field_distribute_optional_users_id: 流程被分发时分发对象选择范围
|
|
326
|
+
flows_action_distributeAdmin_dialog_field_distribute_to_self: 分发时可分发给自己
|
|
327
|
+
flows_action_distributeAdmin_dialog_field_distribute_end_notification: 分发结束后提醒发起人
|
|
328
|
+
flows_action_distributeAdmin_dialog_field_upload_after_being_distributed: 被分发后是否允许上传附件
|
|
329
|
+
flows_page_record_field_form_name: 表单名称
|
|
330
|
+
flows_page_record_field_form_description: 表单描述
|
|
331
|
+
flows_page_record_field_form_name_forumla: 标题公式
|
|
332
|
+
flows_page_record_field_form_script: 表单脚本
|
|
333
|
+
flows_page_record_action_edit_dialog_title: 编辑表单
|
|
@@ -5,7 +5,7 @@ amis_schema: |-
|
|
|
5
5
|
"body": [
|
|
6
6
|
{
|
|
7
7
|
"type": "button",
|
|
8
|
-
"label": "
|
|
8
|
+
"label": "${'CustomAction.flows.del' | t}",
|
|
9
9
|
"id": "u:del",
|
|
10
10
|
"editorState": "default",
|
|
11
11
|
"level": "danger",
|
|
@@ -18,7 +18,7 @@ amis_schema: |-
|
|
|
18
18
|
"actionType": "dialog",
|
|
19
19
|
"dialog": {
|
|
20
20
|
"type": "dialog",
|
|
21
|
-
"title": "
|
|
21
|
+
"title": "${'flows_action_del_dialog_title' | t}",
|
|
22
22
|
"body": [
|
|
23
23
|
{
|
|
24
24
|
"id": "u:f6977226303b",
|
|
@@ -30,7 +30,7 @@ amis_schema: |-
|
|
|
30
30
|
"body": [
|
|
31
31
|
{
|
|
32
32
|
"name": "flowName",
|
|
33
|
-
"label": "
|
|
33
|
+
"label": "${'flows_action_del_dialog_field_flowName' | t}",
|
|
34
34
|
"type": "input-text",
|
|
35
35
|
"id": "u:5c7f7b0c4f06",
|
|
36
36
|
"editorState": "default",
|
|
@@ -73,10 +73,7 @@ amis_schema: |-
|
|
|
73
73
|
"url": "/am/forms?methodOverride=DELETE",
|
|
74
74
|
"method": "post",
|
|
75
75
|
"requestAdaptor": "api.data = { 'Forms': [{ 'id': context._master.record.form }] }; return api;",
|
|
76
|
-
"adaptor": "",
|
|
77
|
-
"messages": {
|
|
78
|
-
"success": "操作成功"
|
|
79
|
-
},
|
|
76
|
+
"adaptor": "return payload.ChangeSet ? {data: {...payload}, status: 0, msg: t('flows_action_del_dialog_message_success')} : {...payload, status: 1, msg: t('flows_action_del_dialog_message_failed')};",
|
|
80
77
|
"sendOn": "${name === _master.record.name}"
|
|
81
78
|
}
|
|
82
79
|
}
|
|
@@ -86,13 +83,13 @@ amis_schema: |-
|
|
|
86
83
|
{
|
|
87
84
|
"type": "button",
|
|
88
85
|
"actionType": "cancel",
|
|
89
|
-
"label": "
|
|
86
|
+
"label": "${'Cancel' | t}",
|
|
90
87
|
"id": "u:cc2293523b91"
|
|
91
88
|
},
|
|
92
89
|
{
|
|
93
90
|
"type": "button",
|
|
94
91
|
"actionType": "confirm",
|
|
95
|
-
"label": "
|
|
92
|
+
"label": "${'OK' | t}",
|
|
96
93
|
"primary": true,
|
|
97
94
|
"id": "u:753881d2d453",
|
|
98
95
|
"editorState": "default",
|
|
@@ -103,7 +100,7 @@ amis_schema: |-
|
|
|
103
100
|
{
|
|
104
101
|
"ignoreError": false,
|
|
105
102
|
"actionType": "custom",
|
|
106
|
-
"script": "if (event.data._master.record.name != event.data._scoped.getComponentById('u:f6977226303b').props.data.flowName) {\n doAction({\n \"actionType\": \"toast\",\n \"args\": {\n \"msgType\": \"error\",\n \"msg\": \
|
|
103
|
+
"script": "if (event.data._master.record.name != event.data._scoped.getComponentById('u:f6977226303b').props.data.flowName) {\n doAction({\n \"actionType\": \"toast\",\n \"args\": {\n \"msgType\": \"error\",\n \"msg\": t('flows_action_del_dialog_error_not_same')\n }\n });\n event.stopPropagation();event.preventDefault();\n}\n\n",
|
|
107
104
|
"args": {}
|
|
108
105
|
}
|
|
109
106
|
]
|
|
@@ -15,8 +15,11 @@ module.exports = {
|
|
|
15
15
|
if (!record) {
|
|
16
16
|
return toastr.error("未找到记录");
|
|
17
17
|
}
|
|
18
|
-
|
|
19
|
-
|
|
18
|
+
var locale = Builder.settings.context?.user?.language || window.navigator.language;
|
|
19
|
+
if(locale === 'en' || locale.startsWith('en-')){
|
|
20
|
+
locale = 'en-US'
|
|
21
|
+
}
|
|
22
|
+
window.open(Steedos.getRelativeUrl("/api/workflow/form_design?fid=" + record_id+`&assetUrls=${Builder.settings.assetUrls}&locale=${locale}`));
|
|
20
23
|
},
|
|
21
24
|
design_form_layoutVisible: function(object_name, record_id, record_permissions, data) {
|
|
22
25
|
var record = data && data.record;
|
|
@@ -5,7 +5,7 @@ amis_schema: |-
|
|
|
5
5
|
"body": [
|
|
6
6
|
{
|
|
7
7
|
"type": "button",
|
|
8
|
-
"label": "
|
|
8
|
+
"label": "${'CustomAction.flows.distributeAdmin' | t}",
|
|
9
9
|
"id": "u:distributeAdmin",
|
|
10
10
|
"editorState": "default",
|
|
11
11
|
"onEvent": {
|
|
@@ -17,7 +17,7 @@ amis_schema: |-
|
|
|
17
17
|
"actionType": "dialog",
|
|
18
18
|
"dialog": {
|
|
19
19
|
"type": "dialog",
|
|
20
|
-
"title": "
|
|
20
|
+
"title": "${'CustomAction.flows.distributeAdmin' | t}",
|
|
21
21
|
"body": [
|
|
22
22
|
{
|
|
23
23
|
"id": "u:473feaee9de7",
|
|
@@ -27,7 +27,7 @@ amis_schema: |-
|
|
|
27
27
|
"url": "/api/v1/flows/${recordId}?fields=[\"_id\",\"name\",\"current\",\"distribute_optional_users_id\",\"distribute_to_self\",\"distribute_end_notification\",\"upload_after_being_distributed\"]",
|
|
28
28
|
"method": "get",
|
|
29
29
|
"requestAdaptor": "",
|
|
30
|
-
"adaptor": "const data = payload.data;\n\n\n\nconst steps = _.filter(data.current.steps, { allowDistribute: true });\n\nconst stepsInputFields = [];\n\nif (steps.length == 0) {\n return {\n data: {\n \"type\": \"alert\",\n \"body\":
|
|
30
|
+
"adaptor": "const data = payload.data;\n\n\n\nconst steps = _.filter(data.current.steps, { allowDistribute: true });\n\nconst stepsInputFields = [];\n\nif (steps.length == 0) {\n return {\n data: {\n \"type\": \"alert\",\n \"body\": t('flows_action_distributeAdmin_dialog_error_not_find_step'),\n \"level\": \"info\",\n \"className\": \"mb-1\"\n }\n }\n} else { \n\n _.each(steps, (step) => {\n stepsInputFields.push({\n type: 'steedos-field',\n config: {\n label: step.name,\n name: `step_distribute_flows_${step._id}`,\n multiple: true, amis: {value: step.distribute_optional_flows},\n \n type: 'lookup',\n reference_to: 'flows',\n filters: ['state', '=', 'enabled']\n }\n })\n })\n\n}\n\nreturn {\n data: {\n \"id\": \"u:90ea4939d3d12\",\n \"type\": \"form\",\n \"title\": \"表单\",\n \"wrapWithPanel\": false,\n \"mode\": \"normal\",\n \"dsType\": \"api\",\n \"feat\": \"Insert\",\n \"body\": [\n {\n \"type\": \"steedos-field\",\n \"config\": {\n \"type\": \"lookup\",\n \"label\": t('flows_action_distributeAdmin_dialog_field_distribute_optional_users_id'),\n \"name\": \"distribute_optional_users_id\",\n \"deleted_lookup_record_behavior\": \"clear\",\n \"reference_to\": \"users\",\n \"multiple\": true,\n \"object\": \"\"\n },\n \"id\": \"u:36461e5ef6f9\"\n },\n {\n \"type\": \"checkbox\",\n \"option\": t('flows_action_distributeAdmin_dialog_field_distribute_to_self'),\n \"name\": \"distribute_to_self\",\n \"id\": \"u:e8607f80e975\"\n },\n {\n \"type\": \"checkbox\",\n \"option\": t('flows_action_distributeAdmin_dialog_field_distribute_end_notification'),\n \"name\": \"distribute_end_notification\",\n \"id\": \"u:f63212af4190\"\n },\n {\n \"type\": \"checkbox\",\n \"option\": t('flows_action_distributeAdmin_dialog_field_upload_after_being_distributed'),\n \"name\": \"upload_after_being_distributed\",\n \"id\": \"u:05e00a1f59b6\"\n },\n ...stepsInputFields\n ],\n \"actions\": [\n {\n \"type\": \"button\",\n \"label\": t('Submit'),\n \"onEvent\": {\n \"click\": {\n \"actions\": [\n {\n \"actionType\": \"submit\",\n \"componentId\": \"u:90ea4939d3d1\"\n }\n ]\n }\n },\n \"level\": \"primary\"\n }\n ],\n \"resetAfterSubmit\": true,\n \"api\": {\n \"url\": \"/api/workflow/flow/${recordId}/settings/update_distribute_settings\",\n \"method\": \"post\",\n \"requestAdaptor\": \"\",\n \"adaptor\": \"\",\n \"messages\": {\n }\n },\n \"initApi\": {\n \"url\": \"/api/v1/flows/${recordId}?fields=[\\\"_id\\\",\\\"name\\\",\\\"current\\\",\\\"distribute_optional_users_id\\\",\\\"distribute_to_self\\\",\\\"distribute_end_notification\\\",\\\"upload_after_being_distributed\\\"]\",\n \"method\": \"get\",\n \"requestAdaptor\": \"\",\n \"adaptor\": \"\",\n \"messages\": {\n }\n }\n },\n}",
|
|
31
31
|
"messages": {}
|
|
32
32
|
}
|
|
33
33
|
}
|
|
@@ -37,13 +37,13 @@ amis_schema: |-
|
|
|
37
37
|
{
|
|
38
38
|
"type": "button",
|
|
39
39
|
"actionType": "cancel",
|
|
40
|
-
"label": "
|
|
40
|
+
"label": "${'Cancel' | t}",
|
|
41
41
|
"id": "u:7cfe0ffa8b8f"
|
|
42
42
|
},
|
|
43
43
|
{
|
|
44
44
|
"type": "button",
|
|
45
45
|
"actionType": "confirm",
|
|
46
|
-
"label": "
|
|
46
|
+
"label": "${'OK' | t}",
|
|
47
47
|
"primary": true,
|
|
48
48
|
"id": "u:c271fb676733"
|
|
49
49
|
}
|
|
@@ -39,7 +39,7 @@ fields:
|
|
|
39
39
|
filterable: true
|
|
40
40
|
mode:
|
|
41
41
|
type: select
|
|
42
|
-
label: Mode
|
|
42
|
+
label: Form Mode
|
|
43
43
|
options:
|
|
44
44
|
- label: Normal
|
|
45
45
|
value: normal
|
|
@@ -48,7 +48,18 @@ fields:
|
|
|
48
48
|
- label: Inline
|
|
49
49
|
value: inline
|
|
50
50
|
readonly: true
|
|
51
|
-
name:
|
|
51
|
+
name: mode
|
|
52
|
+
filterable: true
|
|
53
|
+
wizard_mode:
|
|
54
|
+
type: select
|
|
55
|
+
label: Wizard Mode
|
|
56
|
+
options:
|
|
57
|
+
- label: Vertical
|
|
58
|
+
value: vertical
|
|
59
|
+
- label: Horizontal
|
|
60
|
+
value: horizontal
|
|
61
|
+
readonly: true
|
|
62
|
+
name: wizard_mode
|
|
52
63
|
filterable: true
|
|
53
64
|
description:
|
|
54
65
|
type: textarea
|
|
@@ -72,7 +72,7 @@
|
|
|
72
72
|
"actionType": "dialog",
|
|
73
73
|
"dialog": {
|
|
74
74
|
"type": "dialog",
|
|
75
|
-
"title": "
|
|
75
|
+
"title": "${'flows_page_record_action_edit_dialog_title' | t}",
|
|
76
76
|
"body": [
|
|
77
77
|
{
|
|
78
78
|
"type": "form",
|
|
@@ -80,13 +80,13 @@
|
|
|
80
80
|
"body": [
|
|
81
81
|
{
|
|
82
82
|
"type": "input-text",
|
|
83
|
-
"label": "
|
|
83
|
+
"label": "${'flows_page_record_field_form_name' | t}",
|
|
84
84
|
"name": "name",
|
|
85
85
|
"id": "u:84af37d53da42"
|
|
86
86
|
},
|
|
87
87
|
{
|
|
88
88
|
"type": "textarea",
|
|
89
|
-
"label": "
|
|
89
|
+
"label": "${'flows_page_record_field_form_description' | t}",
|
|
90
90
|
"name": "description",
|
|
91
91
|
"id": "u:84af37d53da4",
|
|
92
92
|
"minRows": 3,
|
|
@@ -94,7 +94,7 @@
|
|
|
94
94
|
},
|
|
95
95
|
{
|
|
96
96
|
"type": "textarea",
|
|
97
|
-
"label": "
|
|
97
|
+
"label": "${'flows_page_record_field_form_name_forumla' | t}",
|
|
98
98
|
"name": "name_forumla",
|
|
99
99
|
"id": "u:69b6536e9fd8",
|
|
100
100
|
"minRows": 3,
|
|
@@ -102,7 +102,7 @@
|
|
|
102
102
|
},
|
|
103
103
|
{
|
|
104
104
|
"type": "editor",
|
|
105
|
-
"label": "
|
|
105
|
+
"label": "${'flows_page_record_field_form_script' | t}",
|
|
106
106
|
"name": "form_script",
|
|
107
107
|
"id": "u:025f8c4f09b6",
|
|
108
108
|
"minRows": 3,
|
|
@@ -163,13 +163,13 @@
|
|
|
163
163
|
"body": [
|
|
164
164
|
{
|
|
165
165
|
"type": "input-text",
|
|
166
|
-
"label": "
|
|
166
|
+
"label": "${'flows_page_record_field_form_name' | t}",
|
|
167
167
|
"name": "name",
|
|
168
168
|
"id": "u:84af37d53da42"
|
|
169
169
|
},
|
|
170
170
|
{
|
|
171
171
|
"type": "textarea",
|
|
172
|
-
"label": "
|
|
172
|
+
"label": "${'flows_page_record_field_form_description' | t}",
|
|
173
173
|
"name": "description",
|
|
174
174
|
"id": "u:84af37d53da4",
|
|
175
175
|
"minRows": 3,
|
|
@@ -177,7 +177,7 @@
|
|
|
177
177
|
},
|
|
178
178
|
{
|
|
179
179
|
"type": "textarea",
|
|
180
|
-
"label": "
|
|
180
|
+
"label": "${'flows_page_record_field_form_name_forumla' | t}",
|
|
181
181
|
"name": "name_forumla",
|
|
182
182
|
"id": "u:69b6536e9fd8",
|
|
183
183
|
"minRows": 3,
|
|
@@ -185,7 +185,7 @@
|
|
|
185
185
|
},
|
|
186
186
|
{
|
|
187
187
|
"type": "editor",
|
|
188
|
-
"label": "
|
|
188
|
+
"label": "${'flows_page_record_field_form_script' | t}",
|
|
189
189
|
"name": "form_script",
|
|
190
190
|
"id": "u:025f8c4f09b6",
|
|
191
191
|
"minRows": 3,
|
|
@@ -66,7 +66,10 @@
|
|
|
66
66
|
useOpenAPI: useOpenAPI,
|
|
67
67
|
id: "<%=id%>",
|
|
68
68
|
pageId: "<%=id%>",
|
|
69
|
-
hiddenDeploy: true
|
|
69
|
+
hiddenDeploy: true,
|
|
70
|
+
title: "<%=locale%>" === 'zh-CN' ? '流程表单设计器': 'Flow Form Designer',
|
|
71
|
+
saveText: "<%=locale%>" === 'zh-CN' ? '保存': 'Save',
|
|
72
|
+
deployText: "<%=locale%>" === 'zh-CN' ? '发布': 'Deploy',
|
|
70
73
|
};
|
|
71
74
|
|
|
72
75
|
let comp = document.querySelector("builder-fiddle");
|
|
@@ -35,7 +35,7 @@ router.get('/api/workflow/form_design', auth.requireAuthentication, async functi
|
|
|
35
35
|
// authToken: userSession.authToken
|
|
36
36
|
// }
|
|
37
37
|
let locale = "zh-CN";
|
|
38
|
-
if (req.query.locale
|
|
38
|
+
if (req.query.locale?.startsWith('en')) {
|
|
39
39
|
locale = "en-US";
|
|
40
40
|
} else if (req.query.locale == "zh-cn") {
|
|
41
41
|
locale = "zh-CN";
|
|
@@ -56,7 +56,8 @@ router.get('/api/workflow/form_design', auth.requireAuthentication, async functi
|
|
|
56
56
|
authToken: userSession.authToken,
|
|
57
57
|
userSession: userSession,
|
|
58
58
|
id: flow.form,
|
|
59
|
-
useOpenAPI: process.env.STEEDOS_PUBLIC_USE_OPEN_API
|
|
59
|
+
useOpenAPI: process.env.STEEDOS_PUBLIC_USE_OPEN_API,
|
|
60
|
+
locale
|
|
60
61
|
}
|
|
61
62
|
const options = {}
|
|
62
63
|
ejs.renderFile(filename, data, options, function(err, str){
|
|
@@ -526,8 +526,10 @@ module.exports = {
|
|
|
526
526
|
form.current.amis_schema = amis_schema;
|
|
527
527
|
form.current.style = formSchema.style;
|
|
528
528
|
form.current.mode = formSchema.mode;
|
|
529
|
+
form.current.wizard_mode = formSchema.wizard_mode;
|
|
529
530
|
form.style = formSchema.style;
|
|
530
531
|
form.mode = formSchema.mode;
|
|
532
|
+
form.wizard_mode = formSchema.wizard_mode;
|
|
531
533
|
form.description = formSchema.description;
|
|
532
534
|
|
|
533
535
|
// 以下为将解析字段存储的功能,为将解析字段存储至数据库forms表的功能
|
|
@@ -223,6 +223,7 @@ async function updateForm(formId, form, forms, flows, currentUserId) {
|
|
|
223
223
|
current.name_forumla = form["current"]["name_forumla"];
|
|
224
224
|
current.style = form["current"]["style"];
|
|
225
225
|
current.mode = form["current"]["mode"];
|
|
226
|
+
current.wizard_mode = form["current"]["wizard_mode"];
|
|
226
227
|
|
|
227
228
|
formUpdateObj.$set = {
|
|
228
229
|
'current': current,
|
|
@@ -232,6 +233,7 @@ async function updateForm(formId, form, forms, flows, currentUserId) {
|
|
|
232
233
|
'is_valid': form["is_valid"],
|
|
233
234
|
'style': form["style"],
|
|
234
235
|
'mode': form["mode"],
|
|
236
|
+
'wizard_mode': form["wizard_mode"],
|
|
235
237
|
'description': form["description"],
|
|
236
238
|
'help_text': form["help_text"],
|
|
237
239
|
'error_message': form["error_message"],
|
package/package.json
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* @Author: 孙浩林 sunhaolin@steedos.com
|
|
3
3
|
* @Date: 2023-11-04 18:16:15
|
|
4
|
-
* @LastEditors:
|
|
5
|
-
* @LastEditTime:
|
|
4
|
+
* @LastEditors: 殷亮辉 yinlianghui@hotoa.com
|
|
5
|
+
* @LastEditTime: 2025-09-01 16:23:40
|
|
6
6
|
* @FilePath: /steedos-platform-2.3/services/service-workflow/src/rests/api_workflow_instance_batch_remove.js
|
|
7
7
|
* @Description: 草稿箱列表删除按钮调用此接口批量删除草稿
|
|
8
8
|
*/
|
|
@@ -22,6 +22,7 @@ module.exports = {
|
|
|
22
22
|
|
|
23
23
|
const insObj = this.getObject('instances')
|
|
24
24
|
const insTaskObj = this.getObject('instance_tasks')
|
|
25
|
+
const lang = userSession.locale === 'zh-cn' ? 'zh-CN' : 'en';
|
|
25
26
|
|
|
26
27
|
// 先检查是否符合删除条件:1、状态为草稿,2、提交人人为当前用户。
|
|
27
28
|
const insDocs = await insObj.find({
|
|
@@ -62,7 +63,7 @@ module.exports = {
|
|
|
62
63
|
|
|
63
64
|
return {
|
|
64
65
|
'status': 0, // 返回 0,表示当前接口正确返回,否则按错误请求处理
|
|
65
|
-
'msg': '草稿已删除',
|
|
66
|
+
'msg': t('instance.draft_deleted_success', {}, lang),//'草稿已删除',
|
|
66
67
|
'data': {
|
|
67
68
|
}
|
|
68
69
|
}
|