reaction-cudl-log
This commit is contained in:
@@ -192,13 +192,16 @@ def get_with_stat(q):
|
||||
with local_session() as session:
|
||||
for cols in session.execute(q):
|
||||
entity = cols[0]
|
||||
entity.stat = {'shouts': cols[1], 'authors': cols[2], 'followers': cols[3]}
|
||||
entity.stat = {}
|
||||
entity.stat['shouts'] = cols[1]
|
||||
entity.stat['authors'] = cols[2]
|
||||
entity.stat['followers'] = cols[3]
|
||||
entity.stat['comments'] = cols[4]
|
||||
if is_author:
|
||||
entity.stat['comments'] = cols[4]
|
||||
entity.stat['topics'] = cols[5]
|
||||
# entity.stat['rating'] = cols[5] - cols[6]
|
||||
# entity.stat['rating_shouts'] = cols[7] - cols[8]
|
||||
pass
|
||||
|
||||
records.append(entity)
|
||||
|
||||
return records
|
||||
|
Reference in New Issue
Block a user