Skip to content
Snippets Groups Projects
Commit f07fd744 authored by Lev Tsypin's avatar Lev Tsypin
Browse files

Add entity to registration object when rendering field as a form.

parent 72a8f51a
Branches 3.x
No related tags found
No related merge requests found
......@@ -125,6 +125,7 @@ function registration_field_formatter_view($entity_type, $entity, $field, $insta
$registration = entity_get_controller('registration')->create(array('type' => $reg_type->name));
$registration->entity_id = $entity_id;
$registration->entity_type = $entity_type;
$registration->entity = entity_load_single($entity_type, $entity_id);
$element[0] = drupal_get_form('registration_form', $registration);
}
break;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment