Skip to content
Snippets Groups Projects

Override maintenance mode service with domain specific config.

Open Stef De Waele requested to merge issue/domain-2857402:2857402-maintenance-mode into 2.0.x
1 unresolved thread

Closes #2857402

Merge request reports

Loading
Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
179 180 }
180 181 return \Drupal::service('router.admin_context')->isAdminRoute($route);
181 182 }
183
184 /**
185 * Implements hook_form_FORM_ID_alter().
186 */
187 function domain_config_ui_form_system_site_maintenance_mode_alter(&$form, FormStateInterface $form_state, $form_id) {
188 $config = \Drupal::service('config.factory')->get('domain_config_ui.domain_settings');
189
190 // Override the default value by taking it from this module's configuration setting object.
191 $form['maintenance_mode']['#default_value'] = $config->get('maintenance_mode');
192 $form['maintenance_mode']['#description'] .= t(' This setting is overridden by the Domain Access module.');
  • Suggested change
    203 $form['maintenance_mode']['#description'] .= t(' This setting is overridden by the Domain Access module.');
    203 $form['maintenance_mode']['#description'] .= t('This setting is overridden by the Domain Access module.');
  • Please register or sign in to reply
  • Justin LELUC added 22 commits

    added 22 commits

    • a0b7a83b...aa655852 - 20 commits from branch project:2.0.x
    • 039c44c9 - Override maintenance mode service with domain specific config.
    • 8381e830 - Merge branch '2857402-maintenance-mode' of git.drupal.org:issue/domain-2857402...

    Compare with previous version

  • Justin LELUC added 1 commit

    added 1 commit

    • 5d4052ea - Remove duplicate fonction and use

    Compare with previous version

  • Please register or sign in to reply
    Loading