我在我的网站中使用https://github.com/caprica/jquery-orgchart 。对于正常的组织结构,它工作得很好。我被要求展示一个最高级别的人,然后是下一行,第 2 行更高级别的人,然后是第三行的最后 2 个人。
想象一个副总裁(上)、2 名董事(第 2 行)和 2 名经理(第 3 行)。
数据:
<ul id="organisation" class="hide">
<li>Name Top Row
<ul>
<li>Goes onto Row 2</li>
<li>Goes onto Row 2</li>
<li>Goes onto Row 3</li>
<li>Goes onto Row 3</li>
</ul>
</li>
</ul>
对于我的生活,我无法让这个工作。有没有人有这样做的代码示例 URL 或 jsfiddle?
谢谢!