ActionView::Helpers::FormOptionsHelper

対応表

<select> を作るヘルパーは、中で <option> だけを作るヘルパーを呼んで <option> を作り、それを <select> で包みます。<option> だけを作るヘルパーは、select_tag などに渡して使います。名前の付け方はそろっていないので、名前だけでは対応関係がわかりません。

<select> を作るヘルパー<option> だけを作るヘルパー(select_tag などに渡す)<option> だけを作るヘルパーが中で呼ぶもの
配列か Hash から作る
selectoptions_for_select−(自分で <option> を作る)
select(グループの形)grouped_options_for_selectoptions_for_select(グループごと)
オブジェクトの一覧から作る
collection_selectoptions_from_collection_for_selectoptions_for_select
grouped_collection_selectoption_groups_from_collection_for_selectoptions_from_collection_for_select(要素ごと)
そのほか
time_zone_selecttime_zone_options_for_selectoptions_for_select
weekday_selectweekday_options_for_selectoptions_for_select

ほとんどの <option> は、最後に options_for_select が作ります。include_blank や prompt で先頭に足す value が空の <option> は、<select> を作るヘルパーのほうで足します。grouped_options_for_select の prompt と、time_zone_options_for_select の区切り(-------------)の <option> は、そのヘルパーが自分で作ります。