【发布时间】:2014-09-05 08:13:25
【问题描述】:
如何在EntityFieldQuery中添加多个entity_type和bundle?
$query->entityCondition('entity_type', 'profile2')
->entityCondition('bundle', 'user_profile');
有没有办法做到这一点?
$query->entityCondition('entity_type', array('profile2','user'))
->entityCondition('bundle', array('user_profile','property'));
【问题讨论】:
-
你试过了吗?根据文档,它应该像那样工作。
-
它适用于单一实体类型。