lw-cdp-ui 1.1.21 → 1.1.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/dist/components/lwFlow/config/nodesList.js +174 -17
- package/dist/components/lwFlow/index.vue +109 -23
- package/dist/components/lwFlow/nodeEdit/basicSettings.vue +31 -2
- package/dist/components/lwFlow/nodeEdit/index.vue +1 -1
- package/dist/components/lwFlow/nodeEdit/styleSettings.vue +1 -1
- package/dist/components/lwFlow/nodes/custom.js +8 -0
- package/dist/components/lwFlow/nodes/et2lTable.js +9 -19
- package/dist/components/lwFlow/nodesData/datas/collap.js +13 -2
- package/dist/components/lwFlow/nodesData/datas/expand.js +9 -8
- package/dist/components/lwFlow/nodesData/datas/filter.js +13 -2
- package/dist/components/lwFlow/nodesData/datas/joiner.js +143 -37
- package/dist/components/lwFlow/nodesData/datas/mapper.js +15 -4
- package/dist/components/lwFlow/nodesData/datas/reduce.js +17 -9
- package/dist/components/lwFlow/nodesData/datas/source.js +13 -2
- package/dist/components/lwFlow/nodesData/datas/target.js +13 -2
- package/dist/components/lwFlow/nodesData/datas/timer.js +3 -2
- package/dist/components/lwFlow/nodesData/index.js +9 -0
- package/dist/components/lwForm/index.vue +2 -2
- package/dist/components/lwLayout/components/bu.vue +10 -3
- package/dist/components/lwTableForm/index.vue +11 -6
- package/dist/lw-cdp-ui.esm.js +2102 -1696
- package/dist/lw-cdp-ui.umd.js +11 -11
- package/dist/style.css +1 -1
- package/package.json +1 -1
|
@@ -1,21 +1,4 @@
|
|
|
1
1
|
export default [
|
|
2
|
-
{
|
|
3
|
-
title: '基础流程',
|
|
4
|
-
list: [
|
|
5
|
-
{
|
|
6
|
-
name: '开始',
|
|
7
|
-
icon: 'icon-next',
|
|
8
|
-
type: 'start',
|
|
9
|
-
themeColor: '#39bcc5'
|
|
10
|
-
},
|
|
11
|
-
{
|
|
12
|
-
name: '结束',
|
|
13
|
-
icon: 'icon-cease',
|
|
14
|
-
type: 'end',
|
|
15
|
-
themeColor: '#f53f3f'
|
|
16
|
-
}
|
|
17
|
-
]
|
|
18
|
-
},
|
|
19
2
|
{
|
|
20
3
|
title: 'ET2L节点',
|
|
21
4
|
list: [
|
|
@@ -74,5 +57,179 @@ export default [
|
|
|
74
57
|
themeColor: '#EF5612'
|
|
75
58
|
}
|
|
76
59
|
]
|
|
60
|
+
},
|
|
61
|
+
{
|
|
62
|
+
title: '营销目标',
|
|
63
|
+
list: [
|
|
64
|
+
{
|
|
65
|
+
name: '接收事件',
|
|
66
|
+
icon: 'icon-event',
|
|
67
|
+
type: 'event_receive',
|
|
68
|
+
themeColor: '#39BCC5'
|
|
69
|
+
},
|
|
70
|
+
{
|
|
71
|
+
name: '人群包',
|
|
72
|
+
icon: 'icon-user-info',
|
|
73
|
+
type: 'audience_receive',
|
|
74
|
+
themeColor: '#39BCC5'
|
|
75
|
+
}
|
|
76
|
+
]
|
|
77
|
+
},
|
|
78
|
+
{
|
|
79
|
+
title: '营销触达',
|
|
80
|
+
list: [
|
|
81
|
+
{
|
|
82
|
+
name: '短信',
|
|
83
|
+
icon: 'icon-auto-reply',
|
|
84
|
+
type: 'event_receive',
|
|
85
|
+
themeColor: '#4594f3'
|
|
86
|
+
},
|
|
87
|
+
{
|
|
88
|
+
name: '微信',
|
|
89
|
+
icon: 'icon-scrm-l',
|
|
90
|
+
type: 'wechat',
|
|
91
|
+
themeColor: '#4594f3'
|
|
92
|
+
},
|
|
93
|
+
{
|
|
94
|
+
name: '邮件',
|
|
95
|
+
icon: 'icon-mail-l',
|
|
96
|
+
type: 'email',
|
|
97
|
+
themeColor: '#4594f3'
|
|
98
|
+
},
|
|
99
|
+
{
|
|
100
|
+
name: '权益',
|
|
101
|
+
icon: 'icon-license',
|
|
102
|
+
type: 'benefit',
|
|
103
|
+
themeColor: '#4594f3'
|
|
104
|
+
},
|
|
105
|
+
{
|
|
106
|
+
name: '积分',
|
|
107
|
+
icon: 'icon-coin',
|
|
108
|
+
type: 'benefit',
|
|
109
|
+
themeColor: '#4594f3'
|
|
110
|
+
},
|
|
111
|
+
{
|
|
112
|
+
name: '优惠券',
|
|
113
|
+
icon: 'icon--coupon-2',
|
|
114
|
+
type: 'coupon',
|
|
115
|
+
themeColor: '#4594f3'
|
|
116
|
+
}
|
|
117
|
+
]
|
|
118
|
+
},
|
|
119
|
+
{
|
|
120
|
+
title: '营销功能',
|
|
121
|
+
list: [
|
|
122
|
+
{
|
|
123
|
+
name: '客户标签',
|
|
124
|
+
icon: 'icon-tag',
|
|
125
|
+
type: 'tag',
|
|
126
|
+
themeColor: '#39BCC5'
|
|
127
|
+
},
|
|
128
|
+
{
|
|
129
|
+
name: 'Flow',
|
|
130
|
+
icon: 'icon-event',
|
|
131
|
+
type: 'flow',
|
|
132
|
+
themeColor: '#e8ffea'
|
|
133
|
+
},
|
|
134
|
+
{
|
|
135
|
+
name: '扩展数据',
|
|
136
|
+
icon: 'icon-event',
|
|
137
|
+
type: 'extend_data',
|
|
138
|
+
themeColor: '#ff6d69'
|
|
139
|
+
},
|
|
140
|
+
{
|
|
141
|
+
name: '定制功能',
|
|
142
|
+
icon: 'icon-flow-stop',
|
|
143
|
+
type: 'customization',
|
|
144
|
+
themeColor: '#ff6d69'
|
|
145
|
+
}
|
|
146
|
+
]
|
|
147
|
+
},
|
|
148
|
+
{
|
|
149
|
+
title: 'Flow',
|
|
150
|
+
list: [
|
|
151
|
+
{
|
|
152
|
+
name: 'flow测试',
|
|
153
|
+
icon: 'icon-event',
|
|
154
|
+
type: 'tag',
|
|
155
|
+
themeColor: '#39BCC5'
|
|
156
|
+
}
|
|
157
|
+
]
|
|
158
|
+
},
|
|
159
|
+
{
|
|
160
|
+
title: '逻辑操作',
|
|
161
|
+
list: [
|
|
162
|
+
{
|
|
163
|
+
name: '交集',
|
|
164
|
+
icon: 'icon-cross',
|
|
165
|
+
type: 'intersect',
|
|
166
|
+
themeColor: '#fba980'
|
|
167
|
+
},
|
|
168
|
+
{
|
|
169
|
+
name: '并集',
|
|
170
|
+
icon: 'icon-merge',
|
|
171
|
+
type: 'union',
|
|
172
|
+
themeColor: '#fba980'
|
|
173
|
+
},
|
|
174
|
+
{
|
|
175
|
+
name: '差集',
|
|
176
|
+
icon: 'icon-chaji',
|
|
177
|
+
type: 'exclusion',
|
|
178
|
+
themeColor: '#fba980'
|
|
179
|
+
},
|
|
180
|
+
{
|
|
181
|
+
name: '过滤',
|
|
182
|
+
icon: 'icon-ma-filter',
|
|
183
|
+
type: 'filter',
|
|
184
|
+
themeColor: '#fba980'
|
|
185
|
+
},
|
|
186
|
+
{
|
|
187
|
+
name: '去重',
|
|
188
|
+
icon: 'icon-quzhong',
|
|
189
|
+
type: 'unique',
|
|
190
|
+
themeColor: '#fba980'
|
|
191
|
+
},
|
|
192
|
+
{
|
|
193
|
+
name: 'A/B测试',
|
|
194
|
+
icon: 'icon-ABtestshezhi',
|
|
195
|
+
type: 'abtest',
|
|
196
|
+
themeColor: '#fba980'
|
|
197
|
+
},
|
|
198
|
+
{
|
|
199
|
+
name: '排序',
|
|
200
|
+
icon: 'icon-sort-fill',
|
|
201
|
+
type: 'sort',
|
|
202
|
+
themeColor: '#fba980'
|
|
203
|
+
}
|
|
204
|
+
]
|
|
205
|
+
},
|
|
206
|
+
{
|
|
207
|
+
title: '流程控制',
|
|
208
|
+
list: [
|
|
209
|
+
{
|
|
210
|
+
name: '开始',
|
|
211
|
+
icon: 'icon-start',
|
|
212
|
+
type: 'start',
|
|
213
|
+
themeColor: '#39BCC5'
|
|
214
|
+
},
|
|
215
|
+
{
|
|
216
|
+
name: '定时',
|
|
217
|
+
icon: 'icon-timing',
|
|
218
|
+
type: 'timer',
|
|
219
|
+
themeColor: '#105a63'
|
|
220
|
+
},
|
|
221
|
+
{
|
|
222
|
+
name: '限流',
|
|
223
|
+
icon: 'icon-timing',
|
|
224
|
+
type: 'restrict',
|
|
225
|
+
themeColor: '#105a63'
|
|
226
|
+
},
|
|
227
|
+
{
|
|
228
|
+
name: '结束',
|
|
229
|
+
icon: 'icon-flow-stop',
|
|
230
|
+
type: 'end',
|
|
231
|
+
themeColor: '#ff6d69'
|
|
232
|
+
}
|
|
233
|
+
]
|
|
77
234
|
}
|
|
78
235
|
]
|
|
@@ -25,7 +25,6 @@
|
|
|
25
25
|
</template>
|
|
26
26
|
|
|
27
27
|
</div>
|
|
28
|
-
|
|
29
28
|
</template>
|
|
30
29
|
|
|
31
30
|
<script>
|
|
@@ -49,6 +48,7 @@ import nodeEdit from './nodeEdit/index.vue'
|
|
|
49
48
|
|
|
50
49
|
// 参数配置
|
|
51
50
|
import configNodesList from './config/nodesList'
|
|
51
|
+
import nodeDatas from './nodesData/index.js'
|
|
52
52
|
export default {
|
|
53
53
|
components: {
|
|
54
54
|
lfControl,
|
|
@@ -96,6 +96,13 @@ export default {
|
|
|
96
96
|
type: Boolean,
|
|
97
97
|
default: false
|
|
98
98
|
},
|
|
99
|
+
/**
|
|
100
|
+
* 需要展示的节点分组 不传默认展示所有内置节点
|
|
101
|
+
*/
|
|
102
|
+
showNodeGroup: {
|
|
103
|
+
type: Array,
|
|
104
|
+
default: []
|
|
105
|
+
},
|
|
99
106
|
/**
|
|
100
107
|
* apiNodes - 接口返回的节点数组,用于与内容节点合并。
|
|
101
108
|
* @type {Array<Object>}
|
|
@@ -217,6 +224,13 @@ export default {
|
|
|
217
224
|
} else {
|
|
218
225
|
baseList = Object.values(list)
|
|
219
226
|
}
|
|
227
|
+
|
|
228
|
+
if (this.showNodeGroup.length > 0) {
|
|
229
|
+
baseList = baseList.filter(item => {
|
|
230
|
+
return this.showNodeGroup.includes(item.title)
|
|
231
|
+
})
|
|
232
|
+
}
|
|
233
|
+
|
|
220
234
|
return baseList
|
|
221
235
|
}
|
|
222
236
|
},
|
|
@@ -323,28 +337,7 @@ export default {
|
|
|
323
337
|
},
|
|
324
338
|
},
|
|
325
339
|
], // 全局右键菜单
|
|
326
|
-
graphMenu: [
|
|
327
|
-
// {
|
|
328
|
-
// text: '全局直线',
|
|
329
|
-
// callback() {
|
|
330
|
-
// // 切换边类型
|
|
331
|
-
// _this.logicFlow.setDefaultEdgeType("line")
|
|
332
|
-
// },
|
|
333
|
-
// },
|
|
334
|
-
// {
|
|
335
|
-
// text: '全局曲线',
|
|
336
|
-
// callback() {
|
|
337
|
-
// // 切换边类型
|
|
338
|
-
// _this.logicFlow.setDefaultEdgeType("bezier")
|
|
339
|
-
// },
|
|
340
|
-
// },
|
|
341
|
-
// {
|
|
342
|
-
// text: '全局折线',
|
|
343
|
-
// callback() {
|
|
344
|
-
// _this.logicFlow.setDefaultEdgeType("polyline")
|
|
345
|
-
// },
|
|
346
|
-
// },
|
|
347
|
-
]
|
|
340
|
+
graphMenu: []
|
|
348
341
|
});
|
|
349
342
|
},
|
|
350
343
|
/**
|
|
@@ -409,6 +402,22 @@ export default {
|
|
|
409
402
|
message: data.msg
|
|
410
403
|
})
|
|
411
404
|
})
|
|
405
|
+
|
|
406
|
+
|
|
407
|
+
this.changeEdge()
|
|
408
|
+
},
|
|
409
|
+
/**
|
|
410
|
+
* 改变连线时处理上下级节点数据
|
|
411
|
+
* 本扩展暂无使用 本意是直接提供接口说要的数据结构
|
|
412
|
+
* 但是存在触发限制(可能存在连线后用户有修改了数据导致关联指向数据不完整) 暂停开发
|
|
413
|
+
* 所以本组件只提供原始的流程图数据输出 结构数据开发人员自行处理
|
|
414
|
+
*/
|
|
415
|
+
changeEdge() {
|
|
416
|
+
this.logicFlow.on('edge:add', ({ data: edge }) => {
|
|
417
|
+
})
|
|
418
|
+
this.logicFlow.on('edge:delete', ({ data: edge }) => {
|
|
419
|
+
})
|
|
420
|
+
|
|
412
421
|
},
|
|
413
422
|
// 关闭属性抽屉
|
|
414
423
|
nodeEditClose() {
|
|
@@ -416,9 +425,63 @@ export default {
|
|
|
416
425
|
},
|
|
417
426
|
// 打开属性抽屉
|
|
418
427
|
nodeEditOpen(data) {
|
|
428
|
+
// 去除为空校验结果
|
|
429
|
+
delete data.properties.error
|
|
430
|
+
this.logicFlow.setProperties(data.id, {
|
|
431
|
+
error: false
|
|
432
|
+
});
|
|
433
|
+
|
|
419
434
|
this.clickNode = data
|
|
420
435
|
this.drawerShow = true
|
|
436
|
+
|
|
421
437
|
},
|
|
438
|
+
/**
|
|
439
|
+
* 节点必传字段校验
|
|
440
|
+
* 用于父组件校验使用
|
|
441
|
+
* @returns {Promise<boolean>} 验证是否通过 true 通过
|
|
442
|
+
*/
|
|
443
|
+
async validate() {
|
|
444
|
+
let { nodes } = this.logicFlow.getGraphData();
|
|
445
|
+
let errorNodes = {};
|
|
446
|
+
|
|
447
|
+
for (const node of nodes) {
|
|
448
|
+
let { formConfig } = nodeDatas[node.type];
|
|
449
|
+
let { formItems } = formConfig;
|
|
450
|
+
let { data } = node.properties;
|
|
451
|
+
|
|
452
|
+
if (formItems?.length > 0) {
|
|
453
|
+
for (const item of formItems) {
|
|
454
|
+
let value = data ? data[item?.name] : data;
|
|
455
|
+
let isHideHandle = false;
|
|
456
|
+
// 处理 hideHandle 字段逻辑
|
|
457
|
+
if (data && typeof item?.hideHandle === 'string') {
|
|
458
|
+
isHideHandle = eval(item.hideHandle.replace(/\$/g, "data"));
|
|
459
|
+
} else if (data && typeof item?.hideHandle === 'boolean') {
|
|
460
|
+
isHideHandle = item.hideHandle;
|
|
461
|
+
}
|
|
462
|
+
|
|
463
|
+
// 校验规则,如果不符合则记录错误
|
|
464
|
+
if (!isHideHandle && item?.rules && !value) {
|
|
465
|
+
this.logicFlow.setProperties(node.id, {
|
|
466
|
+
data: data,
|
|
467
|
+
error: true,
|
|
468
|
+
});
|
|
469
|
+
errorNodes[node.id] = true;
|
|
470
|
+
break;
|
|
471
|
+
}
|
|
472
|
+
}
|
|
473
|
+
}
|
|
474
|
+
|
|
475
|
+
// 如果节点没有错误,清除错误状态
|
|
476
|
+
if (!errorNodes[node.id]) {
|
|
477
|
+
this.logicFlow.setProperties(node.id, {
|
|
478
|
+
data: data,
|
|
479
|
+
error: false,
|
|
480
|
+
});
|
|
481
|
+
}
|
|
482
|
+
}
|
|
483
|
+
return Object.keys(errorNodes).length === 0;
|
|
484
|
+
}
|
|
422
485
|
|
|
423
486
|
},
|
|
424
487
|
}
|
|
@@ -516,6 +579,12 @@ export default {
|
|
|
516
579
|
i {
|
|
517
580
|
font-size: 20px;
|
|
518
581
|
}
|
|
582
|
+
.text {
|
|
583
|
+
width: 100%;
|
|
584
|
+
white-space: nowrap;
|
|
585
|
+
overflow: hidden;
|
|
586
|
+
text-overflow: ellipsis;
|
|
587
|
+
}
|
|
519
588
|
}
|
|
520
589
|
// 自定义节点样式
|
|
521
590
|
:deep(.lw-flow-node-custom) {
|
|
@@ -553,4 +622,21 @@ export default {
|
|
|
553
622
|
line-height: 14px;
|
|
554
623
|
}
|
|
555
624
|
}
|
|
625
|
+
:deep(.lw-flow-node-error) {
|
|
626
|
+
&::after {
|
|
627
|
+
content: "必填字段不能为空";
|
|
628
|
+
position: absolute;
|
|
629
|
+
bottom: 0;
|
|
630
|
+
right: 0;
|
|
631
|
+
width: 100px;
|
|
632
|
+
height: 20px;
|
|
633
|
+
font-size: 10px;
|
|
634
|
+
color: #fff;
|
|
635
|
+
z-index: 9;
|
|
636
|
+
display: flex;
|
|
637
|
+
align-items: center;
|
|
638
|
+
justify-content: center;
|
|
639
|
+
background-color: rgba($color: #e61010, $alpha: 0.8);
|
|
640
|
+
}
|
|
641
|
+
}
|
|
556
642
|
</style>
|
|
@@ -2,10 +2,38 @@
|
|
|
2
2
|
<lw-form ref="dataFormRef"
|
|
3
3
|
:config="config"
|
|
4
4
|
v-model="dataForm">
|
|
5
|
-
<!-- 定时器
|
|
5
|
+
<!-- 定时器 表单自定义部分 -->
|
|
6
6
|
<template #dateCron>
|
|
7
7
|
<lwCronSelect v-model="dataForm.cron" />
|
|
8
8
|
</template>
|
|
9
|
+
|
|
10
|
+
<!-- et2l 表单自定义部分 -->
|
|
11
|
+
<template #KeyableSource>
|
|
12
|
+
<lwTableForm :config="joiner.configKeyableSource"
|
|
13
|
+
v-model="dataForm.from" />
|
|
14
|
+
</template>
|
|
15
|
+
<template #MapAction>
|
|
16
|
+
<lwTableForm :config="joiner.configMapAction"
|
|
17
|
+
v-model="dataForm.with">
|
|
18
|
+
<template #sourceField="{row}">
|
|
19
|
+
<el-input v-if="row.type == 'direct'"
|
|
20
|
+
size="small"
|
|
21
|
+
v-model="row.sourceField"
|
|
22
|
+
placeholder="来源字段" />
|
|
23
|
+
<el-select v-else
|
|
24
|
+
v-model="row.sourceField"
|
|
25
|
+
multiple
|
|
26
|
+
filterable
|
|
27
|
+
allow-create
|
|
28
|
+
size="small"
|
|
29
|
+
default-first-option
|
|
30
|
+
:reserve-keyword="false"
|
|
31
|
+
placeholder="来源字段"
|
|
32
|
+
style="width: 100%">
|
|
33
|
+
</el-select>
|
|
34
|
+
</template>
|
|
35
|
+
</lwTableForm>
|
|
36
|
+
</template>
|
|
9
37
|
<span></span>
|
|
10
38
|
</lw-form>
|
|
11
39
|
</template>
|
|
@@ -16,7 +44,8 @@ export default {
|
|
|
16
44
|
name: 'basicSettings',
|
|
17
45
|
data() {
|
|
18
46
|
return {
|
|
19
|
-
dataForm: {}
|
|
47
|
+
dataForm: {},
|
|
48
|
+
...nodeDatas
|
|
20
49
|
}
|
|
21
50
|
},
|
|
22
51
|
props: {
|
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
<el-drawer v-model="isShow"
|
|
3
3
|
title="节点编辑"
|
|
4
4
|
direction="rtl"
|
|
5
|
+
:append-to-body="true"
|
|
5
6
|
:before-close="close">
|
|
6
7
|
<div class="drawer-form">
|
|
7
8
|
<el-collapse v-model="activeName"
|
|
@@ -36,7 +37,6 @@
|
|
|
36
37
|
<script>
|
|
37
38
|
import basicSettings from './basicSettings.vue'
|
|
38
39
|
import styleSettings from './styleSettings.vue'
|
|
39
|
-
|
|
40
40
|
export default {
|
|
41
41
|
name: 'drawerForm',
|
|
42
42
|
components: {
|
|
@@ -72,6 +72,14 @@ export default function registerCustom(lf, node) {
|
|
|
72
72
|
el.style.justifyContent = properties?.style?.textAlign || ''
|
|
73
73
|
el.style.textDecoration = properties?.style?.textDecoration || ''
|
|
74
74
|
el.style.fontStyle = properties?.style?.fontStyle || ''
|
|
75
|
+
|
|
76
|
+
// 检验不通过提示
|
|
77
|
+
if (properties.error) {
|
|
78
|
+
el.classList.add('lw-flow-node-error')
|
|
79
|
+
} else {
|
|
80
|
+
el.classList.remove('lw-flow-node-error')
|
|
81
|
+
}
|
|
82
|
+
|
|
75
83
|
const html = `<div class="top-name" style="border-color: ${node.themeColor};">
|
|
76
84
|
<i class="iconfont ${node.icon}"></i> ${properties?.data?.name || node.name}</div>
|
|
77
85
|
<div class="bottom-content" style="border-color: ${node.themeColor};">
|
|
@@ -72,7 +72,15 @@ export default function registerEt2l(lf, node) {
|
|
|
72
72
|
el.style.justifyContent = properties?.style?.textAlign || ''
|
|
73
73
|
el.style.textDecoration = properties?.style?.textDecoration || ''
|
|
74
74
|
el.style.fontStyle = properties?.style?.fontStyle || ''
|
|
75
|
-
|
|
75
|
+
|
|
76
|
+
// 检验不通过提示
|
|
77
|
+
if (properties.error) {
|
|
78
|
+
el.classList.add('lw-flow-node-error')
|
|
79
|
+
} else {
|
|
80
|
+
el.classList.remove('lw-flow-node-error')
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
const html = `<i class="iconfont ${node.icon}"></i> <span class="text" title="${properties?.data?.name || node.name}">${properties?.data?.name || node.name}</span>`
|
|
76
84
|
|
|
77
85
|
// 暂无显示需求
|
|
78
86
|
// if (properties?.data.mode) {
|
|
@@ -99,27 +107,9 @@ export default function registerEt2l(lf, node) {
|
|
|
99
107
|
this.width = 120
|
|
100
108
|
this.height = 40
|
|
101
109
|
this.text.editable = false
|
|
102
|
-
|
|
103
|
-
console.log('---------------1', 12312)
|
|
104
110
|
}
|
|
105
111
|
initNodeData(data) {
|
|
106
112
|
super.initNodeData(data)
|
|
107
|
-
|
|
108
|
-
// const circleOnlyAsTarget = {
|
|
109
|
-
// message: '目标节点只允许一个上级连接',
|
|
110
|
-
// validate: (sourceNode, targetNode, sourceAnchor, targetAnchor) => {
|
|
111
|
-
// let { edges } = targetNode.graphModel
|
|
112
|
-
// let { id } = targetNode
|
|
113
|
-
// let number = [...edges].filter((item) => {
|
|
114
|
-
// let { targetNodeId } = { ...item }
|
|
115
|
-
// return targetNodeId == id
|
|
116
|
-
// })
|
|
117
|
-
// console.log(number)
|
|
118
|
-
// return number.length < 1
|
|
119
|
-
// }
|
|
120
|
-
// }
|
|
121
|
-
// this.targetRules.push(circleOnlyAsTarget)
|
|
122
|
-
|
|
123
113
|
// 目标节点校验
|
|
124
114
|
nodeDatas[node.type]?.targetRules?.forEach((item) => {
|
|
125
115
|
this.targetRules.push(item)
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* ET2L
|
|
2
|
+
* ET2L数据折叠节点 COLAP 配置数据
|
|
3
3
|
*/
|
|
4
4
|
|
|
5
5
|
export default {
|
|
6
6
|
// 暂无显示需求
|
|
7
7
|
nodeHtml: [],
|
|
8
|
-
//
|
|
8
|
+
// 目标节点校验
|
|
9
9
|
targetRules: [
|
|
10
10
|
{
|
|
11
11
|
message: '目标节点只允许一个上级连接',
|
|
@@ -68,6 +68,17 @@ export default {
|
|
|
68
68
|
},
|
|
69
69
|
span: 24
|
|
70
70
|
},
|
|
71
|
+
{
|
|
72
|
+
label: '输出名称',
|
|
73
|
+
name: 'into',
|
|
74
|
+
value: '',
|
|
75
|
+
component: 'input',
|
|
76
|
+
options: {
|
|
77
|
+
placeholder: '请输入输出名称'
|
|
78
|
+
},
|
|
79
|
+
span: 24,
|
|
80
|
+
rules: [{ required: true, message: '不能为空', trigger: 'blur' }]
|
|
81
|
+
},
|
|
71
82
|
{
|
|
72
83
|
label: '描述信息',
|
|
73
84
|
name: 'desp',
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* ET2L
|
|
2
|
+
* ET2L数据折叠节点 EXPAND 配置数据
|
|
3
3
|
*/
|
|
4
4
|
|
|
5
5
|
export default {
|
|
6
6
|
// 暂无显示需求
|
|
7
7
|
nodeHtml: [],
|
|
8
|
-
//
|
|
8
|
+
// 目标节点校验
|
|
9
9
|
targetRules: [
|
|
10
10
|
{
|
|
11
11
|
message: '目标节点只允许一个上级连接',
|
|
@@ -48,25 +48,26 @@ export default {
|
|
|
48
48
|
rules: [{ required: true, message: '不能为空', trigger: 'blur' }]
|
|
49
49
|
},
|
|
50
50
|
{
|
|
51
|
-
label: '
|
|
51
|
+
label: '展开字段名称',
|
|
52
52
|
name: 'with',
|
|
53
53
|
value: '',
|
|
54
54
|
component: 'input',
|
|
55
55
|
options: {
|
|
56
|
-
placeholder: '
|
|
56
|
+
placeholder: '请输入展开字段名称'
|
|
57
57
|
},
|
|
58
58
|
span: 24,
|
|
59
59
|
rules: [{ required: true, message: '不能为空', trigger: 'blur' }]
|
|
60
60
|
},
|
|
61
61
|
{
|
|
62
|
-
label: '
|
|
63
|
-
name: '
|
|
62
|
+
label: '输出名称',
|
|
63
|
+
name: 'into',
|
|
64
64
|
value: '',
|
|
65
65
|
component: 'input',
|
|
66
66
|
options: {
|
|
67
|
-
placeholder: '
|
|
67
|
+
placeholder: '请输入输出名称'
|
|
68
68
|
},
|
|
69
|
-
span: 24
|
|
69
|
+
span: 24,
|
|
70
|
+
rules: [{ required: true, message: '不能为空', trigger: 'blur' }]
|
|
70
71
|
},
|
|
71
72
|
{
|
|
72
73
|
label: '描述信息',
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* ET2L
|
|
2
|
+
* ET2L数据过滤节点 FILTER 配置数据
|
|
3
3
|
*/
|
|
4
4
|
|
|
5
5
|
export default {
|
|
6
6
|
// 暂无显示需求
|
|
7
7
|
nodeHtml: [],
|
|
8
|
-
//
|
|
8
|
+
// 目标节点校验
|
|
9
9
|
targetRules: [
|
|
10
10
|
{
|
|
11
11
|
message: '目标节点只允许一个上级连接',
|
|
@@ -47,6 +47,17 @@ export default {
|
|
|
47
47
|
span: 24,
|
|
48
48
|
rules: [{ required: true, message: '不能为空', trigger: 'blur' }]
|
|
49
49
|
},
|
|
50
|
+
{
|
|
51
|
+
label: '输出名称',
|
|
52
|
+
name: 'into',
|
|
53
|
+
value: '',
|
|
54
|
+
component: 'input',
|
|
55
|
+
options: {
|
|
56
|
+
placeholder: '请输入输出名称'
|
|
57
|
+
},
|
|
58
|
+
span: 24,
|
|
59
|
+
rules: [{ required: true, message: '不能为空', trigger: 'blur' }]
|
|
60
|
+
},
|
|
50
61
|
{
|
|
51
62
|
label: '过滤条件',
|
|
52
63
|
name: 'when',
|