There are way too many theme functions / template files in core. Some are similar (if not identical) and should be consolidated.

Proposed resolution

We have two options:

  1. Remove theme_book_admin_table and call theme('table') instead.
  2. If we really do need a separate preprocess function for the admin tables in book module, then call theme('table__book_admin') instead of theme('table') and add all our preprocess magic into template_preprocess_table__book_admin()

Remaining tasks

Decide which of the 2 options above to pursue, and do it.

User interface changes


API changes

Removal of theme_book_admin_table

#1812684: [meta] Consolidate all table templates and add theme_hook_suggestions
#1968982: Convert book theme tables to table #type

#1 2035905-remove-theme_book_admin_table-1.patch7.93 KBjoelpittet
FAILED: [[SimpleTest]]: [PHP 5.4 MySQL] 75,794 pass(es), 5 fail(s), and 0 exception(s). View
Members fund testing for the Drupal project. Drupal Association Learn more


joelpittet’s picture

Issue summary: View changes
Status: Active » Needs review
7.93 KB
FAILED: [[SimpleTest]]: [PHP 5.4 MySQL] 75,794 pass(es), 5 fail(s), and 0 exception(s). View

I thought I'd give this a stab to get it started and maybe someone can pick it up from here.

The values aren't showing but most everything else is rendering. May be due to something render element does...

Status: Needs review » Needs work

The last submitted patch, 1: 2035905-remove-theme_book_admin_table-1.patch, failed testing.

joelpittet’s picture

Status: Needs work » Closed (duplicate)

Woops, should have checked this is a dupe, will compare above with this #1968982: Convert book theme tables to table #type