WiceGrid 3.6.0.pre4 examples

Most simple grid

The simplest grid is defined by the grid helper with column blocks inside for each column. The value of each column block is the contents of a cell.

  • # encoding: utf-8
    class Basics1Controller < ApplicationController
      def index
        @tasks_grid = initialize_grid(Task)
      end
    end
    
  • .well
      %h2= current_page_title
      %p
        The simplest grid is defined by the
        %code grid
        helper with column blocks inside  for each column.
        The value of each column block is the contents of a cell.
    
    = show_code
    
    .row-fluid
      .col-md-12
        = render   'grid'
  • <%= grid(@tasks_grid) do |g|
    
      g.column do |task|
        task.id
      end
    
      g.column  do |task|
        task.title
      end
    
      g.column do |task|
        task.description
      end
    
      g.column do |task|
        task.archived? ? 'Yes' : 'No'
      end
    
      g.column do |task|
        task.created_at.to_s(:short)
      end
    
      g.column do |task|
        link_to('Edit', edit_task_path(task))
      end
    end -%>
    
21-40 / 500 Alle rijen tonen
201voluptasEt ut autem at ex voluptatibus assumenda.No16 Mar 12:37Edit
319et voluptatemDicta vel deleniti quasi enim laudantium repudiandae est sint.No16 Mar 12:37Edit
365eligendi delenitiNemo rerum aut non eos dolore in et ea.No16 Mar 12:37Edit
132quiaNemo nostrum perspiciatis in iste neque omnis est.No17 Mar 12:37Edit
412nonPerferendis consequatur error doloremque non voluptas sed aspernatur animi.No17 Mar 12:37Edit
4nisi quiQuas assumenda eos molestiae recusandae eveniet sit sint.No18 Mar 12:37Edit
148porro ducimus voluptatibusRerum sint et minima.No18 Mar 12:37Edit
177ex perferendis velitSed qui sunt ut quod ex.No18 Mar 12:37Edit
428commodi omnis temporeEsse sint deleniti a rerum est praesentium unde.No18 Mar 12:37Edit
463excepturiNobis doloribus eos aut voluptatem eaque.No18 Mar 12:37Edit
21et rerum laborumVelit consequatur quas sunt perspiciatis quae nihil.No19 Mar 12:37Edit
57nequeNisi mollitia ipsam autem est voluptas consequatur expedita.No19 Mar 12:37Edit
152nihilReiciendis explicabo sit porro veritatis illum nemo asperiores est.No19 Mar 12:37Edit
224quia illum natusIpsam alias necessitatibus quaerat.No19 Mar 12:37Edit
453omnisBlanditiis optio in inventore qui consequatur et.No19 Mar 12:37Edit
466autIllum corporis occaecati quia quo aut ratione voluptatem.No19 Mar 12:37Edit
160aut voluptatesEarum odio voluptatem nulla.No20 Mar 12:37Edit
281velitDolorum quaerat asperiores itaque quibusdam libero aspernatur sed eius.No20 Mar 12:37Edit
359placeat molestiae officiisReiciendis soluta quo voluptas quod.No20 Mar 12:37Edit
3aliquam repudiandaeConsequatur iste similique dolorum ducimus ut.No21 Mar 12:37Edit

Fork me on GitHub