Try installing minimal and switching on entity. entity_get_property_info() will happily report node body.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

umtj’s picture

Issue summary: View changes
Status: Active » Needs review
FileSize
1.96 KB

And here's a patch for it.

Chris Matthews’s picture

Status: Needs review » Needs work
Issue tags: +Needs reroll

The 4 year old patch to comment.info.inc and node.info.inc does not apply to the latest entity 7.x-1.x-dev and (if still relevant) needs a reroll.

Checking patch modules/comment.info.inc...
Checking patch modules/node.info.inc...
error: while searching for:
    'access callback' => 'entity_metadata_node_revision_access',
  );
  return $info;
}

/**
 * Implements hook_entity_property_info_alter() on top of node module.
 * @see entity_metadata_entity_property_info_alter()
 */
function entity_metadata_node_entity_property_info_alter(&$info) {
  // Move the body property to the node by default, as its usually there this
  // makes dealing with it more convenient.
  $info['node']['properties']['body'] = array(
    'type' => 'text_formatted',
    'label' => t('The main body text'),
    'getter callback' => 'entity_metadata_field_verbatim_get',
    'setter callback' => 'entity_metadata_field_verbatim_set',
    'property info' => entity_property_text_formatted_info(),
    'auto creation' => 'entity_property_create_array',
    'field' => TRUE,
  );
}

error: patch failed: modules/node.info.inc:145
error: modules/node.info.inc: patch does not apply
Snehal Brahmbhatt’s picture

Status: Needs work » Needs review
FileSize
2.03 KB

@Chris2, Please review my rerolled patch for entity 7.x-1.x-dev, hope this helps you. Let me know if any further changes are required for the same.

Thanks!..