|
@ -3,7 +3,7 @@ import sqlite3 as sqlite |
|
|
import random |
|
|
import random |
|
|
import base64 |
|
|
import base64 |
|
|
import simplejson as json |
|
|
import simplejson as json |
|
|
|
|
|
|
|
|
|
|
|
import uuid |
|
|
|
|
|
|
|
|
class Book: |
|
|
class Book: |
|
|
id: str |
|
|
id: str |
|
@ -58,7 +58,7 @@ class BookDB: |
|
|
"LIMIT ? OFFSET ?", (size, start)) |
|
|
"LIMIT ? OFFSET ?", (size, start)) |
|
|
for row in cursor: |
|
|
for row in cursor: |
|
|
book = Book() |
|
|
book = Book() |
|
|
book.id = row[0] |
|
|
|
|
|
|
|
|
book.id = row[0] + '_' + str(uuid.uuid1()) |
|
|
book.title = row[1] |
|
|
book.title = row[1] |
|
|
book.author = row[2] |
|
|
book.author = row[2] |
|
|
book.publisher = row[3] |
|
|
book.publisher = row[3] |
|
|