aboutsummaryrefslogtreecommitdiff
path: root/wqflask/base/trait.py
diff options
context:
space:
mode:
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():