import React, { Component } from "react";

import Wallet from './Wallet';
import Budget from './Budget';
import Reconciliation from './Reconciliation';
import ElectronicReceipt from './ElectronicReceipt';
import {
  taskComBhAccountGetComBhAccountAmount
} from '../../../../services/api';

import { gup } from '../../../../utils/utils';

import { Tabs } from "antd";

const { TabPane } = Tabs;

export default class StepFive extends Component {
  constructor(props, context) {
    super(props, context);
    this.state = {
      // accountInfo: {},
      bankInfo: props.bankInfo,
      tab: gup('tab')
    };
  }
  componentWillMount() {
    // taskComBhAccountGetComBhAccountAmount().then(res => {
    //   this.setState({accountInfo: res.data});
    // });
  }
  componentDidMount() {

  }
  render() {
    // const { walletAccountNo } = this.state.accountInfo;
    return (
      <Tabs defaultActiveKey={this.state.tab || '1'}>
        <TabPane tab="企业发薪账户" key="1">
          <Wallet
            // accountInfo={this.state.accountInfo}
            bankInfo={this.props.bankInfo}
            updateBackInfo={this.props.reload.bind(this)}
          ></Wallet>
        </TabPane>
        <TabPane forceRender={true} tab="收支明细查询" key="2">
          <Budget
            bankInfo={this.props.bankInfo}
          // walletAccountNo={walletAccountNo}
          ></Budget>
        </TabPane>
      </Tabs>
    );
  }
}
