protected function Log::defaultLabel in Log entity 7
Defines the entity label if the 'entity_class_label' callback is used.
Specify 'entity_class_label' as 'label callback' in hook_entity_info() to let the entity label point to this method. Override this in order to implement a custom default label.
Overrides Entity::defaultLabel
File
- ./
log.class.inc, line 16 - Log classes.
Class
- Log
- Log class.
Code
protected function defaultLabel() {
if (!empty($this->name)) {
return $this->name;
}
else {
return 'Log';
}
}