// ==UserScript== // @name 种子列表过滤与认领 // @namespace https://greasyfork.org/zh-CN/scripts/451748 // @version 0.5.1 // @license GPL-3.0 License // @description 在种子列表页中,过滤: 未作种,无国语,有中字,标题不含,描述不含,大小介于,以及imdb大于输入值 的种子 // @author ccf2012 // @source https://github.com/ccf-2012/torfilter // @icon https://pterclub.com/favicon.ico // @grant GM_setClipboard // @grant GM_xmlhttpRequest // @require https://code.jquery.com/jquery-3.6.0.min.js // @match https://pterclub.com/torrents.php* // @match https://pterclub.com/officialgroup* // @match https://chdbits.co/torrents.php* // @match https://audiences.me/torrents.php* // @match https://ourbits.club/torrents.php* // @match https://springsunday.net/torrents.php* // @downloadURL none // ==/UserScript== const not_supported = (element) => { return '' }; const pter_imdb = (element) => { var t = $(element).find("td:nth-child(2) > table > tbody > tr > td > a:nth-child(1) > span"); return t.text(); }; const pter_douban = (element) => { var d = $(element).find("td:nth-child(2) > table > tbody > tr > td > a:nth-child(2) > span"); return d.text(); }; const pter_seeding = (element) => { var d = $(element).find("img.progbargreen"); return (d.length > 0); }; const chd_imdb = (element) => { var t = $(element).find("td:nth-child(2) > table > tbody > tr > td:nth-child(2)"); return t.text(); }; const chd_seeding = (element) => { var d = $(element).find("td:nth-child(10)"); return (d.length > 0 && d.css("color") === 'rgb(0, 128, 0)') // return (d.text() === "100%") }; const ade_imdb = (element) => { var t = $(element).find("td.rowfollow.torrents-box > div.torrents-name > table > tbody > tr > td:nth-child(2) > table > tbody > tr > td:nth-child(1) > div > a:nth-child(3)"); return t.text(); }; const ade_douban = (element) => { var d = $(element).find("td.rowfollow.torrents-box > div.torrents-name > table > tbody > tr > td:nth-child(2) > table > tbody > tr > td:nth-child(1) > div > a:nth-child(1)"); return d.text(); }; const ade_seeding = (element) => { var d = $(element).find("div.torrents-progress"); return (d.length > 0 && d.css("width") != '0px') // return d.text() === "100%"; }; const ob_imdb = (element) => { var t = $(element).find("td:nth-child(2) > table > tbody > tr > td:nth-child(4) > div:nth-child(1) > em > label"); return t.text(); }; const ob_douban = (element) => { var d = $(element).find("td:nth-child(2) > table > tbody > tr > td:nth-child(4) > div:nth-child(2) > em > label"); return d.text(); }; const ob_seeding = (element) => { var d = $(element).find("div.progressBar"); return ((d.length > 0) && (d.attr("title").startsWith('100'))) }; const ssd_imdb = (element) => { var t = $(element).find("td:nth-child(3) > div:nth-child(1) > a > span"); let imdb = ""; if (t.parent().attr("href") && t.parent().attr("href").includes("imdb")){ imdb = t.text() } return imdb; }; const ssd_douban = (element) => { var d = $(element).find("td:nth-child(3) > div:nth-child(2) > a > span"); if (!d){ d = $(element).find("td:nth-child(3) > div > a > span"); } let douban = ""; if (t.parent().attr("href") && t.parent().attr("href").includes("douban")){ douban = t.text() } return douban; }; const ssd_seeding = (element) => { var d = $(element).find("div.p_seeding"); return (d.length > 0); }; var config = [ { host: "pterclub.com", eleTorTable: "#torrenttable", eleCurPage: "#outer > table > tbody > tr > td > p:nth-child(4) > font", eleTorList: "#torrenttable > tbody > tr", eleTorItem: " table > tbody > tr > td > div > div:nth-child(1) > a", eleTorItemDesc: "table > tbody > tr > td > div > div:nth-child(2) > span", eleTorItemSize: "td:nth-child(5)", eleTorItemSeednum: "td:nth-child(6)", eleTorItemAdded: "td:nth-child(4) > span", useTitleName: 1, eleIntnTag: "a.chs_tag-gf", eleCnLangTag: "a.chs_tag-gy", eleCnSubTag: "a.chs_tag-sub", // eleCHNAreaTag: "img.chn", eleDownLink: "td:nth-child(2) > table > tbody > tr > td > a:first", eleCatImg: "td:nth-child(1) > a:nth-child(1) > img", filterGY: true, filterZZ: true, funcIMDb:pter_imdb, funcDouban:pter_douban, funcSeeding: pter_seeding, }, { host: "chdbits.co", eleTorTable: "#outer > table > tbody > tr > td > table", eleCurPage: "#outer > table > tbody > tr > td > p:nth-child(3) > font", eleTorList: "#outer > table > tbody > tr > td > table > tbody > tr", eleTorItem: "td:nth-child(2) > table > tbody > tr > td:nth-child(1) > a", eleTorItemDesc: "td:nth-child(2) > table > tbody > tr > td:nth-child(1) > font", eleTorItemSize: "td:nth-child(5)", eleTorItemSeednum: "td:nth-child(6)", eleTorItemAdded: "td:nth-child(4) > span", useTitleName: 1, eleIntnTag: "div.tag-gf", eleCnLangTag: "div.tag-gy", eleCnSubTag: "div.tag-sub", eleDownLink: "td:nth-child(2) > table > tbody > tr > td:nth-child(2) > a:nth-child(1)", eleCatImg: "td:nth-child(1) > a:nth-child(1) > img", filterGY: true, filterZZ: true, funcIMDb:chd_imdb, funcDouban:not_supported, funcSeeding: chd_seeding, }, { host: "audiences.me", eleTorTable: "#torrenttable", eleCurPage: "#outer > table > tbody > tr > td > p:nth-child(2) > font", eleTorList: "#torrenttable > tbody > tr", eleTorItem: "td.rowfollow.torrents-box > div.torrents-name > table > tbody > tr > td:nth-child(1) > a", eleTorItemDesc: "td > div.torrents-name > table > tbody > tr > td:nth-child(1) > span", eleTorItemSize: "td:nth-child(5)", eleTorItemSeednum: "td:nth-child(6)", eleTorItemAdded: "td:nth-child(4) > span", useTitleName: 1, eleIntnTag: "span.tgf", eleCnLangTag: "span.tgy", eleCnSubTag: "span.tzz", eleDownLink: "td > div.torrents-name > table > tbody > tr > td:nth-child(2) > table > tbody > tr > td:nth-child(2) > a:nth-child(1)", eleCatImg: "td:nth-child(1) > a > img", filterGY: true, filterZZ: true, funcIMDb:ade_imdb, funcDouban:ade_douban, funcSeeding: ade_seeding, }, { host: "ourbits.club", eleTorTable: "#torrenttable", eleCurPage: "#outer > table > tbody > tr > td > p:nth-child(7) > font", eleTorList: "#torrenttable > tbody > tr", eleTorItem: "td:nth-child(2) > table > tbody > tr > td:nth-child(1) > a", eleTorItemDesc: "td:nth-child(2) > table > tbody > tr > td:nth-child(1)", eleTorItemSize: "td:nth-child(5)", eleTorItemSeednum: "td:nth-child(6)", eleTorItemAdded: "td:nth-child(4) > span", useTitleName: 1, eleIntnTag: "div.tag-gf", eleCnLangTag: "div.tag-gy", eleCnSubTag: "div.tag-zz", eleDownLink: "td:nth-child(2) > table > tbody > tr > td:nth-child(5) > a:nth-child(1)", eleCatImg: "td:nth-child(1) > a:nth-child(1) > img", filterGY: true, filterZZ: true, funcIMDb:ob_imdb, funcDouban:ob_douban, funcSeeding: ob_seeding, }, { host: "springsunday.net", eleTorTable: "table.torrents", eleCurPage: "#outer > table > tbody > tr > td > p:nth-child(3) > font", eleTorList: "table.torrents > tbody > tr", eleTorItem: "td:nth-child(2) > table > tbody > tr > td:nth-child(1) > a", eleTorItemDesc: "td:nth-child(2) > table > tbody > tr > td:nth-child(1)", eleTorItemSize: "td:nth-child(6)", eleTorItemSeednum: "td:nth-child(7)", eleTorItemAdded: "td:nth-child(5) > span", useTitleName: 1, eleIntnTag: "", eleCnLangTag: "", eleCnSubTag: "", eleDownLink: "td:nth-child(2) > table > tbody > tr > td:nth-child(2) > a:nth-child(1)", eleCatImg: "td:nth-child(1) > a > img", filterGY: false, filterZZ: false, funcIMDb:ssd_imdb, funcDouban:ssd_douban, funcSeeding: ssd_seeding, }, ] var THISCONFIG = config.find((cc) => window.location.host.includes(cc.host)); function addFilterPanel() { var torTable = $(THISCONFIG.eleTorTable); var donwnloadPanel = `
标题不含
|
描述不含
|
大小介于
|
IMDb >
|