mirror of
https://github.com/simon987/nyaa.git
synced 2025-12-13 23:29:02 +00:00
WIP hack in es as the provider for search results
real sketch. lots of stuff is still broken. But! you can make elasticsearch q= style queries and it shows up properly. only first page works; need to adapt pager to elasticsearch's "total-hits" thing.
This commit is contained in:
@@ -35,6 +35,10 @@ def mk_es(t):
|
||||
"_type": "torrent",
|
||||
"_index": "nyaav2",
|
||||
"_source": {
|
||||
# we're also indexing the id as a number so you can
|
||||
# order by it. seems like this is just equivalent to
|
||||
# order by created_time, but oh well
|
||||
"id": t.id,
|
||||
"display_name": t.display_name,
|
||||
"created_time": t.created_time,
|
||||
"updated_time": t.updated_time,
|
||||
|
||||
Reference in New Issue
Block a user