组织层次结构图 [英] organizational hierarchy chart

查看:195
本文介绍了组织层次结构图的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我必须根据asp.net 2.0版(vs 2008)中数据库的数据显示可编辑的组织层次结构图。迫切需要一些指导方针



一些明确的代码结构将非常受欢迎。

解决方案

有一些不同的可能性HTML5提供两种选择:Canvas或SVG。 SVG可以直接嵌入到HTML中,并且可以使用JavaScript进行操作,而Canvas图形应该从头开始使用JavaScript完全构建。请参阅:

https://en.wikipedia.org/wiki/Scalable_Vector_Graphics [< a href =https://en.wikipedia.org/wiki/Scalable_Vector_Graphicstarget =_ blanktitle =New Window> ^ ],

https://developer.mozilla.org/en-US/docs/Web/SVG [ ^ ],

https://en.wikipedia.org/wiki/HTML5 [ ^ ],

https://developer.mozilla.org/en-US/docs/SVG_In_HTML_Introduction [ ^ ],

http://en.wikipedia.org/wiki/Html5_canvas [ ^ ],

https:// developer .mozilla.org / zh-CN / docs / Web / API / Canvas_API [ ^ ],

https://developer.mozilla.org/en-US/docs/Web/API/Canvas_API/Tutorial [ ^ ],

https://developer.mozilla.org/en-US/docs/Web/API/Canvas_API/Tutorial/Drawing_shapes [ ^ ]。



如果没有这两个高级HTML功能中的一个,其他解决方案看起来真的很无聊。您可以使用服务器端的ASP.NET动态创建图表;使用 System.Drawing System.Drawing.Imaging 从数据中创建位图资源,并在HTTP响应中以回发方式发送它们。使图元素交互式要困难得多。您必须在JavaScript中处理鼠标/键盘事件并在每个最小的移动中创建回发。要在此类交互式移动上发送HTTP请求,您可以使用AJAX。这将产生相当大的性能成本。然而,这样的系统确实存在。趋势是摆脱这种架构并转向客户端处理,这提供了出色的性能。这些系统是目前浏览器快速HTML / DOM / API标准化的目标之一。



请理解Quick Questions&答案几乎不允许我们认真讨论建模,数据层,UI架构和其他细节。这是严肃的建筑,设计和编程工作的问题,更重要的是获得专家建议。





-SA

I have to show a editable organizational hierarchy chart based on the data from database in asp.net version 2.0 (vs 2008). Desperately in need of some guidelines

Some definitive code structures would be very appreciated.

解决方案

There are some different possibilities. HTML5 provides two choices: Canvas or SVG. SVG which can be directly embedded in HTML and both can be manipulated using JavaScript, and Canvas graphics should be completely build with JavaScript from scratch. Please see:
https://en.wikipedia.org/wiki/Scalable_Vector_Graphics[^],
https://developer.mozilla.org/en-US/docs/Web/SVG[^],
https://en.wikipedia.org/wiki/HTML5[^],
https://developer.mozilla.org/en-US/docs/SVG_In_HTML_Introduction[^],
http://en.wikipedia.org/wiki/Html5_canvas[^],
https://developer.mozilla.org/en-US/docs/Web/API/Canvas_API[^],
https://developer.mozilla.org/en-US/docs/Web/API/Canvas_API/Tutorial[^],
https://developer.mozilla.org/en-US/docs/Web/API/Canvas_API/Tutorial/Drawing_shapes[^].

Without one of these two advanced HTML features, other solutions looks really boring. You can create the diagrams on the fly using ASP.NET on server side; create bitmap resources out of data using System.Drawing, System.Drawing.Imaging and send them on postback in HTTP response. It would be much harder to make the diagram elements interactive. You would have to handle mouse/keyboard events in JavaScript and create a postback on every smallest move. To send HTTP requests on such interactive moves, you can use AJAX. It will incur considerable performance costs. Nevertheless, such system do exists. The trend is to get away from such architectures and shift to client-side processing, which offers excellent performance. Such systems is one of the goals of the quick HTML/DOM/API standardization of browsers which takes place these days.

Please understand that the format of Quick Questions & Answers hardly allows us to seriously discuss modeling, data layers, UI architecture and other detail. This is all the matter of serious architectural, design and programming work, more then the matter of getting expert advice.


—SA


这篇关于组织层次结构图的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆