function profile_module_manager_batch_finished in Profile Module Manager 7
Same name and namespace in other branches
- 7.2 profile_module_manager.module \profile_module_manager_batch_finished()
1 string reference to 'profile_module_manager_batch_finished'
- profile_module_manager_bundle_enable in ./
profile_module_manager.admin.inc - Callback function for admin/settings/bundles/list/enable/%
File
- ./
profile_module_manager.module, line 253 - Alters grouping in admin/modules using hook_system_info_alter
Code
function profile_module_manager_batch_finished($success, $results, $operations) {
if ($success) {
// Get bundle name from $results and print message.
$bundle_name = $results['bundle'];
$bundle_path = drupal_get_path('module', $bundle_name);
$bundle = drupal_parse_info_file($bundle_path . '/' . $bundle_name . '.info');
drupal_set_message('The ' . $bundle['name'] . ' Bundle has been successfully enabled on your site. You may now begin using this functionality and go back to editing your site.');
// Log bundle enable time.
$start_time = variable_get('profile_module_manager_enable_timer', 0);
$end_time = microtime(TRUE);
$total_time = $end_time - $start_time;
watchdog('profile_module_manager', '!bundle enable time: !time seconds.', array(
'!bundle' => $bundle['name'],
'!time' => $total_time,
));
}
else {
_revert_bundle_on_error();
}
}