//
// SPDX-License-Identifier: AGPL-3.0
-import { RunProcessPanelAction, runProcessPanelActions } from '~/store/run-process-panel/run-process-panel-actions';
-import { WorkflowResource, CommandInputParameter, getWorkflowInputs, parseWorkflowDefinition } from '~/models/workflow';
+import { RunProcessPanelAction, runProcessPanelActions } from 'store/run-process-panel/run-process-panel-actions';
+import { WorkflowResource, CommandInputParameter, getWorkflowInputs, parseWorkflowDefinition } from 'models/workflow';
interface RunProcessPanel {
+ processPathname: string;
processOwnerUuid: string;
currentStep: number;
isStepChanged: boolean;
}
const initialState: RunProcessPanel = {
+ processPathname: '',
processOwnerUuid: '',
currentStep: 0,
isStepChanged: false,
export const runProcessPanelReducer = (state = initialState, action: RunProcessPanelAction): RunProcessPanel =>
runProcessPanelActions.match(action, {
+ SET_PROCESS_PATHNAME: processPathname => ({ ...state, processPathname }),
SET_PROCESS_OWNER_UUID: processOwnerUuid => ({ ...state, processOwnerUuid }),
SET_CURRENT_STEP: currentStep => ({ ...state, currentStep }),
SET_STEP_CHANGED: isStepChanged => ({ ...state, isStepChanged }),