function farm_asset_load in farmOS 7
Load an asset.
Parameters
int $id: The asset id.
bool $reset: Whether or not to reset the entity cache.
Return value
FarmAsset Returns a farm asset object.
20 calls to farm_asset_load()
- farm_asset_plugin_argument_validate_farm_asset::validate_argument in modules/
farm/ farm_asset/ includes/ views/ plugins/ farm_asset_plugin_argument_validate_farm_asset.inc - farm_group_asset_membership in modules/
farm/ farm_group/ farm_group.module - Load groups that an asset is a member of.
- farm_group_circular_membership_validate in modules/
farm/ farm_group/ farm_group.module - Form helper function for validating against circular membership assignment.
- farm_group_farm_area_link_alter in modules/
farm/ farm_group/ farm_group.farm_area.inc - Implements hook_farm_area_link_alter().
- farm_group_members in modules/
farm/ farm_group/ farm_group.module - Load all members of a group.
1 string reference to 'farm_asset_load'
- farm_asset_entity_info in modules/
farm/ farm_asset/ farm_asset.module - Implements hook_entity_info().
File
- modules/
farm/ farm_asset/ farm_asset.module, line 789 - Farm asset - A farm asset entity type.
Code
function farm_asset_load($id, $reset = FALSE) {
$farm_assets = farm_asset_load_multiple(array(
$id,
), array(), $reset);
return reset($farm_assets);
}