mirror of
https://github.com/qbittorrent/qBittorrent
synced 2025-07-06 21:21:24 -07:00
WebUI: Allow to display only hostname in the Tracker column
It is now possible to display only hostname in the Tracker column. Closes #11357. PR #21243.
This commit is contained in:
parent
fc82abe7f6
commit
9d0fa213be
4 changed files with 68 additions and 47 deletions
|
@ -1248,6 +1248,14 @@ window.qBittorrent.DynamicTable ??= (() => {
|
|||
}
|
||||
};
|
||||
|
||||
// tracker
|
||||
this.columns["tracker"].updateTd = function(td, row) {
|
||||
const value = this.getRowValue(row);
|
||||
const tracker = displayFullURLTrackerColumn ? value : window.qBittorrent.Misc.getHost(value);
|
||||
td.textContent = tracker;
|
||||
td.title = value;
|
||||
};
|
||||
|
||||
// dl_limit, up_limit
|
||||
this.columns["dl_limit"].updateTd = function(td, row) {
|
||||
const speed = this.getRowValue(row);
|
||||
|
@ -1424,7 +1432,7 @@ window.qBittorrent.DynamicTable ??= (() => {
|
|||
break; // do nothing
|
||||
default:
|
||||
if (!useSubcategories) {
|
||||
if (categoryHash !== window.qBittorrent.Client.genHash(row["full_data"].category))
|
||||
if (categoryHash !== window.qBittorrent.Misc.genHash(row["full_data"].category))
|
||||
return false;
|
||||
}
|
||||
else {
|
||||
|
@ -1449,7 +1457,7 @@ window.qBittorrent.DynamicTable ??= (() => {
|
|||
break; // do nothing
|
||||
|
||||
default: {
|
||||
const tagHashes = row["full_data"].tags.split(", ").map(tag => window.qBittorrent.Client.genHash(tag));
|
||||
const tagHashes = row["full_data"].tags.split(", ").map(tag => window.qBittorrent.Misc.genHash(tag));
|
||||
if (!tagHashes.contains(tagHash))
|
||||
return false;
|
||||
break;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue