18 lines
488 B
TypeScript
18 lines
488 B
TypeScript
import { STEP } from '../constants';
|
|
import type { GetActionProps } from '../interfaces';
|
|
|
|
/**
|
|
* Метод получение экшенов МО установки КМ в зависимости от шага.
|
|
*/
|
|
export const getActions = ({ checkActions, installActions, resultActions, step }: GetActionProps) => {
|
|
switch (step) {
|
|
case STEP.INSTALL:
|
|
return installActions;
|
|
case STEP.RESULT:
|
|
return resultActions;
|
|
|
|
default:
|
|
return checkActions;
|
|
}
|
|
};
|