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 -%>
    
361-380 / 500 Alle rijen tonen
7ut veniamMolestiae qui qui quo occaecati.No10 May 12:37Edit
312repellendus perferendis vitaePariatur officia maxime libero ut vel dolor delectus.No17 May 12:37Edit
262eosQuia ea eos qui omnis odio et.No22 Apr 12:37Edit
131iure autem ametOmnis tenetur dolores commodi consequatur nobis.No05 May 12:37Edit
142maxime accusamus consecteturSunt deleniti ex porro vel quod.No31 May 12:37Edit
274eos sint ametVitae nihil et quos aliquam possimus porro qui.No19 Jun 12:37Edit
302eligendi velVel iste ea at sapiente eligendi inventore laudantium quas.No24 Mar 12:37Edit
239nesciuntHarum quo vel maiores praesentium non sit sapiente fugiat.No30 May 12:37Edit
208officiaTemporibus nulla vero voluptatum repudiandae.No17 Apr 12:37Edit
347sint aut velDeleniti et aut laboriosam praesentium.No04 May 12:37Edit
115sit et estUllam dolorum dolorem placeat doloribus aut ea consequatur.No16 Mar 12:37Edit
10rerum occaecatiCum aperiam voluptas aut.No22 May 12:37Edit
188aliquid adipisciEaque maxime mollitia in vel.No21 May 12:37Edit
400et voluptatibusQui aliquam et quia.No23 Apr 12:37Edit
43impedit atque minimaAperiam expedita autem porro enim veniam.Yes03 Jun 12:37Edit
135dignissimos idId iure vero quas nobis et quibusdam.No11 Apr 12:37Edit
191quis aut architectoNatus molestiae inventore voluptatem.No30 Apr 12:37Edit
458quisUt corrupti consequatur iste.No03 May 12:37Edit
202beataeVel cupiditate quis autem.No08 May 12:37Edit
158aut voluptatibus autLaudantium quae beatae et architecto voluptatem libero et.No12 Apr 12:37Edit

Fork me on GitHub