diff options
Diffstat (limited to 'app/client/system')
| -rw-r--r-- | app/client/system/system.actions.js | 4 | ||||
| -rw-r--r-- | app/client/system/system.reducer.js | 11 |
2 files changed, 15 insertions, 0 deletions
diff --git a/app/client/system/system.actions.js b/app/client/system/system.actions.js index 519e140..4c5f98e 100644 --- a/app/client/system/system.actions.js +++ b/app/client/system/system.actions.js @@ -5,3 +5,7 @@ export const run = (cmd) => { socket.system.run_system_command(cmd) return { type: types.system.running_command, cmd } } + +export const changeTool = (tool) => { + return { type: types.app.change_tool, tool } +}
\ No newline at end of file diff --git a/app/client/system/system.reducer.js b/app/client/system/system.reducer.js index f945a65..fe3d9e3 100644 --- a/app/client/system/system.reducer.js +++ b/app/client/system/system.reducer.js @@ -9,6 +9,9 @@ const systemInitialState = { site: { name: 'Lens Cortex', }, + app: { + tool: 'samplernn', + }, server: { connected: false, status: "disconnected", @@ -179,6 +182,14 @@ const systemReducer = (state = systemInitialState, action) => { [action.task.processor]: { status: 'IDLE', task: {} }, }, } + case types.app.change_tool: + return { + ...state, + app: { + ...state.app, + tool: action.tool, + } + } case types.system.stdout: return { ...state, |
