Pimcore\Model\Element\WorkflowState::setCtype PHP Метод

setCtype() публичный Метод

public setCtype ( string $ctype )
$ctype string
    public function setCtype($ctype)
    {
        $this->ctype = $ctype;
    }

Usage Example

Пример #1
0
 /**
  * @return null|WorkflowState
  */
 public function getWorkflowStateForElement()
 {
     $elementType = Service::getElementType($this->element);
     $workflowState = WorkflowState::getByPrimary($this->element->getId(), $elementType, $this->workflow->getId());
     if (empty($workflowState)) {
         $workflowState = new WorkflowState();
         $workflowState->setCid($this->element->getId());
         $workflowState->setCtype($elementType);
         $workflowState->setWorkflowId($this->workflow->getId());
     }
     return $workflowState;
 }