diff options
| author | Jules Laplace <julescarbon@gmail.com> | 2018-05-28 13:06:54 +0200 |
|---|---|---|
| committer | Jules Laplace <julescarbon@gmail.com> | 2018-05-28 13:06:54 +0200 |
| commit | 2664eb3e474f5d03d1782c15673b774d68fb2c58 (patch) | |
| tree | 1f1e58a6090f6befa75d8f6915388ddee30df04d /app/client/system | |
| parent | 3a8d99c5e4f64a9426585943c40635eb183b47ae (diff) | |
textInput/fileUpload
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, |
