torrentgalaxy: add config sort options

This commit is contained in:
Garfield69
2019-12-21 15:48:56 +13:00
parent 3d582fe851
commit 172f71de81

View File

@@ -54,7 +54,23 @@
tv-search: [q, season, ep] tv-search: [q, season, ep]
movie-search: [q] movie-search: [q]
settings: [] settings:
- name: sort
type: select
label: Sort requested from site
default: "id"
options:
"id": "created"
"seeders": "seeders"
"size": "size"
"name": "title"
- name: type
type: select
label: Order requested from site
default: "desc"
options:
"desc": "desc"
"asc": "asc"
login: login:
# https://torrentgalaxy.to/galaxyfence.php?f&dropoff=%2Ftorrents.php%3Fsearch%3DHarry%2BPotter # https://torrentgalaxy.to/galaxyfence.php?f&dropoff=%2Ftorrents.php%3Fsearch%3DHarry%2BPotter
@@ -62,7 +78,7 @@
method: form method: form
form: form[action="/galaxyfence.php"] form: form[action="/galaxyfence.php"]
inputs: inputs:
dropoff: "/torrents.php" dropoff: /torrents.php
captcha: captcha:
type: image type: image
selector: img#captcha selector: img#captcha
@@ -76,13 +92,15 @@
# https://torrentgalaxy.org/torrents.php?c41=1&search=mercedes+s02e04&lang=0&sort=id&order=desc # https://torrentgalaxy.org/torrents.php?c41=1&search=mercedes+s02e04&lang=0&sort=id&order=desc
path: torrents.php path: torrents.php
inputs: inputs:
$raw: "{{range .Categories}}c{{.}}=1&{{end}}" $raw: "{{ range .Categories }}c{{.}}=1&{{end}}"
search: "{{.Keywords}}" search: "{{ .Keywords }}"
lang: "0" lang: 0
sort: "id" sort: "{{ .Config.sort }}"
order: "desc" order: "{{ .Config.type }}"
rows: rows:
selector: div[class="tgxtablerow"] selector: div[class="tgxtablerow"]
fields: fields:
title: title:
selector: div a[href^="/torrent/"] selector: div a[href^="/torrent/"]
@@ -119,6 +137,6 @@
- name: dateparse - name: dateparse
args: "02/01/06 15:04" args: "02/01/06 15:04"
downloadvolumefactor: downloadvolumefactor:
text: "0" text: 0
uploadvolumefactor: uploadvolumefactor:
text: "1" text: 1