$ diffstat user.patch
database/database.mysql | 4
database/database.pgsql | 2
database/updates.inc | 10 -
modules/block.module | 20 +-
modules/locale.module | 9
modules/profile.module | 108 +++++++----
modules/system.module | 8
modules/user.module | 456 +++++++++++++++++++-----------------------------
8 files changed, 289 insertions(+), 328 deletions(-)
More functionality, less code. Here is a list of the changes:
- Some user API changes:
+ When $type is 'form', you have to return an associative array of groups. In turn, each group is an array with a 'title', 'data' and 'weight'.
+ A new $type has been added, namely 'categories'. User settings can be organized in categories. Categories can be sorted, as can the groups within a category. (Ordering 'categories' is somewhat broken due to a bug in the menu system.)
- The 'my account > edit' page will use subtabs for each 'category'. Read: you can break down the account settings into multiple subpages.
- Profile module improvements:
+ Added support for private fields to the profile module!
+ Improved workflow of profile administration pages.
+ Improved the form descriptions.
- Code improvements:
+ Unified user_edit() and user_admin_edit().
+ Unified and cleaned up the validation code. Fixed some validation glitches too.
CHANGES
-------
+ Introduced tabs. First, we extended the menu system to support tabs. Next, a tab was added for every link that was (1) an administrative action other than the implicit 'view' (2) relevant to that particular page only. This is illustrated by the fact that all tabs are verbs and that clicking a page's tab leads you to a subpage of that page.
+ Flattened the administration menu. The tabs helped simplify the navigation menu as I could separate 'actions' from 'navigation'. In addition, I removed the 'administer > configuration'-menu, renamed 'blocks' to 'sidebars' which I hope is a bit more descriptive, and made a couple more changes. Earlier, we already renamed 'taxonomy' to 'categorization' and we move 'statistics' under 'logs'.
+ Grouped settings. All settings have been grouped under 'administer > settings'.
TODO
----
+ Update core themes: only Xtemplate default supports tabs and even those look ugly. Need help.
+ Update contributed modules. The menu() hook changed drastically. Updating your code adhere the new menu() function should be 90% of the work. Moreover, ensure that your modue's admin links are still valid and that URLs to node get updated to the new scheme ('node/view/x' -> 'node/x').
administrators will be able to define a custom 403 page, just as they
can define 404 pages now.
This needs to be documented in the "Changes since / migrating to ..."
pages.
- Strips the leading / from URLs to match with block paths. The reason is that everywhere else in Drupal, we use URLs without leading slash (e.g. URL aliasing). For consistency we should keep this behaviour everywhere. The replacement uses ereg_replace instead of str_replace, but the expression now only match the beginning of the URI so in fact it's faster, esp. for longer URIs.
- Updates the block docs about path matching: gets rid of leading slash, adds initial matching operator '^' and emphasises the slash behaviour (which was not mentioned anywhere before)
- Replaces the example expression for a negative match. It was horribly broken and odd, the replacement in this patch is correct and simpler.
+ Tidied up the profile configuration page: grouped form elements.
+ Tidied up the block configuration settings: removed hard-coded
table.
+ Changed the profile API to return the preferred group name, and
changed the user module to group settings. Modules implementing
the _user hook will need to be udpated.
+ Removed register_form and register_validate for now.
- puts the long multiline help text into one string
- fixes the ambiquity of calling two things on the same name: "custom block"
now the user customizeable blocks are called custom blocks, and the admin
defined blocks are called Administator Defined Blocks
- added info on throttle to the explanation on when a block is displyed
- also fixing some small typos
Contributed themes and modules need to be updated:
- modules: status() is no more; use drupal_set_message() instead.
- themes: use drupal_get_message() to check for status messages and
visualize them.
* fixes all doxygen warnings [#]_ in the current code base
+ changes @param style from phpDocumentor (@param type $var desc) to doxygen (@param $var desc)
+ documents all undocumented parameters
+ escapes / fixes html warnings
+ fixes @defgroup in theme.inc
* adds more groupings [#]_
+ drupal_{set|get}_title, drupal_{set|get}_breadcrumb
+ pager.inc: pager_api (pager_query(), pager_display()), pager pieces
* adds a new group "themeable" which contains all themeable functions.
Phase 2 of the menu system integration project. This unifies the interface
used by admin and non-admin pages, and deprecates the _page hook in favor of
explicit callbacks from menu(). Breadcrumbs, titles, and help text go away
as a result of this patch; they will return in the phase 3 patch, printed
by the theme.
+ block_list() (in block.module): returns an array of block objects for
$region.
+ theme_blocks() (in theme.inc): uses block_list() and theme("block") to
actually render them.
Advantages:
+ Decouples blocks content and layout, allows block_list() to be used
for non-output purposes (think "pull").
+ Unifies naming in theme.inc: render_blocks()) didn't really fit there.
+ Puts block_list() in blocks.module where it logically belongs.
- Removed some cruft from the Xtemplate theme. Patch by Ax.