public function Workflow::getSetting in Workflow 7.2
Same name and namespace in other branches
- 7 includes/Entity/Workflow.php \Workflow::getSetting()
Gets a setting from the state object.
File
- includes/
Entity/ Workflow.php, line 664 - Contains workflow\includes\Entity\Workflow. Contains workflow\includes\Entity\WorkflowController.
Class
Code
public function getSetting($key, array $field = array()) {
switch ($key) {
case 'watchdog_log':
if (isset($this->options['watchdog_log'])) {
// This is set via Node API.
return $this->options['watchdog_log'];
}
elseif ($field) {
if (isset($field['settings']['watchdog_log'])) {
// This is set via Field API.
return $field['settings']['watchdog_log'];
}
}
drupal_set_message('Setting Workflow::getSetting(' . $key . ') does not exist', 'error');
break;
default:
drupal_set_message('Setting Workflow::getSetting(' . $key . ') does not exist', 'error');
}
}