aboutsummaryrefslogtreecommitdiff
path: root/wqflask/base/trait.py
diff options
context:
space:
mode:
authorLei Yan2014-07-14 16:23:12 +0000
committerLei Yan2014-07-14 17:02:01 +0000
commit214bf0128b8ecdda718983c5563cf34160743758 (patch)
tree917e7a5ae78dc4ff65dc08d107a0e3ae3a47c67c /wqflask/base/trait.py
parent8de6fec18cd98a10c58702c448a1e01e147dc5f7 (diff)
parentfbdbf4b7410185e2a978ecc8e120ae56ff6da0ce (diff)
downloadgenenetwork2-214bf0128b8ecdda718983c5563cf34160743758.tar.gz
Merge /home/zas1024/gene
Conflicts: wqflask/wqflask/static/new/javascript/dataset_select_menu.js wqflask/wqflask/templates/corr_scatter_plot_old.html
Diffstat (limited to 'wqflask/base/trait.py')
-rwxr-xr-xwqflask/base/trait.py6
1 files changed, 5 insertions, 1 deletions
diff --git a/wqflask/base/trait.py b/wqflask/base/trait.py
index 712d9af5..2bbd1f2a 100755
--- a/wqflask/base/trait.py
+++ b/wqflask/base/trait.py
@@ -40,6 +40,7 @@ class GeneralTrait(object):
else:
self.dataset = kw.get('dataset')
self.name = kw.get('name') # Trait ID, ProbeSet ID, Published ID, etc.
+ print("THE NAME IS:", self.name)
self.cellid = kw.get('cellid')
self.identification = kw.get('identification', 'un-named trait')
self.haveinfo = kw.get('haveinfo', False)
@@ -295,6 +296,9 @@ class GeneralTrait(object):
PublishXRef.InbredSetId = PublishFreeze.InbredSetId AND
PublishFreeze.Id = %s
""" % (self.name, self.dataset.id)
+
+ print("query is:", query)
+
trait_info = g.db.execute(query).fetchone()
#XZ, 05/08/2009: Xiaodong add this block to use ProbeSet.Id to find the probeset instead of just using ProbeSet.Name
#XZ, 05/08/2009: to avoid the problem of same probeset name from different platforms.
@@ -641,7 +645,7 @@ def get_sample_data():
trait_ob = GeneralTrait(name=trait, dataset_name=dataset)
- return json.dumps({key: value.value for key, value in trait_ob.data.iteritems() })
+ return json.dumps([trait, {key: value.value for key, value in trait_ob.data.iteritems() }])
#jsonable_sample_data = {}
#for sample in trait_ob.data.iteritems():