InstallmentAccountContainer.js 1.6 KB
'use strict'

import React, {Component} from 'react';
import {
    StyleSheet,
    Dimensions,
    Platform,
    View,
    NativeModules,
    InteractionManager,
    NativeAppEventEmitter,
    Text,
} from 'react-native'

import {bindActionCreators} from 'redux';
import {connect} from 'react-redux';
import {Map} from 'immutable';
import * as installmentActions from '../reducers/installment/installmentActions';
import AccountPageLineCell from '../components/installment/AccountPageLineCell';
import ServerError from '../components/installment/ServerError';

const actions = [
    installmentActions,
];
function mapStateToProps(state) {
    return {
        ...state
    };
}
function mapDispatchToProps(dispatch) {

    const creators = Map()
        .merge(...actions)
        .filter(value => typeof value === 'function')
        .toObject();

    return {
        actions: bindActionCreators(creators, dispatch),
        dispatch
    };
}
class InstallmentAccountContainer extends Component {
    constructor(props) {
        super(props);
        this._onPressMyCard = this._onPressMyCard.bind(this);
    }
    componentDidMount() {
    }


    _onPressMyCard() {
        this.props.actions.gotoMyCards();
    }

    render() {
        let {installmentStausPageInfo} = this.props.installment;
        return (
            <AccountPageLineCell
                title={"我的银行卡"}
                onPress={this._onPressMyCard}
            />
        );
    }
}
let styles = StyleSheet.create({
    container: {
        flex: 1,
    },

});

export default connect(mapStateToProps, mapDispatchToProps)(InstallmentAccountContainer);