export default connect(
null,
dispatch => ({
onLoginSystem: (account) => {
return dispatch(loginSystem(account));
}
})
)(AdminPanel);
export const loginSystem = (data) => {
return dispatch => {
return axios.post('/user', {
login: data.login,
password: data.password
})
}
}
this.props.onLoginSystem(account).then((response) => {
.... не работает
})