Method: TableSettings::Button#css_class_type

Defined in:
lib/table_settings/table_button.rb

#css_class_type(type) ⇒ Object



149
150
151
152
153
154
155
156
157
158
159
160
# File 'lib/table_settings/table_button.rb', line 149

def css_class_type(type)
  css=case type
        when :show then "btn btn-success"
        when :edit then "btn btn-warning"
        when :delete then "btn btn-danger"
        when :destroy then "btn btn-danger"
        when :log then "btn btn-inverse"
        else "btn"
      end
  @hash[:class] = css
  self
end