Class: Kiss::Form::Section

Inherits:
Object show all
Defined in:
lib/kiss/form.rb

Instance Method Summary collapse

Constructor Details

#initialize(form = nil) ⇒ Section

Returns a new instance of Section.



107
108
109
110
# File 'lib/kiss/form.rb', line 107

def initialize(form = nil)
  @_form = form
  @_columns = [Column.new(form)]
end

Instance Method Details

#htmlObject



112
113
114
115
116
117
118
119
120
# File 'lib/kiss/form.rb', line 112

def html
  [
    '<tr><td>',
    '<table class="kiss_form_section"><tbody><tr>',
    columns.map {|column| column.html}.join,
    '</tr></tbody></table>',
    '</td></tr>',
  ].join
end