function commerce_registration_handler_field_registration_entity::render in Commerce Registration 7
Render the field.
Parameters
array $values: The values retrieved from the database.
Overrides views_handler_field::render
File
- includes/
views/ handlers/ commerce_registration_handler_field_registration_entity.inc, line 13 - Commerce Registration attached entity views field handler.
Class
- commerce_registration_handler_field_registration_entity
- @file Commerce Registration attached entity views field handler.
Code
function render($values) {
$product = commerce_product_load($values->registration_eid);
$uri = entity_uri('commerce_product', $product);
$text = t('@product (@sku)', array(
'@product' => $product->title,
'@sku' => $product->sku,
));
return l($text, $uri['path']);
}