Is it possible to add a new state (and transitions) to an already existing Drupal 8 Workflows through a custom module?
And can we were to apply this to all workflows available?
Or is it possible to add new state to existing workflows through code?
I use module described as following link:- https://www.drupal.org/docs/8/core/modules/workflows/overview
I was able to add workflow element with below code, but is that correct way?
\Drupal::configFactory()->getEditable('workflows.workflow.standard')->set('type_settings.states.perform_check',array("published"=>false,"default_revision"=> false, "label"=>"Perform Check","weight"=> -3))->save();
It added "perform_check" state with below settings:-
- published: false
- default_revision: false
- label: 'In Performance Check'
- weight: -3