Add remote mount
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
import * as Constants from '../../constants';
|
||||
import {createReducer} from 'redux-starter-kit';
|
||||
import {
|
||||
addRemoteMount2,
|
||||
DISPLAY_CONFIGURATION,
|
||||
removeRemoteMount3,
|
||||
RESET_MOUNTS_STATE,
|
||||
@@ -56,6 +57,27 @@ export const createMountReducer = state => {
|
||||
ProviderState: providerState,
|
||||
RemoteMounts: state.RemoteMounts ? state.RemoteMounts : ['Remotelocalhost:20000'],
|
||||
}, {
|
||||
[addRemoteMount2]: (state, action) => {
|
||||
let mountState = {...state.MountState};
|
||||
mountState[action.payload] = {
|
||||
AllowMount: false,
|
||||
DriveLetters: [],
|
||||
Mounted: false,
|
||||
};
|
||||
|
||||
let providerState = {...state.ProviderState};
|
||||
providerState[action.payload] = {
|
||||
AutoMount: false,
|
||||
AutoRestart: false,
|
||||
MountLocation: '',
|
||||
};
|
||||
return {
|
||||
...state,
|
||||
MountState: mountState,
|
||||
ProviderState: providerState,
|
||||
RemoteMounts: [...state.RemoteMounts, action.payload],
|
||||
}
|
||||
},
|
||||
[DISPLAY_CONFIGURATION]: (state, action) => {
|
||||
return {
|
||||
...state,
|
||||
|
||||
Reference in New Issue
Block a user