[Web] Use panel instead of tab-pane to find panel-heading, fixes #3022
parent
6213d6ee02
commit
71994b1bcd
|
@ -43,7 +43,7 @@ jQuery(function($){
|
||||||
var current_page = JSON.parse(localStorage.getItem('current_page'));
|
var current_page = JSON.parse(localStorage.getItem('current_page'));
|
||||||
}
|
}
|
||||||
function table_admin_ready(ft, name) {
|
function table_admin_ready(ft, name) {
|
||||||
heading = ft.$el.parents('.tab-pane').find('.panel-heading')
|
heading = ft.$el.parents('.panel').find('.panel-heading')
|
||||||
var ft_paging = ft.use(FooTable.Paging)
|
var ft_paging = ft.use(FooTable.Paging)
|
||||||
$(heading).children('.table-lines').text(function(){
|
$(heading).children('.table-lines').text(function(){
|
||||||
return ft_paging.totalRows;
|
return ft_paging.totalRows;
|
||||||
|
|
|
@ -18,7 +18,7 @@ jQuery(function($){
|
||||||
eval(draw_table + '()');
|
eval(draw_table + '()');
|
||||||
});
|
});
|
||||||
function table_log_ready(ft, name) {
|
function table_log_ready(ft, name) {
|
||||||
heading = ft.$el.parents('.tab-pane').find('.panel-heading')
|
heading = ft.$el.parents('.panel').find('.panel-heading')
|
||||||
var ft_paging = ft.use(FooTable.Paging)
|
var ft_paging = ft.use(FooTable.Paging)
|
||||||
$(heading).children('.table-lines').text(function(){
|
$(heading).children('.table-lines').text(function(){
|
||||||
return ft_paging.totalRows;
|
return ft_paging.totalRows;
|
||||||
|
@ -446,7 +446,7 @@ jQuery(function($){
|
||||||
"on": {
|
"on": {
|
||||||
"ready.ft.table": function(e, ft){
|
"ready.ft.table": function(e, ft){
|
||||||
table_log_ready(ft, 'rspamd_history');
|
table_log_ready(ft, 'rspamd_history');
|
||||||
heading = ft.$el.parents('.tab-pane').find('.panel-heading')
|
heading = ft.$el.parents('.panel').find('.panel-heading')
|
||||||
$(heading).children('.table-lines').text(function(){
|
$(heading).children('.table-lines').text(function(){
|
||||||
var ft_paging = ft.use(FooTable.Paging)
|
var ft_paging = ft.use(FooTable.Paging)
|
||||||
return ft_paging.totalRows;
|
return ft_paging.totalRows;
|
||||||
|
@ -625,7 +625,7 @@ jQuery(function($){
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if (ft = FooTable.get($('#' + log_table))) {
|
if (ft = FooTable.get($('#' + log_table))) {
|
||||||
var heading = ft.$el.parents('.tab-pane').find('.panel-heading')
|
var heading = ft.$el.parents('.panel').find('.panel-heading')
|
||||||
var ft_paging = ft.use(FooTable.Paging)
|
var ft_paging = ft.use(FooTable.Paging)
|
||||||
var load_rows = (ft_paging.totalRows + 1) + '-' + (ft_paging.totalRows + new_nrows)
|
var load_rows = (ft_paging.totalRows + 1) + '-' + (ft_paging.totalRows + new_nrows)
|
||||||
$.get('/api/v1/get/logs/' + log_url + '/' + load_rows).then(function(data){
|
$.get('/api/v1/get/logs/' + log_url + '/' + load_rows).then(function(data){
|
||||||
|
|
|
@ -208,7 +208,7 @@ jQuery(function($){
|
||||||
.tooltip();
|
.tooltip();
|
||||||
}
|
}
|
||||||
$('.refresh_table').prop("disabled", false);
|
$('.refresh_table').prop("disabled", false);
|
||||||
heading = ft.$el.parents('.tab-pane').find('.panel-heading')
|
heading = ft.$el.parents('.panel').find('.panel-heading')
|
||||||
var ft_paging = ft.use(FooTable.Paging)
|
var ft_paging = ft.use(FooTable.Paging)
|
||||||
$(heading).children('.table-lines').text(function(){
|
$(heading).children('.table-lines').text(function(){
|
||||||
return ft_paging.totalRows;
|
return ft_paging.totalRows;
|
||||||
|
|
Loading…
Reference in New Issue