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 -%>
    
221-240 / 500 show all
221sequiQuo nobis aut ut dolor perferendis odit.No17 Apr 12:37Edit
222voluptasAnimi odio ad et nisi quod perferendis natus possimus.No04 Jun 12:37Edit
223laboriosam aut etEt possimus dicta hic sunt et itaque facilis.No11 Apr 12:37Edit
224quia illum natusIpsam alias necessitatibus quaerat.No19 Mar 12:37Edit
225beatae porroAut mollitia et ut.No22 Apr 12:37Edit
226ex aperiamSed iusto quisquam nostrum.No08 May 12:37Edit
227et voluptatibusEt corporis voluptas quam harum praesentium.No09 Jun 12:37Edit
228reprehenderitDeleniti non necessitatibus voluptas.No19 Apr 12:37Edit
229omnis commodiArchitecto qui voluptatum vel et.No08 Apr 12:37Edit
230aliquid rerum modiFugit hic blanditiis esse alias.Yes23 Apr 12:37Edit
231quia quisCupiditate error facilis qui nobis modi hic.Yes21 Mar 12:37Edit
232eos quam doloremEt aspernatur voluptatem qui commodi esse.No18 Jun 12:37Edit
233nesciunt suscipit quisDicta vel atque occaecati quisquam qui est tempora.Yes14 Mar 12:37Edit
234quidem corporisAut velit earum velit assumenda.No09 Jun 12:37Edit
235sunt ametHic similique sit cupiditate.No20 May 12:37Edit
236consequatur quisquamMinus mollitia ab quia soluta provident aut tempora aut.No05 Jun 12:37Edit
237vel esseDistinctio accusamus et dolores aliquam repudiandae omnis.No04 Jun 12:37Edit
238namDolor culpa laboriosam enim omnis ipsa.No10 Jun 12:37Edit
239nesciuntHarum quo vel maiores praesentium non sit sapiente fugiat.No30 May 12:37Edit
240illoMolestias nostrum quis itaque sed.No24 May 12:37Edit

Fork me on GitHub