Skip to content

Instantly share code, notes, and snippets.

@lantian
Created August 18, 2013 10:46
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save lantian/6261037 to your computer and use it in GitHub Desktop.
Save lantian/6261037 to your computer and use it in GitHub Desktop.
Grid example
<?php
interface GridInterface
{
/**
* Get grid items for current page.
*
* @return array
*/
public function getItems();
/**
* Define pager allowed
*
* @return bool
*/
public function pagerAllowed();
/**
* Define filter allowed.
*
* @return bool
*/
public function filterAllowed();
/**
* Get item partial path.
*
* @return string
*/
function getItemPartial();
/**
* Init filter form.
*
* @return FormInterface
*/
public function initForm();
/**
* Init table.
*
* @return TableInterface
*/
public function initTable();
/**
* Return fields configuration.
*
* @return array
*/
public function initFields();
/**
* Get the route name.
*
* @return string
*/
public function getRoute();
/**
* Get the route data.
*
* @return string
*/
public function getRouteData();
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment