流程图定义的迷惑(线不能不交叉?)

这是定义好的流程图路由:
0(Parent:receive order)--->1(Child:check finances)
1(Parent:check finances)--->2(Child:decline order)
1(Parent:check finances)--->9(Child:check stock)
3(Parent:R1)--->4(Child:check part. ship)
3(Parent:R1)--->5(Child:plan part. production)
4(Parent:check part. ship)--->6(Child:R2)
4(Parent:check part. ship)--->8(Child:plan full production)
5(Parent:plan part. production)--->6(Child:R2)
6(Parent:R2)--->7(Child:produce)
7(Parent:produce)--->11(Child:Notify partial shipment)
8(Parent:plan full production)--->7(Child:produce)
9(Parent:check stock)--->3(Child:R1)
9(Parent:check stock)--->8(Child:plan full production)
9(Parent:check stock)--->10(Child:Notify full shipment)
10(Parent:Notify full shipment)--->12(Child:Ship & Report)
11(Parent:Notify partial shipment)--->12(Child:Ship & Report)
我按照层次关系,把图画了出来,可惜,线的交叉非常多。也想不清,这个东西应该是一个算法的问题,还是一个design的问题?后来我抛弃了层次,修改成了这样,呵呵,效果是好了。可惜,想不清楚,代码中如何实现这种效果?!
我做了一个矩阵,结果如下:
 

0,1,0,0,0,0,0,0,0,0,0,0,0,
0,0,1,0,0,0,0,0,0,1,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,1,1,0,0,0,0,0,0,0,
0,0,0,0,0,0,1,0,1,0,0,0,0,
0,0,0,0,0,0,1,0,0,0,0,0,0,
0,0,0,0,0,0,0,1,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,1,0,
0,0,0,0,0,0,0,1,0,0,0,0,0,
0,0,0,1,0,0,0,0,1,0,1,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,1,
0,0,0,0,0,0,0,0,0,0,0,0,1,
0,0,0,0,0,0,0,0,0,0,0,0,0,
可是这个矩阵也只是表明了层次关系而已。
下面是我手工调整的结果。已经问了一些人了,看看下午是否会有结果?
workflow(small).JPG

转载于:https://www.cnblogs.com/juqiang/archive/2004/04/27/7805.html

  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值