Nigel Banks
11 years ago
4 changed files with 55 additions and 3 deletions
@ -0,0 +1,26 @@ |
|||||||
|
<?php |
||||||
|
|
||||||
|
/** |
||||||
|
* @file |
||||||
|
* Implementation of Rules hooks, giving default configurations. |
||||||
|
*/ |
||||||
|
|
||||||
|
/** |
||||||
|
* Implements hook_default_rules_configuration(). |
||||||
|
*/ |
||||||
|
function islandora_default_rules_configuration() { |
||||||
|
$rule = rules_reaction_rule(); |
||||||
|
$rule->label = 'E-mail admin'; |
||||||
|
$rule->active = FALSE; |
||||||
|
$rule |
||||||
|
->event('islandora_object_ingested') |
||||||
|
->action( |
||||||
|
'mail', |
||||||
|
array( |
||||||
|
'to' => '[site:mail]', |
||||||
|
'subject' => '[[site:name]] "[object:label]" has been ingested', |
||||||
|
'message' => '[object:label] has been ingested as [object:id].', |
||||||
|
) |
||||||
|
); |
||||||
|
return array('islandora_object_ingested_notify_admin' => $rule); |
||||||
|
} |
Loading…
Reference in new issue