import React from 'react';
import { Input, Button, Form, Radio, Upload, Icon, DatePicker, Spin, message } from 'antd';
import moment from 'moment';
import './base.less';
import ajax from 'jquery/src/ajax/xhr.js'
import $ from 'jquery/src/ajax';
import ChangePw from './changePassword.jsx';
import ChangeMobile from './changeMobile.jsx';
const FormItem = Form.Item;
const RadioGroup = Radio.Group;
const { MonthPicker, RangePicker } = DatePicker
import weixin from '../../../../image/weixin-w.png';
import qq from '../../../../image/qq-w.png';
import weibo from '../../../../image/weibo-w.png';
import card1 from '../../../../image/idcard1.jpg';
import card2 from '../../../../image/idcard2.jpg';
function getBase64(img, callback) {
const reader = new FileReader();
reader.addEventListener('load', () => callback(reader.result));
reader.readAsDataURL(img);
};
function beforeUpload(file) {
const isJPG = file.type === 'image/jpeg';
if (!isJPG) {
message.error('You can only upload JPG file!');
}
const isLt2M = file.size / 1024 / 1024 < 2;
if (!isLt2M) {
message.error('Image must smaller than 2MB!');
}
return isJPG && isLt2M;
};
class Avatar extends React.Component {
constructor(props) {
super(props);
this.state = {
imageUrl: ''
}
}
handleChange(info) {
if (info.file.status === 'done') {
// Get this url from response in real world.
getBase64(info.file.originFileObj, imageUrl => this.setState({ imageUrl }));
this.props.urlData(info.file.response.data);
}
}
render() {
const imageUrl = this.state.imageUrl;
return (
您登录的账号
阿凡提号: {userData.number || undefined}
登录手机号: {userData.mobile || undefined}
认证状态: {userData.lvl == '1' ? 已认证 : 未认证 马上认证}
绑定账号 绑定后,可使用第三方账号直接登录阿凡提网
身份信息 提供正确的身份信息,有助于进行身份验证,提升信用形象
请上传清晰的个人身份证正反面原件照片/扫描件 (不能截图、图片内容要求完整 ),
//要求2M 以下的jpg、jpeg、gif、png格式的图片。该资料不会公开展示,仅作为审核材料使用。
//{
// this.state.oppositeIdUrl !== "" && this.state.oppositeIdUrl !== undefined && this.state.oppositeIdUrl !== null ?
//
{
// this.state.positiveIdUrl !== "" && this.state.positiveIdUrl !== undefined && this.state.positiveIdUrl !== null ?
//
示例
//