我试图在graphviz中创建流量控制图,但我无法让节点保持在顺序中。我尝试用数字作为前缀,因为这是我能够以正确的顺序进行聚类的唯一方法(通过试验错误),但这对节点不起作用。
我给节点提供了100的权重以供订购(我打算在实际工作后使其隐藏)无济于事。
digraph G {
rankdir=LR;
splines=ortho;
subgraph cluster_I {
color=lightgrey;
style=filled;
label="Incoming Numbers";
newrank="true";
node [color=white,
style=filled];
"thisExtention" [color=lightskyblue1,
shape=square,
style="rounded, filled",
label="Extension 20"];
"+15412362468" [color=azure,
shape=rectangle,
style="rounded, filled"];
"+15412362468" -> "thisExtention" [tailport=e];
"+12069732753" [color=azure,
shape=rectangle,
style="rounded, filled"];
"+12069732753" -> "thisExtention" [tailport=e];
"+441134037186" [color=azure,
shape=rectangle,
style="rounded, filled"];
"+441134037186" -> "thisExtention" [tailport=e];
{
rank=same;
"+15412362468";
"+12069732753";
"+441134037186";
}
}
subgraph cluster_A {
color=blue;
subgraph cluster_1W {
color=lightgrey;
style=filled;
"actionstart" [label="Start Inbound Action Steps\n(can be interrupted by menu dial)"];
"thisExtention" -> "actionstart" [tailport=e];
}
subgraph cluster_2G {
color=aquamarine2;
style=filled;
"2if" [color=azure,
shape=diamond,
label="IF MENUKEY does equal 4"];
"3if" [color=azure,
shape=diamond,
label="IF SUM does equal 2\nAND INSIDE “BUSINESS HOURS”"];
"4ring" [color=azure,
shape=rectangle,
label="ring"];
"6playrecording" [color=azure,
shape=rectangle,
label="playrecording"];
}
subgraph cluster_3Y {
color=salmon1;
style=filled;
"7else" [color=azure,
shape=diamond,
label=ELSE];
"8playrecording" [color=azure,
shape=rectangle,
label="playrecording"];
}
subgraph cluster_W4 {
color=lightgrey;
style=filled;
"9transfer" [color=azure,
shape=rectangle,
label="transfer"];
}
subgraph cluster_5G {
color=aquamarine2;
style=filled;
"10else" [color=azure,
shape=diamond,
label=ELSE];
"11hangup" [color=azure,
shape=rectangle,
label="hangup"];
}
subgraph cluster_O {
color=lightgray;
style=filled;
label="Dial Menu";
"17ring" [color=azure,
shape=rectangle,
label="DIAL (#):\nring"];
"18set" [color=azure,
shape=rectangle,
label="DIAL ①:\nset"];
"19playrecording" [color=azure,
shape=rectangle,
label="DIAL ②:\nplayrecording"];
"20huntgroup" [color=azure,
shape=rectangle,
label="DIAL ③:\nRing HuntGroup: test hunt group"];
"21transfer" [color=azure,
shape=rectangle,
label="DIAL ④:\ntransfer"];
"22huntgroup" [color=azure,
shape=rectangle,
label="DIAL ⑤:\nRing HuntGroup: test hunt group"];
}
{
rank="same";
"actionstart";
"2if";
"3if";
"4ring";
"6playrecording";
"7else";
"8playrecording";
"9transfer";
"10else";
"11hangup";
"17ring";
"18set";
"19playrecording";
"20huntgroup";
"21transfer";
"22huntgroup";
}
"actionstart" -> "2if" [weight=100];
"2if" -> "3if" [weight=100];
"3if" -> "4ring" [weight=100];
"4ring" -> "6playrecording" [weight=100];
"6playrecording" -> "7else" [weight=100];
"7else" -> "8playrecording" [weight=100];
"8playrecording" -> "9transfer" [weight=100];
"9transfer" -> "10else" [weight=100];
"10else" -> "11hangup" [weight=100];
"11hangup" -> "17ring" [weight=100];
"17ring" -> "18set" [weight=100];
"18set" -> "19playrecording" [weight=100];
"19playrecording" -> "20huntgroup" [weight=100];
"20huntgroup" -> "21transfer" [weight=100];
"21transfer" -> "22huntgroup" [weight=100];
}
subgraph columnthree {
"Extension 10" [shape=square,
style="rounded, filled",
fillcolor=lightskyblue1];
"9transfer" -> "Extension 10" [weight=0,
tailport=e];
"HuntGroup 2" [shape=septagon,
style="filled",
fillcolor=lightcyan1];
"20huntgroup" -> "HuntGroup 2" [weight=0,
tailport=e];
"Extension 10" [shape=square,
style="rounded, filled",
fillcolor=lightskyblue1];
"21transfer" -> "Extension 10" [weight=0,
tailport=e];
"HuntGroup 2" [shape=septagon,
style="filled",
fillcolor=lightcyan1];
"22huntgroup" -> "HuntGroup 2" [weight=0,
tailport=e];
}
}