Example: Tablesort

Same name in other branches
  1. 7.x-1.x tablesort_example/tablesort_example.module \tablesort_example
  2. 4.0.x modules/tablesort_example/tablesort_example.module \tablesort_example

Example of a sortable table display. Three columns are sortable (Numbers, Letters and Mixture) We are using TableSort Extender extend('Drupal\Core\Database\Query\TableSortExtender')

Parent topics

File

modules/tablesort_example/tablesort_example.module, line 8

Functions

Title Sort descending File name Summary
tablesort_example_install modules/tablesort_example/tablesort_example.install Implements hook_install().
tablesort_example_schema modules/tablesort_example/tablesort_example.install Implements hook_schema().
tablesort_example_uninstall modules/tablesort_example/tablesort_example.install Implements hook_uninstall().

Classes

Title Sort descending File name Summary
TableSortExampleTest modules/tablesort_example/tests/src/Functional/TableSortExampleTest.php Verify the tablesort functionality.
ThemingExampleTest modules/theming_example/tests/src/Functional/ThemingExampleTest.php Verify the tablesort functionality.