Problem/Motivation
The workflow code is douplicating a lot of code.
Also, many 'Workflow' settings can be managed via the 'Manage Form Display' settings, where all sub- and attached fields of a workflow transition are listed.
For that, recently some attributes (like 'execute', 'scheduled', are moved to the Field UI.
There is still some to do
Steps to reproduce
Proposed resolution
Add also the timestamp to the 'Manage Form Display' settings. You can choose between 'Timestamp', Timestamp Timezone', widget or hide the widget.
Until now, the settings from the 'Edit workflow' screen take precedence.
Then , on the Node form workflow widget, the widget is compiled by creating a new form element for the Transition object, and parsing the submitted results can also be delegated to core code.
Afterwards, the remaining duplicated, or twice executed code can be removed, too.
(In Initial versions of D8, workflow would duplicate a lot of code)
Remaining tasks
Create update script that removes settings from Workflow Settings.
Create hook to influence the visible/required states of each element.
User interface changes
Additional files on Workflow > Workflow type > Manager Form Display
Comments
Comment #17
johnvThis is now complete, and also the Ajax widgets on Node and WorkflowTransition are working on Node create and Node edit.