recharge.js
2.6 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
79
80
81
import * as types from '../constants/ActionTypes';
const initialState = {
orderList: {},
accountBalance: {},
yesterdayPay: {},
monthBillList: {},
monthAccountTotal: {},
consumeRecordList: {},
invoicesList: {},
invoicesInfos: {},
invoiceTem: {},
invoiceTemDetail: {},
invoiceMoney: {},
//企业充值后台
accountManageList: {},
invoiceRecordList:{}
};
export default function environment(state = initialState, action) {
switch (action.type) {
case types.LOAD_ORDER_LIST:
return Object.assign({}, state, {
orderList: action.orderList
});
case types.LOAD_ACCOUNT_BALANCE:
return Object.assign({}, state, {
accountBalance: action.accountBalance
});
case types.LOAD_YESTERDAY_PAY:
return Object.assign({}, state, {
yesterdayPay: action.yesterdayPay
});
case types.LOAD_MONRH_BILL_list:
return Object.assign({}, state, {
monthBillList: action.monthBillList
});
case types.LOAD_MONRH_ACCOUNT_TOTAL:
return Object.assign({}, state, {
monthAccountTotal: action.monthAccountTotal
});
case types.LOAD_CONSUME_RECORD_LIST:
return Object.assign({}, state, {
consumeRecordList: action.consumeRecordList
});
case types.LOAD_INVOICES_LIST:
return Object.assign({}, state, {
invoicesList: action.invoicesList
});
case types.ASK_FOR_INVOICES:
return Object.assign({}, state, {
invoicesInfos: action.invoicesInfos
});
case types.LOAD_INVOICE_TEM:
return Object.assign({}, state, {
invoiceTem: action.invoiceTem
});
case types.LOAD_INVOICE_TEM_DETAIL:
return Object.assign({}, state, {
invoiceTemDetail: action.invoiceTemDetail
});
case types.LOAD_INCOICE_MONEY:
return Object.assign({}, state, {
invoiceMoney: action.invoiceMoney
});
//企业充值后台
case types.LOAD_ACCOUNT_MANAGE:
return Object.assign({}, state, {
accountManageList: action.accountManageList
});
case types.LOAD_INVOICE_RECORD:
return Object.assign({}, state, {
invoiceRecordList: action.invoiceRecordList
});
default:
return state;
}
}