From 5bf029b378b9e43df4b9cfca7e550fe8e1df7c46 Mon Sep 17 00:00:00 2001 From: kostis30fyllou Date: Fri, 31 May 2019 16:42:39 +0300 Subject: [PATCH] 1. Fix pagination at frontend. 2. Add alter table on backend to create column notified with default value 0. 3. Add notified column on creation of database table of new user. --- interactive-mining-backend/madoap/src/madserverv3.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/interactive-mining-backend/madoap/src/madserverv3.py b/interactive-mining-backend/madoap/src/madserverv3.py index ea62704..050624f 100755 --- a/interactive-mining-backend/madoap/src/madserverv3.py +++ b/interactive-mining-backend/madoap/src/madserverv3.py @@ -403,7 +403,7 @@ class InitialClientHandshakeHandler(BaseHandler): cursor.execute('''CREATE TABLE community(id)''', parse=False) cursor.execute('''INSERT INTO community VALUES(?)''', (community_id,), parse=False) cursor.execute('''DROP TABLE IF EXISTS database''', parse=False) - cursor.execute('''CREATE TABLE database(id,name,datecreated,status,matches,docname,docsnumber)''', parse=False) + cursor.execute('''CREATE TABLE database(id,name,datecreated,status,matches,docname,docsnumber,notified)''', parse=False) cursor.close() else: cursor=madis.functions.Connection(database_file_name).cursor() @@ -462,6 +462,7 @@ class GetUsersProfilesHandler(BaseHandler): return # get the database cursor cursor=madis.functions.Connection(database_file_name).cursor() + cursor.execute('''ALTER TABLE database ADD COLUMN notified INTEGER DEFAULT 0''') try: # get community id community_id = [r for r in cursor.execute('''SELECT id FROM community''')][0]