public function UltimateCronJob::build_operations_alter in Ultimate Cron 7.2
Allow a job to alter the allowed operations on it in the Export UI.
File
- ./
ultimate_cron.job.inc, line 283 - Job class for Ultimate Cron.
Class
- UltimateCronJob
- Class for handling cron jobs.
Code
public function build_operations_alter(&$allowed_operations) {
ctools_include('plugins');
$plugin_types = ctools_plugin_get_plugin_type_info();
foreach ($plugin_types['ultimate_cron'] as $name => $info) {
$static = $info['defaults']['static'];
$class = $static['class'];
if (!$class::$multiple) {
$this
->getPlugin($name)
->build_operations_alter($this, $allowed_operations);
}
else {
$plugins = _ultimate_cron_plugin_load_all($name);
foreach ($plugins as $plugin) {
$this
->getPlugin($name, $plugin->name)
->build_operations_alter($this, $allowed_operations);
}
}
}
drupal_alter('ultimate_cron_plugin_build_operations', $this, $allowed_operations);
}