From 606cc89926b8e12c2007af1f4a1cbdefc9b9d3bd Mon Sep 17 00:00:00 2001 From: gebele Date: Mon, 29 Aug 2011 13:08:34 +0200 Subject: show only users models --- views/predict.haml | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/views/predict.haml b/views/predict.haml index ec667e6..65e4113 100644 --- a/views/predict.haml +++ b/views/predict.haml @@ -31,11 +31,12 @@ Choose one or more prediction models %br - @models.each do |model| - %input{:type => 'checkbox', :name => "selection[#{model.id}]", :value => true, :id => "model#{model.id}", :disabled => false} - %label{:for => "model#{model.id}"} - = model.name - -#%input{:type => 'checkbox', :name => "selection[#{model.id}]", :value => true, :id => model.id, :disabled => !is_authorized(model.uri, "GET")} - %br + - if is_authorized(model.web_uri, "DELETE") + %input{:type => 'checkbox', :name => "selection[#{model.id}]", :value => true, :id => "model#{model.id}", :disabled => false} + %label{:for => "model#{model.id}"} + = model.name + -#%input{:type => 'checkbox', :name => "selection[#{model.id}]", :value => true, :id => model.id, :disabled => !is_authorized(model.uri, "GET")} + %br %br %input{:type => 'hidden', :name => 'subjectid', :id => 'subjectid', :value => session[:subjectid]} %input{ :type => "submit", :value => "Predict", :onclick => "getsmiles();"} -- cgit v1.2.3