21 lines
617 B
JavaScript
21 lines
617 B
JavaScript
|
import { connect } from 'react-redux';
|
||
|
import { add_dialog_msg, toggle_loading, add_confirm } from '../../actions';
|
||
|
import ServerPage from '../../components/AdminPage/Server';
|
||
|
|
||
|
const mapStateToProps = (state) => ({
|
||
|
i18n: state.i18n
|
||
|
});
|
||
|
|
||
|
const mapDispatchToProps = (dispatch, ownProps) => ({
|
||
|
showDialog: (msg) => {
|
||
|
dispatch(add_dialog_msg(msg));
|
||
|
},
|
||
|
toggleLoading: (flag = false) => {
|
||
|
dispatch(toggle_loading(flag));
|
||
|
},
|
||
|
callConfirm: (msg, act = null) => {
|
||
|
dispatch(add_confirm(msg, act));
|
||
|
}
|
||
|
})
|
||
|
|
||
|
export default connect(mapStateToProps, mapDispatchToProps)(ServerPage);
|