function user_restrictions_rules_action_info in User restrictions 7
Implements hook_rules_action_info
Provides actions for rules events to block and unblock names/emails.
Return value
array
File
- ./
user_restrictions.rules.inc, line 44 - Rules_info for the User restrictions module.
Code
function user_restrictions_rules_action_info() {
$defaults = array(
'group' => t('User Restrictions'),
'parameter' => array(
'account' => array(
'label' => t('User'),
'type' => 'user',
'description' => t('The User the event will affect.'),
),
),
);
$actions['user_restrictions_block_name'] = $defaults + array(
'label' => t('Block username'),
);
$actions['user_restrictions_block_mail'] = $defaults + array(
'label' => t('Block email address'),
);
$actions['user_restrictions_unblock_name'] = $defaults + array(
'label' => t('Unblock username'),
);
$actions['user_restrictions_unblock_mail'] = $defaults + array(
'label' => t('Unblock email address'),
);
return $actions;
}