Commit ff813ab6 authored by webchick's avatar webchick

#564562 by Gábor Hojtsy, Bojhan, yoroy, and catch: Added 'System' configuration section.

parent 39d2e4af
......@@ -292,7 +292,7 @@ function actions_synchronize($delete_orphans = FALSE) {
}
}
else {
$link = l(t('Remove orphaned actions'), 'admin/settings/actions/orphan');
$link = l(t('Remove orphaned actions'), 'admin/config/system/actions/orphan');
$count = count($actions_in_db);
$orphans = implode(', ', $orphaned);
watchdog('actions', format_plural($count, 'One orphaned action (%orphans) exists in the actions table. !link', '@count orphaned actions (%orphans) exist in the actions table. !link'), array('@count' => $count, '%orphans' => $orphans, '!link' => $link), WATCHDOG_WARNING);
......
......@@ -1905,7 +1905,7 @@ function node_page_default() {
$default_links[] = l(t('Create content'), 'node/add');
}
if (user_access('administer site configuration')) {
$default_links[] = l(t('Change the default front page'), 'admin/settings/site-information');
$default_links[] = l(t('Change the default front page'), 'admin/config/system/site-information');
}
if (!empty($default_links)) {
$default_message .= theme('item_list', $default_links);
......
......@@ -19,17 +19,17 @@ class ActionsConfigurationTestCase extends DrupalWebTestCase {
$user = $this->drupalCreateUser(array('administer actions'));
$this->drupalLogin($user);
// Make a POST request to admin/settings/actions/manage.
// Make a POST request to admin/config/system/actions/manage.
$edit = array();
$edit['action'] = md5('system_goto_action');
$this->drupalPost('admin/settings/actions/manage', $edit, t('Create'));
$this->drupalPost('admin/config/system/actions/manage', $edit, t('Create'));
// Make a POST request to the individual action configuration page.
$edit = array();
$action_description = $this->randomName();
$edit['actions_description'] = $action_description;
$edit['url'] = 'admin';
$this->drupalPost('admin/settings/actions/configure/' . md5('system_goto_action'), $edit, t('Save'));
$this->drupalPost('admin/config/system/actions/configure/' . md5('system_goto_action'), $edit, t('Save'));
// Make sure that the new complex action was saved properly.
$this->assertText(t('The action has been successfully saved.'), t("Make sure we get a confirmation that we've successfully saved the complex action."));
......@@ -41,7 +41,7 @@ class ActionsConfigurationTestCase extends DrupalWebTestCase {
$new_action_description = $this->randomName();
$edit['actions_description'] = $new_action_description;
$edit['url'] = 'admin';
$this->drupalPost('admin/settings/actions/configure/1', $edit, t('Save'));
$this->drupalPost('admin/config/system/actions/configure/1', $edit, t('Save'));
// Make sure that the action updated properly.
$this->assertText(t('The action has been successfully saved.'), t("Make sure we get a confirmation that we've successfully updated the complex action."));
......@@ -51,11 +51,11 @@ class ActionsConfigurationTestCase extends DrupalWebTestCase {
// Make sure that deletions work properly.
$this->clickLink(t('delete'));
$edit = array();
$this->drupalPost('admin/settings/actions/delete/1', $edit, t('Delete'));
$this->drupalPost('admin/config/system/actions/delete/1', $edit, t('Delete'));
// Make sure that the action was actually deleted.
$this->assertRaw(t('Action %action was deleted', array('%action' => $new_action_description)), t('Make sure that we get a delete confirmation message.'));
$this->drupalGet('admin/settings/actions/manage');
$this->drupalGet('admin/config/system/actions/manage');
$this->assertNoText($new_action_description, t("Make sure the action description does not appear on the overview page after we've deleted the action."));
$exists = db_query('SELECT aid FROM {actions} WHERE callback = :callback', array(':callback' => 'drupal_goto_action'))->fetchField();
$this->assertFalse($exists, t('Make sure the action is gone from the database after being deleted.'));
......
This diff is collapsed.
......@@ -545,7 +545,7 @@ class AccessDeniedTestCase extends DrupalWebTestCase {
$node = $this->drupalCreateNode($edit);
// Use a custom 403 page.
$this->drupalPost('admin/settings/site-information', array('site_403' => 'node/' . $node->nid), t('Save configuration'));
$this->drupalPost('admin/config/system/site-information', array('site_403' => 'node/' . $node->nid), t('Save configuration'));
$this->drupalGet('admin');
$this->assertText($node->title, t('Found the custom 403 page'));
......@@ -559,7 +559,7 @@ class AccessDeniedTestCase extends DrupalWebTestCase {
// Log back in and remove the custom 403 page.
$this->drupalLogin($this->admin_user);
$this->drupalPost('admin/settings/site-information', array('site_403' => ''), t('Save configuration'));
$this->drupalPost('admin/config/system/site-information', array('site_403' => ''), t('Save configuration'));
// Logout and check that the user login block is shown on default 403 pages.
$this->drupalLogout();
......@@ -579,7 +579,7 @@ class AccessDeniedTestCase extends DrupalWebTestCase {
'name' => $this->admin_user->name,
'pass' => $this->admin_user->pass_raw,
);
$this->drupalPost('admin/settings/site-information', $edit, t('Log in'));
$this->drupalPost('admin/config/system/site-information', $edit, t('Log in'));
// Check that we're still on the same page.
$this->assertText(t('Site information'));
......@@ -622,7 +622,7 @@ class PageNotFoundTestCase extends DrupalWebTestCase {
$node = $this->drupalCreateNode($edit);
// Use a custom 404 page.
$this->drupalPost('admin/settings/site-information', array('site_404' => 'node/' . $node->nid), t('Save configuration'));
$this->drupalPost('admin/config/system/site-information', array('site_404' => 'node/' . $node->nid), t('Save configuration'));
$this->drupalGet($this->randomName(10));
$this->assertText($node->title, t('Found the custom 404 page'));
......@@ -862,12 +862,12 @@ class FrontPageTestCase extends DrupalWebTestCase {
// Change the front page to an invalid path.
$edit = array('site_frontpage' => 'kittens');
$this->drupalPost('admin/settings/site-information', $edit, t('Save configuration'));
$this->drupalPost('admin/config/system/site-information', $edit, t('Save configuration'));
$this->assertText(t("The path '@path' is either invalid or you do not have access to it.", array('@path' => $edit['site_frontpage'])));
// Change the front page to a valid path.
$edit['site_frontpage'] = $this->node_path;
$this->drupalPost('admin/settings/site-information', $edit, t('Save configuration'));
$this->drupalPost('admin/config/system/site-information', $edit, t('Save configuration'));
$this->assertText(t('The configuration options have been saved.'), t('The front page path has been saved.'));
$this->drupalGet('');
......
......@@ -176,7 +176,7 @@ function trigger_assign_form($form_state, $hook, $op, $description) {
}
else {
$form[$op]['none'] = array(
'#markup' => t('No actions available for this trigger. <a href="@link">Add action</a>.', array('@link' => url('admin/settings/actions/manage')))
'#markup' => t('No actions available for this trigger. <a href="@link">Add action</a>.', array('@link' => url('admin/config/system/actions/manage')))
);
}
return $form;
......
......@@ -11,7 +11,7 @@
* Implement hook_help().
*/
function trigger_help($path, $arg) {
$explanation = '<p>' . t('Triggers are system events, such as when new content is added or when a user logs in. Trigger module combines these triggers with actions (functional tasks), such as unpublishing content or e-mailing an administrator. The <a href="@url">Actions settings page</a> contains a list of existing actions and provides the ability to create and configure additional actions.', array('@url' => url('admin/settings/actions'))) . '</p>';
$explanation = '<p>' . t('Triggers are system events, such as when new content is added or when a user logs in. Trigger module combines these triggers with actions (functional tasks), such as unpublishing content or e-mailing an administrator. The <a href="@url">Actions settings page</a> contains a list of existing actions and provides the ability to create and configure additional actions.', array('@url' => url('admin/config/system/actions'))) . '</p>';
switch ($path) {
case 'admin/structure/trigger/comment':
return $explanation . '<p>' . t('Below you can assign actions to run when certain comment-related triggers happen. For example, you could promote a post to the front page when a comment is added.') . '</p>';
......@@ -24,7 +24,7 @@ function trigger_help($path, $arg) {
case 'admin/structure/trigger/user':
return $explanation . '<p>' . t("Below you can assign actions to run when certain user-related triggers happen. For example, you could send an e-mail to an administrator when a user account is deleted.") . '</p>';
case 'admin/help#trigger':
$output = '<p>' . t('The Trigger module provides the ability to trigger <a href="@actions">actions</a> upon system events, such as when new content is added or when a user logs in.', array('@actions' => url('admin/settings/actions'))) . '</p>';
$output = '<p>' . t('The Trigger module provides the ability to trigger <a href="@actions">actions</a> upon system events, such as when new content is added or when a user logs in.', array('@actions' => url('admin/config/system/actions'))) . '</p>';
$output .= '<p>' . t('The combination of actions and triggers can perform many useful tasks, such as e-mailing an administrator if a user account is deleted, or automatically unpublishing comments that contain certain words. By default, there are five "contexts" of events (Comments, Content, Cron, Taxonomy, and Users), but more may be added by additional modules.') . '</p>';
$output .= '<p>' . t('For more information, see the online handbook entry for <a href="@trigger">Trigger module</a>.', array('@trigger' => 'http://drupal.org/handbook/modules/trigger/')) . '</p>';
return $output;
......
......@@ -150,7 +150,7 @@ class TriggerCronTestCase extends DrupalWebTestCase {
'actions_description' => $action_description,
'subject' => $action_description,
);
$this->drupalPost('admin/settings/actions/configure/' . $hash, $edit, t('Save'));
$this->drupalPost('admin/config/system/actions/configure/' . $hash, $edit, t('Save'));
$edit = array('aid' => md5('1'));
$this->drupalPost('admin/structure/trigger/cron', $edit, t('Assign'));
......@@ -160,7 +160,7 @@ class TriggerCronTestCase extends DrupalWebTestCase {
'actions_description' => $action_description,
'subject' => $action_description,
);
$this->drupalPost('admin/settings/actions/configure/' . $hash, $edit, t('Save'));
$this->drupalPost('admin/config/system/actions/configure/' . $hash, $edit, t('Save'));
$edit = array('aid' => md5('2'));
$this->drupalPost('admin/structure/trigger/cron', $edit, t('Assign'));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment