diff options
author | shingo-nakanishi <shingo7ka24@gmail.com> | 2016-09-01 17:31:07 +0900 |
---|---|---|
committer | GitHub <noreply@github.com> | 2016-09-01 17:31:07 +0900 |
commit | d089fe2810216fb85cd52a2b89a861c07dc5bbb9 (patch) | |
tree | 5d9204d6bfa6617dff74c69708960b6cf521376a | |
parent | dd65843a0a78268935a5d49cf0a1d459c253e29d (diff) | |
download | rails-d089fe2810216fb85cd52a2b89a861c07dc5bbb9.tar.gz rails-d089fe2810216fb85cd52a2b89a861c07dc5bbb9.tar.bz2 rails-d089fe2810216fb85cd52a2b89a861c07dc5bbb9.zip |
fix document for radio_button
add `# Let's say that @user.receive_newsletter returns "no":` for `def radio_button(object_name, method, tag_value, options = {})`.
fix `# Let's say that @user.category returns "no":` to `# Let's say that @user.receive_newsletter returns "no":`
-rw-r--r-- | actionview/lib/action_view/helpers/form_helper.rb | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/actionview/lib/action_view/helpers/form_helper.rb b/actionview/lib/action_view/helpers/form_helper.rb index 7d574f0a14..b82dff1c17 100644 --- a/actionview/lib/action_view/helpers/form_helper.rb +++ b/actionview/lib/action_view/helpers/form_helper.rb @@ -965,6 +965,7 @@ module ActionView # # => <input type="radio" id="post_category_rails" name="post[category]" value="rails" checked="checked" /> # # <input type="radio" id="post_category_java" name="post[category]" value="java" /> # + # # Let's say that @user.receive_newsletter returns "no": # radio_button("user", "receive_newsletter", "yes") # radio_button("user", "receive_newsletter", "no") # # => <input type="radio" id="user_receive_newsletter_yes" name="user[receive_newsletter]" value="yes" /> @@ -1711,7 +1712,7 @@ module ActionView # # => <input type="radio" id="post_category_rails" name="post[category]" value="rails" checked="checked" /> # # <input type="radio" id="post_category_java" name="post[category]" value="java" /> # - # # Let's say that @user.category returns "no": + # # Let's say that @user.receive_newsletter returns "no": # radio_button("receive_newsletter", "yes") # radio_button("receive_newsletter", "no") # # => <input type="radio" id="user_receive_newsletter_yes" name="user[receive_newsletter]" value="yes" /> |