aboutsummaryrefslogtreecommitdiff
path: root/wqflask
diff options
context:
space:
mode:
authorSam Ockman2012-06-07 04:10:16 -0400
committerSam Ockman2012-06-07 04:10:16 -0400
commitf3733aa972a3b1ab2eb1ab9d02d859eb75cebbb9 (patch)
treefc129f1a2a57fdf60969e73bdb31a5a5229d8320 /wqflask
parenta6386179f0f94df749d7af232060ff10a68c42f6 (diff)
downloadgenenetwork2-f3733aa972a3b1ab2eb1ab9d02d859eb75cebbb9.tar.gz
Before generating hidden fields in the template
Diffstat (limited to 'wqflask')
-rwxr-xr-xwqflask/wqflask/show_trait/DataEditingPage.py68
-rw-r--r--wqflask/wqflask/templates/trait_data_and_analysis.html71
2 files changed, 86 insertions, 53 deletions
diff --git a/wqflask/wqflask/show_trait/DataEditingPage.py b/wqflask/wqflask/show_trait/DataEditingPage.py
index fda26322..20840975 100755
--- a/wqflask/wqflask/show_trait/DataEditingPage.py
+++ b/wqflask/wqflask/show_trait/DataEditingPage.py
@@ -1,6 +1,7 @@
import string
import os
import cPickle
+from collections import OrderedDict
#import pyXLWriter as xl
from htmlgen import HTMLgen2 as HT
@@ -77,37 +78,37 @@ class DataEditingPage(templatePage):
#############################
# Some fields, like method, are defaulted to None; otherwise in IE the field can't be changed using jquery
- hddn = {
- 'FormID':fmID,
- 'RISet':fd.RISet,
- 'submitID':'',
- 'scale':'physic',
- 'additiveCheck':'ON',
- 'showSNP':'ON',
- 'showGenes':'ON',
- 'method':None,
- 'parentsf14regression':'OFF',
- 'stats_method':'1',
- 'chromosomes':'-1',
- 'topten':'',
- 'viewLegend':'ON',
- 'intervalAnalystCheck':'ON',
- 'valsHidden':'OFF',
- 'database':'',
- 'criteria':None,
- 'MDPChoice':None,
- 'bootCheck':None,
- 'permCheck':None,
- 'applyVarianceSE':None,
- 'strainNames':'_',
- 'strainVals':'_',
- 'strainVars':'_',
- 'otherStrainNames':'_',
- 'otherStrainVals':'_',
- 'otherStrainVars':'_',
- 'extra_attributes':'_',
- 'other_extra_attributes':'_'
- }
+ hddn = OrderedDict(
+ FormID = fmID,
+ RISet = fd.RISet,
+ submitID = '',
+ scale = 'physic',
+ additiveCheck = 'ON',
+ showSNP = 'ON',
+ showGenes = 'ON',
+ method = None,
+ parentsf14regression = 'OFF',
+ stats_method = '1',
+ chromosomes = '-1',
+ topten = '',
+ viewLegend = 'ON',
+ intervalAnalystCheck = 'ON',
+ valsHidden = 'OFF',
+ database = '',
+ criteria = None,
+ MDPChoice = None,
+ bootCheck = None,
+ permCheck = None,
+ applyVarianceSE = None,
+ strainNames = '_',
+ strainVals = '_',
+ strainVars = '_',
+ otherStrainNames = '_',
+ otherStrainVals = '_',
+ otherStrainVars = '_',
+ extra_attributes = '_',
+ other_extra_attributes = '_'
+ )
if fd.enablevariance:
hddn['enablevariance']='ON'
@@ -486,6 +487,7 @@ class DataEditingPage(templatePage):
# ))
#pass
+ thisTrait.species = _Species # We need this in the template, so we tuck it into thisTrait
thisTrait.database = thisTrait.get_database()
#XZ: ID links
@@ -1683,8 +1685,10 @@ class DataEditingPage(templatePage):
or (fd.f1list and thisTrait.data.has_key(fd.f1list[1])):
fd.allstrainlist = allstrainlist_neworder
+ # Sam - is this correct?
if nCols == 6 and fd.varianceDispName != 'Variance':
- mainForm.append(HT.Input(name='isSE', value="yes", type='hidden'))
+ #mainForm.append(HT.Input(name='isSE', value="yes", type='hidden'))
+ hddn['isSE'] = "yes"
primary_div = HT.Div(primary_table, Id="primary") #Container for table with primary (for example, BXD) strain values
container.append(primary_div)
diff --git a/wqflask/wqflask/templates/trait_data_and_analysis.html b/wqflask/wqflask/templates/trait_data_and_analysis.html
index 1e67834c..81d6540f 100644
--- a/wqflask/wqflask/templates/trait_data_and_analysis.html
+++ b/wqflask/wqflask/templates/trait_data_and_analysis.html
@@ -9,23 +9,46 @@
<tr>
<td valign="top" width="100%" bgcolor="#FAFAFA">
<form method="post" action="/webqtl/main.py" name="dataInput">
- <input type="hidden" name="isSE" value="yes"> <input type="hidden" name="permCheck"> <input type="hidden" name="otherStrainVals" value="_">
- <input type="hidden" name="FormID" value="dataEditing"> <input type="hidden" name="normalPlotTitle" value="Sall3: 1441186_at"> <input type=
- "hidden" name="strainVars" value="_"> <input type="hidden" name="additiveCheck" value="ON"> <input type="hidden" name="incparentsf1" value=
- "ON"> <input type="hidden" name="strainNames" value="_"> <input type="hidden" name="submitID" value=""> <input type="hidden" name="scale"
- value="physic"> <input type="hidden" name="intervalAnalystCheck" value="ON"> <input type="hidden" name="topten" value=""> <input type="hidden"
- name="parentsf14regression" value="OFF"> <input type="hidden" name="identification" value="Hippocampus M430v2 BXD 06/06 PDNN : 1441186_at">
- <input type="hidden" name="mappingMethodId" value="1"> <input type="hidden" name="criteria"> <input type="hidden" name="other_extra_attributes"
- value="_"> <input type="hidden" name="otherStrainNames" value="_"> <input type="hidden" name="method"> <input type="hidden" name="showGenes"
- value="ON"> <input type="hidden" name="attribute_names" value=""> <input type="hidden" name="chromosomes" value="-1"> <input type="hidden"
- name="allstrainlist" value=
- "B6D2F1 D2B6F1 C57BL/6J DBA/2J BXD1 BXD2 BXD5 BXD6 BXD8 BXD9 BXD11 BXD12 BXD13 BXD14 BXD15 BXD16 BXD18 BXD19 BXD20 BXD21 BXD22 BXD23 BXD24a BXD24 BXD25 BXD27 BXD28 BXD29 BXD30 BXD31 BXD32 BXD33 BXD34 BXD35 BXD36 BXD37 BXD38 BXD39 BXD40 BXD41 BXD42 BXD43 BXD44 BXD45 BXD48 BXD49 BXD50 BXD51 BXD52 BXD53 BXD54 BXD55 BXD56 BXD59 BXD60 BXD61 BXD62 BXD63 BXD64 BXD65 BXD66 BXD67 BXD68 BXD69 BXD70 BXD71 BXD72 BXD73 BXD74 BXD75 BXD76 BXD77 BXD78 BXD79 BXD80 BXD81 BXD83 BXD84 BXD85 BXD86 BXD87 BXD88 BXD89 BXD90 BXD91 BXD92 BXD93 BXD94 BXD95 BXD96 BXD97 BXD98 BXD99 BXD100 BXD101 BXD102 BXD103 BALB/cByJ PWK/PhJ A/J KK/HlJ LG/J 129S1/SvImJ NZO/HlLtJ CAST/EiJ PWD/PhJ AKR/J CXB13 CXB12 CXB11 CXB10 WSB/EiJ C3H/HeJ CXB7 CXB6 CXB5 CXB4 CXB3 CXB2 CXB1 CXB9 CXB8 NOD/ShiLtJ C57BL/6ByJ BALB/cJ">
- <input type="hidden" name="applyVarianceSE"> <input type="hidden" name="MDPChoice"> <input type="hidden" name="otherStrainVars" value="_">
- <input type="hidden" name="strainVals" value="_"> <input type="hidden" name="showSNP" value="ON"> <input type="hidden" name="bootCheck">
- <input type="hidden" name="GeneId" value="20689"> <input type="hidden" name="extra_attributes" value="_"> <input type="hidden" name=
- "stats_method" value="1"> <input type="hidden" name="heritability" value="None"> <input type="hidden" name="database" value=""> <input type=
- "hidden" name="viewLegend" value="ON"> <input type="hidden" name="fromDataEditingPage" value="1"> <input type="hidden" name="trait_type" value=
- "ProbeSet"> <input type="hidden" name="valsHidden" value="OFF"> <input type="hidden" name="fullname" value="HC_M2_0606_P::1441186_at">
+ <input type="hidden" name="isSE" value="yes">
+ <input type="hidden" name="permCheck">
+ <input type="hidden" name="otherStrainVals" value="_">
+ <input type="hidden" name="FormID" value="dataEditing">
+ <input type="hidden" name="normalPlotTitle" value="Sall3: 1441186_at">
+ <input type="hidden" name="strainVars" value="_">
+ <input type="hidden" name="additiveCheck" value="ON">
+ <input type="hidden" name="incparentsf1" value="ON">
+ <input type="hidden" name="strainNames" value="_">
+ <input type="hidden" name="submitID" value="">
+ <input type="hidden" name="scale" value="physic">
+ <input type="hidden" name="intervalAnalystCheck" value="ON">
+ <input type="hidden" name="topten" value="">
+ <input type="hidden" name="parentsf14regression" value="OFF">
+ <input type="hidden" name="identification" value="Hippocampus M430v2 BXD 06/06 PDNN : 1441186_at">
+ <input type="hidden" name="mappingMethodId" value="1">
+ <input type="hidden" name="criteria">
+ <input type="hidden" name="other_extra_attributes" is it value="_">
+ <input type="hidden" name="otherStrainNames" value="_">
+ <input type="hidden" name="method">
+ <input type="hidden" name="showGenes" value="ON">
+ <input type="hidden" name="attribute_names" value="">
+ <input type="hidden" name="chromosomes" value="-1">
+ <input type="hidden" name="allstrainlist" value="B6D2F1 D2B6F1 C57BL/6J DBA/2J BXD1 BXD2 BXD5 BXD6 BXD8 BXD9 BXD11 BXD12 BXD13 BXD14 BXD15 BXD16 BXD18 BXD19 BXD20 BXD21 BXD22 BXD23 BXD24a BXD24 BXD25 BXD27 BXD28 BXD29 BXD30 BXD31 BXD32 BXD33 BXD34 BXD35 BXD36 BXD37 BXD38 BXD39 BXD40 BXD41 BXD42 BXD43 BXD44 BXD45 BXD48 BXD49 BXD50 BXD51 BXD52 BXD53 BXD54 BXD55 BXD56 BXD59 BXD60 BXD61 BXD62 BXD63 BXD64 BXD65 BXD66 BXD67 BXD68 BXD69 BXD70 BXD71 BXD72 BXD73 BXD74 BXD75 BXD76 BXD77 BXD78 BXD79 BXD80 BXD81 BXD83 BXD84 BXD85 BXD86 BXD87 BXD88 BXD89 BXD90 BXD91 BXD92 BXD93 BXD94 BXD95 BXD96 BXD97 BXD98 BXD99 BXD100 BXD101 BXD102 BXD103 BALB/cByJ PWK/PhJ A/J KK/HlJ LG/J 129S1/SvImJ NZO/HlLtJ CAST/EiJ PWD/PhJ AKR/J CXB13 CXB12 CXB11 CXB10 WSB/EiJ C3H/HeJ CXB7 CXB6 CXB5 CXB4 CXB3 CXB2 CXB1 CXB9 CXB8 NOD/ShiLtJ C57BL/6ByJ BALB/cJ">
+ <input type="hidden" name="applyVarianceSE">
+ <input type="hidden" name="MDPChoice">
+ <input type="hidden" name="otherStrainVars" value="_">
+ <input type="hidden" name="strainVals" value="_">
+ <input type="hidden" name="showSNP" value="ON">
+ <input type="hidden" name="bootCheck">
+ <input type="hidden" name="GeneId" value="20689">
+ <input type="hidden" name="extra_attributes" value="_">
+ <input type="hidden" name="stats_method" value="1">
+ <input type="hidden" name="heritability" value="None">
+ <input type="hidden" name="database" value="">
+ <input type="hidden" name="viewLegend" value="ON">
+ <input type="hidden" name="fromDataEditingPage" value="1">
+ <input type="hidden" name="trait_type" value="ProbeSet">
+ <input type="hidden" name="valsHidden" value="OFF">
+ <input type="hidden" name="fullname" value="HC_M2_0606_P::1441186_at">
<input type="hidden" name="RISet" value="BXD">
<div>
@@ -91,7 +114,7 @@
<td valign="top" width="10"></td>
- <td valign="top"><span class="fs13">Mouse, BXD</span></td>
+ <td valign="top"><span class="fs13">{{ thisTrait.species.capitalize() }}, {{fd.RISet}}</span></td>
</tr>
<tr>
@@ -113,9 +136,15 @@
<td valign="top" width="10"></td>
- <td valign="top"><span class="fs13"><span style="background:#dddddd;padding:2"><a href=
- "http://www.ncbi.nlm.nih.gov/entrez/query.fcgi?db=gene&amp;cmd=Retrieve&amp;dopt=Graphics&amp;list_uids=20689" target="_blank" class=
- "fs14 fwn" title="Info from NCBI Entrez Gene">Gene</a></span>&nbsp;&nbsp;<span style="background:#dddddd;padding:2"><a href=
+ <td valign="top">
+ <span class="fs13">
+ <span style="background:#dddddd;padding:2">
+ <a href="http://www.ncbi.nlm.nih.gov/entrez/query.fcgi?db=gene&amp;cmd=Retrieve&amp;dopt=Graphics&amp;list_uids=20689" target="_blank" class=
+ "fs14 fwn" title="Info from NCBI Entrez Gene">
+ Gene
+ </a>
+ </span>
+ &nbsp;&nbsp;<span style="background:#dddddd;padding:2"><a href=
"http://www.ncbi.nlm.nih.gov/UniGene/clust.cgi?ORG=Mm&amp;CID=215917" target="_blank" class="fs14 fwn" title=
"UniGene ID">UniGene</a></span>&nbsp;&nbsp;<span style="background:#dddddd;padding:2"><a href=
"http://www.ncbi.nlm.nih.gov/entrez/query.fcgi?db=Nucleotide&amp;cmd=search&amp;doptcmdl=DocSum&amp;term=BM119035" target="_blank" class=