You are here

function hook_workflow_fields_alter in Workflow Fields 7

Perform alterations to described non-fields before a form is rendered.

Parameters

$fields: The array of additional fields defined by hook_workflow_fields.

$type: Content type being handled.

1 invocation of hook_workflow_fields_alter()
_workflow_fields_get_fields in ./workflow_fields.module

File

./workflow_fields.api.php, line 45
Hooks provided by the workflow_fields module.

Code

function hook_workflow_fields_alter(&$fields, $type) {

  // The Worflow Fields module does nothing with this hook.
  // Here is an example how to change the widget label for the page content type.
  $content = node_type_get_type($type);
  if ($content->type == 'page') {
    $fields['page']['title']['widget']['label'] = 'Reference';
  }
}