Bug fixes and tiny tweaks.

This commit is contained in:
Scott Taylor
2015-08-31 14:43:48 +10:00
parent 21a9cb251b
commit f02164d860
15 changed files with 177 additions and 91 deletions

View File

@@ -41,6 +41,8 @@
if(query.category && query.category != "")
//world << "\red query category ([query.category])"
searchquery += " [!where ? "WHERE" : "AND"] category LIKE '%[query.category]%'"
if(query.category == "Fiction")
searchquery += " AND category NOT LIKE '%Non-Fiction%'"
where = 1
var/sql = "SELECT id, author, title, category, ckey FROM library [searchquery] LIMIT [page_num * LIBRARY_BOOKS_PER_PAGE], [LIBRARY_BOOKS_PER_PAGE]"