function slickgrid_callback_delete in Slickgrid 7
Same name and namespace in other branches
- 6 slickgrid.callbacks.inc \slickgrid_callback_delete()
Callback function - delete a node
File
- includes/
slickgrid.callbacks.inc, line 44
Code
function slickgrid_callback_delete() {
foreach ($_POST['entity_ids'] as $entity_id) {
entity_delete($_POST['entity_type'], $entity_id);
}
drupal_set_message(format_plural(count($_POST['entity_ids']), '1 item was deleted.', '@count items were deleted.'));
return array(
'deleted' => $_POST['entity_ids'],
);
}