automated_cron_settings_submit

automated_cron_settings_submit(array $form, FormStateInterface $form_state)

Form submission handler for system_cron_settings().

File

core/modules/automated_cron/automated_cron.module, line 69
Provides an automated cron by executing it at the end of a response.

Code

function automated_cron_settings_submit(array $form, FormStateInterface $form_state) {
  \Drupal::configFactory()->getEditable('automated_cron.settings')
    ->set('interval', $form_state->getValue('interval'))
    ->save();
  drupal_set_message(t('The configuration options have been saved.'));
}
doc_Drupal
2016-10-29 08:45:18
Comments
Leave a Comment

Please login to continue.