diff --git a/inline_entity_form.module b/inline_entity_form.module index be41f13..fe3b4de 100644 --- a/inline_entity_form.module +++ b/inline_entity_form.module @@ -1385,6 +1385,29 @@ function theme_inline_entity_form_entity_table($variables) { // label() returns human-readable versions of token and list properties. $data = $property->label() ? $property->label() : $property->value(); $data = check_plain($data); + + if (isset($field['process']) && function_exists($field['process'])) { + if (isset($field['arguments']) && is_array($field['arguments'])) { + // swap integer 1 for the data, similair to hook_menu + $arguments = array(); + $replaced = false; + foreach ($field['arguments'] as $arg) { + if ($arg === 1) { + $arguments[] = $data; + $replaced = true; + } else { + $arguments[] = $arg; + } + } + // If the data was never swapped in, use it as the first argument + if (!$replaced) { + array_unshift($arguments, $data); + } + } else { + $arguments = array($data); + } + $data = call_user_func_array($field['process'], $arguments); + } } elseif ($field['type'] == 'field') { $display = array(