You are here

public function PredefinedStatesWorkflowTestType::setStateLabel in Drupal 10

Same name and namespace in other branches
  1. 8 core/modules/workflows/tests/modules/workflow_type_test/src/Plugin/WorkflowType/PredefinedStatesWorkflowTestType.php \Drupal\workflow_type_test\Plugin\WorkflowType\PredefinedStatesWorkflowTestType::setStateLabel()
  2. 9 core/modules/workflows/tests/modules/workflow_type_test/src/Plugin/WorkflowType/PredefinedStatesWorkflowTestType.php \Drupal\workflow_type_test\Plugin\WorkflowType\PredefinedStatesWorkflowTestType::setStateLabel()

Sets a state's label.

Parameters

string $state_id: The state ID to set the label for.

string $label: The state's label.

Return value

$this

Overrides WorkflowTypeBase::setStateLabel

File

core/modules/workflows/tests/modules/workflow_type_test/src/Plugin/WorkflowType/PredefinedStatesWorkflowTestType.php, line 68

Class

PredefinedStatesWorkflowTestType
Test workflow type.

Namespace

Drupal\workflow_type_test\Plugin\WorkflowType

Code

public function setStateLabel($state_id, $label) {

  // States cannot be altered on this workflow.
  return $this;
}