0

我在使用简单形式 gem 的 rails 视图中有这段代码:

<%= simple_form_for :beta_signup, :url => url_for(:action => 'update', :controller => 'survey'), :html => { :id => 'info-form' } do |beta_signup| %>
<%=   beta_signup.collection_radio_buttons :this_excited, [[0,'Not really excited at all'], [1,''], [2, ''], [3, ''], [4, 'Super Excited!!']], :first, :last, :checked => 2, required: false %>
<% end %>

而不是为中间单选按钮显示空白,而是显示“这个兴奋 1”、“这个兴奋 2”、“这个兴奋 3”。有没有办法让中间的 3 个单选按钮不显示标签?

输入 " " 不起作用(显示“这个兴奋的 1”),并且 " " 和 "\t" 不起作用(分别显示 " " 和 "\t")。

4

0 回答 0