I'm not 100% sure if this is actually needed, but it rounds out the API nicely.
Usage of entity_load_multiple_by_name() borrowed from search_api.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

tim.plunkett’s picture

Status: Active » Needs review
FileSize
882 bytes
fago’s picture

Status: Needs review » Needs work

+1 for adding such a helper, field-collection items are not identified by name though. Thus we should use entity_load().

tim.plunkett’s picture

Status: Needs work » Needs review
FileSize
1.4 KB

Now with basic doxygen.

fago’s picture

Status: Needs review » Needs work
+ *   An aray of field_collection_item objects.

Typo in array. Also let's specify the return type in case of the single load so IDEs can pick that up. Then, I'd not call them field_collection_item objects, but "field-collections items" or "field-collection item entities".

tim.plunkett’s picture

Status: Needs work » Needs review
FileSize
1.43 KB

Sounds good.

fago’s picture

Status: Needs review » Fixed

thanks, committed.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

jmuzz’s picture

Issue summary: View changes
Status: Needs work » Closed (fixed)

I don't understand, the last few posts point to this being fixed, but somehow the issue is "Needs Work."

I'm setting it to fixed.