content_tag メソッドを使用して、Ruby on Rails でテーブルを構築しようとしています。
これを実行すると:
def itemSemanticDifferential(method, options = {})
if options[:surveyQuestion].any? then
@template.content_tag(:tr) do
@template.content_tag(:td, options[:surveyQuestion], :colspan => 3)
end
end
@template.content_tag(:tr) do
@template.content_tag(:th, options[:argument0])
end
end
2 番目の部分のみがレンダリングされます。
@template.content_tag(:tr) do
@template.content_tag(:th, options[:argument0])
end
これがなぜなのか誰か教えてもらえますか?