function opigno_moxtra_update_8013 in Opigno Moxtra 8
Creates create cronjobs.
File
- ./
opigno_moxtra.install, line 320 - Install, update and uninstall functions for the Opigno Moxtra module.
Code
function opigno_moxtra_update_8013() {
// Enable new module opigno_cron.
if (!\Drupal::moduleHandler()
->moduleExists('opigno_cron')) {
\Drupal::service('module_installer')
->install([
'opigno_cron',
]);
}
// Add new cron configuretions.
$config_path = drupal_get_path('module', 'opigno_moxtra') . '/config/install';
$storage = new FileStorage($config_path);
$config_storage = \Drupal::service('config.storage');
$data = $storage
->read('ultimate_cron.job.opigno_moxtra_save_meeting_records');
$config_storage
->write('ultimate_cron.job.opigno_moxtra_save_meeting_records', $data);
$data = $storage
->read('ultimate_cron.job.opigno_moxtra_meeting_notification');
$config_storage
->write('ultimate_cron.job.opigno_moxtra_meeting_notification', $data);
}