From 2a123f0ac94cad2771b19ca81b9637f83cb06869 Mon Sep 17 00:00:00 2001 From: Dries Buytaert Date: Fri, 21 Aug 2009 14:27:47 +0000 Subject: =?UTF-8?q?-=20Patch=20#549432=20by=20Bohjan,=20G=C3=A1bor=20Hojts?= =?UTF-8?q?y:=20create=20'people=20and=20permissions'=20section=20in=20'co?= =?UTF-8?q?nfiguration=20and=20modules'.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- modules/user/user.module | 55 ++++++++++++++++++++++++++++++------------------ 1 file changed, 34 insertions(+), 21 deletions(-) (limited to 'modules/user/user.module') diff --git a/modules/user/user.module b/modules/user/user.module index a7fb466c5..0f62c996b 100644 --- a/modules/user/user.module +++ b/modules/user/user.module @@ -97,7 +97,7 @@ function user_fieldable_info() { 'user' => array( 'label' => t('User'), 'admin' => array( - 'path' => 'admin/settings/user', + 'path' => 'admin/config/people/accounts', 'access arguments' => array('administer users'), ), ), @@ -813,7 +813,7 @@ function user_permission() { ), 'cancel account' => array( 'title' => t('Cancel account'), - 'description' => t('Remove or disable own user account and unpublish, anonymize, or remove own submissions depending on the configured user settings.', array('@user-settings-url' => url('admin/settings/user'))), + 'description' => t('Remove or disable own user account and unpublish, anonymize, or remove own submissions depending on the configured user settings.', array('@user-settings-url' => url('admin/config/people/accounts'))), ), 'select account cancellation method' => array( 'title' => t('Select method for cancelling own account'), @@ -1345,7 +1345,7 @@ function user_menu() { 'menu_name' => 'user-menu', ); - // User administration pages. + // User listing pages. $items['admin/people'] = array( 'title' => 'People', 'description' => 'Find and manage people interacting with your site.', @@ -1366,40 +1366,53 @@ function user_menu() { 'access arguments' => array('administer users'), 'type' => MENU_LOCAL_TASK, ); - $items['admin/settings/user'] = array( - 'title' => 'Users', + + // Administration pages. + $items['admin/config/people'] = array( + 'title' => 'People and permissions', + 'description' => 'Configure user accounts, roles and permissions.', + 'position' => 'right', + 'page callback' => 'system_admin_menu_block_page', + 'access callback' => 'system_admin_menu_block_access', + 'access arguments' => array('admin/config/people', 'access administration pages'), + ); + $items['admin/config/people/accounts'] = array( + 'title' => 'Account settings', 'description' => 'Configure default behavior of users, including registration requirements, e-mails, and user pictures.', 'page callback' => 'drupal_get_form', 'page arguments' => array('user_admin_settings'), 'access arguments' => array('administer users'), + 'weight' => -10, ); - $items['admin/settings/user/settings'] = array( + $items['admin/config/people/accounts/settings'] = array( 'title' => 'Settings', 'type' => MENU_DEFAULT_LOCAL_TASK, 'weight' => -10, ); // Permission administration pages. - $items['admin/settings/permissions'] = array( - 'title' => 'Permissions', - 'description' => 'Determine access to features by selecting permissions for roles.', - 'page callback' => 'drupal_get_form', - 'page arguments' => array('user_admin_permissions'), - 'access arguments' => array('administer permissions'), - ); - $items['admin/settings/roles'] = array( + $items['admin/config/people/roles'] = array( 'title' => 'Roles', 'description' => 'List, edit, or add user roles.', 'page callback' => 'drupal_get_form', 'page arguments' => array('user_admin_new_role'), 'access arguments' => array('administer permissions'), + 'weight' => -9, ); - $items['admin/settings/roles/edit'] = array( + $items['admin/config/people/roles/edit'] = array( 'title' => 'Edit role', 'page arguments' => array('user_admin_role'), 'access arguments' => array('administer permissions'), 'type' => MENU_CALLBACK, ); + $items['admin/config/people/permissions'] = array( + 'title' => 'Permissions', + 'description' => 'Determine access to features by selecting permissions for roles.', + 'page callback' => 'drupal_get_form', + 'page arguments' => array('user_admin_permissions'), + 'access arguments' => array('administer permissions'), + 'weight' => -8, + ); $items['user/%user_uid_optional'] = array( 'title' => 'My account', @@ -2456,17 +2469,17 @@ function user_help($path, $arg) { return $output; case 'admin/people/create': return '

' . t("This web page allows administrators to register new users. Users' e-mail addresses and usernames must be unique.") . '

'; - case 'admin/settings/permissions': - return '

' . t('Permissions let you control what users can do and see on your site. You can define a specific set of permissions for each role. (See the Roles page to create a role). Two important roles to consider are Authenticated Users and Administrators. Any permissions granted to the Authenticated Users role will be given to any user who can log into your site. You can make any role the Administrator role for the site, meaning this will be granted all new permissions automatically. You can do this on the User Settings page. You should be careful to ensure that only trusted users are given this access and level of control of your site.', array('@role' => url('admin/settings/roles'), '@settings' => url('admin/settings/user'))) . '

'; - case 'admin/settings/roles': + case 'admin/config/people/permissions': + return '

' . t('Permissions let you control what users can do and see on your site. You can define a specific set of permissions for each role. (See the Roles page to create a role). Two important roles to consider are Authenticated Users and Administrators. Any permissions granted to the Authenticated Users role will be given to any user who can log into your site. You can make any role the Administrator role for the site, meaning this will be granted all new permissions automatically. You can do this on the User Settings page. You should be careful to ensure that only trusted users are given this access and level of control of your site.', array('@role' => url('admin/config/people/roles'), '@settings' => url('admin/config/people/accounts'))) . '

'; + case 'admin/config/people/roles': return t('

Roles allow you to fine tune the security and administration of Drupal. A role defines a group of users that have certain privileges as defined in user permissions. Examples of roles include: anonymous user, authenticated user, moderator, administrator and so on. In this area you will define the role names of the various roles. To delete a role choose "edit".

By default, Drupal comes with two user roles:

', array('@permissions' => url('admin/settings/permissions'))); - case 'admin/settings/user/fields': + ', array('@permissions' => url('admin/config/people/permissions'))); + case 'admin/config/people/accounts/fields': return '

' . t('This form lets administrators add, edit, and arrange fields for storing user data.') . '

'; - case 'admin/settings/user/display': + case 'admin/config/people/accounts/display': return '

' . t('This form lets administrators configure how fields should be displayed when rendering a user profile page.') . '

'; case 'admin/people/search': return '

' . t('Enter a simple pattern ("*" may be used as a wildcard match) to search for a username or e-mail address. For example, one may search for "br" and Drupal might return "brian", "brad", and "brenda@example.com".') . '

'; -- cgit v1.2.3