function tmgmt_local_tmgmt_job_delete in Translation Management Tool 7
Same name and namespace in other branches
- 8 translators/tmgmt_local/tmgmt_local.module \tmgmt_local_tmgmt_job_delete()
Implements hook_tmgmt_job_delete().
File
- translators/
tmgmt_local/ tmgmt_local.module, line 634 - Main module file for the local translation module.
Code
function tmgmt_local_tmgmt_job_delete(TMGMTJob $job) {
$query = new EntityFieldQuery();
$result = $query
->entityCondition('entity_type', 'tmgmt_local_task')
->propertyCondition('tjid', $job->tjid)
->execute();
if (!empty($result['tmgmt_local_task'])) {
entity_delete_multiple('tmgmt_local_task', array_keys($result['tmgmt_local_task']));
}
}