mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-06-23 15:30:45 -04:00
...
This commit is contained in:
parent
30b3fdb925
commit
e15c223b37
@ -410,6 +410,9 @@ class AjaxServer(object):
|
|||||||
@Endpoint()
|
@Endpoint()
|
||||||
def ajax_books_in(self, category, item, sort='title', num=25, offset=0,
|
def ajax_books_in(self, category, item, sort='title', num=25, offset=0,
|
||||||
sort_order='asc'):
|
sort_order='asc'):
|
||||||
|
'''
|
||||||
|
Return the books (as list of ids) present in the specified category.
|
||||||
|
'''
|
||||||
try:
|
try:
|
||||||
dname, ditem = map(decode_name, (category, item))
|
dname, ditem = map(decode_name, (category, item))
|
||||||
except:
|
except:
|
||||||
@ -471,6 +474,10 @@ class AjaxServer(object):
|
|||||||
@Endpoint()
|
@Endpoint()
|
||||||
def ajax_search(self, query='', sort='title', offset=0, num=25,
|
def ajax_search(self, query='', sort='title', offset=0, num=25,
|
||||||
sort_order='asc'):
|
sort_order='asc'):
|
||||||
|
'''
|
||||||
|
Return the books (as list of ids) matching the specified search query.
|
||||||
|
'''
|
||||||
|
|
||||||
try:
|
try:
|
||||||
num = int(num)
|
num = int(num)
|
||||||
except:
|
except:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user