myexperiment-hackers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[myexperiment-hackers] [2247] trunk/app/views: Fixed bug in blobs and wo


From: noreply
Subject: [myexperiment-hackers] [2247] trunk/app/views: Fixed bug in blobs and workflows licenses select box.
Date: Wed, 15 Jul 2009 10:58:46 -0400 (EDT)

Revision
2247
Author
drn05r
Date
2009-07-15 10:58:46 -0400 (Wed, 15 Jul 2009)

Log Message

Fixed bug in blobs and workflows licenses select box.  collection_select macro does not support :selected chnage to select macro which does

Modified Paths

Diff

Modified: trunk/app/views/blobs/_license_form.rhtml (2246 => 2247)


--- trunk/app/views/blobs/_license_form.rhtml	2009-07-15 10:15:21 UTC (rev 2246)
+++ trunk/app/views/blobs/_license_form.rhtml	2009-07-15 14:58:46 UTC (rev 2247)
@@ -27,12 +27,12 @@
             <strong>What license do you want people to adhere to if they download and use this File?</strong>
         </p>
         <div style="padding-left: 1em;">
-        
-        <%= collection_select(:blob, :license_id, License.find(:all), :id, :title, {}, 
-              {: remote_function(:update => 'license_info',
-	       :selected => @license.id,
-               :url ="" {:controller => 'licenses', :action="" 'update_license_info' },
-               :with => "'license_id=' + escape(value)")}) %>
+          <%= select(:blob, :license_id, License.find(:all).collect {|l| [l.title, l.id] }, 
+	    { :selected => @license.id },
+	    {  : remote_function(:update => 'license_info',
+	         :url ="" {:controller => 'licenses', :action="" 'update_license_info' },
+	         :with => "'license_id=' + escape(value)")}) %>
+
         </div>
         <hr/>
         <div id="license_info" style="padding: 0 20px;">

Modified: trunk/app/views/workflows/_license_form.rhtml (2246 => 2247)


--- trunk/app/views/workflows/_license_form.rhtml	2009-07-15 10:15:21 UTC (rev 2246)
+++ trunk/app/views/workflows/_license_form.rhtml	2009-07-15 14:58:46 UTC (rev 2247)
@@ -27,12 +27,12 @@
             <strong>What license do you want people to adhere to if they download and use this File?</strong>
         </p>
         <div style="padding-left: 1em;">
-        
-        <%= collection_select(:workflow, :license_id, License.find(:all), :id, :title, {}, 
-              {: remote_function(:update => 'license_info',
-	       :selected => @license.id,
-               :url ="" {:controller => 'licenses', :action="" 'update_license_info' },
-               :with => "'license_id=' + escape(value)")}) %>
+          <%= select(:workflow, :license_id, License.find(:all).collect {|l| [l.title, l.id] },
+            { :selected => @license.id },
+            {  : remote_function(:update => 'license_info',
+                 :url ="" {:controller => 'licenses', :action="" 'update_license_info' },
+                 :with => "'license_id=' + escape(value)")}) %>
+
         </div>
         <hr/>
         <div id="license_info" style="padding: 0 20px;">

reply via email to

[Prev in Thread] Current Thread [Next in Thread]