From 49e84a59439074fb7742b662db21e9638d41cfd0 Mon Sep 17 00:00:00 2001 From: "Stephen St. Martin" Date: Sat, 23 Jan 2010 12:48:11 -0500 Subject: fix failing tests from fork/merge --- actionpack/lib/action_view/helpers/ajax_helper.rb | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'actionpack/lib/action_view/helpers') diff --git a/actionpack/lib/action_view/helpers/ajax_helper.rb b/actionpack/lib/action_view/helpers/ajax_helper.rb index 7d97fb9698..f2ff424576 100644 --- a/actionpack/lib/action_view/helpers/ajax_helper.rb +++ b/actionpack/lib/action_view/helpers/ajax_helper.rb @@ -32,8 +32,9 @@ module ActionView end def button_to_remote(name, options = {}, html_options = {}) - attributes = html_options.merge!(:type => "button") + attributes = html_options.merge!(:type => "button", :value => name) attributes.merge!(extract_remote_attributes!(options)) + attributes.merge!(extract_request_attributes!(options)) tag(:input, attributes) end @@ -59,7 +60,7 @@ module ActionView def observe_field(name, options = {}) options[:observed] = name attributes = extract_observer_attributes!(options) - attributes["data-js-type"] = "field_observer" + attributes["data-observe"] = true script_decorator(attributes) end @@ -85,7 +86,7 @@ module ActionView attributes.merge!(extract_update_attributes!(options)) attributes.merge!(extract_request_attributes!(options)) - attributes["data-js-type"] = options.delete(:js_type) || "remote" + attributes["data-remote"] = true attributes end -- cgit v1.2.3