mirror of
https://github.com/node-red/node-red.git
synced 2023-10-10 13:36:53 +02:00
parent
3e235ecc0b
commit
e7dccf04d2
@ -750,8 +750,8 @@ RED.editor = (function() {
|
|||||||
var wasDirty = RED.view.dirty();
|
var wasDirty = RED.view.dirty();
|
||||||
|
|
||||||
var newName = $("#subflow-input-name").val();
|
var newName = $("#subflow-input-name").val();
|
||||||
var newInCount = $("#subflow-input-inCount").val();
|
var newInCount = Number($("#subflow-input-inCount").val())||0;
|
||||||
var newOutCount = $("#subflow-input-outCount").val();
|
var newOutCount = Number($("#subflow-input-outCount").val())||0;
|
||||||
|
|
||||||
var oldInCount = editing_node.in.length;
|
var oldInCount = editing_node.in.length;
|
||||||
var oldOutCount = editing_node.out.length;
|
var oldOutCount = editing_node.out.length;
|
||||||
|
@ -2016,20 +2016,22 @@ RED.view = (function() {
|
|||||||
type:"subflow",
|
type:"subflow",
|
||||||
id:subflowId,
|
id:subflowId,
|
||||||
name:name,
|
name:name,
|
||||||
in: candidateInputs.map(function(v,i) { return {
|
in: candidateInputs.map(function(v,i) { var index = i; return {
|
||||||
type:"subflow",
|
type:"subflow",
|
||||||
direction:"in",
|
direction:"in",
|
||||||
x:v.target.x-(v.target.w/2)-80,
|
x:v.target.x-(v.target.w/2)-80,
|
||||||
y:v.target.y,
|
y:v.target.y,
|
||||||
z:subflowId,
|
z:subflowId,
|
||||||
|
i:index,
|
||||||
wires:[{id:v.target.id}]
|
wires:[{id:v.target.id}]
|
||||||
}}),
|
}}),
|
||||||
out: candidateOutputs.map(function(v) { return {
|
out: candidateOutputs.map(function(v,i) { var index = i; return {
|
||||||
type:"subflow",
|
type:"subflow",
|
||||||
direction:"in",
|
direction:"in",
|
||||||
x:v.source.x+(v.source.w/2)+80,
|
x:v.source.x+(v.source.w/2)+80,
|
||||||
y:v.source.y,
|
y:v.source.y,
|
||||||
z:subflowId,
|
z:subflowId,
|
||||||
|
i:index,
|
||||||
wires:[{id:v.source.id,port:v.sourcePort}]
|
wires:[{id:v.source.id,port:v.sourcePort}]
|
||||||
}})
|
}})
|
||||||
};
|
};
|
||||||
|
Loading…
Reference in New Issue
Block a user