Am using a JQUERY Datatable and Webui Popover plugin on my page. The popover actually assigned for an element in
我在我的页面上使用了JQUERY Datatable和Webui Popover插件。实际上为一个元素分配的popover
<small style=" color: #10336B;" class='codedescription'
data-title="My Title" data-content='My Dynamic Content'><b>CODE
and here the Popover initialisation
这里是Popover的初始化
$('.codedescription').webuiPopover({ closeable: false, trigger: 'hover', title: '', content: '', delay: { show: null, hide: 300} });
Its working fine when the first page or just after the Datatable being binded. But if we move to another page on the datatable or after the page changed, the popover stopped working. Only the first time initialised popovers worked.
它在第一页或数据表被绑定之后工作正常。但是,如果我们移动到数据表上的另一个页面或页面更改后,弹出窗口停止工作。只有第一次初始化的popovers工作。
So I tried reinitialising the popover plugin at the Datatable page change event as follows.
所以我尝试在Datatable页面更改事件中重新初始化popover插件,如下所示。
$('#tbl_main').on('page.dt', function () {
alert(55);
$('.codedescription').webuiPopover({ closeable: false, trigger: 'hover', title: '', content: '', delay: { show: null, hide: 300} });
});
But when ever the page changes alert shows, but the popovers not showing in any pages other than the first page. What is making the popovers to not work after the page changes in JQUERY Datatable.
但是当页面更改警报显示时,但是弹出窗口没有显示在第一页以外的任何页面中。在JQUERY Datatable中页面更改后,什么使popovers不起作用。