aboutsummaryrefslogtreecommitdiff
path: root/wqflask
diff options
context:
space:
mode:
Diffstat (limited to 'wqflask')
-rw-r--r--wqflask/wqflask/server_side.py9
-rw-r--r--wqflask/wqflask/views.py7
2 files changed, 10 insertions, 6 deletions
diff --git a/wqflask/wqflask/server_side.py b/wqflask/wqflask/server_side.py
index d044d411..824b00aa 100644
--- a/wqflask/wqflask/server_side.py
+++ b/wqflask/wqflask/server_side.py
@@ -24,14 +24,13 @@ class ServerSideTable(object):
wqflask/wqflask/views.py for reference use.
'''
- def __init__(self, table_data, request_values):
+ def __init__(self, rows_count, table_rows, header_data_names, request_values):
self.request_values = request_values
self.sEcho = self.request_values['sEcho']
- self.table_data = table_data
- self.rows_count = self.table_data.rows_count
- self.table_rows = self.table_data.table_rows
- self.header_data_names = self.table_data.header_data_names
+ self.rows_count = rows_count
+ self.table_rows = table_rows
+ self.header_data_names = header_data_names
self.sort_rows()
self.paginate_rows()
diff --git a/wqflask/wqflask/views.py b/wqflask/wqflask/views.py
index f0b78188..63570815 100644
--- a/wqflask/wqflask/views.py
+++ b/wqflask/wqflask/views.py
@@ -922,7 +922,12 @@ def db_info_page():
def snp_browser_table():
logger.info(request.url)
snp_table_data = snp_browser.SnpBrowser(request.args)
- current_page = server_side.ServerSideTable(snp_table_data, request.args).get_page()
+ current_page = server_side.ServerSideTable(
+ snp_table_data.rows_count,
+ snp_table_data.table_rows,
+ snp_table_data.header_data_names,
+ request.args,
+ ).get_page()
return flask.jsonify(current_page)