function tripal_feature_edit_ALL_properties_page

1.x tripal_feature-properties.inc tripal_feature_edit_ALL_properties_page($node)

Related topics

File

tripal_feature/includes/tripal_feature-properties.inc, line 12
@todo Add file header description

Code

function tripal_feature_edit_ALL_properties_page($node) {
  $output = '';

  // get the list of properties for this feature
  $values = array('feature_id' => $node->feature->feature_id);
  $options = array('order_by' => array('type_id' => 'ASC', 'rank' => 'ASC'));
  $properties = tripal_core_generate_chado_var('featureprop', $values, $options);
  $properties = tripal_core_expand_chado_vars($properties, 'field', 'featureprop.value');

  $expand_add = (sizeof($properties)) ? FALSE : TRUE;

  // add the appopriate form sections
  $output .= drupal_get_form('tripal_feature_add_ONE_property_form', $node, $expand_add);
  $output .= drupal_get_form('tripal_feature_edit_ALL_properties_form', $node, $properties);
  $output .= drupal_get_form('tripal_feature_implement_back_to_feature_button', $node->nid);

  return $output;
}