2016-10-05 13:36:47 -04:00
|
|
|
var connect = require('react-redux').connect;
|
|
|
|
|
|
|
|
var UserActions = require('../actions/UserActions');
|
2017-06-21 21:25:38 -04:00
|
|
|
|
2016-10-05 13:45:09 -04:00
|
|
|
var AccountSettingsModal = require('../components/AccountSettingsModal');
|
2016-10-05 13:36:47 -04:00
|
|
|
|
|
|
|
function mapStateToProps(state) {
|
|
|
|
return {
|
2017-06-21 21:25:38 -04:00
|
|
|
user: state.user,
|
|
|
|
currencies: state.securities.currency_list
|
2016-10-05 13:36:47 -04:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
function mapDispatchToProps(dispatch) {
|
|
|
|
return {
|
|
|
|
onUpdateUser: function(user) {dispatch(UserActions.update(user))}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
module.exports = connect(
|
|
|
|
mapStateToProps,
|
|
|
|
mapDispatchToProps
|
|
|
|
)(AccountSettingsModal)
|