From f94566b6285a462600570d93cbd4eeb0f98818b9 Mon Sep 17 00:00:00 2001 From: Garfield69 Date: Tue, 15 Sep 2020 07:45:37 +1200 Subject: [PATCH] spacetorrent: add freeleech filter #9456 --- .../Definitions/spacetorrent.yml | 34 +++++++++++++++---- 1 file changed, 27 insertions(+), 7 deletions(-) diff --git a/src/Jackett.Common/Definitions/spacetorrent.yml b/src/Jackett.Common/Definitions/spacetorrent.yml index 1cf228c5c..29ab9f53e 100644 --- a/src/Jackett.Common/Definitions/spacetorrent.yml +++ b/src/Jackett.Common/Definitions/spacetorrent.yml @@ -24,20 +24,32 @@ caps: movie-search: [q] music-search: [q] +settings: + - name: username + type: text + label: Username + - name: password + type: password + label: Password + - name: freeleech + type: checkbox + label: Search freeleech only + default: false + login: method: post path: ajax/takelogin.php inputs: - snlo: "certified" + snlo: certified username: "{{ .Config.username }}" password: "{{ .Config.password }}" - returnto: "/my.php" + returnto: "/recherche" test: - path: my.php + path: recherche selector: a[href="../logout"] ratio: - path: my.php + path: recherche selector: a.nav-link i[class="ti-pulse"] download: @@ -45,12 +57,17 @@ download: attribute: href search: + # https://www.spacetorrent.cloud/recherche?advanced_search=true&advanced_search_term=&cat=0&freemium=1 path: recherche inputs: - search: "{{ .Keywords }}" + advanced_search: true + advanced_search_term: "{{ .Keywords }}" cat: 0 + freemium: "{{ if .Config.freeleech }}1{{ else }}{{ end }}" + rows: selector: table#table-1 tbody tr + fields: download: selector: a[href^="../torrent/"] @@ -95,8 +112,11 @@ search: selector: td:nth-child(7) downloadvolumefactor: case: - "i.fa-star": "0" - "*": "1" + "i.fa-star": 0 + "*": 1 uploadvolumefactor: text: 1 + minimumseedtime: + # 1 day (as seconds = 24 x 60 x 60) + text: 86400 # engine n/a