<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array"/>
  <modified type="array">
    <modified>
      <diff>@@ -10,15 +10,20 @@
 
 All of the [standard ajax attributes](/api_taglibs/rapid_forms) are also supported. 
   --&gt;
-&lt;def tag=&quot;transition-button&quot; attrs=&quot;transition, update, label&quot;&gt;&lt;%= 
-    transition = transition.name unless transition.is_a?(String)
+&lt;def tag=&quot;transition-button&quot; attrs=&quot;transition, update, label&quot;&gt;&lt;%=
+    if transition.is_a?(String)
+      transition = this.lifecycle.find_transition(transition, current_user)
+    end
+    transition_name = transition.name
+    has_params = !transition.options[:params].blank?
     ajax_attributes, html_attributes = attributes.partition_hash(Hobo::RapidHelper::AJAX_ATTRS)
 
-    html_attributes[:method] = :put
-    url = object_url(this, transition, :method =&gt; :put)
-    add_classes!(html_attributes, &quot;transition-button #{transition}-button&quot;)
-    label ||= transition.to_s.titleize
-    if update || !ajax_attributes.empty?
+    html_attributes[:method] ||= has_params ? :get : :put
+    add_classes!(html_attributes, &quot;transition-button #{transition_name}-button&quot;)
+    label ||= transition_name.to_s.titleize
+    url = object_url(this, transition_name, :method =&gt; html_attributes[:method])
+
+    if (update || !ajax_attributes.empty?) &amp;&amp; !has_params
       ajax_attributes[:message] ||= label
       func = ajax_updater(url, update, ajax_attributes)
       html_attributes.update(:onclick =&gt; &quot;var e = this; &quot; + func, :type =&gt;'button', :value =&gt; label)
@@ -28,10 +33,10 @@ All of the [standard ajax attributes](/api_taglibs/rapid_forms) are also support
     end
   %&gt;
 &lt;/def&gt;
-  
+
 
 &lt;!-- Renders a div containing transition buttons for every transition available to the current user.
-  
+
 For example, you could use this on a `Friendship` card: the person invited to have friendship would automatically see 'Accept' and 'Decline' buttons, while the person initiating the invite would see 'Retract'.
   --&gt;  
 &lt;def tag=&quot;transition-buttons&quot;&gt;</diff>
      <filename>hobo/taglibs/rapid_lifecycles.dryml</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>827c1f97f1152ff6c92d0277d2fb6ff87d45b3a8</id>
    </parent>
  </parents>
  <author>
    <name>Matt Jones</name>
    <email>al2o3cr@gmail.com</email>
  </author>
  <url>http://github.com/tablatom/hobo/commit/2a349a4403d57c6122e26221d9e18d353ee13652</url>
  <id>2a349a4403d57c6122e26221d9e18d353ee13652</id>
  <committed-date>2009-11-08T12:20:31-08:00</committed-date>
  <authored-date>2009-11-08T12:20:31-08:00</authored-date>
  <message>Bug 464: transition-button for a transition that requires params now links to the form</message>
  <tree>307ba44f199f083b38c1e79cebc39d5dfa729982</tree>
  <committer>
    <name>Matt Jones</name>
    <email>al2o3cr@gmail.com</email>
  </committer>
</commit>
