import * as snSearchService from '../../services/MM/snSearchService';

export default {
    namespace: 'snSearch',
    state: {
    },
    subscriptions: {
        setup({ dispatch, history }) {  // eslint-disable-line

        },
    },
    effects: {
        *getFullSn({ payload, onComplete }, { call }) {
            const ret = yield call(snSearchService.GetSNOrderEntities, payload);
            if (typeof onComplete === 'function') {
                onComplete(ret)
            }
        }
    },
    reducers: {
        save(state, action) {
            return { ...state, ...action.payload };
        },
    }
}