File tree 1 file changed +10
-6
lines changed
ui/src/workflow/nodes/form-node 1 file changed +10
-6
lines changed Original file line number Diff line number Diff line change @@ -7,18 +7,22 @@ class FormNode extends AppNode {
7
7
get_node_field_list ( ) {
8
8
const result = [ ]
9
9
const fields = this . props . model . properties ?. config ?. fields || [ ]
10
- let otherFields = [ ]
10
+
11
11
try {
12
- otherFields = this . props . model . properties . node_data . form_field_list . map ( ( item : any ) => ( {
13
- label : typeof item . label == 'string' ? item . label : item . label . label ,
14
- value : item . field
15
- } ) )
12
+ this . props . model . properties . node_data . form_field_list . forEach ( ( item : any ) => {
13
+ if ( ! fields . some ( ( f : any ) => f . value === item . field ) ) {
14
+ fields . push ( {
15
+ value : item . field ,
16
+ label : typeof item . label == 'string' ? item . label : item . label . label
17
+ } )
18
+ }
19
+ } )
16
20
} catch ( e ) { }
17
21
result . push ( {
18
22
value : this . props . model . id ,
19
23
label : this . props . model . properties . stepName ,
20
24
type : this . props . model . type ,
21
- children : [ ... fields , ... otherFields ]
25
+ children : fields
22
26
} )
23
27
return result
24
28
}
You can’t perform that action at this time.
0 commit comments