You are here

function multifield_load_all in Multifield 7.2

Same name and namespace in other branches
  1. 7 multifield.module \multifield_load_all()
5 calls to multifield_load_all()
multifield_admin_menu_map in ./multifield.module
Implements hook_admin_menu_map().
multifield_entity_info in ./multifield.module
Implements hook_entity_info().
multifield_field_info in ./multifield.field.inc
Implements hook_field_info().
multifield_list_page in ./multifield.admin.inc
@file Administation pages and forms for the Multifield module.
multifield_load in ./multifield.module
1 string reference to 'multifield_load_all'
multifield_schema in ./multifield.install
Implements hook_schema().

File

./multifield.module, line 139

Code

function multifield_load_all() {
  ctools_include('export');
  $result = ctools_export_load_object('multifield');
  $fields = field_read_fields(array(
    'type' => 'multifield',
  ));
  foreach ($fields as $field) {
    $multifield = new stdClass();
    $multifield->machine_name = $field['field_name'];
    $multifield->label = $field['field_name'];
    $multifield->description = NULL;
    $multifield->locked = TRUE;
    $result[$multifield->machine_name] = $multifield;
  }
  return $result;
}