Skip to end of metadata
Go to start of metadata
You are viewing an old version of this page. View the current version. Compare with Current  |   View Page History

<ac:macro ac:name="unmigrated-inline-wiki-markup"><ac:plain-text-body><![CDATA[

Zend Framework: Zend_Grid Component Proposal

Proposed Component Name Zend_Grid
Developer Notes
Proposers Bento Vilas Boas
Zend Liaison TBD
Revision 1.0 - 26 June 2010: Initial Draft. (wiki revision: 2)

Table of Contents

1. Overview

Zend_Grid is a component for display/manage data with source abstraction.

2. References

  • Community

3. Component Requirements, Constraints, and Acceptance Criteria

Must Support:

  • Multiples sources
  • CRUD operations with bulk add/edit/remove options and auto-validation from tables definition
  • PRG Form Processing
  • Templates
  • Multiples renders (Table, PDF, Print, Xml, Excel, etc, etc)
  • Extra columns
  • Extra rows
  • Aggregate Expressions
  • Horizontal splitting of records
  • Multiple instances per page
  • Custom Filters
  • Auto-filters based on field definition (enum, set, etc, etc)
  • Mass actions
  • Cache
  • Content format plugins
  • Ajax
  • Conditional Field Rendering
  • Render specific parts of grid
  • Sorting results
  • Auto-paging. Change number of results per page
  • Save params in session (Filters, Order, Page, Records per page)
  • Detailed view of records
  • Internationalization
  • Decorators
  • Callbacks
  • Routing

4. Dependencies on Other Framework Components

  • Zend_View
  • Zend_Config
  • Zend_Form
  • Zend_Session
  • Zend_Controller
  • Zend_Registry
  • Zend_Cache
  • Zend_Exception

5. Theory of Operation

The component is instantiated with a mind-link that ...

6. Milestones / Tasks

Milestone 1: [DONE] Working prototype written and tested.
Milestone 2: Unit testing converted to PHPUnit.
Milestone 3: [DONE] Create initial documentation.
Milestone 4: Working code and tests checked into SVN.
Milestone 5: Submitted to Ready for Review.

7. Class Index

  • Zend_Magic_Exception
  • Zend_Magic (factory class)
  • Zend_Magic_MindProbe
  • Zend_Magic_MindProbe_Intent
  • Zend_Magic_Action
  • Zend_Magic_CodeGen

8. Use Cases

UC-01 UC-02
$select = $db->select()->from('Users');
$grid = new * Zend_Grid::factory('Table',* Zend_Config $config, $gridId);
$grid->setSource(new * Zend_Grid_Source_* Zend_Select($select));
$select = $db->select()->from('Users',array('id','username','email','firstname','lastname','access'));
$grid = new * Zend_Grid::factory('Table',* Zend_Config $config, $gridId);
$grid->setSource(new * Zend_Grid_Source_* Zend_Select($select));

//Change title display for email column
$grid->updateColumn('email',array('title'=>"User's Email"));

//Id id column

//Apply different css classes based on field value
$grid->setClassCellCondition('access', "'access' > 'admin'", "red", 'green');


... (see good use cases book)

9. Class Skeletons

zone: Missing {zone-data:skeletons}

Enter labels to add to this page:
Please wait 
Looking for a label? Just start typing.