|
|
|
@ -30,7 +30,13 @@ class Bankcardnumberverification extends Component {
|
|
|
|
|
window.document.title = '竞赛';
|
|
|
|
|
// console.log("3获取用户信息");
|
|
|
|
|
// console.log(this.props)
|
|
|
|
|
this.props.triggerRef(this);
|
|
|
|
|
try {
|
|
|
|
|
this.props.triggerRef(this);
|
|
|
|
|
}catch (e) {
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
console.log(this.props.bank_account);
|
|
|
|
|
|
|
|
|
|
//初始化值
|
|
|
|
|
if (this.props.bank_account) {
|
|
|
|
|
this.props.form.setFieldsValue({
|
|
|
|
@ -38,6 +44,11 @@ class Bankcardnumberverification extends Component {
|
|
|
|
|
subbranch: this.props.bank_account.second_bank,
|
|
|
|
|
subbranchs: this.props.bank_account.card_no,
|
|
|
|
|
})
|
|
|
|
|
this.setState({
|
|
|
|
|
openingbank: this.props.bank_account.bank,
|
|
|
|
|
subbranch: this.props.bank_account.second_bank,
|
|
|
|
|
subbranchs: this.props.bank_account.card_no,
|
|
|
|
|
})
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
@ -50,6 +61,30 @@ class Bankcardnumberverification extends Component {
|
|
|
|
|
})
|
|
|
|
|
}
|
|
|
|
|
componentDidUpdate = (prevProps) => {
|
|
|
|
|
if (prevProps.bank_account != this.props.bank_account) {
|
|
|
|
|
console.log("componentDidUpdate");
|
|
|
|
|
console.log(this.props);//是新数据
|
|
|
|
|
console.log(prevProps);//是老数据
|
|
|
|
|
////console.log("Registration");
|
|
|
|
|
////console.log("componentDidUpdate");
|
|
|
|
|
////console.log(this.props.user.admin);
|
|
|
|
|
try {
|
|
|
|
|
if(this.props.bank_account){
|
|
|
|
|
this.props.form.setFieldsValue({
|
|
|
|
|
openingbank: this.props.bank_account.bank,
|
|
|
|
|
subbranch: this.props.bank_account.second_bank,
|
|
|
|
|
subbranchs: this.props.bank_account.card_no,
|
|
|
|
|
})
|
|
|
|
|
}
|
|
|
|
|
this.setState({
|
|
|
|
|
openingbank: this.props.bank_account.bank,
|
|
|
|
|
subbranch: this.props.bank_account.second_bank,
|
|
|
|
|
subbranchs: this.props.bank_account.card_no,
|
|
|
|
|
})
|
|
|
|
|
}catch (e) {
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
yhBankstrue = () => {
|
|
|
|
@ -64,13 +99,25 @@ class Bankcardnumberverification extends Component {
|
|
|
|
|
})
|
|
|
|
|
.then((result) => {
|
|
|
|
|
try {
|
|
|
|
|
if (result.data.status == 0) {
|
|
|
|
|
// console.log(JSON.stringify(result));
|
|
|
|
|
this.props.form.setFieldsValue({
|
|
|
|
|
openingbank: values.openingbank,
|
|
|
|
|
subbranch: values.subbranch,
|
|
|
|
|
subbranchs: values.subbranchs,
|
|
|
|
|
})
|
|
|
|
|
if (result.data.status === 0) {
|
|
|
|
|
try {
|
|
|
|
|
// console.log(values.openingbank);
|
|
|
|
|
// console.log(values.subbranch);
|
|
|
|
|
// console.log(values.subbranchs);
|
|
|
|
|
this.props.form.setFieldsValue({
|
|
|
|
|
openingbank: values.openingbank,
|
|
|
|
|
subbranch: values.subbranch,
|
|
|
|
|
subbranchs: values.subbranchs,
|
|
|
|
|
});
|
|
|
|
|
this.setState({
|
|
|
|
|
openingbank: values.openingbank,
|
|
|
|
|
subbranch: values.subbranch,
|
|
|
|
|
subbranchs: values.subbranchs,
|
|
|
|
|
})
|
|
|
|
|
}catch (e) {
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
try {
|
|
|
|
|
this.props.showNotification(`提交成功,等待审核!`);
|
|
|
|
|
|
|
|
|
@ -103,24 +150,6 @@ class Bankcardnumberverification extends Component {
|
|
|
|
|
render() {
|
|
|
|
|
const {getFieldDecorator} = this.props.form;
|
|
|
|
|
const {updating, seconds, secondsFlag, basicInfo, phonebool, emailbool, certification, formationdata, bank_account_editable, leader, bank_account} = this.state
|
|
|
|
|
var bank="";
|
|
|
|
|
if(this.props.bank_account){
|
|
|
|
|
if(this.props.bank_account.bank){
|
|
|
|
|
bank=this.props.bank_account.bank;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
var second_bank ="";
|
|
|
|
|
if(this.props.bank_account){
|
|
|
|
|
if(this.props.bank_account.second_bank){
|
|
|
|
|
second_bank=this.props.bank_account.second_bank;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
var card_no="";
|
|
|
|
|
if(this.props.bank_account){
|
|
|
|
|
if(this.props.bank_account.card_no){
|
|
|
|
|
card_no=this.props.bank_account.card_no;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
return (
|
|
|
|
|
<div>
|
|
|
|
|
<div className="flexdirections mt36">
|
|
|
|
|