function flag_actions_update_action in Flag 7.3
Same name and namespace in other branches
- 5 flag_actions.module \flag_actions_update_action()
- 6.2 flag_actions.module \flag_actions_update_action()
- 6 flag_actions.module \flag_actions_update_action()
- 7.2 flag_actions.module \flag_actions_update_action()
Update an existing flag action.
Parameters
int $aid: The flag action ID to update.
string $event: The flag event, such as "flag" or "unflag".
int $threshold: The flagging threshold at which this action will be executed.
int $repeat_threshold: The number of additional flaggings after which the action will be repeated.
array $parameters: The action parameters.
1 call to flag_actions_update_action()
- flag_actions_form_submit in ./
flag_actions.module - Generic submit handler for saving flag actions.
File
- ./
flag_actions.module, line 179 - Actions support for the Flag module.
Code
function flag_actions_update_action($aid, $event, $threshold, $repeat_threshold, $parameters) {
return db_update('flag_actions')
->fields(array(
'event' => $event,
'threshold' => $threshold,
'repeat_threshold' => $repeat_threshold,
'parameters' => serialize($parameters),
))
->condition('aid', $aid)
->execute();
}