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 -%>
    
441-460 / 500 show all
441in autRatione quam eveniet corporis.No23 May 12:37Edit
442ut voluptatemQuibusdam et veniam ut.No10 Jun 12:37Edit
443ullam laudantium commodiEaque tempora non quia sit quia perspiciatis mollitia.No18 May 12:37Edit
444asperiores quisIure est soluta deserunt sunt.Yes09 Apr 12:37Edit
445delectusOptio aut tempora mollitia corporis dicta temporibus eum vitae.No13 May 12:37Edit
446ut et sitUt voluptatem est facere quasi.No04 Apr 12:37Edit
447animi accusantium utSequi dolorem distinctio sit doloremque et corporis voluptatem alias.No06 Apr 12:37Edit
448tempore aliquam rationeQuam rerum tenetur aliquid.No23 Mar 12:37Edit
449dolores sedVoluptatibus et excepturi molestiae.No05 Jun 12:37Edit
450distinctio aspernaturVel perspiciatis exercitationem dolorem ducimus.No18 Apr 12:37Edit
451expedita nihilVoluptate maiores et sapiente.No04 Apr 12:37Edit
452illum et voluptatemAccusamus quis quis sapiente distinctio aut et quaerat asperiores.Yes13 May 12:37Edit
453omnisBlanditiis optio in inventore qui consequatur et.No19 Mar 12:37Edit
454similique enim odioEa cupiditate sit ex aut laudantium voluptatem.No14 Mar 12:37Edit
455etRerum unde adipisci praesentium ut dolore ea quia debitis.No14 Apr 12:37Edit
456inventore voluptasQuis molestiae ipsa omnis blanditiis ut dolores.No31 May 12:37Edit
457asperiores qui nonIllum consequatur laboriosam iusto praesentium sed dolore.No15 May 12:37Edit
458quisUt corrupti consequatur iste.No03 May 12:37Edit
459et rerumExplicabo totam asperiores cupiditate ea dolore ipsam.No19 Jun 12:37Edit
460consequatur nemoVel minus voluptatem facere voluptatem sit.No10 Apr 12:37Edit

Fork me on GitHub