public function TMGMTJobItem::getSiblings in Translation Management Tool 7
Retrieves all siblings of this job item.
Return value
array An array of job items that are the siblings of this job item.
File
- entity/
tmgmt.entity.job_item.inc, line 823
Class
- TMGMTJobItem
- Entity class for the tmgmt_job entity.
Code
public function getSiblings() {
$query = new EntityFieldQuery();
$result = $query
->entityCondition('entity_type', 'tmgmt_job_item')
->propertyCondition('tjiid', $this->tjiid, '<>')
->propertyCondition('tjid', $this->tjid)
->execute();
if (!empty($result['tmgmt_job_item'])) {
return entity_load('tmgmt_job_item', array_keys($result['tmgmt_job_item']));
}
return FALSE;
}