Browse Source

remove unused file

master
farhantock 3 months ago
parent
commit
d9918afa00
  1. 41
      src/appredux/modules/shipment/actions.js
  2. 34
      src/appredux/modules/shipment/reducers.js

41
src/appredux/modules/shipment/actions.js

@ -1,41 +0,0 @@
export const SET_SHIPMENT_DATA = 'SET_SHIPMENT_DATA';
export const SET_SELECTED_DROP_POINT = 'SET_SELECTED_DROP_POINT';
export const SET_SELECTED_HISTORY = 'SET_SELECTED_HISTORY';
export const SET_SHOW_HISTORY_PICTURE = 'SET_SHOW_HISTORY_PICTURE';
export const SET_SELECTED_HISTORY_PICTURE = 'SET_SELECTED_HISTORY_PICTURE';
export const setShipmentData = obj => dispatch => {
dispatch({
type: SET_SHIPMENT_DATA,
payload: obj
})
}
export const setSelectedDropPoint = obj => dispatch => {
dispatch({
type: SET_SELECTED_DROP_POINT,
payload: obj
})
}
export const setSelectedHistory = obj => dispatch => {
dispatch({
type: SET_SELECTED_HISTORY,
payload: obj
})
}
export const setShowHistoryPicture = obj => dispatch => {
dispatch({
type: SET_SHOW_HISTORY_PICTURE,
payload: obj
})
}
export const setSelectedHistoryPicture = obj => dispatch => {
dispatch({
type: SET_SELECTED_HISTORY_PICTURE,
payload: obj
})
}

34
src/appredux/modules/shipment/reducers.js

@ -1,34 +0,0 @@
import {
SET_SHIPMENT_DATA,
SET_SELECTED_DROP_POINT,
SET_SELECTED_HISTORY,
SET_SHOW_HISTORY_PICTURE,
SET_SELECTED_HISTORY_PICTURE
} from "./actions";
const initialState = {
shipmentData: null,
selectedDropPoint: null,
selectedHistory: null,
showHistoryPicture: false,
selectedHistoryPicture: null
}
function shipmentReducer(state = initialState, action) {
switch (action.type) {
case SET_SHIPMENT_DATA:
return { ...state, shipmentData: action.payload }
case SET_SELECTED_DROP_POINT:
return { ...state, selectedDropPoint: action.payload }
case SET_SELECTED_HISTORY:
return { ...state, selectedHistory: action.payload }
case SET_SHOW_HISTORY_PICTURE:
return { ...state, showHistoryPicture: action.payload }
case SET_SELECTED_HISTORY_PICTURE:
return { ...state, selectedHistoryPicture: action.payload }
default:
return state;
}
}
export default shipmentReducer;
Loading…
Cancel
Save