From 12002a6390b10c3c12462936484ba967da2478e4 Mon Sep 17 00:00:00 2001 From: gebele Date: Tue, 10 Mar 2015 16:58:49 +0100 Subject: marked links >;resize body if large table;setup sdf --- views/predict.haml | 23 +++++++++++++---------- 1 file changed, 13 insertions(+), 10 deletions(-) (limited to 'views/predict.haml') diff --git a/views/predict.haml b/views/predict.haml index bed0837..b37d6ab 100644 --- a/views/predict.haml +++ b/views/predict.haml @@ -14,9 +14,9 @@ function checksmiles () { if (document.form.identifier.value == "") { alert("Please draw or insert a chemical structure."); - //$("img.circle").hide(); + $("img.circle").hide(); document.form.identifier.focus(); - $('#progressBar').hide(); + //$('#progressBar').hide(); return false; }; return true; @@ -30,8 +30,8 @@ }); if (checked == false){ alert("Please select an endpoint."); - //$("img.circle").hide(); - $('#progressBar').hide(); + $("img.circle").hide(); + //$('#progressBar').hide(); return false; }; return true; @@ -48,9 +48,9 @@ document.form.identifier.value = document.JME.smiles() ; }; }; - //function showcircle(){ - //$("img.circle").show(); - //}; + function showcircle(){ + $("img.circle").show(); + }; // whole site content needs to be in one form. Input and checkboxes are proofed by js functions. %form{:name => "form", :action => to('/predict'), :method => "post", :enctype => "multipart/form-data", :onsubmit => "return !!(checksmiles() & checkboxes())" } @@ -130,10 +130,12 @@ %br %p{:style=>"display:inline"}= "Feature Dataset: " %a{:href=>"#{to("/predict/#{CGI.escape(model[RDF::OT.featureDataset])}")}", :title=>"download"} rdf + -#%a{:href=>"#{to("/predict/#{CGI.escape(model[RDF::OT.featureDataset])}")}/sdf", :title=>"download"} sdf %br %br %p{:style=>"display:inline"}= "Training Dataset: " %a{:href=>"#{to("/predict/#{CGI.escape(model[RDF::OT.trainingDataset])}")}", :title=>"link opens in new window."} rdf + -#%a{:href=>"#{to("/predict/#{CGI.escape(model[RDF::OT.trainingDataset])}/sdf")}", :title=>"link opens in new window."} sdf %br - unless model.metadata[RDF::OT.crossValidation].nil? %h3 Validation: @@ -153,8 +155,9 @@ %h1 3. Predict %td{:style=>"width:10%;align:center;valign:middle;"} - %input{ :type => "submit", :id => "submit", :value=>">>", :onclick => "(progress(1,$('#progressBar')) & getsmiles() & checkboxes())", :style=>"cursor: pointer;display:inline;width:50px;height:50px;border-radius: 50%;color:#2b2b2b;text-align:center;text-decoration:none;background:#f76700;box-shadow: 0 0 5px white;font-weight:bold;"} + %input{ :type => "submit", :id => "submit", :value=>">>", :onclick => "(showcircle() & getsmiles() & checkboxes())", :style=>"cursor: pointer;display:inline;width:50px;height:50px;border-radius: 50%;color:#2b2b2b;text-align:center;text-decoration:none;background:#f76700;box-shadow: 0 0 5px white;font-weight:bold;"} %td{:style=>"align:center;valign:middle;"} - #progressBar{:style=>"width: 400px;height: 22px;border:1px solid #2b2b2b;background-color:gray;display:none;"} - #bar{:style =>"width:0;height: 100%;color: #fff;text-align: right;line-height: 22px;background-color: #0099ff;"} + %img{:src=>"/images/wait30trans.gif", :class=>"circle", :style=>"display:none;background-color:white;margin-left:10%;border:solid 1px;vertical-align:middle;"} + -##progressBar{:style=>"width: 400px;height: 22px;border:1px solid #2b2b2b;background-color:gray;display:none;"} + -##bar{:style =>"width:0;height: 100%;color: #fff;text-align: right;line-height: 22px;background-color: #0099ff;"} -- cgit v1.2.3