summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoropentox <opentox@ot-dev.in-silico.ch>2011-06-15 18:50:47 +0200
committeropentox <opentox@ot-dev.in-silico.ch>2011-06-15 18:50:47 +0200
commit13313d9fa8f5e4b29bbbc0ddeb0e455765b0774d (patch)
treedd163b819933c2e516e6f6ac841b1981931c957d
parent48c30444036f5f761a13fdd56036790dc7d61a3f (diff)
cactvs name lookup disabled
-rw-r--r--application.rb2
-rw-r--r--views/predict.haml3
2 files changed, 3 insertions, 2 deletions
diff --git a/application.rb b/application.rb
index 60d50cd..8d96dbe 100644
--- a/application.rb
+++ b/application.rb
@@ -338,7 +338,7 @@ post '/predict/?' do # post chemical name to model
redirect url_for('/predict')
end
begin
- @compound = OpenTox::Compound.from_name(params[:identifier])
+ @compound = OpenTox::Compound.from_smiles(params[:identifier])
rescue
flash[:notice] = "Could not find a structure for '#{@identifier}'. Please try again."
redirect url_for('/predict')
diff --git a/views/predict.haml b/views/predict.haml
index ec667e6..7d5e30a 100644
--- a/views/predict.haml
+++ b/views/predict.haml
@@ -23,7 +23,8 @@
%a{:href => 'http://www.molinspiration.com/jme/index.html', :rel => "external"} JME Editor
courtesy of Peter Ertl, Novartis</span>
%br
- %label{:for => 'identifier'} or enter a Name, InChI, Smiles, CAS, ...
+ -# %label{:for => 'identifier'} or enter a Name, InChI, Smiles, CAS, ...
+ %label{:for => 'identifier'} or enter a Smiles string
%input{:type => 'text', :name => 'identifier', :id => 'identifier', :size => '60'}
%br
%fieldset