function hosting_block in Hostmaster (Aegir) 6
Implementation of hook_block().
File
- modules/
hosting/ hosting.module, line 336 - Hosting module.
Code
function hosting_block($op = 'list', $delta = 0, $edit = array()) {
switch ($op) {
case 'list':
$blocks['hosting_summary'] = array(
'info' => t('Hosting summary'),
'enabled' => 1,
'region' => 'left',
'weight' => 10,
);
$blocks['hosting_queues'] = array(
'info' => t('Hosting queues'),
'enabled' => 1,
'region' => 'right',
'weight' => 0,
);
$blocks['hosting_queues_summary'] = array(
'info' => t('Hosting queues summary'),
'enabled' => 1,
'region' => 'right',
'weight' => 1,
'cache' => BLOCK_NO_CACHE,
);
return $blocks;
case 'view':
switch ($delta) {
case 'hosting_queues':
return array(
'title' => t('Queues'),
'content' => hosting_queue_block(),
);
case 'hosting_queues_summary':
return array(
'title' => t('Queues summary'),
'content' => hosting_queue_summary_block(),
);
}
break;
}
}