Sha256: d50e0bd84f9cd7d4b020b7f5bb9f8b6815c3692a3df7679052d0ce08e311fdc3
Contents?: true
Size: 1.3 KB
Versions: 5
Compression:
Stored size: 1.3 KB
Contents
:css table.my-grid { border: 1px solid red; } table.my-grid tr.my-header { background-color: #ebebeb; } .card.bg-light .card-body %h2= current_page_title %ul %li %code :html in the %code grid helper defines html arguments for the %code table tag. %li %code :header_tr_html in the %code grid helper defines html attributes for the header rows with column names and filters. %li %code :html in the %code column helper defines html attributes for the %code td tag. %li %code g.row_attributes do |record| ... end is similar to a %code column definition, but returns a hash of html attributes to be added to each %code tr. Because the block is evaluated for each record, just like %column , the returned value can be calculated dynamically depending on the record. %li Each %code column block can return a 2-value array, the first value of which is the content of the cell, and the second is a hash of html attributes for the %code td tag. = show_code .row .col-md-12 = render 'grid1' .row .col-md-12 = render 'grid2'
Version data entries
5 entries across 5 versions & 1 rubygems