Javascript 为我添加的每个元素在节点内容中添加模态窗口

Javascript 为我添加的每个元素在节点内容中添加模态窗口,javascript,jquery,bootstrap-modal,orgchart,Javascript,Jquery,Bootstrap Modal,Orgchart,我现在正在使用库jquery.orgchart.js 我在我的组织结构图中显示了不同的层次,一切都很好。 对于最后一个级别,人们希望看到团队中的每个人,在同一个节点中,并通过弹出的链接显示带有一些文本的图像 对于节点,我们可以添加第二个菜单,如本例所示: 我想知道是否有可能为我在hover或onclick上添加到节点中的每个元素(每个员工)提供一个弹出窗口。 以下是我的按钮对话框Modal的引导代码: OnHover:仅显示标题,不显示数据内容: <button type="button"

我现在正在使用库jquery.orgchart.js

我在我的组织结构图中显示了不同的层次,一切都很好。 对于最后一个级别,人们希望看到团队中的每个人,在同一个节点中,并通过弹出的链接显示带有一些文本的图像

对于节点,我们可以添加第二个菜单,如本例所示:

我想知道是否有可能为我在hover或onclick上添加到节点中的每个元素(每个员工)提供一个弹出窗口。 以下是我的按钮对话框Modal的引导代码:

OnHover:仅显示标题,不显示数据内容:

<button type="button" class="btn btn-primary" data-toggle="popover" title="Test en cours" data-content="You gotta go through it to see there aint nothing to it. Listen to the silence."> Hover 1</button>

                $(document).ready(function() {
                       $('[data-toggle="popover"]').popover({
                          placement: 'bottom',
                          trigger: 'click',
                          title: 'Sign in to the website builder',
                          content: 'testing 123'    
                       });

                    });

我添加标签容器:“body”和我的弹出窗口终于出现了

我刚刚在这里找到了解决方案:github.com/twbs/bootstrap/issues/5889我更新了我的帖子

        $(document).ready(function() {
                       $('[data-toggle="popover"]').popover({
                          placement: 'bottom',
                          trigger: 'hover',
                          title: 'Sign in to the website builder',
                          content: 'testing 123',
                          container: 'body' 
                       });

                    });