1
0
mirror of https://github.com/mailcow/mailcow-dockerized.git synced 2024-12-04 10:24:42 +02:00

[BS5] jquery datatables disable orderable checkboxes

This commit is contained in:
FreddleSpl0it 2022-06-08 12:03:54 +02:00
parent 351c803623
commit 09ae37410e
5 changed files with 166 additions and 90 deletions

View File

@ -86,7 +86,10 @@ jQuery(function($){
},
{
title: '',
data: 'chkbox'
data: 'chkbox',
searchable: false,
orderable: false,
defaultContent: ''
},
{
title: lang.username,
@ -145,7 +148,10 @@ jQuery(function($){
},
{
title: '',
data: 'chkbox'
data: 'chkbox',
searchable: false,
orderable: false,
defaultContent: ''
},
{
title: 'ID',
@ -193,7 +199,10 @@ jQuery(function($){
},
{
title: '',
data: 'chkbox'
data: 'chkbox',
searchable: false,
orderable: false,
defaultContent: ''
},
{
title: lang.username,
@ -245,7 +254,10 @@ jQuery(function($){
},
{
title: '',
data: 'chkbox'
data: 'chkbox',
searchable: false,
orderable: false,
defaultContent: ''
},
{
title: lang.host,
@ -289,7 +301,10 @@ jQuery(function($){
},
{
title: '',
data: 'chkbox'
data: 'chkbox',
searchable: false,
orderable: false,
defaultContent: ''
},
{
title: 'ID',
@ -341,7 +356,10 @@ jQuery(function($){
},
{
title: '',
data: 'chkbox'
data: 'chkbox',
searchable: false,
orderable: false,
defaultContent: ''
},
{
title: 'ID',
@ -393,7 +411,10 @@ jQuery(function($){
},
{
title: '',
data: 'chkbox'
data: 'chkbox',
searchable: false,
orderable: false,
defaultContent: ''
},
{
title: 'QID',

View File

@ -97,7 +97,10 @@ jQuery(function($){
},
{
title: '',
data: 'chkbox'
data: 'chkbox',
searchable: false,
orderable: false,
defaultContent: ''
},
{
title: 'ID',
@ -146,7 +149,10 @@ jQuery(function($){
},
{
title: '',
data: 'chkbox'
data: 'chkbox',
searchable: false,
orderable: false,
defaultContent: ''
},
{
title: 'ID',

View File

@ -240,7 +240,6 @@ jQuery(function($){
type: "GET",
url: "/api/v1/get/domain/all",
dataSrc: function(json){
console.log(json);
$.each(json, function(i, item) {
item.aliases = item.aliases_in_domain + " / " + item.max_num_aliases_for_domain;
item.mailboxes = item.mboxes_in_domain + " / " + item.max_num_mboxes_for_domain;
@ -279,11 +278,25 @@ jQuery(function($){
}
});
console.log(json);
return json;
}
},
columns: [
{
// placeholder, so checkbox will not block child row toggle
title: '',
data: null,
searchable: false,
orderable: false,
defaultContent: ''
},
{
title: '',
data: 'chkbox',
searchable: false,
orderable: false,
defaultContent: ''
},
{
title: lang.domain,
data: 'domain_name'
@ -421,7 +434,6 @@ jQuery(function($){
item.username = escapeHtml(item.username);
});
console.log(json);
return json;
}
},
@ -436,7 +448,10 @@ jQuery(function($){
},
{
title: '',
data: 'chkbox'
data: 'chkbox',
searchable: false,
orderable: false,
defaultContent: ''
},
{
title: lang.username,
@ -542,7 +557,6 @@ jQuery(function($){
item.name = escapeHtml(item.name);
});
console.log(json);
return json;
}
},
@ -557,7 +571,10 @@ jQuery(function($){
},
{
title: '',
data: 'chkbox'
data: 'chkbox',
searchable: false,
orderable: false,
defaultContent: ''
},
{
title: lang.description,
@ -617,7 +634,6 @@ jQuery(function($){
}
});
console.log(json);
return json;
}
},
@ -632,7 +648,10 @@ jQuery(function($){
},
{
title: '',
data: 'chkbox'
data: 'chkbox',
searchable: false,
orderable: false,
defaultContent: ''
},
{
title: 'ID',
@ -689,7 +708,6 @@ jQuery(function($){
item.chkbox = '<input type="checkbox" data-id="recipient_map" name="multi_select" value="' + item.id + '" />';
});
console.log(json);
return json;
}
},
@ -704,7 +722,10 @@ jQuery(function($){
},
{
title: '',
data: 'chkbox'
data: 'chkbox',
searchable: false,
orderable: false,
defaultContent: ''
},
{
title: 'ID',
@ -758,7 +779,6 @@ jQuery(function($){
item.chkbox = '<input type="checkbox" data-id="tls-policy-map" name="multi_select" value="' + item.id + '" />';
});
console.log(json);
return json;
}
},
@ -773,7 +793,10 @@ jQuery(function($){
},
{
title: '',
data: 'chkbox'
data: 'chkbox',
searchable: false,
orderable: false,
defaultContent: ''
},
{
title: 'ID',
@ -857,7 +880,6 @@ jQuery(function($){
}
});
console.log(json);
return json;
}
},
@ -872,7 +894,10 @@ jQuery(function($){
},
{
title: '',
data: 'chkbox'
data: 'chkbox',
searchable: false,
orderable: false,
defaultContent: ''
},
{
title: 'ID',
@ -943,7 +968,6 @@ jQuery(function($){
}
});
console.log(json);
return json;
}
},
@ -958,7 +982,10 @@ jQuery(function($){
},
{
title: '',
data: 'chkbox'
data: 'chkbox',
searchable: false,
orderable: false,
defaultContent: ''
},
{
title: lang.alias,
@ -1039,7 +1066,6 @@ jQuery(function($){
item.exit_status = item.success + ' ' + item.exit_status;
});
console.log(json);
return json;
}
},
@ -1054,7 +1080,10 @@ jQuery(function($){
},
{
title: '',
data: 'chkbox'
data: 'chkbox',
searchable: false,
orderable: false,
defaultContent: ''
},
{
title: 'ID',
@ -1130,7 +1159,6 @@ jQuery(function($){
item.chkbox = '<input type="checkbox" data-id="filter_item" name="multi_select" value="' + item.id + '" />'
});
console.log(json);
return json;
}
},
@ -1145,7 +1173,10 @@ jQuery(function($){
},
{
title: '',
data: 'chkbox'
data: 'chkbox',
searchable: false,
orderable: false,
defaultContent: ''
},
{
title: 'ID',

View File

@ -75,7 +75,10 @@ jQuery(function($){
},
{
title: '',
data: 'chkbox'
data: 'chkbox',
searchable: false,
orderable: false,
defaultContent: ''
},
{
title: 'ID',

View File

@ -165,7 +165,10 @@ jQuery(function($){
},
{
title: '',
data: 'chkbox'
data: 'chkbox',
searchable: false,
orderable: false,
defaultContent: ''
},
{
title: lang.alias,
@ -252,7 +255,10 @@ jQuery(function($){
},
{
title: '',
data: 'chkbox'
data: 'chkbox',
searchable: false,
orderable: false,
defaultContent: ''
},
{
title: 'ID',
@ -355,7 +361,10 @@ jQuery(function($){
},
{
title: '',
data: 'chkbox'
data: 'chkbox',
searchable: false,
orderable: false,
defaultContent: ''
},
{
title: 'ID',
@ -419,7 +428,10 @@ jQuery(function($){
},
{
title: '',
data: 'chkbox'
data: 'chkbox',
searchable: false,
orderable: false,
defaultContent: ''
},
{
title: 'ID',
@ -472,7 +484,10 @@ jQuery(function($){
},
{
title: '',
data: 'chkbox'
data: 'chkbox',
searchable: false,
orderable: false,
defaultContent: ''
},
{
title: 'ID',