commerce_order_user.form_entity.inc in Flexiform 7
Contains class for a basic entity getter.
File
includes/form_entity/commerce_order_user.form_entity.incView source
<?php
/**
* @file
* Contains class for a basic entity getter.
*/
/**
* Form Entity Class for getting users from commerce order.
*/
class FlexiformFormEntityCommerceOrderUser extends FlexiformFormEntityBase {
/**
* {@inheritdoc}
*/
public function getEntity() {
parent::getEntity();
// Get the base order
$order = $this
->getParam('base');
// Check we have enough information to load the entity.
if (!$order) {
return FALSE;
}
return entity_load_single('user', $order->uid);
}
}
Classes
Name | Description |
---|---|
FlexiformFormEntityCommerceOrderUser | Form Entity Class for getting users from commerce order. |