public function __construct() { parent::__construct(); $this->values = array(); $this->variableService = wfEngine_models_classes_VariableService::singleton(); if (!$this->activityExecution->hasType(new core_kernel_classes_Class(CLASS_ACTIVITY_EXECUTION))) { $this->activityExecution = null; $this->setErrorMessage(__('The resource is not an activity execution')); } $code = urldecode($this->getRequestParameter('code')); if (!empty($code)) { if (is_null($this->variableService->getProcessVariable($code))) { $this->setErrorMessage(__('The variable with the code ' . $code . ' does not exists')); } else { $this->code = $code; } } else { $this->setErrorMessage(__('No variable code given')); } // don't use getRequestParameter since it modifies the params if (isset($_REQUEST['value'])) { $values = $_REQUEST['value']; if (is_array($values)) { foreach ($values as $value) { $this->values[] = urldecode($value); } } else { $this->values[] = urldecode($values); } } }
public function __construct() { parent::__construct(); if (!$this->processExecution->hasType(new core_kernel_classes_Class(CLASS_PROCESSINSTANCES))) { $this->processExecution = null; $this->setErrorMessage(__('The resource is not a process execution')); } }
public function __construct() { parent::__construct(); if (!$this->activityExecution->hasType(new core_kernel_classes_Class(CLASS_ACTIVITY_EXECUTION))) { $this->activityExecution = null; $this->setErrorMessage(__('The resource is not an activity execution')); } $this->activityExecutionService = wfEngine_models_classes_ActivityExecutionService::singleton(); }
public function __construct() { parent::__construct(); $this->processDefinitionService = wfEngine_models_classes_ProcessDefinitionService::singleton(); $processDefinitionUri = urldecode($this->getRequestParameter('processDefinitionUri')); if (!empty($processDefinitionUri) && common_Utils::isUri($processDefinitionUri)) { $process = new core_kernel_classes_Resource($processDefinitionUri); if ($process->hasType(new core_kernel_classes_Class(CLASS_PROCESS))) { $this->processDefinition = $process; } else { $this->setErrorMessage(__('The resource is not a process definition')); } } else { $this->setErrorMessage(__('No process definition uri given')); } }