Sha256: 7bca6b2b3ff0269c8158fccf50230a3e1efa7a984edd32e052ae5603fdc5e93c

Contents?: true

Size: 989 Bytes

Versions: 15

Compression:

Stored size: 989 Bytes

Contents

- rtc_controller_name ||= controller_name
- rtc_partial = rtc_controller_name.singularize if rtc_partial.nil?
- rtc_empty_data_message = sanitize "Data #{t(rtc_controller_name)} kosong" if rtc_empty_data_message.nil?

- @controller_names = instance_variable_get("@#{rtc_controller_name}")

%form#filter_form
  - params.select{|key, val| key != "action" && key != "controller" && key.to_s != "q"}.each_pair do |key, val|
    = hidden_field_tag key.to_s, val.to_s
  

%table
  - if @controller_names.present?
    - offset = (params[:page].to_i - 1) * params[:per_page].to_i
    - unless params[:list_view].eql? 'th'
      = render partial: rtc_partial, collection: @controller_names, locals: {offset: offset, rtc_partial: rtc_partial}
    - else
      %ul
        = render partial: rtc_partial, collection: @controller_names, locals: {offset: offset, rtc_partial: rtc_partial}
  - else
    .rtc_empty_message
      %br
      %center
        %span.rtc_data_empty_text= rtc_empty_data_message

Version data entries

15 entries across 15 versions & 1 rubygems

Version Path
rich_table_component-0.0.30 app/views/rich_table_component/rtc/_table.html.haml
rich_table_component-0.0.29 app/views/rich_table_component/rtc/_table.html.haml
rich_table_component-0.0.28 app/views/rich_table_component/rtc/_table.html.haml
rich_table_component-0.0.27 app/views/rich_table_component/rtc/_table.html.haml
rich_table_component-0.0.26 app/views/rich_table_component/rtc/_table.html.haml
rich_table_component-0.0.24 app/views/rich_table_component/rtc/_table.html.haml
rich_table_component-0.0.22 app/views/rich_table_component/rtc/_table.html.haml
rich_table_component-0.0.21 app/views/rich_table_component/rtc/_table.html.haml
rich_table_component-0.0.18 app/views/rich_table_component/rtc/_table.html.haml
rich_table_component-0.0.17 app/views/rich_table_component/rtc/_table.html.haml
rich_table_component-0.0.16 app/views/rich_table_component/rtc/_table.html.haml
rich_table_component-0.0.15 app/views/rich_table_component/rtc/_table.html.haml
rich_table_component-0.0.14 app/views/rich_table_component/rtc/_table.html.haml
rich_table_component-0.0.13 app/views/rich_table_component/rtc/_table.html.haml
rich_table_component-0.0.10 app/views/rich_table_component/rtc/_table.html.haml