dailySalary.js
2.4 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
import * as types from '../constants/ActionTypes';
const initialState = {
dailyShareList :{},
getDailyWage :{},
getDailyStatic :{},
getDailyPayment:{},
getAttendance :{},
is_import :'init',
errorMeg :'',
getDailyRecruit:{},
getPositionDet :{},
getRecruiter :{},
add_failed :'init',
getCustomService:{},
reloadPositionDetailStatus:true,
sailyInvitees :[]
};
export default function environment(state = initialState,action) {
switch(action.type) {
case types.DAILY_SHARE_LIST:
return Object.assign({}, state, {
dailyShareList: action.dailyShareList
});
case types.GET_DAILY_WAGE:
return Object.assign({}, state, {
getDailyWage: action.getDailyWage
});
case types.LOAD_DAILY_INVITEES:
return Object.assign({}, state, {
sailyInvitees: action.sailyInvitees
});
case types.GET_DAILY_STATIC:
return Object.assign({}, state, {
getDailyStatic: action.getDailyStatic
});
case types.GET_DAILY_PAYMENT:
return Object.assign({}, state, {
getDailyPayment: action.getDailyPayment
});
case types.GET_ATTENDANCE:
return Object.assign({}, state, {
getAttendance: action.getAttendance
});
case types.IMPORT_SALARY:
return Object.assign({}, state, {
is_import: action.is_import,
errorMeg : action.errorMeg
});
case types.GET_DAILY_RECRUIT:
return Object.assign({}, state, {
getDailyRecruit: action.getDailyRecruit
});
case types.GET_POSITION_DET:
return Object.assign({}, state, {
getPositionDet: action.getPositionDet
});
case types.GET_RECRUITER:
return Object.assign({}, state, {
getRecruiter: action.getRecruiter
});
case types.ADD_DAILY_POSITION:
return Object.assign({}, state, {
add_failed: action.add_failed
});
case types.GET_CUSTOM_SERVICE:
return Object.assign({}, state, {
getCustomService: action.getCustomService
});
case types.RELOAD_DAILYPOSI_DET:
return Object.assign({}, state, {
reloadPositionDetailStatus: action.reloadPositionDetailStatus
});
default:
return state;
}
}